/**
 * Copyright 2025 Google LLC
 *
 * Licensed under the Apache License, Version 2.0 (the "License");
 * you may not use this file except in compliance with the License.
 * You may obtain a copy of the License at
 *
 *     http://www.apache.org/licenses/LICENSE-2.0
 *
 * Unless required by applicable law or agreed to in writing, software
 * distributed under the License is distributed on an "AS IS" BASIS,
 * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
 * See the License for the specific language governing permissions and
 * limitations under the License.
 */
import{a as nA,b as Ne,c as y7,d as Le,e as xh,f as _n}from"./chunk-EQDQRRRY.js";var SP=Le((Tge,kP)=>{"use strict";kP.exports=[{value:"#B0171F",name:"indian red"},{value:"#DC143C",css:!0,name:"crimson"},{value:"#FFB6C1",css:!0,name:"lightpink"},{value:"#FFAEB9",name:"lightpink 1"},{value:"#EEA2AD",name:"lightpink 2"},{value:"#CD8C95",name:"lightpink 3"},{value:"#8B5F65",name:"lightpink 4"},{value:"#FFC0CB",css:!0,name:"pink"},{value:"#FFB5C5",name:"pink 1"},{value:"#EEA9B8",name:"pink 2"},{value:"#CD919E",name:"pink 3"},{value:"#8B636C",name:"pink 4"},{value:"#DB7093",css:!0,name:"palevioletred"},{value:"#FF82AB",name:"palevioletred 1"},{value:"#EE799F",name:"palevioletred 2"},{value:"#CD6889",name:"palevioletred 3"},{value:"#8B475D",name:"palevioletred 4"},{value:"#FFF0F5",name:"lavenderblush 1"},{value:"#FFF0F5",css:!0,name:"lavenderblush"},{value:"#EEE0E5",name:"lavenderblush 2"},{value:"#CDC1C5",name:"lavenderblush 3"},{value:"#8B8386",name:"lavenderblush 4"},{value:"#FF3E96",name:"violetred 1"},{value:"#EE3A8C",name:"violetred 2"},{value:"#CD3278",name:"violetred 3"},{value:"#8B2252",name:"violetred 4"},{value:"#FF69B4",css:!0,name:"hotpink"},{value:"#FF6EB4",name:"hotpink 1"},{value:"#EE6AA7",name:"hotpink 2"},{value:"#CD6090",name:"hotpink 3"},{value:"#8B3A62",name:"hotpink 4"},{value:"#872657",name:"raspberry"},{value:"#FF1493",name:"deeppink 1"},{value:"#FF1493",css:!0,name:"deeppink"},{value:"#EE1289",name:"deeppink 2"},{value:"#CD1076",name:"deeppink 3"},{value:"#8B0A50",name:"deeppink 4"},{value:"#FF34B3",name:"maroon 1"},{value:"#EE30A7",name:"maroon 2"},{value:"#CD2990",name:"maroon 3"},{value:"#8B1C62",name:"maroon 4"},{value:"#C71585",css:!0,name:"mediumvioletred"},{value:"#D02090",name:"violetred"},{value:"#DA70D6",css:!0,name:"orchid"},{value:"#FF83FA",name:"orchid 1"},{value:"#EE7AE9",name:"orchid 2"},{value:"#CD69C9",name:"orchid 3"},{value:"#8B4789",name:"orchid 4"},{value:"#D8BFD8",css:!0,name:"thistle"},{value:"#FFE1FF",name:"thistle 1"},{value:"#EED2EE",name:"thistle 2"},{value:"#CDB5CD",name:"thistle 3"},{value:"#8B7B8B",name:"thistle 4"},{value:"#FFBBFF",name:"plum 1"},{value:"#EEAEEE",name:"plum 2"},{value:"#CD96CD",name:"plum 3"},{value:"#8B668B",name:"plum 4"},{value:"#DDA0DD",css:!0,name:"plum"},{value:"#EE82EE",css:!0,name:"violet"},{value:"#FF00FF",vga:!0,name:"magenta"},{value:"#FF00FF",vga:!0,css:!0,name:"fuchsia"},{value:"#EE00EE",name:"magenta 2"},{value:"#CD00CD",name:"magenta 3"},{value:"#8B008B",name:"magenta 4"},{value:"#8B008B",css:!0,name:"darkmagenta"},{value:"#800080",vga:!0,css:!0,name:"purple"},{value:"#BA55D3",css:!0,name:"mediumorchid"},{value:"#E066FF",name:"mediumorchid 1"},{value:"#D15FEE",name:"mediumorchid 2"},{value:"#B452CD",name:"mediumorchid 3"},{value:"#7A378B",name:"mediumorchid 4"},{value:"#9400D3",css:!0,name:"darkviolet"},{value:"#9932CC",css:!0,name:"darkorchid"},{value:"#BF3EFF",name:"darkorchid 1"},{value:"#B23AEE",name:"darkorchid 2"},{value:"#9A32CD",name:"darkorchid 3"},{value:"#68228B",name:"darkorchid 4"},{value:"#4B0082",css:!0,name:"indigo"},{value:"#8A2BE2",css:!0,name:"blueviolet"},{value:"#9B30FF",name:"purple 1"},{value:"#912CEE",name:"purple 2"},{value:"#7D26CD",name:"purple 3"},{value:"#551A8B",name:"purple 4"},{value:"#9370DB",css:!0,name:"mediumpurple"},{value:"#AB82FF",name:"mediumpurple 1"},{value:"#9F79EE",name:"mediumpurple 2"},{value:"#8968CD",name:"mediumpurple 3"},{value:"#5D478B",name:"mediumpurple 4"},{value:"#483D8B",css:!0,name:"darkslateblue"},{value:"#8470FF",name:"lightslateblue"},{value:"#7B68EE",css:!0,name:"mediumslateblue"},{value:"#6A5ACD",css:!0,name:"slateblue"},{value:"#836FFF",name:"slateblue 1"},{value:"#7A67EE",name:"slateblue 2"},{value:"#6959CD",name:"slateblue 3"},{value:"#473C8B",name:"slateblue 4"},{value:"#F8F8FF",css:!0,name:"ghostwhite"},{value:"#E6E6FA",css:!0,name:"lavender"},{value:"#0000FF",vga:!0,css:!0,name:"blue"},{value:"#0000EE",name:"blue 2"},{value:"#0000CD",name:"blue 3"},{value:"#0000CD",css:!0,name:"mediumblue"},{value:"#00008B",name:"blue 4"},{value:"#00008B",css:!0,name:"darkblue"},{value:"#000080",vga:!0,css:!0,name:"navy"},{value:"#191970",css:!0,name:"midnightblue"},{value:"#3D59AB",name:"cobalt"},{value:"#4169E1",css:!0,name:"royalblue"},{value:"#4876FF",name:"royalblue 1"},{value:"#436EEE",name:"royalblue 2"},{value:"#3A5FCD",name:"royalblue 3"},{value:"#27408B",name:"royalblue 4"},{value:"#6495ED",css:!0,name:"cornflowerblue"},{value:"#B0C4DE",css:!0,name:"lightsteelblue"},{value:"#CAE1FF",name:"lightsteelblue 1"},{value:"#BCD2EE",name:"lightsteelblue 2"},{value:"#A2B5CD",name:"lightsteelblue 3"},{value:"#6E7B8B",name:"lightsteelblue 4"},{value:"#778899",css:!0,name:"lightslategray"},{value:"#708090",css:!0,name:"slategray"},{value:"#C6E2FF",name:"slategray 1"},{value:"#B9D3EE",name:"slategray 2"},{value:"#9FB6CD",name:"slategray 3"},{value:"#6C7B8B",name:"slategray 4"},{value:"#1E90FF",name:"dodgerblue 1"},{value:"#1E90FF",css:!0,name:"dodgerblue"},{value:"#1C86EE",name:"dodgerblue 2"},{value:"#1874CD",name:"dodgerblue 3"},{value:"#104E8B",name:"dodgerblue 4"},{value:"#F0F8FF",css:!0,name:"aliceblue"},{value:"#4682B4",css:!0,name:"steelblue"},{value:"#63B8FF",name:"steelblue 1"},{value:"#5CACEE",name:"steelblue 2"},{value:"#4F94CD",name:"steelblue 3"},{value:"#36648B",name:"steelblue 4"},{value:"#87CEFA",css:!0,name:"lightskyblue"},{value:"#B0E2FF",name:"lightskyblue 1"},{value:"#A4D3EE",name:"lightskyblue 2"},{value:"#8DB6CD",name:"lightskyblue 3"},{value:"#607B8B",name:"lightskyblue 4"},{value:"#87CEFF",name:"skyblue 1"},{value:"#7EC0EE",name:"skyblue 2"},{value:"#6CA6CD",name:"skyblue 3"},{value:"#4A708B",name:"skyblue 4"},{value:"#87CEEB",css:!0,name:"skyblue"},{value:"#00BFFF",name:"deepskyblue 1"},{value:"#00BFFF",css:!0,name:"deepskyblue"},{value:"#00B2EE",name:"deepskyblue 2"},{value:"#009ACD",name:"deepskyblue 3"},{value:"#00688B",name:"deepskyblue 4"},{value:"#33A1C9",name:"peacock"},{value:"#ADD8E6",css:!0,name:"lightblue"},{value:"#BFEFFF",name:"lightblue 1"},{value:"#B2DFEE",name:"lightblue 2"},{value:"#9AC0CD",name:"lightblue 3"},{value:"#68838B",name:"lightblue 4"},{value:"#B0E0E6",css:!0,name:"powderblue"},{value:"#98F5FF",name:"cadetblue 1"},{value:"#8EE5EE",name:"cadetblue 2"},{value:"#7AC5CD",name:"cadetblue 3"},{value:"#53868B",name:"cadetblue 4"},{value:"#00F5FF",name:"turquoise 1"},{value:"#00E5EE",name:"turquoise 2"},{value:"#00C5CD",name:"turquoise 3"},{value:"#00868B",name:"turquoise 4"},{value:"#5F9EA0",css:!0,name:"cadetblue"},{value:"#00CED1",css:!0,name:"darkturquoise"},{value:"#F0FFFF",name:"azure 1"},{value:"#F0FFFF",css:!0,name:"azure"},{value:"#E0EEEE",name:"azure 2"},{value:"#C1CDCD",name:"azure 3"},{value:"#838B8B",name:"azure 4"},{value:"#E0FFFF",name:"lightcyan 1"},{value:"#E0FFFF",css:!0,name:"lightcyan"},{value:"#D1EEEE",name:"lightcyan 2"},{value:"#B4CDCD",name:"lightcyan 3"},{value:"#7A8B8B",name:"lightcyan 4"},{value:"#BBFFFF",name:"paleturquoise 1"},{value:"#AEEEEE",name:"paleturquoise 2"},{value:"#AEEEEE",css:!0,name:"paleturquoise"},{value:"#96CDCD",name:"paleturquoise 3"},{value:"#668B8B",name:"paleturquoise 4"},{value:"#2F4F4F",css:!0,name:"darkslategray"},{value:"#97FFFF",name:"darkslategray 1"},{value:"#8DEEEE",name:"darkslategray 2"},{value:"#79CDCD",name:"darkslategray 3"},{value:"#528B8B",name:"darkslategray 4"},{value:"#00FFFF",name:"cyan"},{value:"#00FFFF",css:!0,name:"aqua"},{value:"#00EEEE",name:"cyan 2"},{value:"#00CDCD",name:"cyan 3"},{value:"#008B8B",name:"cyan 4"},{value:"#008B8B",css:!0,name:"darkcyan"},{value:"#008080",vga:!0,css:!0,name:"teal"},{value:"#48D1CC",css:!0,name:"mediumturquoise"},{value:"#20B2AA",css:!0,name:"lightseagreen"},{value:"#03A89E",name:"manganeseblue"},{value:"#40E0D0",css:!0,name:"turquoise"},{value:"#808A87",name:"coldgrey"},{value:"#00C78C",name:"turquoiseblue"},{value:"#7FFFD4",name:"aquamarine 1"},{value:"#7FFFD4",css:!0,name:"aquamarine"},{value:"#76EEC6",name:"aquamarine 2"},{value:"#66CDAA",name:"aquamarine 3"},{value:"#66CDAA",css:!0,name:"mediumaquamarine"},{value:"#458B74",name:"aquamarine 4"},{value:"#00FA9A",css:!0,name:"mediumspringgreen"},{value:"#F5FFFA",css:!0,name:"mintcream"},{value:"#00FF7F",css:!0,name:"springgreen"},{value:"#00EE76",name:"springgreen 1"},{value:"#00CD66",name:"springgreen 2"},{value:"#008B45",name:"springgreen 3"},{value:"#3CB371",css:!0,name:"mediumseagreen"},{value:"#54FF9F",name:"seagreen 1"},{value:"#4EEE94",name:"seagreen 2"},{value:"#43CD80",name:"seagreen 3"},{value:"#2E8B57",name:"seagreen 4"},{value:"#2E8B57",css:!0,name:"seagreen"},{value:"#00C957",name:"emeraldgreen"},{value:"#BDFCC9",name:"mint"},{value:"#3D9140",name:"cobaltgreen"},{value:"#F0FFF0",name:"honeydew 1"},{value:"#F0FFF0",css:!0,name:"honeydew"},{value:"#E0EEE0",name:"honeydew 2"},{value:"#C1CDC1",name:"honeydew 3"},{value:"#838B83",name:"honeydew 4"},{value:"#8FBC8F",css:!0,name:"darkseagreen"},{value:"#C1FFC1",name:"darkseagreen 1"},{value:"#B4EEB4",name:"darkseagreen 2"},{value:"#9BCD9B",name:"darkseagreen 3"},{value:"#698B69",name:"darkseagreen 4"},{value:"#98FB98",css:!0,name:"palegreen"},{value:"#9AFF9A",name:"palegreen 1"},{value:"#90EE90",name:"palegreen 2"},{value:"#90EE90",css:!0,name:"lightgreen"},{value:"#7CCD7C",name:"palegreen 3"},{value:"#548B54",name:"palegreen 4"},{value:"#32CD32",css:!0,name:"limegreen"},{value:"#228B22",css:!0,name:"forestgreen"},{value:"#00FF00",vga:!0,name:"green 1"},{value:"#00FF00",vga:!0,css:!0,name:"lime"},{value:"#00EE00",name:"green 2"},{value:"#00CD00",name:"green 3"},{value:"#008B00",name:"green 4"},{value:"#008000",vga:!0,css:!0,name:"green"},{value:"#006400",css:!0,name:"darkgreen"},{value:"#308014",name:"sapgreen"},{value:"#7CFC00",css:!0,name:"lawngreen"},{value:"#7FFF00",name:"chartreuse 1"},{value:"#7FFF00",css:!0,name:"chartreuse"},{value:"#76EE00",name:"chartreuse 2"},{value:"#66CD00",name:"chartreuse 3"},{value:"#458B00",name:"chartreuse 4"},{value:"#ADFF2F",css:!0,name:"greenyellow"},{value:"#CAFF70",name:"darkolivegreen 1"},{value:"#BCEE68",name:"darkolivegreen 2"},{value:"#A2CD5A",name:"darkolivegreen 3"},{value:"#6E8B3D",name:"darkolivegreen 4"},{value:"#556B2F",css:!0,name:"darkolivegreen"},{value:"#6B8E23",css:!0,name:"olivedrab"},{value:"#C0FF3E",name:"olivedrab 1"},{value:"#B3EE3A",name:"olivedrab 2"},{value:"#9ACD32",name:"olivedrab 3"},{value:"#9ACD32",css:!0,name:"yellowgreen"},{value:"#698B22",name:"olivedrab 4"},{value:"#FFFFF0",name:"ivory 1"},{value:"#FFFFF0",css:!0,name:"ivory"},{value:"#EEEEE0",name:"ivory 2"},{value:"#CDCDC1",name:"ivory 3"},{value:"#8B8B83",name:"ivory 4"},{value:"#F5F5DC",css:!0,name:"beige"},{value:"#FFFFE0",name:"lightyellow 1"},{value:"#FFFFE0",css:!0,name:"lightyellow"},{value:"#EEEED1",name:"lightyellow 2"},{value:"#CDCDB4",name:"lightyellow 3"},{value:"#8B8B7A",name:"lightyellow 4"},{value:"#FAFAD2",css:!0,name:"lightgoldenrodyellow"},{value:"#FFFF00",vga:!0,name:"yellow 1"},{value:"#FFFF00",vga:!0,css:!0,name:"yellow"},{value:"#EEEE00",name:"yellow 2"},{value:"#CDCD00",name:"yellow 3"},{value:"#8B8B00",name:"yellow 4"},{value:"#808069",name:"warmgrey"},{value:"#808000",vga:!0,css:!0,name:"olive"},{value:"#BDB76B",css:!0,name:"darkkhaki"},{value:"#FFF68F",name:"khaki 1"},{value:"#EEE685",name:"khaki 2"},{value:"#CDC673",name:"khaki 3"},{value:"#8B864E",name:"khaki 4"},{value:"#F0E68C",css:!0,name:"khaki"},{value:"#EEE8AA",css:!0,name:"palegoldenrod"},{value:"#FFFACD",name:"lemonchiffon 1"},{value:"#FFFACD",css:!0,name:"lemonchiffon"},{value:"#EEE9BF",name:"lemonchiffon 2"},{value:"#CDC9A5",name:"lemonchiffon 3"},{value:"#8B8970",name:"lemonchiffon 4"},{value:"#FFEC8B",name:"lightgoldenrod 1"},{value:"#EEDC82",name:"lightgoldenrod 2"},{value:"#CDBE70",name:"lightgoldenrod 3"},{value:"#8B814C",name:"lightgoldenrod 4"},{value:"#E3CF57",name:"banana"},{value:"#FFD700",name:"gold 1"},{value:"#FFD700",css:!0,name:"gold"},{value:"#EEC900",name:"gold 2"},{value:"#CDAD00",name:"gold 3"},{value:"#8B7500",name:"gold 4"},{value:"#FFF8DC",name:"cornsilk 1"},{value:"#FFF8DC",css:!0,name:"cornsilk"},{value:"#EEE8CD",name:"cornsilk 2"},{value:"#CDC8B1",name:"cornsilk 3"},{value:"#8B8878",name:"cornsilk 4"},{value:"#DAA520",css:!0,name:"goldenrod"},{value:"#FFC125",name:"goldenrod 1"},{value:"#EEB422",name:"goldenrod 2"},{value:"#CD9B1D",name:"goldenrod 3"},{value:"#8B6914",name:"goldenrod 4"},{value:"#B8860B",css:!0,name:"darkgoldenrod"},{value:"#FFB90F",name:"darkgoldenrod 1"},{value:"#EEAD0E",name:"darkgoldenrod 2"},{value:"#CD950C",name:"darkgoldenrod 3"},{value:"#8B6508",name:"darkgoldenrod 4"},{value:"#FFA500",name:"orange 1"},{value:"#FF8000",css:!0,name:"orange"},{value:"#EE9A00",name:"orange 2"},{value:"#CD8500",name:"orange 3"},{value:"#8B5A00",name:"orange 4"},{value:"#FFFAF0",css:!0,name:"floralwhite"},{value:"#FDF5E6",css:!0,name:"oldlace"},{value:"#F5DEB3",css:!0,name:"wheat"},{value:"#FFE7BA",name:"wheat 1"},{value:"#EED8AE",name:"wheat 2"},{value:"#CDBA96",name:"wheat 3"},{value:"#8B7E66",name:"wheat 4"},{value:"#FFE4B5",css:!0,name:"moccasin"},{value:"#FFEFD5",css:!0,name:"papayawhip"},{value:"#FFEBCD",css:!0,name:"blanchedalmond"},{value:"#FFDEAD",name:"navajowhite 1"},{value:"#FFDEAD",css:!0,name:"navajowhite"},{value:"#EECFA1",name:"navajowhite 2"},{value:"#CDB38B",name:"navajowhite 3"},{value:"#8B795E",name:"navajowhite 4"},{value:"#FCE6C9",name:"eggshell"},{value:"#D2B48C",css:!0,name:"tan"},{value:"#9C661F",name:"brick"},{value:"#FF9912",name:"cadmiumyellow"},{value:"#FAEBD7",css:!0,name:"antiquewhite"},{value:"#FFEFDB",name:"antiquewhite 1"},{value:"#EEDFCC",name:"antiquewhite 2"},{value:"#CDC0B0",name:"antiquewhite 3"},{value:"#8B8378",name:"antiquewhite 4"},{value:"#DEB887",css:!0,name:"burlywood"},{value:"#FFD39B",name:"burlywood 1"},{value:"#EEC591",name:"burlywood 2"},{value:"#CDAA7D",name:"burlywood 3"},{value:"#8B7355",name:"burlywood 4"},{value:"#FFE4C4",name:"bisque 1"},{value:"#FFE4C4",css:!0,name:"bisque"},{value:"#EED5B7",name:"bisque 2"},{value:"#CDB79E",name:"bisque 3"},{value:"#8B7D6B",name:"bisque 4"},{value:"#E3A869",name:"melon"},{value:"#ED9121",name:"carrot"},{value:"#FF8C00",css:!0,name:"darkorange"},{value:"#FF7F00",name:"darkorange 1"},{value:"#EE7600",name:"darkorange 2"},{value:"#CD6600",name:"darkorange 3"},{value:"#8B4500",name:"darkorange 4"},{value:"#FFA54F",name:"tan 1"},{value:"#EE9A49",name:"tan 2"},{value:"#CD853F",name:"tan 3"},{value:"#CD853F",css:!0,name:"peru"},{value:"#8B5A2B",name:"tan 4"},{value:"#FAF0E6",css:!0,name:"linen"},{value:"#FFDAB9",name:"peachpuff 1"},{value:"#FFDAB9",css:!0,name:"peachpuff"},{value:"#EECBAD",name:"peachpuff 2"},{value:"#CDAF95",name:"peachpuff 3"},{value:"#8B7765",name:"peachpuff 4"},{value:"#FFF5EE",name:"seashell 1"},{value:"#FFF5EE",css:!0,name:"seashell"},{value:"#EEE5DE",name:"seashell 2"},{value:"#CDC5BF",name:"seashell 3"},{value:"#8B8682",name:"seashell 4"},{value:"#F4A460",css:!0,name:"sandybrown"},{value:"#C76114",name:"rawsienna"},{value:"#D2691E",css:!0,name:"chocolate"},{value:"#FF7F24",name:"chocolate 1"},{value:"#EE7621",name:"chocolate 2"},{value:"#CD661D",name:"chocolate 3"},{value:"#8B4513",name:"chocolate 4"},{value:"#8B4513",css:!0,name:"saddlebrown"},{value:"#292421",name:"ivoryblack"},{value:"#FF7D40",name:"flesh"},{value:"#FF6103",name:"cadmiumorange"},{value:"#8A360F",name:"burntsienna"},{value:"#A0522D",css:!0,name:"sienna"},{value:"#FF8247",name:"sienna 1"},{value:"#EE7942",name:"sienna 2"},{value:"#CD6839",name:"sienna 3"},{value:"#8B4726",name:"sienna 4"},{value:"#FFA07A",name:"lightsalmon 1"},{value:"#FFA07A",css:!0,name:"lightsalmon"},{value:"#EE9572",name:"lightsalmon 2"},{value:"#CD8162",name:"lightsalmon 3"},{value:"#8B5742",name:"lightsalmon 4"},{value:"#FF7F50",css:!0,name:"coral"},{value:"#FF4500",name:"orangered 1"},{value:"#FF4500",css:!0,name:"orangered"},{value:"#EE4000",name:"orangered 2"},{value:"#CD3700",name:"orangered 3"},{value:"#8B2500",name:"orangered 4"},{value:"#5E2612",name:"sepia"},{value:"#E9967A",css:!0,name:"darksalmon"},{value:"#FF8C69",name:"salmon 1"},{value:"#EE8262",name:"salmon 2"},{value:"#CD7054",name:"salmon 3"},{value:"#8B4C39",name:"salmon 4"},{value:"#FF7256",name:"coral 1"},{value:"#EE6A50",name:"coral 2"},{value:"#CD5B45",name:"coral 3"},{value:"#8B3E2F",name:"coral 4"},{value:"#8A3324",name:"burntumber"},{value:"#FF6347",name:"tomato 1"},{value:"#FF6347",css:!0,name:"tomato"},{value:"#EE5C42",name:"tomato 2"},{value:"#CD4F39",name:"tomato 3"},{value:"#8B3626",name:"tomato 4"},{value:"#FA8072",css:!0,name:"salmon"},{value:"#FFE4E1",name:"mistyrose 1"},{value:"#FFE4E1",css:!0,name:"mistyrose"},{value:"#EED5D2",name:"mistyrose 2"},{value:"#CDB7B5",name:"mistyrose 3"},{value:"#8B7D7B",name:"mistyrose 4"},{value:"#FFFAFA",name:"snow 1"},{value:"#FFFAFA",css:!0,name:"snow"},{value:"#EEE9E9",name:"snow 2"},{value:"#CDC9C9",name:"snow 3"},{value:"#8B8989",name:"snow 4"},{value:"#BC8F8F",css:!0,name:"rosybrown"},{value:"#FFC1C1",name:"rosybrown 1"},{value:"#EEB4B4",name:"rosybrown 2"},{value:"#CD9B9B",name:"rosybrown 3"},{value:"#8B6969",name:"rosybrown 4"},{value:"#F08080",css:!0,name:"lightcoral"},{value:"#CD5C5C",css:!0,name:"indianred"},{value:"#FF6A6A",name:"indianred 1"},{value:"#EE6363",name:"indianred 2"},{value:"#8B3A3A",name:"indianred 4"},{value:"#CD5555",name:"indianred 3"},{value:"#A52A2A",css:!0,name:"brown"},{value:"#FF4040",name:"brown 1"},{value:"#EE3B3B",name:"brown 2"},{value:"#CD3333",name:"brown 3"},{value:"#8B2323",name:"brown 4"},{value:"#B22222",css:!0,name:"firebrick"},{value:"#FF3030",name:"firebrick 1"},{value:"#EE2C2C",name:"firebrick 2"},{value:"#CD2626",name:"firebrick 3"},{value:"#8B1A1A",name:"firebrick 4"},{value:"#FF0000",vga:!0,name:"red 1"},{value:"#FF0000",vga:!0,css:!0,name:"red"},{value:"#EE0000",name:"red 2"},{value:"#CD0000",name:"red 3"},{value:"#8B0000",name:"red 4"},{value:"#8B0000",css:!0,name:"darkred"},{value:"#800000",vga:!0,css:!0,name:"maroon"},{value:"#8E388E",name:"sgi beet"},{value:"#7171C6",name:"sgi slateblue"},{value:"#7D9EC0",name:"sgi lightblue"},{value:"#388E8E",name:"sgi teal"},{value:"#71C671",name:"sgi chartreuse"},{value:"#8E8E38",name:"sgi olivedrab"},{value:"#C5C1AA",name:"sgi brightgray"},{value:"#C67171",name:"sgi salmon"},{value:"#555555",name:"sgi darkgray"},{value:"#1E1E1E",name:"sgi gray 12"},{value:"#282828",name:"sgi gray 16"},{value:"#515151",name:"sgi gray 32"},{value:"#5B5B5B",name:"sgi gray 36"},{value:"#848484",name:"sgi gray 52"},{value:"#8E8E8E",name:"sgi gray 56"},{value:"#AAAAAA",name:"sgi lightgray"},{value:"#B7B7B7",name:"sgi gray 72"},{value:"#C1C1C1",name:"sgi gray 76"},{value:"#EAEAEA",name:"sgi gray 92"},{value:"#F4F4F4",name:"sgi gray 96"},{value:"#FFFFFF",vga:!0,css:!0,name:"white"},{value:"#F5F5F5",name:"white smoke"},{value:"#F5F5F5",name:"gray 96"},{value:"#DCDCDC",css:!0,name:"gainsboro"},{value:"#D3D3D3",css:!0,name:"lightgrey"},{value:"#C0C0C0",vga:!0,css:!0,name:"silver"},{value:"#A9A9A9",css:!0,name:"darkgray"},{value:"#808080",vga:!0,css:!0,name:"gray"},{value:"#696969",css:!0,name:"dimgray"},{value:"#696969",name:"gray 42"},{value:"#000000",vga:!0,css:!0,name:"black"},{value:"#FCFCFC",name:"gray 99"},{value:"#FAFAFA",name:"gray 98"},{value:"#F7F7F7",name:"gray 97"},{value:"#F2F2F2",name:"gray 95"},{value:"#F0F0F0",name:"gray 94"},{value:"#EDEDED",name:"gray 93"},{value:"#EBEBEB",name:"gray 92"},{value:"#E8E8E8",name:"gray 91"},{value:"#E5E5E5",name:"gray 90"},{value:"#E3E3E3",name:"gray 89"},{value:"#E0E0E0",name:"gray 88"},{value:"#DEDEDE",name:"gray 87"},{value:"#DBDBDB",name:"gray 86"},{value:"#D9D9D9",name:"gray 85"},{value:"#D6D6D6",name:"gray 84"},{value:"#D4D4D4",name:"gray 83"},{value:"#D1D1D1",name:"gray 82"},{value:"#CFCFCF",name:"gray 81"},{value:"#CCCCCC",name:"gray 80"},{value:"#C9C9C9",name:"gray 79"},{value:"#C7C7C7",name:"gray 78"},{value:"#C4C4C4",name:"gray 77"},{value:"#C2C2C2",name:"gray 76"},{value:"#BFBFBF",name:"gray 75"},{value:"#BDBDBD",name:"gray 74"},{value:"#BABABA",name:"gray 73"},{value:"#B8B8B8",name:"gray 72"},{value:"#B5B5B5",name:"gray 71"},{value:"#B3B3B3",name:"gray 70"},{value:"#B0B0B0",name:"gray 69"},{value:"#ADADAD",name:"gray 68"},{value:"#ABABAB",name:"gray 67"},{value:"#A8A8A8",name:"gray 66"},{value:"#A6A6A6",name:"gray 65"},{value:"#A3A3A3",name:"gray 64"},{value:"#A1A1A1",name:"gray 63"},{value:"#9E9E9E",name:"gray 62"},{value:"#9C9C9C",name:"gray 61"},{value:"#999999",name:"gray 60"},{value:"#969696",name:"gray 59"},{value:"#949494",name:"gray 58"},{value:"#919191",name:"gray 57"},{value:"#8F8F8F",name:"gray 56"},{value:"#8C8C8C",name:"gray 55"},{value:"#8A8A8A",name:"gray 54"},{value:"#878787",name:"gray 53"},{value:"#858585",name:"gray 52"},{value:"#828282",name:"gray 51"},{value:"#7F7F7F",name:"gray 50"},{value:"#7D7D7D",name:"gray 49"},{value:"#7A7A7A",name:"gray 48"},{value:"#787878",name:"gray 47"},{value:"#757575",name:"gray 46"},{value:"#737373",name:"gray 45"},{value:"#707070",name:"gray 44"},{value:"#6E6E6E",name:"gray 43"},{value:"#666666",name:"gray 40"},{value:"#636363",name:"gray 39"},{value:"#616161",name:"gray 38"},{value:"#5E5E5E",name:"gray 37"},{value:"#5C5C5C",name:"gray 36"},{value:"#595959",name:"gray 35"},{value:"#575757",name:"gray 34"},{value:"#545454",name:"gray 33"},{value:"#525252",name:"gray 32"},{value:"#4F4F4F",name:"gray 31"},{value:"#4D4D4D",name:"gray 30"},{value:"#4A4A4A",name:"gray 29"},{value:"#474747",name:"gray 28"},{value:"#454545",name:"gray 27"},{value:"#424242",name:"gray 26"},{value:"#404040",name:"gray 25"},{value:"#3D3D3D",name:"gray 24"},{value:"#3B3B3B",name:"gray 23"},{value:"#383838",name:"gray 22"},{value:"#363636",name:"gray 21"},{value:"#333333",name:"gray 20"},{value:"#303030",name:"gray 19"},{value:"#2E2E2E",name:"gray 18"},{value:"#2B2B2B",name:"gray 17"},{value:"#292929",name:"gray 16"},{value:"#262626",name:"gray 15"},{value:"#242424",name:"gray 14"},{value:"#212121",name:"gray 13"},{value:"#1F1F1F",name:"gray 12"},{value:"#1C1C1C",name:"gray 11"},{value:"#1A1A1A",name:"gray 10"},{value:"#171717",name:"gray 9"},{value:"#141414",name:"gray 8"},{value:"#121212",name:"gray 7"},{value:"#0F0F0F",name:"gray 6"},{value:"#0D0D0D",name:"gray 5"},{value:"#0A0A0A",name:"gray 4"},{value:"#080808",name:"gray 3"},{value:"#050505",name:"gray 2"},{value:"#030303",name:"gray 1"},{value:"#F5F5F5",css:!0,name:"whitesmoke"}]});var xP=Le((zge,U2)=>{"use strict";var g8=SP(),RP=g8.filter(function(t){return!!t.css}),LP=g8.filter(function(t){return!!t.vga});U2.exports=function(t){var e=U2.exports.get(t);return e&&e.value};U2.exports.get=function(t){return t=t||"",t=t.trim().toLowerCase(),g8.filter(function(e){return e.name.toLowerCase()===t}).pop()};U2.exports.all=U2.exports.get.all=function(){return g8};U2.exports.get.css=function(t){return t?(t=t||"",t=t.trim().toLowerCase(),RP.filter(function(e){return e.name.toLowerCase()===t}).pop()):RP};U2.exports.get.vga=function(t){return t?(t=t||"",t=t.trim().toLowerCase(),LP.filter(function(e){return e.name.toLowerCase()===t}).pop()):LP}});var ej=Le((Hge,Aj)=>{"use strict";var $4A=1/0,A3A="[object Symbol]",e3A=/[^\x00-\x2f\x3a-\x40\x5b-\x60\x7b-\x7f]+/g,JP="\\ud800-\\udfff",t3A="\\u0300-\\u036f\\ufe20-\\ufe23",i3A="\\u20d0-\\u20f0",TP="\\u2700-\\u27bf",zP="a-z\\xdf-\\xf6\\xf8-\\xff",n3A="\\xac\\xb1\\xd7\\xf7",o3A="\\x00-\\x2f\\x3a-\\x40\\x5b-\\x60\\x7b-\\xbf",r3A="\\u2000-\\u206f",s3A=" \\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",HP="A-Z\\xc0-\\xd6\\xd8-\\xde",a3A="\\ufe0e\\ufe0f",OP=n3A+o3A+r3A+s3A,PP="['\u2019]",FP="["+OP+"]",c3A="["+t3A+i3A+"]",jP="\\d+",l3A="["+TP+"]",qP="["+zP+"]",VP="[^"+JP+OP+jP+TP+zP+HP+"]",g3A="\\ud83c[\\udffb-\\udfff]",I3A="(?:"+c3A+"|"+g3A+")",C3A="[^"+JP+"]",ZP="(?:\\ud83c[\\udde6-\\uddff]){2}",WP="[\\ud800-\\udbff][\\udc00-\\udfff]",yB="["+HP+"]",d3A="\\u200d",NP="(?:"+qP+"|"+VP+")",B3A="(?:"+yB+"|"+VP+")",_P="(?:"+PP+"(?:d|ll|m|re|s|t|ve))?",GP="(?:"+PP+"(?:D|LL|M|RE|S|T|VE))?",XP=I3A+"?",$P="["+a3A+"]?",E3A="(?:"+d3A+"(?:"+[C3A,ZP,WP].join("|")+")"+$P+XP+")*",h3A=$P+XP+E3A,Q3A="(?:"+[l3A,ZP,WP].join("|")+")"+h3A,u3A=RegExp([yB+"?"+qP+"+"+_P+"(?="+[FP,yB,"$"].join("|")+")",B3A+"+"+GP+"(?="+[FP,yB+NP,"$"].join("|")+")",yB+"?"+NP+"+"+_P,yB+"+"+GP,jP,Q3A].join("|"),"g"),f3A=/[a-z][A-Z]|[A-Z]{2,}[a-z]|[0-9][a-zA-Z]|[a-zA-Z][0-9]|[^a-zA-Z0-9 ]/,m3A=typeof global=="object"&&global&&global.Object===Object&&global,p3A=typeof self=="object"&&self&&self.Object===Object&&self,w3A=m3A||p3A||Function("return this")();function D3A(t){return t.match(e3A)||[]}function y3A(t){return f3A.test(t)}function v3A(t){return t.match(u3A)||[]}var b3A=Object.prototype,M3A=b3A.toString,UP=w3A.Symbol,KP=UP?UP.prototype:void 0,YP=KP?KP.toString:void 0;function k3A(t){if(typeof t=="string")return t;if(R3A(t))return YP?YP.call(t):"";var e=t+"";return e=="0"&&1/t==-$4A?"-0":e}function S3A(t){return!!t&&typeof t=="object"}function R3A(t){return typeof t=="symbol"||S3A(t)&&M3A.call(t)==A3A}function L3A(t){return t==null?"":k3A(t)}function x3A(t,e,A){return t=L3A(t),e=A?void 0:e,e===void 0?y3A(t)?v3A(t):D3A(t):t.match(e)||[]}Aj.exports=x3A});var hj=Le((Oge,Ej)=>{"use strict";var F3A=1/0,N3A="[object Symbol]",_3A=/^\s+/,Fk="\\ud800-\\udfff",rj="\\u0300-\\u036f\\ufe20-\\ufe23",sj="\\u20d0-\\u20f0",aj="\\ufe0e\\ufe0f",G3A="["+Fk+"]",Lk="["+rj+sj+"]",xk="\\ud83c[\\udffb-\\udfff]",U3A="(?:"+Lk+"|"+xk+")",cj="[^"+Fk+"]",lj="(?:\\ud83c[\\udde6-\\uddff]){2}",gj="[\\ud800-\\udbff][\\udc00-\\udfff]",Ij="\\u200d",Cj=U3A+"?",dj="["+aj+"]?",K3A="(?:"+Ij+"(?:"+[cj,lj,gj].join("|")+")"+dj+Cj+")*",Y3A=dj+Cj+K3A,J3A="(?:"+[cj+Lk+"?",Lk,lj,gj,G3A].join("|")+")",T3A=RegExp(xk+"(?="+xk+")|"+J3A+Y3A,"g"),z3A=RegExp("["+Ij+Fk+rj+sj+aj+"]"),H3A=typeof global=="object"&&global&&global.Object===Object&&global,O3A=typeof self=="object"&&self&&self.Object===Object&&self,P3A=H3A||O3A||Function("return this")();function j3A(t){return t.split("")}function q3A(t,e,A,i){for(var n=t.length,o=A+(i?1:-1);i?o--:++o<n;)if(e(t[o],o,t))return o;return-1}function V3A(t,e,A){if(e!==e)return q3A(t,Z3A,A);for(var i=A-1,n=t.length;++i<n;)if(t[i]===e)return i;return-1}function Z3A(t){return t!==t}function W3A(t,e){for(var A=-1,i=t.length;++A<i&&V3A(e,t[A],0)>-1;);return A}function X3A(t){return z3A.test(t)}function tj(t){return X3A(t)?$3A(t):j3A(t)}function $3A(t){return t.match(T3A)||[]}var AfA=Object.prototype,efA=AfA.toString,ij=P3A.Symbol,nj=ij?ij.prototype:void 0,oj=nj?nj.toString:void 0;function tfA(t,e,A){var i=-1,n=t.length;e<0&&(e=-e>n?0:n+e),A=A>n?n:A,A<0&&(A+=n),n=e>A?0:A-e>>>0,e>>>=0;for(var o=Array(n);++i<n;)o[i]=t[i+e];return o}function Bj(t){if(typeof t=="string")return t;if(ofA(t))return oj?oj.call(t):"";var e=t+"";return e=="0"&&1/t==-F3A?"-0":e}function ifA(t,e,A){var i=t.length;return A=A===void 0?i:A,!e&&A>=i?t:tfA(t,e,A)}function nfA(t){return!!t&&typeof t=="object"}function ofA(t){return typeof t=="symbol"||nfA(t)&&efA.call(t)==N3A}function rfA(t){return t==null?"":Bj(t)}function sfA(t,e,A){if(t=rfA(t),t&&(A||e===void 0))return t.replace(_3A,"");if(!t||!(e=Bj(e)))return t;var i=tj(t),n=W3A(i,tj(e));return ifA(i,n).join("")}Ej.exports=sfA});var Gj=Le((Pge,_j)=>{"use strict";var Nk=1/0,afA=9007199254740991,cfA=17976931348623157e292,Qj=NaN,lfA="[object Symbol]",gfA=/^\s+|\s+$/g,IfA=/^[-+]0x[0-9a-f]+$/i,CfA=/^0b[01]+$/i,dfA=/^0o[0-7]+$/i,Kk="\\ud800-\\udfff",Dj="\\u0300-\\u036f\\ufe20-\\ufe23",yj="\\u20d0-\\u20f0",vj="\\ufe0e\\ufe0f",BfA="["+Kk+"]",_k="["+Dj+yj+"]",Gk="\\ud83c[\\udffb-\\udfff]",EfA="(?:"+_k+"|"+Gk+")",bj="[^"+Kk+"]",Mj="(?:\\ud83c[\\udde6-\\uddff]){2}",kj="[\\ud800-\\udbff][\\udc00-\\udfff]",Sj="\\u200d",Rj=EfA+"?",Lj="["+vj+"]?",hfA="(?:"+Sj+"(?:"+[bj,Mj,kj].join("|")+")"+Lj+Rj+")*",QfA=Lj+Rj+hfA,ufA="(?:"+[bj+_k+"?",_k,Mj,kj,BfA].join("|")+")",Uk=RegExp(Gk+"(?="+Gk+")|"+ufA+QfA,"g"),ffA=RegExp("["+Sj+Kk+Dj+yj+vj+"]"),mfA=parseInt,pfA=typeof global=="object"&&global&&global.Object===Object&&global,wfA=typeof self=="object"&&self&&self.Object===Object&&self,DfA=pfA||wfA||Function("return this")(),yfA=bfA("length");function vfA(t){return t.split("")}function bfA(t){return function(e){return e?.[t]}}function Yk(t){return ffA.test(t)}function xj(t){return Yk(t)?kfA(t):yfA(t)}function MfA(t){return Yk(t)?SfA(t):vfA(t)}function kfA(t){for(var e=Uk.lastIndex=0;Uk.test(t);)e++;return e}function SfA(t){return t.match(Uk)||[]}var RfA=Object.prototype,LfA=RfA.toString,uj=DfA.Symbol,xfA=Math.ceil,FfA=Math.floor,fj=uj?uj.prototype:void 0,mj=fj?fj.toString:void 0;function pj(t,e){var A="";if(!t||e<1||e>afA)return A;do e%2&&(A+=t),e=FfA(e/2),e&&(t+=t);while(e);return A}function NfA(t,e,A){var i=-1,n=t.length;e<0&&(e=-e>n?0:n+e),A=A>n?n:A,A<0&&(A+=n),n=e>A?0:A-e>>>0,e>>>=0;for(var o=Array(n);++i<n;)o[i]=t[i+e];return o}function Fj(t){if(typeof t=="string")return t;if(Nj(t))return mj?mj.call(t):"";var e=t+"";return e=="0"&&1/t==-Nk?"-0":e}function _fA(t,e,A){var i=t.length;return A=A===void 0?i:A,!e&&A>=i?t:NfA(t,e,A)}function GfA(t,e){e=e===void 0?" ":Fj(e);var A=e.length;if(A<2)return A?pj(e,t):e;var i=pj(e,xfA(t/xj(e)));return Yk(e)?_fA(MfA(i),0,t).join(""):i.slice(0,t)}function wj(t){var e=typeof t;return!!t&&(e=="object"||e=="function")}function UfA(t){return!!t&&typeof t=="object"}function Nj(t){return typeof t=="symbol"||UfA(t)&&LfA.call(t)==lfA}function KfA(t){if(!t)return t===0?t:0;if(t=JfA(t),t===Nk||t===-Nk){var e=t<0?-1:1;return e*cfA}return t===t?t:0}function YfA(t){var e=KfA(t),A=e%1;return e===e?A?e-A:e:0}function JfA(t){if(typeof t=="number")return t;if(Nj(t))return Qj;if(wj(t)){var e=typeof t.valueOf=="function"?t.valueOf():t;t=wj(e)?e+"":e}if(typeof t!="string")return t===0?t:+t;t=t.replace(gfA,"");var A=CfA.test(t);return A||dfA.test(t)?mfA(t.slice(2),A?2:8):IfA.test(t)?Qj:+t}function TfA(t){return t==null?"":Fj(t)}function zfA(t,e,A){t=TfA(t),e=YfA(e);var i=e?xj(t):0;return e&&i<e?t+GfA(e-i,A):t}_j.exports=zfA});var Kj=Le((jge,Uj)=>{"use strict";Uj.exports=(t,e,A,i)=>{let n=(t+(i||"")).toString().includes("%");if(typeof t=="string"?[t,e,A,i]=t.match(/(0?\.?\d{1,3})%?\b/g).map(Number):i!==void 0&&(i=parseFloat(i)),typeof t!="number"||typeof e!="number"||typeof A!="number"||t>255||e>255||A>255)throw new TypeError("Expected three numbers below 256");if(typeof i=="number"){if(!n&&i>=0&&i<=1)i=Math.round(255*i);else if(n&&i>=0&&i<=100)i=Math.round(255*i/100);else throw new TypeError(`Expected alpha value (${i}) as a fraction or percentage`);i=(i|256).toString(16).slice(1)}else i="";return(A|e<<8|t<<16|1<<24).toString(16).slice(1)+i}});var Jj=Le((qge,Yj)=>{"use strict";var bu="a-f\\d",HfA=`#?[${bu}]{3}[${bu}]?`,OfA=`#?[${bu}]{6}([${bu}]{2})?`,PfA=new RegExp(`[^#${bu}]`,"gi"),jfA=new RegExp(`^${HfA}$|^${OfA}$`,"i");Yj.exports=(t,e={})=>{if(typeof t!="string"||PfA.test(t)||!jfA.test(t))throw new TypeError("Expected a valid hex string");t=t.replace(/^#/,"");let A=1;t.length===8&&(A=Number.parseInt(t.slice(6,8),16)/255,t=t.slice(0,6)),t.length===4&&(A=Number.parseInt(t.slice(3,4).repeat(2),16)/255,t=t.slice(0,3)),t.length===3&&(t=t[0]+t[0]+t[1]+t[1]+t[2]+t[2]);let i=Number.parseInt(t,16),n=i>>16,o=i>>8&255,r=i&255,s=typeof e.alpha=="number"?e.alpha:A;if(e.format==="array")return[n,o,r,s];if(e.format==="css"){let a=s===1?"":` / ${Number((s*100).toFixed(2))}%`;return`rgb(${n} ${o} ${r}${a})`}return{red:n,green:o,blue:r,alpha:s}}});var Hj=Le((Vge,zj)=>{"use strict";var qfA=xP(),VfA=ej(),ZfA=hj(),WfA=Gj(),XfA=Kj(),Tj=Jj(),Jk=.75,Tk=.25,zk=16777215,$fA=49979693;zj.exports=function(t){return"#"+tmA(String(JSON.stringify(t)))};function AmA(t){var e=VfA(t),A=[];return e.forEach(function(i){var n=qfA(i);n&&A.push(Tj(ZfA(n,"#"),{format:"array"}))}),A}function emA(t){var e=[0,0,0];return t.forEach(function(A){for(var i=0;i<3;i++)e[i]+=A[i]}),[e[0]/t.length,e[1]/t.length,e[2]/t.length]}function tmA(t){var e,A=AmA(t);A.length>0&&(e=emA(A));var i=1,n=0,o=1;if(t.length>0)for(var r=0;r<t.length;r++)t[r].charCodeAt(0)>n&&(n=t[r].charCodeAt(0)),o=parseInt(zk/n),i=(i+t[r].charCodeAt(0)*o*$fA)%zk;var s=(i*t.length%zk).toString(16);s=WfA(s,6,s);var a=Tj(s,{format:"array"});return e?XfA(Tk*a[0]+Jk*e[0],Tk*a[1]+Jk*e[1],Tk*a[2]+Jk*e[2]):s}});var Eq=Le(iS=>{"use strict";var Bq={b:"\b",f:"\f",n:`
`,r:"\r",t:"	",'"':'"',"/":"/","\\":"\\"},$mA=97;iS.parse=function(t,e,A){var i={},n=0,o=0,r=0,s=A&&A.bigint&&typeof BigInt<"u";return{data:a("",!0),pointers:i};function a(N,K){c();var H;L(N,"value");var j=E();switch(j){case"t":B("rue"),H=!0;break;case"f":B("alse"),H=!1;break;case"n":B("ull"),H=null;break;case'"':H=l();break;case"[":H=C(N);break;case"{":H=d(N);break;default:Q(),"-0123456789".indexOf(j)>=0?H=I():F()}return L(N,"valueEnd"),c(),K&&r<t.length&&F(),H}function c(){A:for(;r<t.length;){switch(t[r]){case" ":o++;break;case"	":o+=4;break;case"\r":o=0;break;case`
`:o=0,n++;break;default:break A}r++}}function l(){for(var N="",K;K=E(),K!='"';)K=="\\"?(K=E(),K in Bq?N+=Bq[K]:K=="u"?N+=u():U()):N+=K;return N}function I(){var N="",K=!0;t[r]=="-"&&(N+=E()),N+=t[r]=="0"?E():v(),t[r]=="."&&(N+=E()+v(),K=!1),(t[r]=="e"||t[r]=="E")&&(N+=E(),(t[r]=="+"||t[r]=="-")&&(N+=E()),N+=v(),K=!1);var H=+N;return s&&K&&(H>Number.MAX_SAFE_INTEGER||H<Number.MIN_SAFE_INTEGER)?BigInt(N):H}function C(N){c();var K=[],H=0;if(E()=="]")return K;for(Q();;){var j=N+"/"+H;K.push(a(j)),c();var IA=E();if(IA=="]")break;IA!=","&&U(),c(),H++}return K}function d(N){c();var K={};if(E()=="}")return K;for(Q();;){var H=y();E()!='"'&&U();var j=l(),IA=N+"/"+tS(j);x(IA,"key",H),L(IA,"keyEnd"),c(),E()!=":"&&U(),c(),K[j]=a(IA),c();var lA=E();if(lA=="}")break;lA!=","&&U(),c()}return K}function B(N){for(var K=0;K<N.length;K++)E()!==N[K]&&U()}function E(){T();var N=t[r];return r++,o++,N}function Q(){r--,o--}function u(){for(var N=4,K=0;N--;){K<<=4;var H=E().toLowerCase();H>="a"&&H<="f"?K+=H.charCodeAt()-$mA+10:H>="0"&&H<="9"?K+=+H:U()}return String.fromCharCode(K)}function v(){for(var N="";t[r]>="0"&&t[r]<="9";)N+=E();if(N.length)return N;T(),F()}function L(N,K){x(N,K,y())}function x(N,K,H){i[N]=i[N]||{},i[N][K]=H}function y(){return{line:n,column:o,pos:r}}function F(){throw new SyntaxError("Unexpected token "+t[r]+" in JSON at position "+r)}function U(){Q(),F()}function T(){if(r>=t.length)throw new SyntaxError("Unexpected end of JSON input")}};iS.stringify=function(t,e,A){if(!m8(t))return;var i=0,n,o,r=typeof A=="object"?A.space:A;switch(typeof r){case"number":var s=r>10?10:r<0?0:Math.floor(r);r=s&&x(s," "),n=s,o=s;break;case"string":r=r.slice(0,10),n=0,o=0;for(var a=0;a<r.length;a++){var c=r[a];switch(c){case" ":o++;break;case"	":o+=4;break;case"\r":o=0;break;case`
`:o=0,i++;break;default:throw new Error("whitespace characters not allowed in JSON")}n++}break;default:r=void 0}var l="",I={},C=0,d=0,B=0,E=A&&A.es6&&typeof Map=="function";return Q(t,0,""),{json:l,pointers:I};function Q(y,F,U){switch(L(U,"value"),typeof y){case"number":case"bigint":case"boolean":u(""+y);break;case"string":u(p8(y));break;case"object":y===null?u("null"):typeof y.toJSON=="function"?u(p8(y.toJSON())):Array.isArray(y)?T():E?y.constructor.BYTES_PER_ELEMENT?T():y instanceof Map?K():y instanceof Set?K(!0):N():N()}L(U,"valueEnd");function T(){if(y.length){u("[");for(var H=F+1,j=0;j<y.length;j++){j&&u(","),v(H);var IA=m8(y[j])?y[j]:null,lA=U+"/"+j;Q(IA,H,lA)}v(F),u("]")}else u("[]")}function N(){var H=Object.keys(y);if(H.length){u("{");for(var j=F+1,IA=0;IA<H.length;IA++){var lA=H[IA],uA=y[lA];if(m8(uA)){IA&&u(",");var p=U+"/"+tS(lA);v(j),L(p,"key"),u(p8(lA)),L(p,"keyEnd"),u(":"),r&&u(" "),Q(uA,j,p)}}v(F),u("}")}else u("{}")}function K(H){if(y.size){u("{");for(var j=F+1,IA=!0,lA=y.entries(),uA=lA.next();!uA.done;){var p=uA.value,V=p[0],cA=H?!0:p[1];if(m8(cA)){IA||u(","),IA=!1;var aA=U+"/"+tS(V);v(j),L(aA,"key"),u(p8(V)),L(aA,"keyEnd"),u(":"),r&&u(" "),Q(cA,j,aA)}uA=lA.next()}v(F),u("}")}else u("{}")}}function u(y){d+=y.length,B+=y.length,l+=y}function v(y){if(r){for(l+=`
`+x(y,r),C++,d=0;y--;)i?(C+=i,d=o):d+=o,B+=n;B+=1}}function L(y,F){I[y]=I[y]||{},I[y][F]={line:C,column:d,pos:B}}function x(y,F){return Array(y+1).join(F)}};var ApA=["number","bigint","boolean","string","object"];function m8(t){return ApA.indexOf(typeof t)>=0}var epA=/"|\\/g,tpA=/[\b]/g,ipA=/\f/g,npA=/\n/g,opA=/\r/g,rpA=/\t/g;function p8(t){return t=t.replace(epA,"\\$&").replace(ipA,"\\f").replace(tpA,"\\b").replace(npA,"\\n").replace(opA,"\\r").replace(rpA,"\\t"),'"'+t+'"'}var spA=/~/g,apA=/\//g;function tS(t){return t.replace(spA,"~0").replace(apA,"~1")}});var GW=Le((F3e,_W)=>{"use strict";var NW=function(t,e){var A,i,n=1,o=0,r=0,s=String.alphabet;function a(c,l,I){if(I){for(A=l;I=a(c,A),I<76&&I>65;)++A;return+c.slice(l-1,A)}return I=s&&s.indexOf(c.charAt(l)),I>-1?I+76:(I=c.charCodeAt(l)||0,I<45||I>127?I:I<46?65:I<48?I-1:I<58?I+18:I<65?I-11:I<91?I+11:I<97?I-37:I<123?I+5:I-63)}if((t+="")!=(e+="")){for(;n;)if(i=a(t,o++),n=a(e,r++),i<76&&n<76&&i>66&&n>66&&(i=a(t,o,o),n=a(e,r,o=A),r=A),i!=n)return i<n?-1:1}return 0};try{_W.exports=NW}catch{String.naturalCompare=NW}});var A4=Le(In=>{"use strict";Object.defineProperty(In,"__esModule",{value:!0});In.regexpCode=In.getEsmExportName=In.getProperty=In.safeStringify=In.stringify=In.strConcat=In.addCodeArg=In.str=In._=In.nil=In._Code=In.Name=In.IDENTIFIER=In._CodeOrName=void 0;var Xu=class{};In._CodeOrName=Xu;In.IDENTIFIER=/^[a-z$_][a-z$_0-9]*$/i;var XI=class extends Xu{constructor(e){if(super(),!In.IDENTIFIER.test(e))throw new Error("CodeGen: name must be a valid identifier");this.str=e}toString(){return this.str}emptyStr(){return!1}get names(){return{[this.str]:1}}};In.Name=XI;var kc=class extends Xu{constructor(e){super(),this._items=typeof e=="string"?[e]:e}toString(){return this.str}emptyStr(){if(this._items.length>1)return!1;let e=this._items[0];return e===""||e==='""'}get str(){var e;return(e=this._str)!==null&&e!==void 0?e:this._str=this._items.reduce((A,i)=>`${A}${i}`,"")}get names(){var e;return(e=this._names)!==null&&e!==void 0?e:this._names=this._items.reduce((A,i)=>(i instanceof XI&&(A[i.str]=(A[i.str]||0)+1),A),{})}};In._Code=kc;In.nil=new kc("");function KW(t,...e){let A=[t[0]],i=0;for(;i<e.length;)YS(A,e[i]),A.push(t[++i]);return new kc(A)}In._=KW;var KS=new kc("+");function YW(t,...e){let A=[$u(t[0])],i=0;for(;i<e.length;)A.push(KS),YS(A,e[i]),A.push(KS,$u(t[++i]));return X7A(A),new kc(A)}In.str=YW;function YS(t,e){e instanceof kc?t.push(...e._items):e instanceof XI?t.push(e):t.push(evA(e))}In.addCodeArg=YS;function X7A(t){let e=1;for(;e<t.length-1;){if(t[e]===KS){let A=$7A(t[e-1],t[e+1]);if(A!==void 0){t.splice(e-1,3,A);continue}t[e++]="+"}e++}}function $7A(t,e){if(e==='""')return t;if(t==='""')return e;if(typeof t=="string")return e instanceof XI||t[t.length-1]!=='"'?void 0:typeof e!="string"?`${t.slice(0,-1)}${e}"`:e[0]==='"'?t.slice(0,-1)+e.slice(1):void 0;if(typeof e=="string"&&e[0]==='"'&&!(t instanceof XI))return`"${t}${e.slice(1)}`}function AvA(t,e){return e.emptyStr()?t:t.emptyStr()?e:YW`${t}${e}`}In.strConcat=AvA;function evA(t){return typeof t=="number"||typeof t=="boolean"||t===null?t:$u(Array.isArray(t)?t.join(","):t)}function tvA(t){return new kc($u(t))}In.stringify=tvA;function $u(t){return JSON.stringify(t).replace(/\u2028/g,"\\u2028").replace(/\u2029/g,"\\u2029")}In.safeStringify=$u;function ivA(t){return typeof t=="string"&&In.IDENTIFIER.test(t)?new kc(`.${t}`):KW`[${t}]`}In.getProperty=ivA;function nvA(t){if(typeof t=="string"&&In.IDENTIFIER.test(t))return new kc(`${t}`);throw new Error(`CodeGen: invalid export name: ${t}, use explicit $id name mapping`)}In.getEsmExportName=nvA;function ovA(t){return new kc(t.toString())}In.regexpCode=ovA});var zS=Le(ua=>{"use strict";Object.defineProperty(ua,"__esModule",{value:!0});ua.ValueScope=ua.ValueScopeName=ua.Scope=ua.varKinds=ua.UsedValueState=void 0;var Qa=A4(),JS=class extends Error{constructor(e){super(`CodeGen: "code" for ${e} not defined`),this.value=e.value}},c5=function(t){return t[t.Started=0]="Started",t[t.Completed=1]="Completed",t}(c5||(ua.UsedValueState=c5={}));ua.varKinds={const:new Qa.Name("const"),let:new Qa.Name("let"),var:new Qa.Name("var")};var l5=class{constructor({prefixes:e,parent:A}={}){this._names={},this._prefixes=e,this._parent=A}toName(e){return e instanceof Qa.Name?e:this.name(e)}name(e){return new Qa.Name(this._newName(e))}_newName(e){let A=this._names[e]||this._nameGroup(e);return`${e}${A.index++}`}_nameGroup(e){var A,i;if(!((i=(A=this._parent)===null||A===void 0?void 0:A._prefixes)===null||i===void 0)&&i.has(e)||this._prefixes&&!this._prefixes.has(e))throw new Error(`CodeGen: prefix "${e}" is not allowed in this scope`);return this._names[e]={prefix:e,index:0}}};ua.Scope=l5;var g5=class extends Qa.Name{constructor(e,A){super(A),this.prefix=e}setValue(e,{property:A,itemIndex:i}){this.value=e,this.scopePath=(0,Qa._)`.${new Qa.Name(A)}[${i}]`}};ua.ValueScopeName=g5;var rvA=(0,Qa._)`\n`,TS=class extends l5{constructor(e){super(e),this._values={},this._scope=e.scope,this.opts=Ne(nA({},e),{_n:e.lines?rvA:Qa.nil})}get(){return this._scope}name(e){return new g5(e,this._newName(e))}value(e,A){var i;if(A.ref===void 0)throw new Error("CodeGen: ref must be passed in value");let n=this.toName(e),{prefix:o}=n,r=(i=A.key)!==null&&i!==void 0?i:A.ref,s=this._values[o];if(s){let l=s.get(r);if(l)return l}else s=this._values[o]=new Map;s.set(r,n);let a=this._scope[o]||(this._scope[o]=[]),c=a.length;return a[c]=A.ref,n.setValue(A,{property:o,itemIndex:c}),n}getValue(e,A){let i=this._values[e];if(i)return i.get(A)}scopeRefs(e,A=this._values){return this._reduceValues(A,i=>{if(i.scopePath===void 0)throw new Error(`CodeGen: name "${i}" has no value`);return(0,Qa._)`${e}${i.scopePath}`})}scopeCode(e=this._values,A,i){return this._reduceValues(e,n=>{if(n.value===void 0)throw new Error(`CodeGen: name "${n}" has no value`);return n.value.code},A,i)}_reduceValues(e,A,i={},n){let o=Qa.nil;for(let r in e){let s=e[r];if(!s)continue;let a=i[r]=i[r]||new Map;s.forEach(c=>{if(a.has(c))return;a.set(c,c5.Started);let l=A(c);if(l){let I=this.opts.es5?ua.varKinds.var:ua.varKinds.const;o=(0,Qa._)`${o}${I} ${c} = ${l};${this.opts._n}`}else if(l=n?.(c))o=(0,Qa._)`${o}${l}${this.opts._n}`;else throw new JS(c);a.set(c,c5.Completed)})}return o}};ua.ValueScope=TS});var Ji=Le(Ui=>{"use strict";Object.defineProperty(Ui,"__esModule",{value:!0});Ui.or=Ui.and=Ui.not=Ui.CodeGen=Ui.operators=Ui.varKinds=Ui.ValueScopeName=Ui.ValueScope=Ui.Scope=Ui.Name=Ui.regexpCode=Ui.stringify=Ui.getProperty=Ui.nil=Ui.strConcat=Ui.str=Ui._=void 0;var An=A4(),ll=zS(),s1=A4();Object.defineProperty(Ui,"_",{enumerable:!0,get:function(){return s1._}});Object.defineProperty(Ui,"str",{enumerable:!0,get:function(){return s1.str}});Object.defineProperty(Ui,"strConcat",{enumerable:!0,get:function(){return s1.strConcat}});Object.defineProperty(Ui,"nil",{enumerable:!0,get:function(){return s1.nil}});Object.defineProperty(Ui,"getProperty",{enumerable:!0,get:function(){return s1.getProperty}});Object.defineProperty(Ui,"stringify",{enumerable:!0,get:function(){return s1.stringify}});Object.defineProperty(Ui,"regexpCode",{enumerable:!0,get:function(){return s1.regexpCode}});Object.defineProperty(Ui,"Name",{enumerable:!0,get:function(){return s1.Name}});var E5=zS();Object.defineProperty(Ui,"Scope",{enumerable:!0,get:function(){return E5.Scope}});Object.defineProperty(Ui,"ValueScope",{enumerable:!0,get:function(){return E5.ValueScope}});Object.defineProperty(Ui,"ValueScopeName",{enumerable:!0,get:function(){return E5.ValueScopeName}});Object.defineProperty(Ui,"varKinds",{enumerable:!0,get:function(){return E5.varKinds}});Ui.operators={GT:new An._Code(">"),GTE:new An._Code(">="),LT:new An._Code("<"),LTE:new An._Code("<="),EQ:new An._Code("==="),NEQ:new An._Code("!=="),NOT:new An._Code("!"),OR:new An._Code("||"),AND:new An._Code("&&"),ADD:new An._Code("+")};var R0=class{optimizeNodes(){return this}optimizeNames(e,A){return this}},HS=class extends R0{constructor(e,A,i){super(),this.varKind=e,this.name=A,this.rhs=i}render({es5:e,_n:A}){let i=e?ll.varKinds.var:this.varKind,n=this.rhs===void 0?"":` = ${this.rhs}`;return`${i} ${this.name}${n};`+A}optimizeNames(e,A){if(e[this.name.str])return this.rhs&&(this.rhs=ZB(this.rhs,e,A)),this}get names(){return this.rhs instanceof An._CodeOrName?this.rhs.names:{}}},C5=class extends R0{constructor(e,A,i){super(),this.lhs=e,this.rhs=A,this.sideEffects=i}render({_n:e}){return`${this.lhs} = ${this.rhs};`+e}optimizeNames(e,A){if(!(this.lhs instanceof An.Name&&!e[this.lhs.str]&&!this.sideEffects))return this.rhs=ZB(this.rhs,e,A),this}get names(){let e=this.lhs instanceof An.Name?{}:nA({},this.lhs.names);return B5(e,this.rhs)}},OS=class extends C5{constructor(e,A,i,n){super(e,i,n),this.op=A}render({_n:e}){return`${this.lhs} ${this.op}= ${this.rhs};`+e}},PS=class extends R0{constructor(e){super(),this.label=e,this.names={}}render({_n:e}){return`${this.label}:`+e}},jS=class extends R0{constructor(e){super(),this.label=e,this.names={}}render({_n:e}){return`break${this.label?` ${this.label}`:""};`+e}},qS=class extends R0{constructor(e){super(),this.error=e}render({_n:e}){return`throw ${this.error};`+e}get names(){return this.error.names}},VS=class extends R0{constructor(e){super(),this.code=e}render({_n:e}){return`${this.code};`+e}optimizeNodes(){return`${this.code}`?this:void 0}optimizeNames(e,A){return this.code=ZB(this.code,e,A),this}get names(){return this.code instanceof An._CodeOrName?this.code.names:{}}},e4=class extends R0{constructor(e=[]){super(),this.nodes=e}render(e){return this.nodes.reduce((A,i)=>A+i.render(e),"")}optimizeNodes(){let{nodes:e}=this,A=e.length;for(;A--;){let i=e[A].optimizeNodes();Array.isArray(i)?e.splice(A,1,...i):i?e[A]=i:e.splice(A,1)}return e.length>0?this:void 0}optimizeNames(e,A){let{nodes:i}=this,n=i.length;for(;n--;){let o=i[n];o.optimizeNames(e,A)||(svA(e,o.names),i.splice(n,1))}return i.length>0?this:void 0}get names(){return this.nodes.reduce((e,A)=>$I(e,A.names),{})}},L0=class extends e4{render(e){return"{"+e._n+super.render(e)+"}"+e._n}},ZS=class extends e4{},WS=(()=>{class t extends L0{}return t.kind="else",t})(),I5=(()=>{class t extends L0{constructor(A,i){super(i),this.condition=A}render(A){let i=`if(${this.condition})`+super.render(A);return this.else&&(i+="else "+this.else.render(A)),i}optimizeNodes(){super.optimizeNodes();let A=this.condition;if(A===!0)return this.nodes;let i=this.else;if(i){let n=i.optimizeNodes();i=this.else=Array.isArray(n)?new WS(n):n}if(i)return A===!1?i instanceof t?i:i.nodes:this.nodes.length?this:new t(OW(A),i instanceof t?[i]:i.nodes);if(!(A===!1||!this.nodes.length))return this}optimizeNames(A,i){var n;if(this.else=(n=this.else)===null||n===void 0?void 0:n.optimizeNames(A,i),!!(super.optimizeNames(A,i)||this.else))return this.condition=ZB(this.condition,A,i),this}get names(){let A=super.names;return B5(A,this.condition),this.else&&$I(A,this.else.names),A}}return t.kind="if",t})(),h5=(()=>{class t extends L0{}return t.kind="for",t})(),XS=class extends h5{constructor(e){super(),this.iteration=e}render(e){return`for(${this.iteration})`+super.render(e)}optimizeNames(e,A){if(super.optimizeNames(e,A))return this.iteration=ZB(this.iteration,e,A),this}get names(){return $I(super.names,this.iteration.names)}},$S=class extends h5{constructor(e,A,i,n){super(),this.varKind=e,this.name=A,this.from=i,this.to=n}render(e){let A=e.es5?ll.varKinds.var:this.varKind,{name:i,from:n,to:o}=this;return`for(${A} ${i}=${n}; ${i}<${o}; ${i}++)`+super.render(e)}get names(){let e=B5(super.names,this.from);return B5(e,this.to)}},d5=class extends h5{constructor(e,A,i,n){super(),this.loop=e,this.varKind=A,this.name=i,this.iterable=n}render(e){return`for(${this.varKind} ${this.name} ${this.loop} ${this.iterable})`+super.render(e)}optimizeNames(e,A){if(super.optimizeNames(e,A))return this.iterable=ZB(this.iterable,e,A),this}get names(){return $I(super.names,this.iterable.names)}},JW=(()=>{class t extends L0{constructor(A,i,n){super(),this.name=A,this.args=i,this.async=n}render(A){return`${this.async?"async ":""}function ${this.name}(${this.args})`+super.render(A)}}return t.kind="func",t})(),TW=(()=>{class t extends e4{render(A){return"return "+super.render(A)}}return t.kind="return",t})(),AR=class extends L0{render(e){let A="try"+super.render(e);return this.catch&&(A+=this.catch.render(e)),this.finally&&(A+=this.finally.render(e)),A}optimizeNodes(){var e,A;return super.optimizeNodes(),(e=this.catch)===null||e===void 0||e.optimizeNodes(),(A=this.finally)===null||A===void 0||A.optimizeNodes(),this}optimizeNames(e,A){var i,n;return super.optimizeNames(e,A),(i=this.catch)===null||i===void 0||i.optimizeNames(e,A),(n=this.finally)===null||n===void 0||n.optimizeNames(e,A),this}get names(){let e=super.names;return this.catch&&$I(e,this.catch.names),this.finally&&$I(e,this.finally.names),e}},zW=(()=>{class t extends L0{constructor(A){super(),this.error=A}render(A){return`catch(${this.error})`+super.render(A)}}return t.kind="catch",t})(),HW=(()=>{class t extends L0{render(A){return"finally"+super.render(A)}}return t.kind="finally",t})(),eR=class{constructor(e,A={}){this._values={},this._blockStarts=[],this._constants={},this.opts=Ne(nA({},A),{_n:A.lines?`
`:""}),this._extScope=e,this._scope=new ll.Scope({parent:e}),this._nodes=[new ZS]}toString(){return this._root.render(this.opts)}name(e){return this._scope.name(e)}scopeName(e){return this._extScope.name(e)}scopeValue(e,A){let i=this._extScope.value(e,A);return(this._values[i.prefix]||(this._values[i.prefix]=new Set)).add(i),i}getScopeValue(e,A){return this._extScope.getValue(e,A)}scopeRefs(e){return this._extScope.scopeRefs(e,this._values)}scopeCode(){return this._extScope.scopeCode(this._values)}_def(e,A,i,n){let o=this._scope.toName(A);return i!==void 0&&n&&(this._constants[o.str]=i),this._leafNode(new HS(e,o,i)),o}const(e,A,i){return this._def(ll.varKinds.const,e,A,i)}let(e,A,i){return this._def(ll.varKinds.let,e,A,i)}var(e,A,i){return this._def(ll.varKinds.var,e,A,i)}assign(e,A,i){return this._leafNode(new C5(e,A,i))}add(e,A){return this._leafNode(new OS(e,Ui.operators.ADD,A))}code(e){return typeof e=="function"?e():e!==An.nil&&this._leafNode(new VS(e)),this}object(...e){let A=["{"];for(let[i,n]of e)A.length>1&&A.push(","),A.push(i),(i!==n||this.opts.es5)&&(A.push(":"),(0,An.addCodeArg)(A,n));return A.push("}"),new An._Code(A)}if(e,A,i){if(this._blockNode(new I5(e)),A&&i)this.code(A).else().code(i).endIf();else if(A)this.code(A).endIf();else if(i)throw new Error('CodeGen: "else" body without "then" body');return this}elseIf(e){return this._elseNode(new I5(e))}else(){return this._elseNode(new WS)}endIf(){return this._endBlockNode(I5,WS)}_for(e,A){return this._blockNode(e),A&&this.code(A).endFor(),this}for(e,A){return this._for(new XS(e),A)}forRange(e,A,i,n,o=this.opts.es5?ll.varKinds.var:ll.varKinds.let){let r=this._scope.toName(e);return this._for(new $S(o,r,A,i),()=>n(r))}forOf(e,A,i,n=ll.varKinds.const){let o=this._scope.toName(e);if(this.opts.es5){let r=A instanceof An.Name?A:this.var("_arr",A);return this.forRange("_i",0,(0,An._)`${r}.length`,s=>{this.var(o,(0,An._)`${r}[${s}]`),i(o)})}return this._for(new d5("of",n,o,A),()=>i(o))}forIn(e,A,i,n=this.opts.es5?ll.varKinds.var:ll.varKinds.const){if(this.opts.ownProperties)return this.forOf(e,(0,An._)`Object.keys(${A})`,i);let o=this._scope.toName(e);return this._for(new d5("in",n,o,A),()=>i(o))}endFor(){return this._endBlockNode(h5)}label(e){return this._leafNode(new PS(e))}break(e){return this._leafNode(new jS(e))}return(e){let A=new TW;if(this._blockNode(A),this.code(e),A.nodes.length!==1)throw new Error('CodeGen: "return" should have one node');return this._endBlockNode(TW)}try(e,A,i){if(!A&&!i)throw new Error('CodeGen: "try" without "catch" and "finally"');let n=new AR;if(this._blockNode(n),this.code(e),A){let o=this.name("e");this._currNode=n.catch=new zW(o),A(o)}return i&&(this._currNode=n.finally=new HW,this.code(i)),this._endBlockNode(zW,HW)}throw(e){return this._leafNode(new qS(e))}block(e,A){return this._blockStarts.push(this._nodes.length),e&&this.code(e).endBlock(A),this}endBlock(e){let A=this._blockStarts.pop();if(A===void 0)throw new Error("CodeGen: not in self-balancing block");let i=this._nodes.length-A;if(i<0||e!==void 0&&i!==e)throw new Error(`CodeGen: wrong number of nodes: ${i} vs ${e} expected`);return this._nodes.length=A,this}func(e,A=An.nil,i,n){return this._blockNode(new JW(e,A,i)),n&&this.code(n).endFunc(),this}endFunc(){return this._endBlockNode(JW)}optimize(e=1){for(;e-- >0;)this._root.optimizeNodes(),this._root.optimizeNames(this._root.names,this._constants)}_leafNode(e){return this._currNode.nodes.push(e),this}_blockNode(e){this._currNode.nodes.push(e),this._nodes.push(e)}_endBlockNode(e,A){let i=this._currNode;if(i instanceof e||A&&i instanceof A)return this._nodes.pop(),this;throw new Error(`CodeGen: not in block "${A?`${e.kind}/${A.kind}`:e.kind}"`)}_elseNode(e){let A=this._currNode;if(!(A instanceof I5))throw new Error('CodeGen: "else" without "if"');return this._currNode=A.else=e,this}get _root(){return this._nodes[0]}get _currNode(){let e=this._nodes;return e[e.length-1]}set _currNode(e){let A=this._nodes;A[A.length-1]=e}};Ui.CodeGen=eR;function $I(t,e){for(let A in e)t[A]=(t[A]||0)+(e[A]||0);return t}function B5(t,e){return e instanceof An._CodeOrName?$I(t,e.names):t}function ZB(t,e,A){if(t instanceof An.Name)return i(t);if(!n(t))return t;return new An._Code(t._items.reduce((o,r)=>(r instanceof An.Name&&(r=i(r)),r instanceof An._Code?o.push(...r._items):o.push(r),o),[]));function i(o){let r=A[o.str];return r===void 0||e[o.str]!==1?o:(delete e[o.str],r)}function n(o){return o instanceof An._Code&&o._items.some(r=>r instanceof An.Name&&e[r.str]===1&&A[r.str]!==void 0)}}function svA(t,e){for(let A in e)t[A]=(t[A]||0)-(e[A]||0)}function OW(t){return typeof t=="boolean"||typeof t=="number"||t===null?!t:(0,An._)`!${tR(t)}`}Ui.not=OW;var avA=PW(Ui.operators.AND);function cvA(...t){return t.reduce(avA)}Ui.and=cvA;var lvA=PW(Ui.operators.OR);function gvA(...t){return t.reduce(lvA)}Ui.or=gvA;function PW(t){return(e,A)=>e===An.nil?A:A===An.nil?e:(0,An._)`${tR(e)} ${t} ${tR(A)}`}function tR(t){return t instanceof An.Name?t:(0,An._)`(${t})`}});var Cn=Le(Ti=>{"use strict";Object.defineProperty(Ti,"__esModule",{value:!0});Ti.checkStrictMode=Ti.getErrorPath=Ti.Type=Ti.useFunc=Ti.setEvaluated=Ti.evaluatedPropsToName=Ti.mergeEvaluated=Ti.eachItem=Ti.unescapeJsonPointer=Ti.escapeJsonPointer=Ti.escapeFragment=Ti.unescapeFragment=Ti.schemaRefOrVal=Ti.schemaHasRulesButRef=Ti.schemaHasRules=Ti.checkUnknownRules=Ti.alwaysValidSchema=Ti.toHash=void 0;var co=Ji(),IvA=A4();function CvA(t){let e={};for(let A of t)e[A]=!0;return e}Ti.toHash=CvA;function dvA(t,e){return typeof e=="boolean"?e:Object.keys(e).length===0?!0:(VW(t,e),!ZW(e,t.self.RULES.all))}Ti.alwaysValidSchema=dvA;function VW(t,e=t.schema){let{opts:A,self:i}=t;if(!A.strictSchema||typeof e=="boolean")return;let n=i.RULES.keywords;for(let o in e)n[o]||$W(t,`unknown keyword: "${o}"`)}Ti.checkUnknownRules=VW;function ZW(t,e){if(typeof t=="boolean")return!t;for(let A in t)if(e[A])return!0;return!1}Ti.schemaHasRules=ZW;function BvA(t,e){if(typeof t=="boolean")return!t;for(let A in t)if(A!=="$ref"&&e.all[A])return!0;return!1}Ti.schemaHasRulesButRef=BvA;function EvA({topSchemaRef:t,schemaPath:e},A,i,n){if(!n){if(typeof A=="number"||typeof A=="boolean")return A;if(typeof A=="string")return(0,co._)`${A}`}return(0,co._)`${t}${e}${(0,co.getProperty)(i)}`}Ti.schemaRefOrVal=EvA;function hvA(t){return WW(decodeURIComponent(t))}Ti.unescapeFragment=hvA;function QvA(t){return encodeURIComponent(nR(t))}Ti.escapeFragment=QvA;function nR(t){return typeof t=="number"?`${t}`:t.replace(/~/g,"~0").replace(/\//g,"~1")}Ti.escapeJsonPointer=nR;function WW(t){return t.replace(/~1/g,"/").replace(/~0/g,"~")}Ti.unescapeJsonPointer=WW;function uvA(t,e){if(Array.isArray(t))for(let A of t)e(A);else e(t)}Ti.eachItem=uvA;function jW({mergeNames:t,mergeToName:e,mergeValues:A,resultToName:i}){return(n,o,r,s)=>{let a=r===void 0?o:r instanceof co.Name?(o instanceof co.Name?t(n,o,r):e(n,o,r),r):o instanceof co.Name?(e(n,r,o),o):A(o,r);return s===co.Name&&!(a instanceof co.Name)?i(n,a):a}}Ti.mergeEvaluated={props:jW({mergeNames:(t,e,A)=>t.if((0,co._)`${A} !== true && ${e} !== undefined`,()=>{t.if((0,co._)`${e} === true`,()=>t.assign(A,!0),()=>t.assign(A,(0,co._)`${A} || {}`).code((0,co._)`Object.assign(${A}, ${e})`))}),mergeToName:(t,e,A)=>t.if((0,co._)`${A} !== true`,()=>{e===!0?t.assign(A,!0):(t.assign(A,(0,co._)`${A} || {}`),oR(t,A,e))}),mergeValues:(t,e)=>t===!0?!0:nA(nA({},t),e),resultToName:XW}),items:jW({mergeNames:(t,e,A)=>t.if((0,co._)`${A} !== true && ${e} !== undefined`,()=>t.assign(A,(0,co._)`${e} === true ? true : ${A} > ${e} ? ${A} : ${e}`)),mergeToName:(t,e,A)=>t.if((0,co._)`${A} !== true`,()=>t.assign(A,e===!0?!0:(0,co._)`${A} > ${e} ? ${A} : ${e}`)),mergeValues:(t,e)=>t===!0?!0:Math.max(t,e),resultToName:(t,e)=>t.var("items",e)})};function XW(t,e){if(e===!0)return t.var("props",!0);let A=t.var("props",(0,co._)`{}`);return e!==void 0&&oR(t,A,e),A}Ti.evaluatedPropsToName=XW;function oR(t,e,A){Object.keys(A).forEach(i=>t.assign((0,co._)`${e}${(0,co.getProperty)(i)}`,!0))}Ti.setEvaluated=oR;var qW={};function fvA(t,e){return t.scopeValue("func",{ref:e,code:qW[e.code]||(qW[e.code]=new IvA._Code(e.code))})}Ti.useFunc=fvA;var iR=function(t){return t[t.Num=0]="Num",t[t.Str=1]="Str",t}(iR||(Ti.Type=iR={}));function mvA(t,e,A){if(t instanceof co.Name){let i=e===iR.Num;return A?i?(0,co._)`"[" + ${t} + "]"`:(0,co._)`"['" + ${t} + "']"`:i?(0,co._)`"/" + ${t}`:(0,co._)`"/" + ${t}.replace(/~/g, "~0").replace(/\\//g, "~1")`}return A?(0,co.getProperty)(t).toString():"/"+nR(t)}Ti.getErrorPath=mvA;function $W(t,e,A=t.opts.strictSchema){if(A){if(e=`strict mode: ${e}`,A===!0)throw new Error(e);t.self.logger.warn(e)}}Ti.checkStrictMode=$W});var x0=Le(rR=>{"use strict";Object.defineProperty(rR,"__esModule",{value:!0});var us=Ji(),pvA={data:new us.Name("data"),valCxt:new us.Name("valCxt"),instancePath:new us.Name("instancePath"),parentData:new us.Name("parentData"),parentDataProperty:new us.Name("parentDataProperty"),rootData:new us.Name("rootData"),dynamicAnchors:new us.Name("dynamicAnchors"),vErrors:new us.Name("vErrors"),errors:new us.Name("errors"),this:new us.Name("this"),self:new us.Name("self"),scope:new us.Name("scope"),json:new us.Name("json"),jsonPos:new us.Name("jsonPos"),jsonLen:new us.Name("jsonLen"),jsonPart:new us.Name("jsonPart")};rR.default=pvA});var t4=Le(fs=>{"use strict";Object.defineProperty(fs,"__esModule",{value:!0});fs.extendErrors=fs.resetErrorsCount=fs.reportExtraError=fs.reportError=fs.keyword$DataError=fs.keywordError=void 0;var an=Ji(),Q5=Cn(),Ys=x0();fs.keywordError={message:({keyword:t})=>(0,an.str)`must pass "${t}" keyword validation`};fs.keyword$DataError={message:({keyword:t,schemaType:e})=>e?(0,an.str)`"${t}" keyword must be ${e} ($data)`:(0,an.str)`"${t}" keyword is invalid ($data)`};function wvA(t,e=fs.keywordError,A,i){let{it:n}=t,{gen:o,compositeRule:r,allErrors:s}=n,a=tX(t,e,A);i??(r||s)?AX(o,a):eX(n,(0,an._)`[${a}]`)}fs.reportError=wvA;function DvA(t,e=fs.keywordError,A){let{it:i}=t,{gen:n,compositeRule:o,allErrors:r}=i,s=tX(t,e,A);AX(n,s),o||r||eX(i,Ys.default.vErrors)}fs.reportExtraError=DvA;function yvA(t,e){t.assign(Ys.default.errors,e),t.if((0,an._)`${Ys.default.vErrors} !== null`,()=>t.if(e,()=>t.assign((0,an._)`${Ys.default.vErrors}.length`,e),()=>t.assign(Ys.default.vErrors,null)))}fs.resetErrorsCount=yvA;function vvA({gen:t,keyword:e,schemaValue:A,data:i,errsCount:n,it:o}){if(n===void 0)throw new Error("ajv implementation error");let r=t.name("err");t.forRange("i",n,Ys.default.errors,s=>{t.const(r,(0,an._)`${Ys.default.vErrors}[${s}]`),t.if((0,an._)`${r}.instancePath === undefined`,()=>t.assign((0,an._)`${r}.instancePath`,(0,an.strConcat)(Ys.default.instancePath,o.errorPath))),t.assign((0,an._)`${r}.schemaPath`,(0,an.str)`${o.errSchemaPath}/${e}`),o.opts.verbose&&(t.assign((0,an._)`${r}.schema`,A),t.assign((0,an._)`${r}.data`,i))})}fs.extendErrors=vvA;function AX(t,e){let A=t.const("err",e);t.if((0,an._)`${Ys.default.vErrors} === null`,()=>t.assign(Ys.default.vErrors,(0,an._)`[${A}]`),(0,an._)`${Ys.default.vErrors}.push(${A})`),t.code((0,an._)`${Ys.default.errors}++`)}function eX(t,e){let{gen:A,validateName:i,schemaEnv:n}=t;n.$async?A.throw((0,an._)`new ${t.ValidationError}(${e})`):(A.assign((0,an._)`${i}.errors`,e),A.return(!1))}var AC={keyword:new an.Name("keyword"),schemaPath:new an.Name("schemaPath"),params:new an.Name("params"),propertyName:new an.Name("propertyName"),message:new an.Name("message"),schema:new an.Name("schema"),parentSchema:new an.Name("parentSchema")};function tX(t,e,A){let{createErrors:i}=t.it;return i===!1?(0,an._)`{}`:bvA(t,e,A)}function bvA(t,e,A={}){let{gen:i,it:n}=t,o=[MvA(n,A),kvA(t,A)];return SvA(t,e,o),i.object(...o)}function MvA({errorPath:t},{instancePath:e}){let A=e?(0,an.str)`${t}${(0,Q5.getErrorPath)(e,Q5.Type.Str)}`:t;return[Ys.default.instancePath,(0,an.strConcat)(Ys.default.instancePath,A)]}function kvA({keyword:t,it:{errSchemaPath:e}},{schemaPath:A,parentSchema:i}){let n=i?e:(0,an.str)`${e}/${t}`;return A&&(n=(0,an.str)`${n}${(0,Q5.getErrorPath)(A,Q5.Type.Str)}`),[AC.schemaPath,n]}function SvA(t,{params:e,message:A},i){let{keyword:n,data:o,schemaValue:r,it:s}=t,{opts:a,propertyName:c,topSchemaRef:l,schemaPath:I}=s;i.push([AC.keyword,n],[AC.params,typeof e=="function"?e(t):e||(0,an._)`{}`]),a.messages&&i.push([AC.message,typeof A=="function"?A(t):A]),a.verbose&&i.push([AC.schema,r],[AC.parentSchema,(0,an._)`${l}${I}`],[Ys.default.data,o]),c&&i.push([AC.propertyName,c])}});var nX=Le(WB=>{"use strict";Object.defineProperty(WB,"__esModule",{value:!0});WB.boolOrEmptySchema=WB.topBoolOrEmptySchema=void 0;var RvA=t4(),LvA=Ji(),xvA=x0(),FvA={message:"boolean schema is false"};function NvA(t){let{gen:e,schema:A,validateName:i}=t;A===!1?iX(t,!1):typeof A=="object"&&A.$async===!0?e.return(xvA.default.data):(e.assign((0,LvA._)`${i}.errors`,null),e.return(!0))}WB.topBoolOrEmptySchema=NvA;function _vA(t,e){let{gen:A,schema:i}=t;i===!1?(A.var(e,!1),iX(t)):A.var(e,!0)}WB.boolOrEmptySchema=_vA;function iX(t,e){let{gen:A,data:i}=t,n={gen:A,keyword:"false schema",data:i,schema:!1,schemaCode:!1,schemaValue:!1,params:{},it:t};(0,RvA.reportError)(n,FvA,void 0,e)}});var sR=Le(XB=>{"use strict";Object.defineProperty(XB,"__esModule",{value:!0});XB.getRules=XB.isJSONType=void 0;var GvA=["string","number","integer","boolean","null","object","array"],UvA=new Set(GvA);function KvA(t){return typeof t=="string"&&UvA.has(t)}XB.isJSONType=KvA;function YvA(){let t={number:{type:"number",rules:[]},string:{type:"string",rules:[]},array:{type:"array",rules:[]},object:{type:"object",rules:[]}};return{types:Ne(nA({},t),{integer:!0,boolean:!0,null:!0}),rules:[{rules:[]},t.number,t.string,t.array,t.object],post:{rules:[]},all:{},keywords:{}}}XB.getRules=YvA});var aR=Le(a1=>{"use strict";Object.defineProperty(a1,"__esModule",{value:!0});a1.shouldUseRule=a1.shouldUseGroup=a1.schemaHasRulesForType=void 0;function JvA({schema:t,self:e},A){let i=e.RULES.types[A];return i&&i!==!0&&oX(t,i)}a1.schemaHasRulesForType=JvA;function oX(t,e){return e.rules.some(A=>rX(t,A))}a1.shouldUseGroup=oX;function rX(t,e){var A;return t[e.keyword]!==void 0||((A=e.definition.implements)===null||A===void 0?void 0:A.some(i=>t[i]!==void 0))}a1.shouldUseRule=rX});var i4=Le(ms=>{"use strict";Object.defineProperty(ms,"__esModule",{value:!0});ms.reportTypeError=ms.checkDataTypes=ms.checkDataType=ms.coerceAndCheckDataType=ms.getJSONTypes=ms.getSchemaTypes=ms.DataType=void 0;var TvA=sR(),zvA=aR(),HvA=t4(),wi=Ji(),sX=Cn(),$B=function(t){return t[t.Correct=0]="Correct",t[t.Wrong=1]="Wrong",t}($B||(ms.DataType=$B={}));function OvA(t){let e=aX(t.type);if(e.includes("null")){if(t.nullable===!1)throw new Error("type: null contradicts nullable: false")}else{if(!e.length&&t.nullable!==void 0)throw new Error('"nullable" cannot be used without "type"');t.nullable===!0&&e.push("null")}return e}ms.getSchemaTypes=OvA;function aX(t){let e=Array.isArray(t)?t:t?[t]:[];if(e.every(TvA.isJSONType))return e;throw new Error("type must be JSONType or JSONType[]: "+e.join(","))}ms.getJSONTypes=aX;function PvA(t,e){let{gen:A,data:i,opts:n}=t,o=jvA(e,n.coerceTypes),r=e.length>0&&!(o.length===0&&e.length===1&&(0,zvA.schemaHasRulesForType)(t,e[0]));if(r){let s=lR(e,i,n.strictNumbers,$B.Wrong);A.if(s,()=>{o.length?qvA(t,e,o):gR(t)})}return r}ms.coerceAndCheckDataType=PvA;var cX=new Set(["string","number","integer","boolean","null"]);function jvA(t,e){return e?t.filter(A=>cX.has(A)||e==="array"&&A==="array"):[]}function qvA(t,e,A){let{gen:i,data:n,opts:o}=t,r=i.let("dataType",(0,wi._)`typeof ${n}`),s=i.let("coerced",(0,wi._)`undefined`);o.coerceTypes==="array"&&i.if((0,wi._)`${r} == 'object' && Array.isArray(${n}) && ${n}.length == 1`,()=>i.assign(n,(0,wi._)`${n}[0]`).assign(r,(0,wi._)`typeof ${n}`).if(lR(e,n,o.strictNumbers),()=>i.assign(s,n))),i.if((0,wi._)`${s} !== undefined`);for(let c of A)(cX.has(c)||c==="array"&&o.coerceTypes==="array")&&a(c);i.else(),gR(t),i.endIf(),i.if((0,wi._)`${s} !== undefined`,()=>{i.assign(n,s),VvA(t,s)});function a(c){switch(c){case"string":i.elseIf((0,wi._)`${r} == "number" || ${r} == "boolean"`).assign(s,(0,wi._)`"" + ${n}`).elseIf((0,wi._)`${n} === null`).assign(s,(0,wi._)`""`);return;case"number":i.elseIf((0,wi._)`${r} == "boolean" || ${n} === null
              || (${r} == "string" && ${n} && ${n} == +${n})`).assign(s,(0,wi._)`+${n}`);return;case"integer":i.elseIf((0,wi._)`${r} === "boolean" || ${n} === null
              || (${r} === "string" && ${n} && ${n} == +${n} && !(${n} % 1))`).assign(s,(0,wi._)`+${n}`);return;case"boolean":i.elseIf((0,wi._)`${n} === "false" || ${n} === 0 || ${n} === null`).assign(s,!1).elseIf((0,wi._)`${n} === "true" || ${n} === 1`).assign(s,!0);return;case"null":i.elseIf((0,wi._)`${n} === "" || ${n} === 0 || ${n} === false`),i.assign(s,null);return;case"array":i.elseIf((0,wi._)`${r} === "string" || ${r} === "number"
              || ${r} === "boolean" || ${n} === null`).assign(s,(0,wi._)`[${n}]`)}}}function VvA({gen:t,parentData:e,parentDataProperty:A},i){t.if((0,wi._)`${e} !== undefined`,()=>t.assign((0,wi._)`${e}[${A}]`,i))}function cR(t,e,A,i=$B.Correct){let n=i===$B.Correct?wi.operators.EQ:wi.operators.NEQ,o;switch(t){case"null":return(0,wi._)`${e} ${n} null`;case"array":o=(0,wi._)`Array.isArray(${e})`;break;case"object":o=(0,wi._)`${e} && typeof ${e} == "object" && !Array.isArray(${e})`;break;case"integer":o=r((0,wi._)`!(${e} % 1) && !isNaN(${e})`);break;case"number":o=r();break;default:return(0,wi._)`typeof ${e} ${n} ${t}`}return i===$B.Correct?o:(0,wi.not)(o);function r(s=wi.nil){return(0,wi.and)((0,wi._)`typeof ${e} == "number"`,s,A?(0,wi._)`isFinite(${e})`:wi.nil)}}ms.checkDataType=cR;function lR(t,e,A,i){if(t.length===1)return cR(t[0],e,A,i);let n,o=(0,sX.toHash)(t);if(o.array&&o.object){let r=(0,wi._)`typeof ${e} != "object"`;n=o.null?r:(0,wi._)`!${e} || ${r}`,delete o.null,delete o.array,delete o.object}else n=wi.nil;o.number&&delete o.integer;for(let r in o)n=(0,wi.and)(n,cR(r,e,A,i));return n}ms.checkDataTypes=lR;var ZvA={message:({schema:t})=>`must be ${t}`,params:({schema:t,schemaValue:e})=>typeof t=="string"?(0,wi._)`{type: ${t}}`:(0,wi._)`{type: ${e}}`};function gR(t){let e=WvA(t);(0,HvA.reportError)(e,ZvA)}ms.reportTypeError=gR;function WvA(t){let{gen:e,data:A,schema:i}=t,n=(0,sX.schemaRefOrVal)(t,i,"type");return{gen:e,keyword:"type",data:A,schema:i.type,schemaCode:n,schemaValue:n,parentSchema:i,params:{},it:t}}});var gX=Le(u5=>{"use strict";Object.defineProperty(u5,"__esModule",{value:!0});u5.assignDefaults=void 0;var AE=Ji(),XvA=Cn();function $vA(t,e){let{properties:A,items:i}=t.schema;if(e==="object"&&A)for(let n in A)lX(t,n,A[n].default);else e==="array"&&Array.isArray(i)&&i.forEach((n,o)=>lX(t,o,n.default))}u5.assignDefaults=$vA;function lX(t,e,A){let{gen:i,compositeRule:n,data:o,opts:r}=t;if(A===void 0)return;let s=(0,AE._)`${o}${(0,AE.getProperty)(e)}`;if(n){(0,XvA.checkStrictMode)(t,`default is ignored for: ${s}`);return}let a=(0,AE._)`${s} === undefined`;r.useDefaults==="empty"&&(a=(0,AE._)`${a} || ${s} === null || ${s} === ""`),i.if(a,(0,AE._)`${s} = ${(0,AE.stringify)(A)}`)}});var Sc=Le(jn=>{"use strict";Object.defineProperty(jn,"__esModule",{value:!0});jn.validateUnion=jn.validateArray=jn.usePattern=jn.callValidateCode=jn.schemaProperties=jn.allSchemaProperties=jn.noPropertyInData=jn.propertyInData=jn.isOwnProperty=jn.hasPropFunc=jn.reportMissingProp=jn.checkMissingProp=jn.checkReportMissingProp=void 0;var So=Ji(),IR=Cn(),c1=x0(),A9A=Cn();function e9A(t,e){let{gen:A,data:i,it:n}=t;A.if(dR(A,i,e,n.opts.ownProperties),()=>{t.setParams({missingProperty:(0,So._)`${e}`},!0),t.error()})}jn.checkReportMissingProp=e9A;function t9A({gen:t,data:e,it:{opts:A}},i,n){return(0,So.or)(...i.map(o=>(0,So.and)(dR(t,e,o,A.ownProperties),(0,So._)`${n} = ${o}`)))}jn.checkMissingProp=t9A;function i9A(t,e){t.setParams({missingProperty:e},!0),t.error()}jn.reportMissingProp=i9A;function IX(t){return t.scopeValue("func",{ref:Object.prototype.hasOwnProperty,code:(0,So._)`Object.prototype.hasOwnProperty`})}jn.hasPropFunc=IX;function CR(t,e,A){return(0,So._)`${IX(t)}.call(${e}, ${A})`}jn.isOwnProperty=CR;function n9A(t,e,A,i){let n=(0,So._)`${e}${(0,So.getProperty)(A)} !== undefined`;return i?(0,So._)`${n} && ${CR(t,e,A)}`:n}jn.propertyInData=n9A;function dR(t,e,A,i){let n=(0,So._)`${e}${(0,So.getProperty)(A)} === undefined`;return i?(0,So.or)(n,(0,So.not)(CR(t,e,A))):n}jn.noPropertyInData=dR;function CX(t){return t?Object.keys(t).filter(e=>e!=="__proto__"):[]}jn.allSchemaProperties=CX;function o9A(t,e){return CX(e).filter(A=>!(0,IR.alwaysValidSchema)(t,e[A]))}jn.schemaProperties=o9A;function r9A({schemaCode:t,data:e,it:{gen:A,topSchemaRef:i,schemaPath:n,errorPath:o},it:r},s,a,c){let l=c?(0,So._)`${t}, ${e}, ${i}${n}`:e,I=[[c1.default.instancePath,(0,So.strConcat)(c1.default.instancePath,o)],[c1.default.parentData,r.parentData],[c1.default.parentDataProperty,r.parentDataProperty],[c1.default.rootData,c1.default.rootData]];r.opts.dynamicRef&&I.push([c1.default.dynamicAnchors,c1.default.dynamicAnchors]);let C=(0,So._)`${l}, ${A.object(...I)}`;return a!==So.nil?(0,So._)`${s}.call(${a}, ${C})`:(0,So._)`${s}(${C})`}jn.callValidateCode=r9A;var s9A=(0,So._)`new RegExp`;function a9A({gen:t,it:{opts:e}},A){let i=e.unicodeRegExp?"u":"",{regExp:n}=e.code,o=n(A,i);return t.scopeValue("pattern",{key:o.toString(),ref:o,code:(0,So._)`${n.code==="new RegExp"?s9A:(0,A9A.useFunc)(t,n)}(${A}, ${i})`})}jn.usePattern=a9A;function c9A(t){let{gen:e,data:A,keyword:i,it:n}=t,o=e.name("valid");if(n.allErrors){let s=e.let("valid",!0);return r(()=>e.assign(s,!1)),s}return e.var(o,!0),r(()=>e.break()),o;function r(s){let a=e.const("len",(0,So._)`${A}.length`);e.forRange("i",0,a,c=>{t.subschema({keyword:i,dataProp:c,dataPropType:IR.Type.Num},o),e.if((0,So.not)(o),s)})}}jn.validateArray=c9A;function l9A(t){let{gen:e,schema:A,keyword:i,it:n}=t;if(!Array.isArray(A))throw new Error("ajv implementation error");if(A.some(a=>(0,IR.alwaysValidSchema)(n,a))&&!n.opts.unevaluated)return;let r=e.let("valid",!1),s=e.name("_valid");e.block(()=>A.forEach((a,c)=>{let l=t.subschema({keyword:i,schemaProp:c,compositeRule:!0},s);e.assign(r,(0,So._)`${r} || ${s}`),t.mergeValidEvaluated(l,s)||e.if((0,So.not)(r))})),t.result(r,()=>t.reset(),()=>t.error(!0))}jn.validateUnion=l9A});var EX=Le(dg=>{"use strict";Object.defineProperty(dg,"__esModule",{value:!0});dg.validateKeywordUsage=dg.validSchemaType=dg.funcKeywordCode=dg.macroKeywordCode=void 0;var Js=Ji(),eC=x0(),g9A=Sc(),I9A=t4();function C9A(t,e){let{gen:A,keyword:i,schema:n,parentSchema:o,it:r}=t,s=e.macro.call(r.self,n,o,r),a=BX(A,i,s);r.opts.validateSchema!==!1&&r.self.validateSchema(s,!0);let c=A.name("valid");t.subschema({schema:s,schemaPath:Js.nil,errSchemaPath:`${r.errSchemaPath}/${i}`,topSchemaRef:a,compositeRule:!0},c),t.pass(c,()=>t.error(!0))}dg.macroKeywordCode=C9A;function d9A(t,e){var A;let{gen:i,keyword:n,schema:o,parentSchema:r,$data:s,it:a}=t;E9A(a,e);let c=!s&&e.compile?e.compile.call(a.self,o,r,a):e.validate,l=BX(i,n,c),I=i.let("valid");t.block$data(I,C),t.ok((A=e.valid)!==null&&A!==void 0?A:I);function C(){if(e.errors===!1)E(),e.modifying&&dX(t),Q(()=>t.error());else{let u=e.async?d():B();e.modifying&&dX(t),Q(()=>B9A(t,u))}}function d(){let u=i.let("ruleErrs",null);return i.try(()=>E((0,Js._)`await `),v=>i.assign(I,!1).if((0,Js._)`${v} instanceof ${a.ValidationError}`,()=>i.assign(u,(0,Js._)`${v}.errors`),()=>i.throw(v))),u}function B(){let u=(0,Js._)`${l}.errors`;return i.assign(u,null),E(Js.nil),u}function E(u=e.async?(0,Js._)`await `:Js.nil){let v=a.opts.passContext?eC.default.this:eC.default.self,L=!("compile"in e&&!s||e.schema===!1);i.assign(I,(0,Js._)`${u}${(0,g9A.callValidateCode)(t,l,v,L)}`,e.modifying)}function Q(u){var v;i.if((0,Js.not)((v=e.valid)!==null&&v!==void 0?v:I),u)}}dg.funcKeywordCode=d9A;function dX(t){let{gen:e,data:A,it:i}=t;e.if(i.parentData,()=>e.assign(A,(0,Js._)`${i.parentData}[${i.parentDataProperty}]`))}function B9A(t,e){let{gen:A}=t;A.if((0,Js._)`Array.isArray(${e})`,()=>{A.assign(eC.default.vErrors,(0,Js._)`${eC.default.vErrors} === null ? ${e} : ${eC.default.vErrors}.concat(${e})`).assign(eC.default.errors,(0,Js._)`${eC.default.vErrors}.length`),(0,I9A.extendErrors)(t)},()=>t.error())}function E9A({schemaEnv:t},e){if(e.async&&!t.$async)throw new Error("async keyword in sync schema")}function BX(t,e,A){if(A===void 0)throw new Error(`keyword "${e}" failed to compile`);return t.scopeValue("keyword",typeof A=="function"?{ref:A}:{ref:A,code:(0,Js.stringify)(A)})}function h9A(t,e,A=!1){return!e.length||e.some(i=>i==="array"?Array.isArray(t):i==="object"?t&&typeof t=="object"&&!Array.isArray(t):typeof t==i||A&&typeof t>"u")}dg.validSchemaType=h9A;function Q9A({schema:t,opts:e,self:A,errSchemaPath:i},n,o){if(Array.isArray(n.keyword)?!n.keyword.includes(o):n.keyword!==o)throw new Error("ajv implementation error");let r=n.dependencies;if(r?.some(s=>!Object.prototype.hasOwnProperty.call(t,s)))throw new Error(`parent schema must have dependencies of ${o}: ${r.join(",")}`);if(n.validateSchema&&!n.validateSchema(t[o])){let a=`keyword "${o}" value is invalid at path "${i}": `+A.errorsText(n.validateSchema.errors);if(e.validateSchema==="log")A.logger.error(a);else throw new Error(a)}}dg.validateKeywordUsage=Q9A});var QX=Le(l1=>{"use strict";Object.defineProperty(l1,"__esModule",{value:!0});l1.extendSubschemaMode=l1.extendSubschemaData=l1.getSubschema=void 0;var Bg=Ji(),hX=Cn();function u9A(t,{keyword:e,schemaProp:A,schema:i,schemaPath:n,errSchemaPath:o,topSchemaRef:r}){if(e!==void 0&&i!==void 0)throw new Error('both "keyword" and "schema" passed, only one allowed');if(e!==void 0){let s=t.schema[e];return A===void 0?{schema:s,schemaPath:(0,Bg._)`${t.schemaPath}${(0,Bg.getProperty)(e)}`,errSchemaPath:`${t.errSchemaPath}/${e}`}:{schema:s[A],schemaPath:(0,Bg._)`${t.schemaPath}${(0,Bg.getProperty)(e)}${(0,Bg.getProperty)(A)}`,errSchemaPath:`${t.errSchemaPath}/${e}/${(0,hX.escapeFragment)(A)}`}}if(i!==void 0){if(n===void 0||o===void 0||r===void 0)throw new Error('"schemaPath", "errSchemaPath" and "topSchemaRef" are required with "schema"');return{schema:i,schemaPath:n,topSchemaRef:r,errSchemaPath:o}}throw new Error('either "keyword" or "schema" must be passed')}l1.getSubschema=u9A;function f9A(t,e,{dataProp:A,dataPropType:i,data:n,dataTypes:o,propertyName:r}){if(n!==void 0&&A!==void 0)throw new Error('both "data" and "dataProp" passed, only one allowed');let{gen:s}=e;if(A!==void 0){let{errorPath:c,dataPathArr:l,opts:I}=e,C=s.let("data",(0,Bg._)`${e.data}${(0,Bg.getProperty)(A)}`,!0);a(C),t.errorPath=(0,Bg.str)`${c}${(0,hX.getErrorPath)(A,i,I.jsPropertySyntax)}`,t.parentDataProperty=(0,Bg._)`${A}`,t.dataPathArr=[...l,t.parentDataProperty]}if(n!==void 0){let c=n instanceof Bg.Name?n:s.let("data",n,!0);a(c),r!==void 0&&(t.propertyName=r)}o&&(t.dataTypes=o);function a(c){t.data=c,t.dataLevel=e.dataLevel+1,t.dataTypes=[],e.definedProperties=new Set,t.parentData=e.data,t.dataNames=[...e.dataNames,c]}}l1.extendSubschemaData=f9A;function m9A(t,{jtdDiscriminator:e,jtdMetadata:A,compositeRule:i,createErrors:n,allErrors:o}){i!==void 0&&(t.compositeRule=i),n!==void 0&&(t.createErrors=n),o!==void 0&&(t.allErrors=o),t.jtdDiscriminator=e,t.jtdMetadata=A}l1.extendSubschemaMode=m9A});var BR=Le((Afe,uX)=>{"use strict";uX.exports=function t(e,A){if(e===A)return!0;if(e&&A&&typeof e=="object"&&typeof A=="object"){if(e.constructor!==A.constructor)return!1;var i,n,o;if(Array.isArray(e)){if(i=e.length,i!=A.length)return!1;for(n=i;n--!==0;)if(!t(e[n],A[n]))return!1;return!0}if(e.constructor===RegExp)return e.source===A.source&&e.flags===A.flags;if(e.valueOf!==Object.prototype.valueOf)return e.valueOf()===A.valueOf();if(e.toString!==Object.prototype.toString)return e.toString()===A.toString();if(o=Object.keys(e),i=o.length,i!==Object.keys(A).length)return!1;for(n=i;n--!==0;)if(!Object.prototype.hasOwnProperty.call(A,o[n]))return!1;for(n=i;n--!==0;){var r=o[n];if(!t(e[r],A[r]))return!1}return!0}return e!==e&&A!==A}});var mX=Le((efe,fX)=>{"use strict";var g1=fX.exports=function(t,e,A){typeof e=="function"&&(A=e,e={}),A=e.cb||A;var i=typeof A=="function"?A:A.pre||function(){},n=A.post||function(){};f5(e,i,n,t,"",t)};g1.keywords={additionalItems:!0,items:!0,contains:!0,additionalProperties:!0,propertyNames:!0,not:!0,if:!0,then:!0,else:!0};g1.arrayKeywords={items:!0,allOf:!0,anyOf:!0,oneOf:!0};g1.propsKeywords={$defs:!0,definitions:!0,properties:!0,patternProperties:!0,dependencies:!0};g1.skipKeywords={default:!0,enum:!0,const:!0,required:!0,maximum:!0,minimum:!0,exclusiveMaximum:!0,exclusiveMinimum:!0,multipleOf:!0,maxLength:!0,minLength:!0,pattern:!0,format:!0,maxItems:!0,minItems:!0,uniqueItems:!0,maxProperties:!0,minProperties:!0};function f5(t,e,A,i,n,o,r,s,a,c){if(i&&typeof i=="object"&&!Array.isArray(i)){e(i,n,o,r,s,a,c);for(var l in i){var I=i[l];if(Array.isArray(I)){if(l in g1.arrayKeywords)for(var C=0;C<I.length;C++)f5(t,e,A,I[C],n+"/"+l+"/"+C,o,n,l,i,C)}else if(l in g1.propsKeywords){if(I&&typeof I=="object")for(var d in I)f5(t,e,A,I[d],n+"/"+l+"/"+p9A(d),o,n,l,i,d)}else(l in g1.keywords||t.allKeys&&!(l in g1.skipKeywords))&&f5(t,e,A,I,n+"/"+l,o,n,l,i)}A(i,n,o,r,s,a,c)}}function p9A(t){return t.replace(/~/g,"~0").replace(/\//g,"~1")}});var n4=Le(fa=>{"use strict";Object.defineProperty(fa,"__esModule",{value:!0});fa.getSchemaRefs=fa.resolveUrl=fa.normalizeId=fa._getFullPath=fa.getFullPath=fa.inlineRef=void 0;var w9A=Cn(),D9A=BR(),y9A=mX(),v9A=new Set(["type","format","pattern","maxLength","minLength","maxProperties","minProperties","maxItems","minItems","maximum","minimum","uniqueItems","multipleOf","required","enum","const"]);function b9A(t,e=!0){return typeof t=="boolean"?!0:e===!0?!ER(t):e?pX(t)<=e:!1}fa.inlineRef=b9A;var M9A=new Set(["$ref","$recursiveRef","$recursiveAnchor","$dynamicRef","$dynamicAnchor"]);function ER(t){for(let e in t){if(M9A.has(e))return!0;let A=t[e];if(Array.isArray(A)&&A.some(ER)||typeof A=="object"&&ER(A))return!0}return!1}function pX(t){let e=0;for(let A in t){if(A==="$ref")return 1/0;if(e++,!v9A.has(A)&&(typeof t[A]=="object"&&(0,w9A.eachItem)(t[A],i=>e+=pX(i)),e===1/0))return 1/0}return e}function wX(t,e="",A){A!==!1&&(e=eE(e));let i=t.parse(e);return DX(t,i)}fa.getFullPath=wX;function DX(t,e){return t.serialize(e).split("#")[0]+"#"}fa._getFullPath=DX;var k9A=/#\/?$/;function eE(t){return t?t.replace(k9A,""):""}fa.normalizeId=eE;function S9A(t,e,A){return A=eE(A),t.resolve(e,A)}fa.resolveUrl=S9A;var R9A=/^[a-z_][-a-z0-9._]*$/i;function L9A(t,e){if(typeof t=="boolean")return{};let{schemaId:A,uriResolver:i}=this.opts,n=eE(t[A]||e),o={"":n},r=wX(i,n,!1),s={},a=new Set;return y9A(t,{allKeys:!0},(I,C,d,B)=>{if(B===void 0)return;let E=r+C,Q=o[B];typeof I[A]=="string"&&(Q=u.call(this,I[A])),v.call(this,I.$anchor),v.call(this,I.$dynamicAnchor),o[C]=Q;function u(L){let x=this.opts.uriResolver.resolve;if(L=eE(Q?x(Q,L):L),a.has(L))throw l(L);a.add(L);let y=this.refs[L];return typeof y=="string"&&(y=this.refs[y]),typeof y=="object"?c(I,y.schema,L):L!==eE(E)&&(L[0]==="#"?(c(I,s[L],L),s[L]=I):this.refs[L]=E),L}function v(L){if(typeof L=="string"){if(!R9A.test(L))throw new Error(`invalid anchor "${L}"`);u.call(this,`#${L}`)}}}),s;function c(I,C,d){if(C!==void 0&&!D9A(I,C))throw l(d)}function l(I){return new Error(`reference "${I}" resolves to more than one schema`)}}fa.getSchemaRefs=L9A});var s4=Le(I1=>{"use strict";Object.defineProperty(I1,"__esModule",{value:!0});I1.getData=I1.KeywordCxt=I1.validateFunctionCode=void 0;var kX=nX(),yX=i4(),QR=aR(),m5=i4(),x9A=gX(),r4=EX(),hR=QX(),gt=Ji(),Xt=x0(),F9A=n4(),F0=Cn(),o4=t4();function N9A(t){if(LX(t)&&(xX(t),RX(t))){U9A(t);return}SX(t,()=>(0,kX.topBoolOrEmptySchema)(t))}I1.validateFunctionCode=N9A;function SX({gen:t,validateName:e,schema:A,schemaEnv:i,opts:n},o){n.code.es5?t.func(e,(0,gt._)`${Xt.default.data}, ${Xt.default.valCxt}`,i.$async,()=>{t.code((0,gt._)`"use strict"; ${vX(A,n)}`),G9A(t,n),t.code(o)}):t.func(e,(0,gt._)`${Xt.default.data}, ${_9A(n)}`,i.$async,()=>t.code(vX(A,n)).code(o))}function _9A(t){return(0,gt._)`{${Xt.default.instancePath}="", ${Xt.default.parentData}, ${Xt.default.parentDataProperty}, ${Xt.default.rootData}=${Xt.default.data}${t.dynamicRef?(0,gt._)`, ${Xt.default.dynamicAnchors}={}`:gt.nil}}={}`}function G9A(t,e){t.if(Xt.default.valCxt,()=>{t.var(Xt.default.instancePath,(0,gt._)`${Xt.default.valCxt}.${Xt.default.instancePath}`),t.var(Xt.default.parentData,(0,gt._)`${Xt.default.valCxt}.${Xt.default.parentData}`),t.var(Xt.default.parentDataProperty,(0,gt._)`${Xt.default.valCxt}.${Xt.default.parentDataProperty}`),t.var(Xt.default.rootData,(0,gt._)`${Xt.default.valCxt}.${Xt.default.rootData}`),e.dynamicRef&&t.var(Xt.default.dynamicAnchors,(0,gt._)`${Xt.default.valCxt}.${Xt.default.dynamicAnchors}`)},()=>{t.var(Xt.default.instancePath,(0,gt._)`""`),t.var(Xt.default.parentData,(0,gt._)`undefined`),t.var(Xt.default.parentDataProperty,(0,gt._)`undefined`),t.var(Xt.default.rootData,Xt.default.data),e.dynamicRef&&t.var(Xt.default.dynamicAnchors,(0,gt._)`{}`)})}function U9A(t){let{schema:e,opts:A,gen:i}=t;SX(t,()=>{A.$comment&&e.$comment&&NX(t),z9A(t),i.let(Xt.default.vErrors,null),i.let(Xt.default.errors,0),A.unevaluated&&K9A(t),FX(t),P9A(t)})}function K9A(t){let{gen:e,validateName:A}=t;t.evaluated=e.const("evaluated",(0,gt._)`${A}.evaluated`),e.if((0,gt._)`${t.evaluated}.dynamicProps`,()=>e.assign((0,gt._)`${t.evaluated}.props`,(0,gt._)`undefined`)),e.if((0,gt._)`${t.evaluated}.dynamicItems`,()=>e.assign((0,gt._)`${t.evaluated}.items`,(0,gt._)`undefined`))}function vX(t,e){let A=typeof t=="object"&&t[e.schemaId];return A&&(e.code.source||e.code.process)?(0,gt._)`/*# sourceURL=${A} */`:gt.nil}function Y9A(t,e){if(LX(t)&&(xX(t),RX(t))){J9A(t,e);return}(0,kX.boolOrEmptySchema)(t,e)}function RX({schema:t,self:e}){if(typeof t=="boolean")return!t;for(let A in t)if(e.RULES.all[A])return!0;return!1}function LX(t){return typeof t.schema!="boolean"}function J9A(t,e){let{schema:A,gen:i,opts:n}=t;n.$comment&&A.$comment&&NX(t),H9A(t),O9A(t);let o=i.const("_errs",Xt.default.errors);FX(t,o),i.var(e,(0,gt._)`${o} === ${Xt.default.errors}`)}function xX(t){(0,F0.checkUnknownRules)(t),T9A(t)}function FX(t,e){if(t.opts.jtd)return bX(t,[],!1,e);let A=(0,yX.getSchemaTypes)(t.schema),i=(0,yX.coerceAndCheckDataType)(t,A);bX(t,A,!i,e)}function T9A(t){let{schema:e,errSchemaPath:A,opts:i,self:n}=t;e.$ref&&i.ignoreKeywordsWithRef&&(0,F0.schemaHasRulesButRef)(e,n.RULES)&&n.logger.warn(`$ref: keywords ignored in schema at path "${A}"`)}function z9A(t){let{schema:e,opts:A}=t;e.default!==void 0&&A.useDefaults&&A.strictSchema&&(0,F0.checkStrictMode)(t,"default is ignored in the schema root")}function H9A(t){let e=t.schema[t.opts.schemaId];e&&(t.baseId=(0,F9A.resolveUrl)(t.opts.uriResolver,t.baseId,e))}function O9A(t){if(t.schema.$async&&!t.schemaEnv.$async)throw new Error("async schema in sync schema")}function NX({gen:t,schemaEnv:e,schema:A,errSchemaPath:i,opts:n}){let o=A.$comment;if(n.$comment===!0)t.code((0,gt._)`${Xt.default.self}.logger.log(${o})`);else if(typeof n.$comment=="function"){let r=(0,gt.str)`${i}/$comment`,s=t.scopeValue("root",{ref:e.root});t.code((0,gt._)`${Xt.default.self}.opts.$comment(${o}, ${r}, ${s}.schema)`)}}function P9A(t){let{gen:e,schemaEnv:A,validateName:i,ValidationError:n,opts:o}=t;A.$async?e.if((0,gt._)`${Xt.default.errors} === 0`,()=>e.return(Xt.default.data),()=>e.throw((0,gt._)`new ${n}(${Xt.default.vErrors})`)):(e.assign((0,gt._)`${i}.errors`,Xt.default.vErrors),o.unevaluated&&j9A(t),e.return((0,gt._)`${Xt.default.errors} === 0`))}function j9A({gen:t,evaluated:e,props:A,items:i}){A instanceof gt.Name&&t.assign((0,gt._)`${e}.props`,A),i instanceof gt.Name&&t.assign((0,gt._)`${e}.items`,i)}function bX(t,e,A,i){let{gen:n,schema:o,data:r,allErrors:s,opts:a,self:c}=t,{RULES:l}=c;if(o.$ref&&(a.ignoreKeywordsWithRef||!(0,F0.schemaHasRulesButRef)(o,l))){n.block(()=>GX(t,"$ref",l.all.$ref.definition));return}a.jtd||q9A(t,e),n.block(()=>{for(let C of l.rules)I(C);I(l.post)});function I(C){(0,QR.shouldUseGroup)(o,C)&&(C.type?(n.if((0,m5.checkDataType)(C.type,r,a.strictNumbers)),MX(t,C),e.length===1&&e[0]===C.type&&A&&(n.else(),(0,m5.reportTypeError)(t)),n.endIf()):MX(t,C),s||n.if((0,gt._)`${Xt.default.errors} === ${i||0}`))}}function MX(t,e){let{gen:A,schema:i,opts:{useDefaults:n}}=t;n&&(0,x9A.assignDefaults)(t,e.type),A.block(()=>{for(let o of e.rules)(0,QR.shouldUseRule)(i,o)&&GX(t,o.keyword,o.definition,e.type)})}function q9A(t,e){t.schemaEnv.meta||!t.opts.strictTypes||(V9A(t,e),t.opts.allowUnionTypes||Z9A(t,e),W9A(t,t.dataTypes))}function V9A(t,e){if(e.length){if(!t.dataTypes.length){t.dataTypes=e;return}e.forEach(A=>{_X(t.dataTypes,A)||uR(t,`type "${A}" not allowed by context "${t.dataTypes.join(",")}"`)}),$9A(t,e)}}function Z9A(t,e){e.length>1&&!(e.length===2&&e.includes("null"))&&uR(t,"use allowUnionTypes to allow union type keyword")}function W9A(t,e){let A=t.self.RULES.all;for(let i in A){let n=A[i];if(typeof n=="object"&&(0,QR.shouldUseRule)(t.schema,n)){let{type:o}=n.definition;o.length&&!o.some(r=>X9A(e,r))&&uR(t,`missing type "${o.join(",")}" for keyword "${i}"`)}}}function X9A(t,e){return t.includes(e)||e==="number"&&t.includes("integer")}function _X(t,e){return t.includes(e)||e==="integer"&&t.includes("number")}function $9A(t,e){let A=[];for(let i of t.dataTypes)_X(e,i)?A.push(i):e.includes("integer")&&i==="number"&&A.push("integer");t.dataTypes=A}function uR(t,e){let A=t.schemaEnv.baseId+t.errSchemaPath;e+=` at "${A}" (strictTypes)`,(0,F0.checkStrictMode)(t,e,t.opts.strictTypes)}var p5=class{constructor(e,A,i){if((0,r4.validateKeywordUsage)(e,A,i),this.gen=e.gen,this.allErrors=e.allErrors,this.keyword=i,this.data=e.data,this.schema=e.schema[i],this.$data=A.$data&&e.opts.$data&&this.schema&&this.schema.$data,this.schemaValue=(0,F0.schemaRefOrVal)(e,this.schema,i,this.$data),this.schemaType=A.schemaType,this.parentSchema=e.schema,this.params={},this.it=e,this.def=A,this.$data)this.schemaCode=e.gen.const("vSchema",UX(this.$data,e));else if(this.schemaCode=this.schemaValue,!(0,r4.validSchemaType)(this.schema,A.schemaType,A.allowUndefined))throw new Error(`${i} value must be ${JSON.stringify(A.schemaType)}`);("code"in A?A.trackErrors:A.errors!==!1)&&(this.errsCount=e.gen.const("_errs",Xt.default.errors))}result(e,A,i){this.failResult((0,gt.not)(e),A,i)}failResult(e,A,i){this.gen.if(e),i?i():this.error(),A?(this.gen.else(),A(),this.allErrors&&this.gen.endIf()):this.allErrors?this.gen.endIf():this.gen.else()}pass(e,A){this.failResult((0,gt.not)(e),void 0,A)}fail(e){if(e===void 0){this.error(),this.allErrors||this.gen.if(!1);return}this.gen.if(e),this.error(),this.allErrors?this.gen.endIf():this.gen.else()}fail$data(e){if(!this.$data)return this.fail(e);let{schemaCode:A}=this;this.fail((0,gt._)`${A} !== undefined && (${(0,gt.or)(this.invalid$data(),e)})`)}error(e,A,i){if(A){this.setParams(A),this._error(e,i),this.setParams({});return}this._error(e,i)}_error(e,A){(e?o4.reportExtraError:o4.reportError)(this,this.def.error,A)}$dataError(){(0,o4.reportError)(this,this.def.$dataError||o4.keyword$DataError)}reset(){if(this.errsCount===void 0)throw new Error('add "trackErrors" to keyword definition');(0,o4.resetErrorsCount)(this.gen,this.errsCount)}ok(e){this.allErrors||this.gen.if(e)}setParams(e,A){A?Object.assign(this.params,e):this.params=e}block$data(e,A,i=gt.nil){this.gen.block(()=>{this.check$data(e,i),A()})}check$data(e=gt.nil,A=gt.nil){if(!this.$data)return;let{gen:i,schemaCode:n,schemaType:o,def:r}=this;i.if((0,gt.or)((0,gt._)`${n} === undefined`,A)),e!==gt.nil&&i.assign(e,!0),(o.length||r.validateSchema)&&(i.elseIf(this.invalid$data()),this.$dataError(),e!==gt.nil&&i.assign(e,!1)),i.else()}invalid$data(){let{gen:e,schemaCode:A,schemaType:i,def:n,it:o}=this;return(0,gt.or)(r(),s());function r(){if(i.length){if(!(A instanceof gt.Name))throw new Error("ajv implementation error");let a=Array.isArray(i)?i:[i];return(0,gt._)`${(0,m5.checkDataTypes)(a,A,o.opts.strictNumbers,m5.DataType.Wrong)}`}return gt.nil}function s(){if(n.validateSchema){let a=e.scopeValue("validate$data",{ref:n.validateSchema});return(0,gt._)`!${a}(${A})`}return gt.nil}}subschema(e,A){let i=(0,hR.getSubschema)(this.it,e);(0,hR.extendSubschemaData)(i,this.it,e),(0,hR.extendSubschemaMode)(i,e);let n=Ne(nA(nA({},this.it),i),{items:void 0,props:void 0});return Y9A(n,A),n}mergeEvaluated(e,A){let{it:i,gen:n}=this;i.opts.unevaluated&&(i.props!==!0&&e.props!==void 0&&(i.props=F0.mergeEvaluated.props(n,e.props,i.props,A)),i.items!==!0&&e.items!==void 0&&(i.items=F0.mergeEvaluated.items(n,e.items,i.items,A)))}mergeValidEvaluated(e,A){let{it:i,gen:n}=this;if(i.opts.unevaluated&&(i.props!==!0||i.items!==!0))return n.if(A,()=>this.mergeEvaluated(e,gt.Name)),!0}};I1.KeywordCxt=p5;function GX(t,e,A,i){let n=new p5(t,A,e);"code"in A?A.code(n,i):n.$data&&A.validate?(0,r4.funcKeywordCode)(n,A):"macro"in A?(0,r4.macroKeywordCode)(n,A):(A.compile||A.validate)&&(0,r4.funcKeywordCode)(n,A)}var AbA=/^\/(?:[^~]|~0|~1)*$/,ebA=/^([0-9]+)(#|\/(?:[^~]|~0|~1)*)?$/;function UX(t,{dataLevel:e,dataNames:A,dataPathArr:i}){let n,o;if(t==="")return Xt.default.rootData;if(t[0]==="/"){if(!AbA.test(t))throw new Error(`Invalid JSON-pointer: ${t}`);n=t,o=Xt.default.rootData}else{let c=ebA.exec(t);if(!c)throw new Error(`Invalid JSON-pointer: ${t}`);let l=+c[1];if(n=c[2],n==="#"){if(l>=e)throw new Error(a("property/index",l));return i[e-l]}if(l>e)throw new Error(a("data",l));if(o=A[e-l],!n)return o}let r=o,s=n.split("/");for(let c of s)c&&(o=(0,gt._)`${o}${(0,gt.getProperty)((0,F0.unescapeJsonPointer)(c))}`,r=(0,gt._)`${r} && ${o}`);return r;function a(c,l){return`Cannot access ${c} ${l} levels up, current level is ${e}`}}I1.getData=UX});var w5=Le(mR=>{"use strict";Object.defineProperty(mR,"__esModule",{value:!0});var fR=class extends Error{constructor(e){super("validation failed"),this.errors=e,this.ajv=this.validation=!0}};mR.default=fR});var a4=Le(DR=>{"use strict";Object.defineProperty(DR,"__esModule",{value:!0});var pR=n4(),wR=class extends Error{constructor(e,A,i,n){super(n||`can't resolve reference ${i} from id ${A}`),this.missingRef=(0,pR.resolveUrl)(e,A,i),this.missingSchema=(0,pR.normalizeId)((0,pR.getFullPath)(e,this.missingRef))}};DR.default=wR});var y5=Le(Rc=>{"use strict";Object.defineProperty(Rc,"__esModule",{value:!0});Rc.resolveSchema=Rc.getCompilingSchema=Rc.resolveRef=Rc.compileSchema=Rc.SchemaEnv=void 0;var gl=Ji(),tbA=w5(),tC=x0(),Il=n4(),KX=Cn(),ibA=s4(),tE=class{constructor(e){var A;this.refs={},this.dynamicAnchors={};let i;typeof e.schema=="object"&&(i=e.schema),this.schema=e.schema,this.schemaId=e.schemaId,this.root=e.root||this,this.baseId=(A=e.baseId)!==null&&A!==void 0?A:(0,Il.normalizeId)(i?.[e.schemaId||"$id"]),this.schemaPath=e.schemaPath,this.localRefs=e.localRefs,this.meta=e.meta,this.$async=i?.$async,this.refs={}}};Rc.SchemaEnv=tE;function vR(t){let e=YX.call(this,t);if(e)return e;let A=(0,Il.getFullPath)(this.opts.uriResolver,t.root.baseId),{es5:i,lines:n}=this.opts.code,{ownProperties:o}=this.opts,r=new gl.CodeGen(this.scope,{es5:i,lines:n,ownProperties:o}),s;t.$async&&(s=r.scopeValue("Error",{ref:tbA.default,code:(0,gl._)`require("ajv/dist/runtime/validation_error").default`}));let a=r.scopeName("validate");t.validateName=a;let c={gen:r,allErrors:this.opts.allErrors,data:tC.default.data,parentData:tC.default.parentData,parentDataProperty:tC.default.parentDataProperty,dataNames:[tC.default.data],dataPathArr:[gl.nil],dataLevel:0,dataTypes:[],definedProperties:new Set,topSchemaRef:r.scopeValue("schema",this.opts.code.source===!0?{ref:t.schema,code:(0,gl.stringify)(t.schema)}:{ref:t.schema}),validateName:a,ValidationError:s,schema:t.schema,schemaEnv:t,rootId:A,baseId:t.baseId||A,schemaPath:gl.nil,errSchemaPath:t.schemaPath||(this.opts.jtd?"":"#"),errorPath:(0,gl._)`""`,opts:this.opts,self:this},l;try{this._compilations.add(t),(0,ibA.validateFunctionCode)(c),r.optimize(this.opts.code.optimize);let I=r.toString();l=`${r.scopeRefs(tC.default.scope)}return ${I}`,this.opts.code.process&&(l=this.opts.code.process(l,t));let d=new Function(`${tC.default.self}`,`${tC.default.scope}`,l)(this,this.scope.get());if(this.scope.value(a,{ref:d}),d.errors=null,d.schema=t.schema,d.schemaEnv=t,t.$async&&(d.$async=!0),this.opts.code.source===!0&&(d.source={validateName:a,validateCode:I,scopeValues:r._values}),this.opts.unevaluated){let{props:B,items:E}=c;d.evaluated={props:B instanceof gl.Name?void 0:B,items:E instanceof gl.Name?void 0:E,dynamicProps:B instanceof gl.Name,dynamicItems:E instanceof gl.Name},d.source&&(d.source.evaluated=(0,gl.stringify)(d.evaluated))}return t.validate=d,t}catch(I){throw delete t.validate,delete t.validateName,l&&this.logger.error("Error compiling schema, function code:",l),I}finally{this._compilations.delete(t)}}Rc.compileSchema=vR;function nbA(t,e,A){var i;A=(0,Il.resolveUrl)(this.opts.uriResolver,e,A);let n=t.refs[A];if(n)return n;let o=sbA.call(this,t,A);if(o===void 0){let r=(i=t.localRefs)===null||i===void 0?void 0:i[A],{schemaId:s}=this.opts;r&&(o=new tE({schema:r,schemaId:s,root:t,baseId:e}))}if(o!==void 0)return t.refs[A]=obA.call(this,o)}Rc.resolveRef=nbA;function obA(t){return(0,Il.inlineRef)(t.schema,this.opts.inlineRefs)?t.schema:t.validate?t:vR.call(this,t)}function YX(t){for(let e of this._compilations)if(rbA(e,t))return e}Rc.getCompilingSchema=YX;function rbA(t,e){return t.schema===e.schema&&t.root===e.root&&t.baseId===e.baseId}function sbA(t,e){let A;for(;typeof(A=this.refs[e])=="string";)e=A;return A||this.schemas[e]||D5.call(this,t,e)}function D5(t,e){let A=this.opts.uriResolver.parse(e),i=(0,Il._getFullPath)(this.opts.uriResolver,A),n=(0,Il.getFullPath)(this.opts.uriResolver,t.baseId,void 0);if(Object.keys(t.schema).length>0&&i===n)return yR.call(this,A,t);let o=(0,Il.normalizeId)(i),r=this.refs[o]||this.schemas[o];if(typeof r=="string"){let s=D5.call(this,t,r);return typeof s?.schema!="object"?void 0:yR.call(this,A,s)}if(typeof r?.schema=="object"){if(r.validate||vR.call(this,r),o===(0,Il.normalizeId)(e)){let{schema:s}=r,{schemaId:a}=this.opts,c=s[a];return c&&(n=(0,Il.resolveUrl)(this.opts.uriResolver,n,c)),new tE({schema:s,schemaId:a,root:t,baseId:n})}return yR.call(this,A,r)}}Rc.resolveSchema=D5;var abA=new Set(["properties","patternProperties","enum","dependencies","definitions"]);function yR(t,{baseId:e,schema:A,root:i}){var n;if(((n=t.fragment)===null||n===void 0?void 0:n[0])!=="/")return;for(let s of t.fragment.slice(1).split("/")){if(typeof A=="boolean")return;let a=A[(0,KX.unescapeFragment)(s)];if(a===void 0)return;A=a;let c=typeof A=="object"&&A[this.opts.schemaId];!abA.has(s)&&c&&(e=(0,Il.resolveUrl)(this.opts.uriResolver,e,c))}let o;if(typeof A!="boolean"&&A.$ref&&!(0,KX.schemaHasRulesButRef)(A,this.RULES)){let s=(0,Il.resolveUrl)(this.opts.uriResolver,e,A.$ref);o=D5.call(this,i,s)}let{schemaId:r}=this.opts;if(o=o||new tE({schema:A,schemaId:r,root:i,baseId:e}),o.schema!==o.root.schema)return o}});var JX=Le((afe,cbA)=>{cbA.exports={$id:"https://raw.githubusercontent.com/ajv-validator/ajv/master/lib/refs/data.json#",description:"Meta-schema for $data reference (JSON AnySchema extension proposal)",type:"object",required:["$data"],properties:{$data:{type:"string",anyOf:[{format:"relative-json-pointer"},{format:"json-pointer"}]}},additionalProperties:!1}});var zX=Le((cfe,TX)=>{"use strict";var lbA={0:0,1:1,2:2,3:3,4:4,5:5,6:6,7:7,8:8,9:9,a:10,A:10,b:11,B:11,c:12,C:12,d:13,D:13,e:14,E:14,f:15,F:15};TX.exports={HEX:lbA}});var WX=Le((lfe,ZX)=>{"use strict";var{HEX:gbA}=zX(),IbA=/^(?:(?:25[0-5]|2[0-4]\d|1\d{2}|[1-9]\d|\d)\.){3}(?:25[0-5]|2[0-4]\d|1\d{2}|[1-9]\d|\d)$/u;function jX(t){if(VX(t,".")<3)return{host:t,isIPV4:!1};let e=t.match(IbA)||[],[A]=e;return A?{host:dbA(A,"."),isIPV4:!0}:{host:t,isIPV4:!1}}function bR(t,e=!1){let A="",i=!0;for(let n of t){if(gbA[n]===void 0)return;n!=="0"&&i===!0&&(i=!1),i||(A+=n)}return e&&A.length===0&&(A="0"),A}function CbA(t){let e=0,A={error:!1,address:"",zone:""},i=[],n=[],o=!1,r=!1,s=!1;function a(){if(n.length){if(o===!1){let c=bR(n);if(c!==void 0)i.push(c);else return A.error=!0,!1}n.length=0}return!0}for(let c=0;c<t.length;c++){let l=t[c];if(!(l==="["||l==="]"))if(l===":"){if(r===!0&&(s=!0),!a())break;if(e++,i.push(":"),e>7){A.error=!0;break}c-1>=0&&t[c-1]===":"&&(r=!0);continue}else if(l==="%"){if(!a())break;o=!0}else{n.push(l);continue}}return n.length&&(o?A.zone=n.join(""):s?i.push(n.join("")):i.push(bR(n))),A.address=i.join(""),A}function qX(t){if(VX(t,":")<2)return{host:t,isIPV6:!1};let e=CbA(t);if(e.error)return{host:t,isIPV6:!1};{let A=e.address,i=e.address;return e.zone&&(A+="%"+e.zone,i+="%25"+e.zone),{host:A,escapedHost:i,isIPV6:!0}}}function dbA(t,e){let A="",i=!0,n=t.length;for(let o=0;o<n;o++){let r=t[o];r==="0"&&i?(o+1<=n&&t[o+1]===e||o+1===n)&&(A+=r,i=!1):(r===e?i=!0:i=!1,A+=r)}return A}function VX(t,e){let A=0;for(let i=0;i<t.length;i++)t[i]===e&&A++;return A}var HX=/^\.\.?\//u,OX=/^\/\.(?:\/|$)/u,PX=/^\/\.\.(?:\/|$)/u,BbA=/^\/?(?:.|\n)*?(?=\/|$)/u;function EbA(t){let e=[];for(;t.length;)if(t.match(HX))t=t.replace(HX,"");else if(t.match(OX))t=t.replace(OX,"/");else if(t.match(PX))t=t.replace(PX,"/"),e.pop();else if(t==="."||t==="..")t="";else{let A=t.match(BbA);if(A){let i=A[0];t=t.slice(i.length),e.push(i)}else throw new Error("Unexpected dot segment condition")}return e.join("")}function hbA(t,e){let A=e!==!0?escape:unescape;return t.scheme!==void 0&&(t.scheme=A(t.scheme)),t.userinfo!==void 0&&(t.userinfo=A(t.userinfo)),t.host!==void 0&&(t.host=A(t.host)),t.path!==void 0&&(t.path=A(t.path)),t.query!==void 0&&(t.query=A(t.query)),t.fragment!==void 0&&(t.fragment=A(t.fragment)),t}function QbA(t){let e=[];if(t.userinfo!==void 0&&(e.push(t.userinfo),e.push("@")),t.host!==void 0){let A=unescape(t.host),i=jX(A);if(i.isIPV4)A=i.host;else{let n=qX(i.host);n.isIPV6===!0?A=`[${n.escapedHost}]`:A=t.host}e.push(A)}return(typeof t.port=="number"||typeof t.port=="string")&&(e.push(":"),e.push(String(t.port))),e.length?e.join(""):void 0}ZX.exports={recomposeAuthority:QbA,normalizeComponentEncoding:hbA,removeDotSegments:EbA,normalizeIPv4:jX,normalizeIPv6:qX,stringArrayToHexStripped:bR}});var i$=Le((gfe,t$)=>{"use strict";var ubA=/^[\da-f]{8}-[\da-f]{4}-[\da-f]{4}-[\da-f]{4}-[\da-f]{12}$/iu,fbA=/([\da-z][\d\-a-z]{0,31}):((?:[\w!$'()*+,\-.:;=@]|%[\da-f]{2})+)/iu;function XX(t){return typeof t.secure=="boolean"?t.secure:String(t.scheme).toLowerCase()==="wss"}function $X(t){return t.host||(t.error=t.error||"HTTP URIs must have a host."),t}function A$(t){let e=String(t.scheme).toLowerCase()==="https";return(t.port===(e?443:80)||t.port==="")&&(t.port=void 0),t.path||(t.path="/"),t}function mbA(t){return t.secure=XX(t),t.resourceName=(t.path||"/")+(t.query?"?"+t.query:""),t.path=void 0,t.query=void 0,t}function pbA(t){if((t.port===(XX(t)?443:80)||t.port==="")&&(t.port=void 0),typeof t.secure=="boolean"&&(t.scheme=t.secure?"wss":"ws",t.secure=void 0),t.resourceName){let[e,A]=t.resourceName.split("?");t.path=e&&e!=="/"?e:void 0,t.query=A,t.resourceName=void 0}return t.fragment=void 0,t}function wbA(t,e){if(!t.path)return t.error="URN can not be parsed",t;let A=t.path.match(fbA);if(A){let i=e.scheme||t.scheme||"urn";t.nid=A[1].toLowerCase(),t.nss=A[2];let n=`${i}:${e.nid||t.nid}`,o=MR[n];t.path=void 0,o&&(t=o.parse(t,e))}else t.error=t.error||"URN can not be parsed.";return t}function DbA(t,e){let A=e.scheme||t.scheme||"urn",i=t.nid.toLowerCase(),n=`${A}:${e.nid||i}`,o=MR[n];o&&(t=o.serialize(t,e));let r=t,s=t.nss;return r.path=`${i||e.nid}:${s}`,e.skipEscape=!0,r}function ybA(t,e){let A=t;return A.uuid=A.nss,A.nss=void 0,!e.tolerant&&(!A.uuid||!ubA.test(A.uuid))&&(A.error=A.error||"UUID is not valid."),A}function vbA(t){let e=t;return e.nss=(t.uuid||"").toLowerCase(),e}var e$={scheme:"http",domainHost:!0,parse:$X,serialize:A$},bbA={scheme:"https",domainHost:e$.domainHost,parse:$X,serialize:A$},v5={scheme:"ws",domainHost:!0,parse:mbA,serialize:pbA},MbA={scheme:"wss",domainHost:v5.domainHost,parse:v5.parse,serialize:v5.serialize},kbA={scheme:"urn",parse:wbA,serialize:DbA,skipNormalize:!0},SbA={scheme:"urn:uuid",parse:ybA,serialize:vbA,skipNormalize:!0},MR={http:e$,https:bbA,ws:v5,wss:MbA,urn:kbA,"urn:uuid":SbA};t$.exports=MR});var o$=Le((Ife,M5)=>{"use strict";var{normalizeIPv6:RbA,normalizeIPv4:LbA,removeDotSegments:c4,recomposeAuthority:xbA,normalizeComponentEncoding:b5}=WX(),kR=i$();function FbA(t,e){return typeof t=="string"?t=Eg(N0(t,e),e):typeof t=="object"&&(t=N0(Eg(t,e),e)),t}function NbA(t,e,A){let i=Object.assign({scheme:"null"},A),n=n$(N0(t,i),N0(e,i),i,!0);return Eg(n,Ne(nA({},i),{skipEscape:!0}))}function n$(t,e,A,i){let n={};return i||(t=N0(Eg(t,A),A),e=N0(Eg(e,A),A)),A=A||{},!A.tolerant&&e.scheme?(n.scheme=e.scheme,n.userinfo=e.userinfo,n.host=e.host,n.port=e.port,n.path=c4(e.path||""),n.query=e.query):(e.userinfo!==void 0||e.host!==void 0||e.port!==void 0?(n.userinfo=e.userinfo,n.host=e.host,n.port=e.port,n.path=c4(e.path||""),n.query=e.query):(e.path?(e.path.charAt(0)==="/"?n.path=c4(e.path):((t.userinfo!==void 0||t.host!==void 0||t.port!==void 0)&&!t.path?n.path="/"+e.path:t.path?n.path=t.path.slice(0,t.path.lastIndexOf("/")+1)+e.path:n.path=e.path,n.path=c4(n.path)),n.query=e.query):(n.path=t.path,e.query!==void 0?n.query=e.query:n.query=t.query),n.userinfo=t.userinfo,n.host=t.host,n.port=t.port),n.scheme=t.scheme),n.fragment=e.fragment,n}function _bA(t,e,A){return typeof t=="string"?(t=unescape(t),t=Eg(b5(N0(t,A),!0),Ne(nA({},A),{skipEscape:!0}))):typeof t=="object"&&(t=Eg(b5(t,!0),Ne(nA({},A),{skipEscape:!0}))),typeof e=="string"?(e=unescape(e),e=Eg(b5(N0(e,A),!0),Ne(nA({},A),{skipEscape:!0}))):typeof e=="object"&&(e=Eg(b5(e,!0),Ne(nA({},A),{skipEscape:!0}))),t.toLowerCase()===e.toLowerCase()}function Eg(t,e){let A={host:t.host,scheme:t.scheme,userinfo:t.userinfo,port:t.port,path:t.path,query:t.query,nid:t.nid,nss:t.nss,uuid:t.uuid,fragment:t.fragment,reference:t.reference,resourceName:t.resourceName,secure:t.secure,error:""},i=Object.assign({},e),n=[],o=kR[(i.scheme||A.scheme||"").toLowerCase()];o&&o.serialize&&o.serialize(A,i),A.path!==void 0&&(i.skipEscape?A.path=unescape(A.path):(A.path=escape(A.path),A.scheme!==void 0&&(A.path=A.path.split("%3A").join(":")))),i.reference!=="suffix"&&A.scheme&&n.push(A.scheme,":");let r=xbA(A);if(r!==void 0&&(i.reference!=="suffix"&&n.push("//"),n.push(r),A.path&&A.path.charAt(0)!=="/"&&n.push("/")),A.path!==void 0){let s=A.path;!i.absolutePath&&(!o||!o.absolutePath)&&(s=c4(s)),r===void 0&&(s=s.replace(/^\/\//u,"/%2F")),n.push(s)}return A.query!==void 0&&n.push("?",A.query),A.fragment!==void 0&&n.push("#",A.fragment),n.join("")}var GbA=Array.from({length:127},(t,e)=>/[^!"$&'()*+,\-.;=_`a-z{}~]/u.test(String.fromCharCode(e)));function UbA(t){let e=0;for(let A=0,i=t.length;A<i;++A)if(e=t.charCodeAt(A),e>126||GbA[e])return!0;return!1}var KbA=/^(?:([^#/:?]+):)?(?:\/\/((?:([^#/?@]*)@)?(\[[^#/?\]]+\]|[^#/:?]*)(?::(\d*))?))?([^#?]*)(?:\?([^#]*))?(?:#((?:.|[\n\r])*))?/u;function N0(t,e){let A=Object.assign({},e),i={scheme:void 0,userinfo:void 0,host:"",port:void 0,path:"",query:void 0,fragment:void 0},n=t.indexOf("%")!==-1,o=!1;A.reference==="suffix"&&(t=(A.scheme?A.scheme+":":"")+"//"+t);let r=t.match(KbA);if(r){if(i.scheme=r[1],i.userinfo=r[3],i.host=r[4],i.port=parseInt(r[5],10),i.path=r[6]||"",i.query=r[7],i.fragment=r[8],isNaN(i.port)&&(i.port=r[5]),i.host){let a=LbA(i.host);if(a.isIPV4===!1){let c=RbA(a.host);i.host=c.host.toLowerCase(),o=c.isIPV6}else i.host=a.host,o=!0}i.scheme===void 0&&i.userinfo===void 0&&i.host===void 0&&i.port===void 0&&i.query===void 0&&!i.path?i.reference="same-document":i.scheme===void 0?i.reference="relative":i.fragment===void 0?i.reference="absolute":i.reference="uri",A.reference&&A.reference!=="suffix"&&A.reference!==i.reference&&(i.error=i.error||"URI is not a "+A.reference+" reference.");let s=kR[(A.scheme||i.scheme||"").toLowerCase()];if(!A.unicodeSupport&&(!s||!s.unicodeSupport)&&i.host&&(A.domainHost||s&&s.domainHost)&&o===!1&&UbA(i.host))try{i.host=URL.domainToASCII(i.host.toLowerCase())}catch(a){i.error=i.error||"Host's domain name can not be converted to ASCII: "+a}(!s||s&&!s.skipNormalize)&&(n&&i.scheme!==void 0&&(i.scheme=unescape(i.scheme)),n&&i.host!==void 0&&(i.host=unescape(i.host)),i.path&&(i.path=escape(unescape(i.path))),i.fragment&&(i.fragment=encodeURI(decodeURIComponent(i.fragment)))),s&&s.parse&&s.parse(i,A)}else i.error=i.error||"URI can not be parsed.";return i}var SR={SCHEMES:kR,normalize:FbA,resolve:NbA,resolveComponents:n$,equal:_bA,serialize:Eg,parse:N0};M5.exports=SR;M5.exports.default=SR;M5.exports.fastUri=SR});var s$=Le(RR=>{"use strict";Object.defineProperty(RR,"__esModule",{value:!0});var r$=o$();r$.code='require("ajv/dist/runtime/uri").default';RR.default=r$});var B$=Le(es=>{"use strict";Object.defineProperty(es,"__esModule",{value:!0});es.CodeGen=es.Name=es.nil=es.stringify=es.str=es._=es.KeywordCxt=void 0;var YbA=s4();Object.defineProperty(es,"KeywordCxt",{enumerable:!0,get:function(){return YbA.KeywordCxt}});var iE=Ji();Object.defineProperty(es,"_",{enumerable:!0,get:function(){return iE._}});Object.defineProperty(es,"str",{enumerable:!0,get:function(){return iE.str}});Object.defineProperty(es,"stringify",{enumerable:!0,get:function(){return iE.stringify}});Object.defineProperty(es,"nil",{enumerable:!0,get:function(){return iE.nil}});Object.defineProperty(es,"Name",{enumerable:!0,get:function(){return iE.Name}});Object.defineProperty(es,"CodeGen",{enumerable:!0,get:function(){return iE.CodeGen}});var JbA=w5(),I$=a4(),TbA=sR(),l4=y5(),zbA=Ji(),g4=n4(),k5=i4(),xR=Cn(),a$=JX(),HbA=s$(),C$=(t,e)=>new RegExp(t,e);C$.code="new RegExp";var ObA=["removeAdditional","useDefaults","coerceTypes"],PbA=new Set(["validate","serialize","parse","wrapper","root","schema","keyword","pattern","formats","validate$data","func","obj","Error"]),jbA={errorDataPath:"",format:"`validateFormats: false` can be used instead.",nullable:'"nullable" keyword is supported by default.',jsonPointers:"Deprecated jsPropertySyntax can be used instead.",extendRefs:"Deprecated ignoreKeywordsWithRef can be used instead.",missingRefs:"Pass empty schema with $id that should be ignored to ajv.addSchema.",processCode:"Use option `code: {process: (code, schemaEnv: object) => string}`",sourceCode:"Use option `code: {source: true}`",strictDefaults:"It is default now, see option `strict`.",strictKeywords:"It is default now, see option `strict`.",uniqueItems:'"uniqueItems" keyword is always validated.',unknownFormats:"Disable strict mode or pass `true` to `ajv.addFormat` (or `formats` option).",cache:"Map is used as cache, schema object as key.",serialize:"Map is used as cache, schema object as key.",ajvErrors:"It is default now."},qbA={ignoreKeywordsWithRef:"",jsPropertySyntax:"",unicode:'"minLength"/"maxLength" account for unicode characters by default.'},c$=200;function VbA(t){var e,A,i,n,o,r,s,a,c,l,I,C,d,B,E,Q,u,v,L,x,y,F,U,T,N;let K=t.strict,H=(e=t.code)===null||e===void 0?void 0:e.optimize,j=H===!0||H===void 0?1:H||0,IA=(i=(A=t.code)===null||A===void 0?void 0:A.regExp)!==null&&i!==void 0?i:C$,lA=(n=t.uriResolver)!==null&&n!==void 0?n:HbA.default;return{strictSchema:(r=(o=t.strictSchema)!==null&&o!==void 0?o:K)!==null&&r!==void 0?r:!0,strictNumbers:(a=(s=t.strictNumbers)!==null&&s!==void 0?s:K)!==null&&a!==void 0?a:!0,strictTypes:(l=(c=t.strictTypes)!==null&&c!==void 0?c:K)!==null&&l!==void 0?l:"log",strictTuples:(C=(I=t.strictTuples)!==null&&I!==void 0?I:K)!==null&&C!==void 0?C:"log",strictRequired:(B=(d=t.strictRequired)!==null&&d!==void 0?d:K)!==null&&B!==void 0?B:!1,code:t.code?Ne(nA({},t.code),{optimize:j,regExp:IA}):{optimize:j,regExp:IA},loopRequired:(E=t.loopRequired)!==null&&E!==void 0?E:c$,loopEnum:(Q=t.loopEnum)!==null&&Q!==void 0?Q:c$,meta:(u=t.meta)!==null&&u!==void 0?u:!0,messages:(v=t.messages)!==null&&v!==void 0?v:!0,inlineRefs:(L=t.inlineRefs)!==null&&L!==void 0?L:!0,schemaId:(x=t.schemaId)!==null&&x!==void 0?x:"$id",addUsedSchema:(y=t.addUsedSchema)!==null&&y!==void 0?y:!0,validateSchema:(F=t.validateSchema)!==null&&F!==void 0?F:!0,validateFormats:(U=t.validateFormats)!==null&&U!==void 0?U:!0,unicodeRegExp:(T=t.unicodeRegExp)!==null&&T!==void 0?T:!0,int32range:(N=t.int32range)!==null&&N!==void 0?N:!0,uriResolver:lA}}var I4=class{constructor(e={}){this.schemas={},this.refs={},this.formats={},this._compilations=new Set,this._loading={},this._cache=new Map,e=this.opts=nA(nA({},e),VbA(e));let{es5:A,lines:i}=this.opts.code;this.scope=new zbA.ValueScope({scope:{},prefixes:PbA,es5:A,lines:i}),this.logger=eMA(e.logger);let n=e.validateFormats;e.validateFormats=!1,this.RULES=(0,TbA.getRules)(),l$.call(this,jbA,e,"NOT SUPPORTED"),l$.call(this,qbA,e,"DEPRECATED","warn"),this._metaOpts=$bA.call(this),e.formats&&WbA.call(this),this._addVocabularies(),this._addDefaultMetaSchema(),e.keywords&&XbA.call(this,e.keywords),typeof e.meta=="object"&&this.addMetaSchema(e.meta),ZbA.call(this),e.validateFormats=n}_addVocabularies(){this.addKeyword("$async")}_addDefaultMetaSchema(){let{$data:e,meta:A,schemaId:i}=this.opts,n=a$;i==="id"&&(n=nA({},a$),n.id=n.$id,delete n.$id),A&&e&&this.addMetaSchema(n,n[i],!1)}defaultMeta(){let{meta:e,schemaId:A}=this.opts;return this.opts.defaultMeta=typeof e=="object"?e[A]||e:void 0}validate(e,A){let i;if(typeof e=="string"){if(i=this.getSchema(e),!i)throw new Error(`no schema with key or ref "${e}"`)}else i=this.compile(e);let n=i(A);return"$async"in i||(this.errors=i.errors),n}compile(e,A){let i=this._addSchema(e,A);return i.validate||this._compileSchemaEnv(i)}compileAsync(e,A){if(typeof this.opts.loadSchema!="function")throw new Error("options.loadSchema should be a function");let{loadSchema:i}=this.opts;return n.call(this,e,A);function n(l,I){return _n(this,null,function*(){yield o.call(this,l.$schema);let C=this._addSchema(l,I);return C.validate||r.call(this,C)})}function o(l){return _n(this,null,function*(){l&&!this.getSchema(l)&&(yield n.call(this,{$ref:l},!0))})}function r(l){return _n(this,null,function*(){try{return this._compileSchemaEnv(l)}catch(I){if(!(I instanceof I$.default))throw I;return s.call(this,I),yield a.call(this,I.missingSchema),r.call(this,l)}})}function s({missingSchema:l,missingRef:I}){if(this.refs[l])throw new Error(`AnySchema ${l} is loaded but ${I} cannot be resolved`)}function a(l){return _n(this,null,function*(){let I=yield c.call(this,l);this.refs[l]||(yield o.call(this,I.$schema)),this.refs[l]||this.addSchema(I,l,A)})}function c(l){return _n(this,null,function*(){let I=this._loading[l];if(I)return I;try{return yield this._loading[l]=i(l)}finally{delete this._loading[l]}})}}addSchema(e,A,i,n=this.opts.validateSchema){if(Array.isArray(e)){for(let r of e)this.addSchema(r,void 0,i,n);return this}let o;if(typeof e=="object"){let{schemaId:r}=this.opts;if(o=e[r],o!==void 0&&typeof o!="string")throw new Error(`schema ${r} must be string`)}return A=(0,g4.normalizeId)(A||o),this._checkUnique(A),this.schemas[A]=this._addSchema(e,i,A,n,!0),this}addMetaSchema(e,A,i=this.opts.validateSchema){return this.addSchema(e,A,!0,i),this}validateSchema(e,A){if(typeof e=="boolean")return!0;let i;if(i=e.$schema,i!==void 0&&typeof i!="string")throw new Error("$schema must be a string");if(i=i||this.opts.defaultMeta||this.defaultMeta(),!i)return this.logger.warn("meta-schema not available"),this.errors=null,!0;let n=this.validate(i,e);if(!n&&A){let o="schema is invalid: "+this.errorsText();if(this.opts.validateSchema==="log")this.logger.error(o);else throw new Error(o)}return n}getSchema(e){let A;for(;typeof(A=g$.call(this,e))=="string";)e=A;if(A===void 0){let{schemaId:i}=this.opts,n=new l4.SchemaEnv({schema:{},schemaId:i});if(A=l4.resolveSchema.call(this,n,e),!A)return;this.refs[e]=A}return A.validate||this._compileSchemaEnv(A)}removeSchema(e){if(e instanceof RegExp)return this._removeAllSchemas(this.schemas,e),this._removeAllSchemas(this.refs,e),this;switch(typeof e){case"undefined":return this._removeAllSchemas(this.schemas),this._removeAllSchemas(this.refs),this._cache.clear(),this;case"string":{let A=g$.call(this,e);return typeof A=="object"&&this._cache.delete(A.schema),delete this.schemas[e],delete this.refs[e],this}case"object":{let A=e;this._cache.delete(A);let i=e[this.opts.schemaId];return i&&(i=(0,g4.normalizeId)(i),delete this.schemas[i],delete this.refs[i]),this}default:throw new Error("ajv.removeSchema: invalid parameter")}}addVocabulary(e){for(let A of e)this.addKeyword(A);return this}addKeyword(e,A){let i;if(typeof e=="string")i=e,typeof A=="object"&&(this.logger.warn("these parameters are deprecated, see docs for addKeyword"),A.keyword=i);else if(typeof e=="object"&&A===void 0){if(A=e,i=A.keyword,Array.isArray(i)&&!i.length)throw new Error("addKeywords: keyword must be string or non-empty array")}else throw new Error("invalid addKeywords parameters");if(iMA.call(this,i,A),!A)return(0,xR.eachItem)(i,o=>LR.call(this,o)),this;oMA.call(this,A);let n=Ne(nA({},A),{type:(0,k5.getJSONTypes)(A.type),schemaType:(0,k5.getJSONTypes)(A.schemaType)});return(0,xR.eachItem)(i,n.type.length===0?o=>LR.call(this,o,n):o=>n.type.forEach(r=>LR.call(this,o,n,r))),this}getKeyword(e){let A=this.RULES.all[e];return typeof A=="object"?A.definition:!!A}removeKeyword(e){let{RULES:A}=this;delete A.keywords[e],delete A.all[e];for(let i of A.rules){let n=i.rules.findIndex(o=>o.keyword===e);n>=0&&i.rules.splice(n,1)}return this}addFormat(e,A){return typeof A=="string"&&(A=new RegExp(A)),this.formats[e]=A,this}errorsText(e=this.errors,{separator:A=", ",dataVar:i="data"}={}){return!e||e.length===0?"No errors":e.map(n=>`${i}${n.instancePath} ${n.message}`).reduce((n,o)=>n+A+o)}$dataMetaSchema(e,A){let i=this.RULES.all;e=JSON.parse(JSON.stringify(e));for(let n of A){let o=n.split("/").slice(1),r=e;for(let s of o)r=r[s];for(let s in i){let a=i[s];if(typeof a!="object")continue;let{$data:c}=a.definition,l=r[s];c&&l&&(r[s]=d$(l))}}return e}_removeAllSchemas(e,A){for(let i in e){let n=e[i];(!A||A.test(i))&&(typeof n=="string"?delete e[i]:n&&!n.meta&&(this._cache.delete(n.schema),delete e[i]))}}_addSchema(e,A,i,n=this.opts.validateSchema,o=this.opts.addUsedSchema){let r,{schemaId:s}=this.opts;if(typeof e=="object")r=e[s];else{if(this.opts.jtd)throw new Error("schema must be object");if(typeof e!="boolean")throw new Error("schema must be object or boolean")}let a=this._cache.get(e);if(a!==void 0)return a;i=(0,g4.normalizeId)(r||i);let c=g4.getSchemaRefs.call(this,e,i);return a=new l4.SchemaEnv({schema:e,schemaId:s,meta:A,baseId:i,localRefs:c}),this._cache.set(a.schema,a),o&&!i.startsWith("#")&&(i&&this._checkUnique(i),this.refs[i]=a),n&&this.validateSchema(e,!0),a}_checkUnique(e){if(this.schemas[e]||this.refs[e])throw new Error(`schema with key or id "${e}" already exists`)}_compileSchemaEnv(e){if(e.meta?this._compileMetaSchema(e):l4.compileSchema.call(this,e),!e.validate)throw new Error("ajv implementation error");return e.validate}_compileMetaSchema(e){let A=this.opts;this.opts=this._metaOpts;try{l4.compileSchema.call(this,e)}finally{this.opts=A}}};I4.ValidationError=JbA.default;I4.MissingRefError=I$.default;es.default=I4;function l$(t,e,A,i="error"){for(let n in t){let o=n;o in e&&this.logger[i](`${A}: option ${n}. ${t[o]}`)}}function g$(t){return t=(0,g4.normalizeId)(t),this.schemas[t]||this.refs[t]}function ZbA(){let t=this.opts.schemas;if(t)if(Array.isArray(t))this.addSchema(t);else for(let e in t)this.addSchema(t[e],e)}function WbA(){for(let t in this.opts.formats){let e=this.opts.formats[t];e&&this.addFormat(t,e)}}function XbA(t){if(Array.isArray(t)){this.addVocabulary(t);return}this.logger.warn("keywords option as map is deprecated, pass array");for(let e in t){let A=t[e];A.keyword||(A.keyword=e),this.addKeyword(A)}}function $bA(){let t=nA({},this.opts);for(let e of ObA)delete t[e];return t}var AMA={log(){},warn(){},error(){}};function eMA(t){if(t===!1)return AMA;if(t===void 0)return console;if(t.log&&t.warn&&t.error)return t;throw new Error("logger must implement log, warn and error methods")}var tMA=/^[a-z_$][a-z0-9_$:-]*$/i;function iMA(t,e){let{RULES:A}=this;if((0,xR.eachItem)(t,i=>{if(A.keywords[i])throw new Error(`Keyword ${i} is already defined`);if(!tMA.test(i))throw new Error(`Keyword ${i} has invalid name`)}),!!e&&e.$data&&!("code"in e||"validate"in e))throw new Error('$data keyword must have "code" or "validate" function')}function LR(t,e,A){var i;let n=e?.post;if(A&&n)throw new Error('keyword with "post" flag cannot have "type"');let{RULES:o}=this,r=n?o.post:o.rules.find(({type:a})=>a===A);if(r||(r={type:A,rules:[]},o.rules.push(r)),o.keywords[t]=!0,!e)return;let s={keyword:t,definition:Ne(nA({},e),{type:(0,k5.getJSONTypes)(e.type),schemaType:(0,k5.getJSONTypes)(e.schemaType)})};e.before?nMA.call(this,r,s,e.before):r.rules.push(s),o.all[t]=s,(i=e.implements)===null||i===void 0||i.forEach(a=>this.addKeyword(a))}function nMA(t,e,A){let i=t.rules.findIndex(n=>n.keyword===A);i>=0?t.rules.splice(i,0,e):(t.rules.push(e),this.logger.warn(`rule ${A} is not defined`))}function oMA(t){let{metaSchema:e}=t;e!==void 0&&(t.$data&&this.opts.$data&&(e=d$(e)),t.validateSchema=this.compile(e,!0))}var rMA={$ref:"https://raw.githubusercontent.com/ajv-validator/ajv/master/lib/refs/data.json#"};function d$(t){return{anyOf:[t,rMA]}}});var E$=Le(FR=>{"use strict";Object.defineProperty(FR,"__esModule",{value:!0});var sMA={keyword:"id",code(){throw new Error('NOT SUPPORTED: keyword "id", use "$id" for schema ID')}};FR.default=sMA});var f$=Le(iC=>{"use strict";Object.defineProperty(iC,"__esModule",{value:!0});iC.callRef=iC.getValidate=void 0;var aMA=a4(),h$=Sc(),ma=Ji(),nE=x0(),Q$=y5(),S5=Cn(),cMA={keyword:"$ref",schemaType:"string",code(t){let{gen:e,schema:A,it:i}=t,{baseId:n,schemaEnv:o,validateName:r,opts:s,self:a}=i,{root:c}=o;if((A==="#"||A==="#/")&&n===c.baseId)return I();let l=Q$.resolveRef.call(a,c,n,A);if(l===void 0)throw new aMA.default(i.opts.uriResolver,n,A);if(l instanceof Q$.SchemaEnv)return C(l);return d(l);function I(){if(o===c)return R5(t,r,o,o.$async);let B=e.scopeValue("root",{ref:c});return R5(t,(0,ma._)`${B}.validate`,c,c.$async)}function C(B){let E=u$(t,B);R5(t,E,B,B.$async)}function d(B){let E=e.scopeValue("schema",s.code.source===!0?{ref:B,code:(0,ma.stringify)(B)}:{ref:B}),Q=e.name("valid"),u=t.subschema({schema:B,dataTypes:[],schemaPath:ma.nil,topSchemaRef:E,errSchemaPath:A},Q);t.mergeEvaluated(u),t.ok(Q)}}};function u$(t,e){let{gen:A}=t;return e.validate?A.scopeValue("validate",{ref:e.validate}):(0,ma._)`${A.scopeValue("wrapper",{ref:e})}.validate`}iC.getValidate=u$;function R5(t,e,A,i){let{gen:n,it:o}=t,{allErrors:r,schemaEnv:s,opts:a}=o,c=a.passContext?nE.default.this:ma.nil;i?l():I();function l(){if(!s.$async)throw new Error("async schema referenced by sync schema");let B=n.let("valid");n.try(()=>{n.code((0,ma._)`await ${(0,h$.callValidateCode)(t,e,c)}`),d(e),r||n.assign(B,!0)},E=>{n.if((0,ma._)`!(${E} instanceof ${o.ValidationError})`,()=>n.throw(E)),C(E),r||n.assign(B,!1)}),t.ok(B)}function I(){t.result((0,h$.callValidateCode)(t,e,c),()=>d(e),()=>C(e))}function C(B){let E=(0,ma._)`${B}.errors`;n.assign(nE.default.vErrors,(0,ma._)`${nE.default.vErrors} === null ? ${E} : ${nE.default.vErrors}.concat(${E})`),n.assign(nE.default.errors,(0,ma._)`${nE.default.vErrors}.length`)}function d(B){var E;if(!o.opts.unevaluated)return;let Q=(E=A?.validate)===null||E===void 0?void 0:E.evaluated;if(o.props!==!0)if(Q&&!Q.dynamicProps)Q.props!==void 0&&(o.props=S5.mergeEvaluated.props(n,Q.props,o.props));else{let u=n.var("props",(0,ma._)`${B}.evaluated.props`);o.props=S5.mergeEvaluated.props(n,u,o.props,ma.Name)}if(o.items!==!0)if(Q&&!Q.dynamicItems)Q.items!==void 0&&(o.items=S5.mergeEvaluated.items(n,Q.items,o.items));else{let u=n.var("items",(0,ma._)`${B}.evaluated.items`);o.items=S5.mergeEvaluated.items(n,u,o.items,ma.Name)}}}iC.callRef=R5;iC.default=cMA});var m$=Le(NR=>{"use strict";Object.defineProperty(NR,"__esModule",{value:!0});var lMA=E$(),gMA=f$(),IMA=["$schema","$id","$defs","$vocabulary",{keyword:"$comment"},"definitions",lMA.default,gMA.default];NR.default=IMA});var p$=Le(_R=>{"use strict";Object.defineProperty(_R,"__esModule",{value:!0});var L5=Ji(),C1=L5.operators,x5={maximum:{okStr:"<=",ok:C1.LTE,fail:C1.GT},minimum:{okStr:">=",ok:C1.GTE,fail:C1.LT},exclusiveMaximum:{okStr:"<",ok:C1.LT,fail:C1.GTE},exclusiveMinimum:{okStr:">",ok:C1.GT,fail:C1.LTE}},CMA={message:({keyword:t,schemaCode:e})=>(0,L5.str)`must be ${x5[t].okStr} ${e}`,params:({keyword:t,schemaCode:e})=>(0,L5._)`{comparison: ${x5[t].okStr}, limit: ${e}}`},dMA={keyword:Object.keys(x5),type:"number",schemaType:"number",$data:!0,error:CMA,code(t){let{keyword:e,data:A,schemaCode:i}=t;t.fail$data((0,L5._)`${A} ${x5[e].fail} ${i} || isNaN(${A})`)}};_R.default=dMA});var w$=Le(GR=>{"use strict";Object.defineProperty(GR,"__esModule",{value:!0});var C4=Ji(),BMA={message:({schemaCode:t})=>(0,C4.str)`must be multiple of ${t}`,params:({schemaCode:t})=>(0,C4._)`{multipleOf: ${t}}`},EMA={keyword:"multipleOf",type:"number",schemaType:"number",$data:!0,error:BMA,code(t){let{gen:e,data:A,schemaCode:i,it:n}=t,o=n.opts.multipleOfPrecision,r=e.let("res"),s=o?(0,C4._)`Math.abs(Math.round(${r}) - ${r}) > 1e-${o}`:(0,C4._)`${r} !== parseInt(${r})`;t.fail$data((0,C4._)`(${i} === 0 || (${r} = ${A}/${i}, ${s}))`)}};GR.default=EMA});var y$=Le(UR=>{"use strict";Object.defineProperty(UR,"__esModule",{value:!0});function D$(t){let e=t.length,A=0,i=0,n;for(;i<e;)A++,n=t.charCodeAt(i++),n>=55296&&n<=56319&&i<e&&(n=t.charCodeAt(i),(n&64512)===56320&&i++);return A}UR.default=D$;D$.code='require("ajv/dist/runtime/ucs2length").default'});var v$=Le(KR=>{"use strict";Object.defineProperty(KR,"__esModule",{value:!0});var nC=Ji(),hMA=Cn(),QMA=y$(),uMA={message({keyword:t,schemaCode:e}){let A=t==="maxLength"?"more":"fewer";return(0,nC.str)`must NOT have ${A} than ${e} characters`},params:({schemaCode:t})=>(0,nC._)`{limit: ${t}}`},fMA={keyword:["maxLength","minLength"],type:"string",schemaType:"number",$data:!0,error:uMA,code(t){let{keyword:e,data:A,schemaCode:i,it:n}=t,o=e==="maxLength"?nC.operators.GT:nC.operators.LT,r=n.opts.unicode===!1?(0,nC._)`${A}.length`:(0,nC._)`${(0,hMA.useFunc)(t.gen,QMA.default)}(${A})`;t.fail$data((0,nC._)`${r} ${o} ${i}`)}};KR.default=fMA});var b$=Le(YR=>{"use strict";Object.defineProperty(YR,"__esModule",{value:!0});var mMA=Sc(),F5=Ji(),pMA={message:({schemaCode:t})=>(0,F5.str)`must match pattern "${t}"`,params:({schemaCode:t})=>(0,F5._)`{pattern: ${t}}`},wMA={keyword:"pattern",type:"string",schemaType:"string",$data:!0,error:pMA,code(t){let{data:e,$data:A,schema:i,schemaCode:n,it:o}=t,r=o.opts.unicodeRegExp?"u":"",s=A?(0,F5._)`(new RegExp(${n}, ${r}))`:(0,mMA.usePattern)(t,i);t.fail$data((0,F5._)`!${s}.test(${e})`)}};YR.default=wMA});var M$=Le(JR=>{"use strict";Object.defineProperty(JR,"__esModule",{value:!0});var d4=Ji(),DMA={message({keyword:t,schemaCode:e}){let A=t==="maxProperties"?"more":"fewer";return(0,d4.str)`must NOT have ${A} than ${e} properties`},params:({schemaCode:t})=>(0,d4._)`{limit: ${t}}`},yMA={keyword:["maxProperties","minProperties"],type:"object",schemaType:"number",$data:!0,error:DMA,code(t){let{keyword:e,data:A,schemaCode:i}=t,n=e==="maxProperties"?d4.operators.GT:d4.operators.LT;t.fail$data((0,d4._)`Object.keys(${A}).length ${n} ${i}`)}};JR.default=yMA});var k$=Le(TR=>{"use strict";Object.defineProperty(TR,"__esModule",{value:!0});var B4=Sc(),E4=Ji(),vMA=Cn(),bMA={message:({params:{missingProperty:t}})=>(0,E4.str)`must have required property '${t}'`,params:({params:{missingProperty:t}})=>(0,E4._)`{missingProperty: ${t}}`},MMA={keyword:"required",type:"object",schemaType:"array",$data:!0,error:bMA,code(t){let{gen:e,schema:A,schemaCode:i,data:n,$data:o,it:r}=t,{opts:s}=r;if(!o&&A.length===0)return;let a=A.length>=s.loopRequired;if(r.allErrors?c():l(),s.strictRequired){let d=t.parentSchema.properties,{definedProperties:B}=t.it;for(let E of A)if(d?.[E]===void 0&&!B.has(E)){let Q=r.schemaEnv.baseId+r.errSchemaPath,u=`required property "${E}" is not defined at "${Q}" (strictRequired)`;(0,vMA.checkStrictMode)(r,u,r.opts.strictRequired)}}function c(){if(a||o)t.block$data(E4.nil,I);else for(let d of A)(0,B4.checkReportMissingProp)(t,d)}function l(){let d=e.let("missing");if(a||o){let B=e.let("valid",!0);t.block$data(B,()=>C(d,B)),t.ok(B)}else e.if((0,B4.checkMissingProp)(t,A,d)),(0,B4.reportMissingProp)(t,d),e.else()}function I(){e.forOf("prop",i,d=>{t.setParams({missingProperty:d}),e.if((0,B4.noPropertyInData)(e,n,d,s.ownProperties),()=>t.error())})}function C(d,B){t.setParams({missingProperty:d}),e.forOf(d,i,()=>{e.assign(B,(0,B4.propertyInData)(e,n,d,s.ownProperties)),e.if((0,E4.not)(B),()=>{t.error(),e.break()})},E4.nil)}}};TR.default=MMA});var S$=Le(zR=>{"use strict";Object.defineProperty(zR,"__esModule",{value:!0});var h4=Ji(),kMA={message({keyword:t,schemaCode:e}){let A=t==="maxItems"?"more":"fewer";return(0,h4.str)`must NOT have ${A} than ${e} items`},params:({schemaCode:t})=>(0,h4._)`{limit: ${t}}`},SMA={keyword:["maxItems","minItems"],type:"array",schemaType:"number",$data:!0,error:kMA,code(t){let{keyword:e,data:A,schemaCode:i}=t,n=e==="maxItems"?h4.operators.GT:h4.operators.LT;t.fail$data((0,h4._)`${A}.length ${n} ${i}`)}};zR.default=SMA});var N5=Le(HR=>{"use strict";Object.defineProperty(HR,"__esModule",{value:!0});var R$=BR();R$.code='require("ajv/dist/runtime/equal").default';HR.default=R$});var L$=Le(PR=>{"use strict";Object.defineProperty(PR,"__esModule",{value:!0});var OR=i4(),ts=Ji(),RMA=Cn(),LMA=N5(),xMA={message:({params:{i:t,j:e}})=>(0,ts.str)`must NOT have duplicate items (items ## ${e} and ${t} are identical)`,params:({params:{i:t,j:e}})=>(0,ts._)`{i: ${t}, j: ${e}}`},FMA={keyword:"uniqueItems",type:"array",schemaType:"boolean",$data:!0,error:xMA,code(t){let{gen:e,data:A,$data:i,schema:n,parentSchema:o,schemaCode:r,it:s}=t;if(!i&&!n)return;let a=e.let("valid"),c=o.items?(0,OR.getSchemaTypes)(o.items):[];t.block$data(a,l,(0,ts._)`${r} === false`),t.ok(a);function l(){let B=e.let("i",(0,ts._)`${A}.length`),E=e.let("j");t.setParams({i:B,j:E}),e.assign(a,!0),e.if((0,ts._)`${B} > 1`,()=>(I()?C:d)(B,E))}function I(){return c.length>0&&!c.some(B=>B==="object"||B==="array")}function C(B,E){let Q=e.name("item"),u=(0,OR.checkDataTypes)(c,Q,s.opts.strictNumbers,OR.DataType.Wrong),v=e.const("indices",(0,ts._)`{}`);e.for((0,ts._)`;${B}--;`,()=>{e.let(Q,(0,ts._)`${A}[${B}]`),e.if(u,(0,ts._)`continue`),c.length>1&&e.if((0,ts._)`typeof ${Q} == "string"`,(0,ts._)`${Q} += "_"`),e.if((0,ts._)`typeof ${v}[${Q}] == "number"`,()=>{e.assign(E,(0,ts._)`${v}[${Q}]`),t.error(),e.assign(a,!1).break()}).code((0,ts._)`${v}[${Q}] = ${B}`)})}function d(B,E){let Q=(0,RMA.useFunc)(e,LMA.default),u=e.name("outer");e.label(u).for((0,ts._)`;${B}--;`,()=>e.for((0,ts._)`${E} = ${B}; ${E}--;`,()=>e.if((0,ts._)`${Q}(${A}[${B}], ${A}[${E}])`,()=>{t.error(),e.assign(a,!1).break(u)})))}}};PR.default=FMA});var x$=Le(qR=>{"use strict";Object.defineProperty(qR,"__esModule",{value:!0});var jR=Ji(),NMA=Cn(),_MA=N5(),GMA={message:"must be equal to constant",params:({schemaCode:t})=>(0,jR._)`{allowedValue: ${t}}`},UMA={keyword:"const",$data:!0,error:GMA,code(t){let{gen:e,data:A,$data:i,schemaCode:n,schema:o}=t;i||o&&typeof o=="object"?t.fail$data((0,jR._)`!${(0,NMA.useFunc)(e,_MA.default)}(${A}, ${n})`):t.fail((0,jR._)`${o} !== ${A}`)}};qR.default=UMA});var F$=Le(VR=>{"use strict";Object.defineProperty(VR,"__esModule",{value:!0});var Q4=Ji(),KMA=Cn(),YMA=N5(),JMA={message:"must be equal to one of the allowed values",params:({schemaCode:t})=>(0,Q4._)`{allowedValues: ${t}}`},TMA={keyword:"enum",schemaType:"array",$data:!0,error:JMA,code(t){let{gen:e,data:A,$data:i,schema:n,schemaCode:o,it:r}=t;if(!i&&n.length===0)throw new Error("enum must have non-empty array");let s=n.length>=r.opts.loopEnum,a,c=()=>a??(a=(0,KMA.useFunc)(e,YMA.default)),l;if(s||i)l=e.let("valid"),t.block$data(l,I);else{if(!Array.isArray(n))throw new Error("ajv implementation error");let d=e.const("vSchema",o);l=(0,Q4.or)(...n.map((B,E)=>C(d,E)))}t.pass(l);function I(){e.assign(l,!1),e.forOf("v",o,d=>e.if((0,Q4._)`${c()}(${A}, ${d})`,()=>e.assign(l,!0).break()))}function C(d,B){let E=n[B];return typeof E=="object"&&E!==null?(0,Q4._)`${c()}(${A}, ${d}[${B}])`:(0,Q4._)`${A} === ${E}`}}};VR.default=TMA});var N$=Le(ZR=>{"use strict";Object.defineProperty(ZR,"__esModule",{value:!0});var zMA=p$(),HMA=w$(),OMA=v$(),PMA=b$(),jMA=M$(),qMA=k$(),VMA=S$(),ZMA=L$(),WMA=x$(),XMA=F$(),$MA=[zMA.default,HMA.default,OMA.default,PMA.default,jMA.default,qMA.default,VMA.default,ZMA.default,{keyword:"type",schemaType:["string","array"]},{keyword:"nullable",schemaType:"boolean"},WMA.default,XMA.default];ZR.default=$MA});var XR=Le(u4=>{"use strict";Object.defineProperty(u4,"__esModule",{value:!0});u4.validateAdditionalItems=void 0;var oC=Ji(),WR=Cn(),AkA={message:({params:{len:t}})=>(0,oC.str)`must NOT have more than ${t} items`,params:({params:{len:t}})=>(0,oC._)`{limit: ${t}}`},ekA={keyword:"additionalItems",type:"array",schemaType:["boolean","object"],before:"uniqueItems",error:AkA,code(t){let{parentSchema:e,it:A}=t,{items:i}=e;if(!Array.isArray(i)){(0,WR.checkStrictMode)(A,'"additionalItems" is ignored when "items" is not an array of schemas');return}_$(t,i)}};function _$(t,e){let{gen:A,schema:i,data:n,keyword:o,it:r}=t;r.items=!0;let s=A.const("len",(0,oC._)`${n}.length`);if(i===!1)t.setParams({len:e.length}),t.pass((0,oC._)`${s} <= ${e.length}`);else if(typeof i=="object"&&!(0,WR.alwaysValidSchema)(r,i)){let c=A.var("valid",(0,oC._)`${s} <= ${e.length}`);A.if((0,oC.not)(c),()=>a(c)),t.ok(c)}function a(c){A.forRange("i",e.length,s,l=>{t.subschema({keyword:o,dataProp:l,dataPropType:WR.Type.Num},c),r.allErrors||A.if((0,oC.not)(c),()=>A.break())})}}u4.validateAdditionalItems=_$;u4.default=ekA});var $R=Le(f4=>{"use strict";Object.defineProperty(f4,"__esModule",{value:!0});f4.validateTuple=void 0;var G$=Ji(),_5=Cn(),tkA=Sc(),ikA={keyword:"items",type:"array",schemaType:["object","array","boolean"],before:"uniqueItems",code(t){let{schema:e,it:A}=t;if(Array.isArray(e))return U$(t,"additionalItems",e);A.items=!0,!(0,_5.alwaysValidSchema)(A,e)&&t.ok((0,tkA.validateArray)(t))}};function U$(t,e,A=t.schema){let{gen:i,parentSchema:n,data:o,keyword:r,it:s}=t;l(n),s.opts.unevaluated&&A.length&&s.items!==!0&&(s.items=_5.mergeEvaluated.items(i,A.length,s.items));let a=i.name("valid"),c=i.const("len",(0,G$._)`${o}.length`);A.forEach((I,C)=>{(0,_5.alwaysValidSchema)(s,I)||(i.if((0,G$._)`${c} > ${C}`,()=>t.subschema({keyword:r,schemaProp:C,dataProp:C},a)),t.ok(a))});function l(I){let{opts:C,errSchemaPath:d}=s,B=A.length,E=B===I.minItems&&(B===I.maxItems||I[e]===!1);if(C.strictTuples&&!E){let Q=`"${r}" is ${B}-tuple, but minItems or maxItems/${e} are not specified or different at path "${d}"`;(0,_5.checkStrictMode)(s,Q,C.strictTuples)}}}f4.validateTuple=U$;f4.default=ikA});var K$=Le(AL=>{"use strict";Object.defineProperty(AL,"__esModule",{value:!0});var nkA=$R(),okA={keyword:"prefixItems",type:"array",schemaType:["array"],before:"uniqueItems",code:t=>(0,nkA.validateTuple)(t,"items")};AL.default=okA});var J$=Le(eL=>{"use strict";Object.defineProperty(eL,"__esModule",{value:!0});var Y$=Ji(),rkA=Cn(),skA=Sc(),akA=XR(),ckA={message:({params:{len:t}})=>(0,Y$.str)`must NOT have more than ${t} items`,params:({params:{len:t}})=>(0,Y$._)`{limit: ${t}}`},lkA={keyword:"items",type:"array",schemaType:["object","boolean"],before:"uniqueItems",error:ckA,code(t){let{schema:e,parentSchema:A,it:i}=t,{prefixItems:n}=A;i.items=!0,!(0,rkA.alwaysValidSchema)(i,e)&&(n?(0,akA.validateAdditionalItems)(t,n):t.ok((0,skA.validateArray)(t)))}};eL.default=lkA});var T$=Le(tL=>{"use strict";Object.defineProperty(tL,"__esModule",{value:!0});var Lc=Ji(),G5=Cn(),gkA={message:({params:{min:t,max:e}})=>e===void 0?(0,Lc.str)`must contain at least ${t} valid item(s)`:(0,Lc.str)`must contain at least ${t} and no more than ${e} valid item(s)`,params:({params:{min:t,max:e}})=>e===void 0?(0,Lc._)`{minContains: ${t}}`:(0,Lc._)`{minContains: ${t}, maxContains: ${e}}`},IkA={keyword:"contains",type:"array",schemaType:["object","boolean"],before:"uniqueItems",trackErrors:!0,error:gkA,code(t){let{gen:e,schema:A,parentSchema:i,data:n,it:o}=t,r,s,{minContains:a,maxContains:c}=i;o.opts.next?(r=a===void 0?1:a,s=c):r=1;let l=e.const("len",(0,Lc._)`${n}.length`);if(t.setParams({min:r,max:s}),s===void 0&&r===0){(0,G5.checkStrictMode)(o,'"minContains" == 0 without "maxContains": "contains" keyword ignored');return}if(s!==void 0&&r>s){(0,G5.checkStrictMode)(o,'"minContains" > "maxContains" is always invalid'),t.fail();return}if((0,G5.alwaysValidSchema)(o,A)){let E=(0,Lc._)`${l} >= ${r}`;s!==void 0&&(E=(0,Lc._)`${E} && ${l} <= ${s}`),t.pass(E);return}o.items=!0;let I=e.name("valid");s===void 0&&r===1?d(I,()=>e.if(I,()=>e.break())):r===0?(e.let(I,!0),s!==void 0&&e.if((0,Lc._)`${n}.length > 0`,C)):(e.let(I,!1),C()),t.result(I,()=>t.reset());function C(){let E=e.name("_valid"),Q=e.let("count",0);d(E,()=>e.if(E,()=>B(Q)))}function d(E,Q){e.forRange("i",0,l,u=>{t.subschema({keyword:"contains",dataProp:u,dataPropType:G5.Type.Num,compositeRule:!0},E),Q()})}function B(E){e.code((0,Lc._)`${E}++`),s===void 0?e.if((0,Lc._)`${E} >= ${r}`,()=>e.assign(I,!0).break()):(e.if((0,Lc._)`${E} > ${s}`,()=>e.assign(I,!1).break()),r===1?e.assign(I,!0):e.if((0,Lc._)`${E} >= ${r}`,()=>e.assign(I,!0)))}}};tL.default=IkA});var O$=Le(hg=>{"use strict";Object.defineProperty(hg,"__esModule",{value:!0});hg.validateSchemaDeps=hg.validatePropertyDeps=hg.error=void 0;var iL=Ji(),CkA=Cn(),m4=Sc();hg.error={message:({params:{property:t,depsCount:e,deps:A}})=>{let i=e===1?"property":"properties";return(0,iL.str)`must have ${i} ${A} when property ${t} is present`},params:({params:{property:t,depsCount:e,deps:A,missingProperty:i}})=>(0,iL._)`{property: ${t},
    missingProperty: ${i},
    depsCount: ${e},
    deps: ${A}}`};var dkA={keyword:"dependencies",type:"object",schemaType:"object",error:hg.error,code(t){let[e,A]=BkA(t);z$(t,e),H$(t,A)}};function BkA({schema:t}){let e={},A={};for(let i in t){if(i==="__proto__")continue;let n=Array.isArray(t[i])?e:A;n[i]=t[i]}return[e,A]}function z$(t,e=t.schema){let{gen:A,data:i,it:n}=t;if(Object.keys(e).length===0)return;let o=A.let("missing");for(let r in e){let s=e[r];if(s.length===0)continue;let a=(0,m4.propertyInData)(A,i,r,n.opts.ownProperties);t.setParams({property:r,depsCount:s.length,deps:s.join(", ")}),n.allErrors?A.if(a,()=>{for(let c of s)(0,m4.checkReportMissingProp)(t,c)}):(A.if((0,iL._)`${a} && (${(0,m4.checkMissingProp)(t,s,o)})`),(0,m4.reportMissingProp)(t,o),A.else())}}hg.validatePropertyDeps=z$;function H$(t,e=t.schema){let{gen:A,data:i,keyword:n,it:o}=t,r=A.name("valid");for(let s in e)(0,CkA.alwaysValidSchema)(o,e[s])||(A.if((0,m4.propertyInData)(A,i,s,o.opts.ownProperties),()=>{let a=t.subschema({keyword:n,schemaProp:s},r);t.mergeValidEvaluated(a,r)},()=>A.var(r,!0)),t.ok(r))}hg.validateSchemaDeps=H$;hg.default=dkA});var j$=Le(nL=>{"use strict";Object.defineProperty(nL,"__esModule",{value:!0});var P$=Ji(),EkA=Cn(),hkA={message:"property name must be valid",params:({params:t})=>(0,P$._)`{propertyName: ${t.propertyName}}`},QkA={keyword:"propertyNames",type:"object",schemaType:["object","boolean"],error:hkA,code(t){let{gen:e,schema:A,data:i,it:n}=t;if((0,EkA.alwaysValidSchema)(n,A))return;let o=e.name("valid");e.forIn("key",i,r=>{t.setParams({propertyName:r}),t.subschema({keyword:"propertyNames",data:r,dataTypes:["string"],propertyName:r,compositeRule:!0},o),e.if((0,P$.not)(o),()=>{t.error(!0),n.allErrors||e.break()})}),t.ok(o)}};nL.default=QkA});var rL=Le(oL=>{"use strict";Object.defineProperty(oL,"__esModule",{value:!0});var U5=Sc(),Cl=Ji(),ukA=x0(),K5=Cn(),fkA={message:"must NOT have additional properties",params:({params:t})=>(0,Cl._)`{additionalProperty: ${t.additionalProperty}}`},mkA={keyword:"additionalProperties",type:["object"],schemaType:["boolean","object"],allowUndefined:!0,trackErrors:!0,error:fkA,code(t){let{gen:e,schema:A,parentSchema:i,data:n,errsCount:o,it:r}=t;if(!o)throw new Error("ajv implementation error");let{allErrors:s,opts:a}=r;if(r.props=!0,a.removeAdditional!=="all"&&(0,K5.alwaysValidSchema)(r,A))return;let c=(0,U5.allSchemaProperties)(i.properties),l=(0,U5.allSchemaProperties)(i.patternProperties);I(),t.ok((0,Cl._)`${o} === ${ukA.default.errors}`);function I(){e.forIn("key",n,Q=>{!c.length&&!l.length?B(Q):e.if(C(Q),()=>B(Q))})}function C(Q){let u;if(c.length>8){let v=(0,K5.schemaRefOrVal)(r,i.properties,"properties");u=(0,U5.isOwnProperty)(e,v,Q)}else c.length?u=(0,Cl.or)(...c.map(v=>(0,Cl._)`${Q} === ${v}`)):u=Cl.nil;return l.length&&(u=(0,Cl.or)(u,...l.map(v=>(0,Cl._)`${(0,U5.usePattern)(t,v)}.test(${Q})`))),(0,Cl.not)(u)}function d(Q){e.code((0,Cl._)`delete ${n}[${Q}]`)}function B(Q){if(a.removeAdditional==="all"||a.removeAdditional&&A===!1){d(Q);return}if(A===!1){t.setParams({additionalProperty:Q}),t.error(),s||e.break();return}if(typeof A=="object"&&!(0,K5.alwaysValidSchema)(r,A)){let u=e.name("valid");a.removeAdditional==="failing"?(E(Q,u,!1),e.if((0,Cl.not)(u),()=>{t.reset(),d(Q)})):(E(Q,u),s||e.if((0,Cl.not)(u),()=>e.break()))}}function E(Q,u,v){let L={keyword:"additionalProperties",dataProp:Q,dataPropType:K5.Type.Str};v===!1&&Object.assign(L,{compositeRule:!0,createErrors:!1,allErrors:!1}),t.subschema(L,u)}}};oL.default=mkA});var Z$=Le(aL=>{"use strict";Object.defineProperty(aL,"__esModule",{value:!0});var pkA=s4(),q$=Sc(),sL=Cn(),V$=rL(),wkA={keyword:"properties",type:"object",schemaType:"object",code(t){let{gen:e,schema:A,parentSchema:i,data:n,it:o}=t;o.opts.removeAdditional==="all"&&i.additionalProperties===void 0&&V$.default.code(new pkA.KeywordCxt(o,V$.default,"additionalProperties"));let r=(0,q$.allSchemaProperties)(A);for(let I of r)o.definedProperties.add(I);o.opts.unevaluated&&r.length&&o.props!==!0&&(o.props=sL.mergeEvaluated.props(e,(0,sL.toHash)(r),o.props));let s=r.filter(I=>!(0,sL.alwaysValidSchema)(o,A[I]));if(s.length===0)return;let a=e.name("valid");for(let I of s)c(I)?l(I):(e.if((0,q$.propertyInData)(e,n,I,o.opts.ownProperties)),l(I),o.allErrors||e.else().var(a,!0),e.endIf()),t.it.definedProperties.add(I),t.ok(a);function c(I){return o.opts.useDefaults&&!o.compositeRule&&A[I].default!==void 0}function l(I){t.subschema({keyword:"properties",schemaProp:I,dataProp:I},a)}}};aL.default=wkA});var AAA=Le(cL=>{"use strict";Object.defineProperty(cL,"__esModule",{value:!0});var W$=Sc(),Y5=Ji(),X$=Cn(),$$=Cn(),DkA={keyword:"patternProperties",type:"object",schemaType:"object",code(t){let{gen:e,schema:A,data:i,parentSchema:n,it:o}=t,{opts:r}=o,s=(0,W$.allSchemaProperties)(A),a=s.filter(E=>(0,X$.alwaysValidSchema)(o,A[E]));if(s.length===0||a.length===s.length&&(!o.opts.unevaluated||o.props===!0))return;let c=r.strictSchema&&!r.allowMatchingProperties&&n.properties,l=e.name("valid");o.props!==!0&&!(o.props instanceof Y5.Name)&&(o.props=(0,$$.evaluatedPropsToName)(e,o.props));let{props:I}=o;C();function C(){for(let E of s)c&&d(E),o.allErrors?B(E):(e.var(l,!0),B(E),e.if(l))}function d(E){for(let Q in c)new RegExp(E).test(Q)&&(0,X$.checkStrictMode)(o,`property ${Q} matches pattern ${E} (use allowMatchingProperties)`)}function B(E){e.forIn("key",i,Q=>{e.if((0,Y5._)`${(0,W$.usePattern)(t,E)}.test(${Q})`,()=>{let u=a.includes(E);u||t.subschema({keyword:"patternProperties",schemaProp:E,dataProp:Q,dataPropType:$$.Type.Str},l),o.opts.unevaluated&&I!==!0?e.assign((0,Y5._)`${I}[${Q}]`,!0):!u&&!o.allErrors&&e.if((0,Y5.not)(l),()=>e.break())})})}}};cL.default=DkA});var eAA=Le(lL=>{"use strict";Object.defineProperty(lL,"__esModule",{value:!0});var ykA=Cn(),vkA={keyword:"not",schemaType:["object","boolean"],trackErrors:!0,code(t){let{gen:e,schema:A,it:i}=t;if((0,ykA.alwaysValidSchema)(i,A)){t.fail();return}let n=e.name("valid");t.subschema({keyword:"not",compositeRule:!0,createErrors:!1,allErrors:!1},n),t.failResult(n,()=>t.reset(),()=>t.error())},error:{message:"must NOT be valid"}};lL.default=vkA});var tAA=Le(gL=>{"use strict";Object.defineProperty(gL,"__esModule",{value:!0});var bkA=Sc(),MkA={keyword:"anyOf",schemaType:"array",trackErrors:!0,code:bkA.validateUnion,error:{message:"must match a schema in anyOf"}};gL.default=MkA});var iAA=Le(IL=>{"use strict";Object.defineProperty(IL,"__esModule",{value:!0});var J5=Ji(),kkA=Cn(),SkA={message:"must match exactly one schema in oneOf",params:({params:t})=>(0,J5._)`{passingSchemas: ${t.passing}}`},RkA={keyword:"oneOf",schemaType:"array",trackErrors:!0,error:SkA,code(t){let{gen:e,schema:A,parentSchema:i,it:n}=t;if(!Array.isArray(A))throw new Error("ajv implementation error");if(n.opts.discriminator&&i.discriminator)return;let o=A,r=e.let("valid",!1),s=e.let("passing",null),a=e.name("_valid");t.setParams({passing:s}),e.block(c),t.result(r,()=>t.reset(),()=>t.error(!0));function c(){o.forEach((l,I)=>{let C;(0,kkA.alwaysValidSchema)(n,l)?e.var(a,!0):C=t.subschema({keyword:"oneOf",schemaProp:I,compositeRule:!0},a),I>0&&e.if((0,J5._)`${a} && ${r}`).assign(r,!1).assign(s,(0,J5._)`[${s}, ${I}]`).else(),e.if(a,()=>{e.assign(r,!0),e.assign(s,I),C&&t.mergeEvaluated(C,J5.Name)})})}}};IL.default=RkA});var nAA=Le(CL=>{"use strict";Object.defineProperty(CL,"__esModule",{value:!0});var LkA=Cn(),xkA={keyword:"allOf",schemaType:"array",code(t){let{gen:e,schema:A,it:i}=t;if(!Array.isArray(A))throw new Error("ajv implementation error");let n=e.name("valid");A.forEach((o,r)=>{if((0,LkA.alwaysValidSchema)(i,o))return;let s=t.subschema({keyword:"allOf",schemaProp:r},n);t.ok(n),t.mergeEvaluated(s)})}};CL.default=xkA});var sAA=Le(dL=>{"use strict";Object.defineProperty(dL,"__esModule",{value:!0});var T5=Ji(),rAA=Cn(),FkA={message:({params:t})=>(0,T5.str)`must match "${t.ifClause}" schema`,params:({params:t})=>(0,T5._)`{failingKeyword: ${t.ifClause}}`},NkA={keyword:"if",schemaType:["object","boolean"],trackErrors:!0,error:FkA,code(t){let{gen:e,parentSchema:A,it:i}=t;A.then===void 0&&A.else===void 0&&(0,rAA.checkStrictMode)(i,'"if" without "then" and "else" is ignored');let n=oAA(i,"then"),o=oAA(i,"else");if(!n&&!o)return;let r=e.let("valid",!0),s=e.name("_valid");if(a(),t.reset(),n&&o){let l=e.let("ifClause");t.setParams({ifClause:l}),e.if(s,c("then",l),c("else",l))}else n?e.if(s,c("then")):e.if((0,T5.not)(s),c("else"));t.pass(r,()=>t.error(!0));function a(){let l=t.subschema({keyword:"if",compositeRule:!0,createErrors:!1,allErrors:!1},s);t.mergeEvaluated(l)}function c(l,I){return()=>{let C=t.subschema({keyword:l},s);e.assign(r,s),t.mergeValidEvaluated(C,r),I?e.assign(I,(0,T5._)`${l}`):t.setParams({ifClause:l})}}}};function oAA(t,e){let A=t.schema[e];return A!==void 0&&!(0,rAA.alwaysValidSchema)(t,A)}dL.default=NkA});var aAA=Le(BL=>{"use strict";Object.defineProperty(BL,"__esModule",{value:!0});var _kA=Cn(),GkA={keyword:["then","else"],schemaType:["object","boolean"],code({keyword:t,parentSchema:e,it:A}){e.if===void 0&&(0,_kA.checkStrictMode)(A,`"${t}" without "if" is ignored`)}};BL.default=GkA});var cAA=Le(EL=>{"use strict";Object.defineProperty(EL,"__esModule",{value:!0});var UkA=XR(),KkA=K$(),YkA=$R(),JkA=J$(),TkA=T$(),zkA=O$(),HkA=j$(),OkA=rL(),PkA=Z$(),jkA=AAA(),qkA=eAA(),VkA=tAA(),ZkA=iAA(),WkA=nAA(),XkA=sAA(),$kA=aAA();function ASA(t=!1){let e=[qkA.default,VkA.default,ZkA.default,WkA.default,XkA.default,$kA.default,HkA.default,OkA.default,zkA.default,PkA.default,jkA.default];return t?e.push(KkA.default,JkA.default):e.push(UkA.default,YkA.default),e.push(TkA.default),e}EL.default=ASA});var lAA=Le(hL=>{"use strict";Object.defineProperty(hL,"__esModule",{value:!0});var gr=Ji(),eSA={message:({schemaCode:t})=>(0,gr.str)`must match format "${t}"`,params:({schemaCode:t})=>(0,gr._)`{format: ${t}}`},tSA={keyword:"format",type:["number","string"],schemaType:"string",$data:!0,error:eSA,code(t,e){let{gen:A,data:i,$data:n,schema:o,schemaCode:r,it:s}=t,{opts:a,errSchemaPath:c,schemaEnv:l,self:I}=s;if(!a.validateFormats)return;n?C():d();function C(){let B=A.scopeValue("formats",{ref:I.formats,code:a.code.formats}),E=A.const("fDef",(0,gr._)`${B}[${r}]`),Q=A.let("fType"),u=A.let("format");A.if((0,gr._)`typeof ${E} == "object" && !(${E} instanceof RegExp)`,()=>A.assign(Q,(0,gr._)`${E}.type || "string"`).assign(u,(0,gr._)`${E}.validate`),()=>A.assign(Q,(0,gr._)`"string"`).assign(u,E)),t.fail$data((0,gr.or)(v(),L()));function v(){return a.strictSchema===!1?gr.nil:(0,gr._)`${r} && !${u}`}function L(){let x=l.$async?(0,gr._)`(${E}.async ? await ${u}(${i}) : ${u}(${i}))`:(0,gr._)`${u}(${i})`,y=(0,gr._)`(typeof ${u} == "function" ? ${x} : ${u}.test(${i}))`;return(0,gr._)`${u} && ${u} !== true && ${Q} === ${e} && !${y}`}}function d(){let B=I.formats[o];if(!B){v();return}if(B===!0)return;let[E,Q,u]=L(B);E===e&&t.pass(x());function v(){if(a.strictSchema===!1){I.logger.warn(y());return}throw new Error(y());function y(){return`unknown format "${o}" ignored in schema at path "${c}"`}}function L(y){let F=y instanceof RegExp?(0,gr.regexpCode)(y):a.code.formats?(0,gr._)`${a.code.formats}${(0,gr.getProperty)(o)}`:void 0,U=A.scopeValue("formats",{key:o,ref:y,code:F});return typeof y=="object"&&!(y instanceof RegExp)?[y.type||"string",y.validate,(0,gr._)`${U}.validate`]:["string",y,U]}function x(){if(typeof B=="object"&&!(B instanceof RegExp)&&B.async){if(!l.$async)throw new Error("async format in sync schema");return(0,gr._)`await ${u}(${i})`}return typeof Q=="function"?(0,gr._)`${u}(${i})`:(0,gr._)`${u}.test(${i})`}}}};hL.default=tSA});var gAA=Le(QL=>{"use strict";Object.defineProperty(QL,"__esModule",{value:!0});var iSA=lAA(),nSA=[iSA.default];QL.default=nSA});var IAA=Le(oE=>{"use strict";Object.defineProperty(oE,"__esModule",{value:!0});oE.contentVocabulary=oE.metadataVocabulary=void 0;oE.metadataVocabulary=["title","description","default","deprecated","readOnly","writeOnly","examples"];oE.contentVocabulary=["contentMediaType","contentEncoding","contentSchema"]});var dAA=Le(uL=>{"use strict";Object.defineProperty(uL,"__esModule",{value:!0});var oSA=m$(),rSA=N$(),sSA=cAA(),aSA=gAA(),CAA=IAA(),cSA=[oSA.default,rSA.default,(0,sSA.default)(),aSA.default,CAA.metadataVocabulary,CAA.contentVocabulary];uL.default=cSA});var EAA=Le(z5=>{"use strict";Object.defineProperty(z5,"__esModule",{value:!0});z5.DiscrError=void 0;var BAA=function(t){return t.Tag="tag",t.Mapping="mapping",t}(BAA||(z5.DiscrError=BAA={}))});var QAA=Le(mL=>{"use strict";Object.defineProperty(mL,"__esModule",{value:!0});var rE=Ji(),fL=EAA(),hAA=y5(),lSA=a4(),gSA=Cn(),ISA={message:({params:{discrError:t,tagName:e}})=>t===fL.DiscrError.Tag?`tag "${e}" must be string`:`value of tag "${e}" must be in oneOf`,params:({params:{discrError:t,tag:e,tagName:A}})=>(0,rE._)`{error: ${t}, tag: ${A}, tagValue: ${e}}`},CSA={keyword:"discriminator",type:"object",schemaType:"object",error:ISA,code(t){let{gen:e,data:A,schema:i,parentSchema:n,it:o}=t,{oneOf:r}=n;if(!o.opts.discriminator)throw new Error("discriminator: requires discriminator option");let s=i.propertyName;if(typeof s!="string")throw new Error("discriminator: requires propertyName");if(i.mapping)throw new Error("discriminator: mapping is not supported");if(!r)throw new Error("discriminator: requires oneOf keyword");let a=e.let("valid",!1),c=e.const("tag",(0,rE._)`${A}${(0,rE.getProperty)(s)}`);e.if((0,rE._)`typeof ${c} == "string"`,()=>l(),()=>t.error(!1,{discrError:fL.DiscrError.Tag,tag:c,tagName:s})),t.ok(a);function l(){let d=C();e.if(!1);for(let B in d)e.elseIf((0,rE._)`${c} === ${B}`),e.assign(a,I(d[B]));e.else(),t.error(!1,{discrError:fL.DiscrError.Mapping,tag:c,tagName:s}),e.endIf()}function I(d){let B=e.name("valid"),E=t.subschema({keyword:"oneOf",schemaProp:d},B);return t.mergeEvaluated(E,rE.Name),B}function C(){var d;let B={},E=u(n),Q=!0;for(let x=0;x<r.length;x++){let y=r[x];if(y?.$ref&&!(0,gSA.schemaHasRulesButRef)(y,o.self.RULES)){let U=y.$ref;if(y=hAA.resolveRef.call(o.self,o.schemaEnv.root,o.baseId,U),y instanceof hAA.SchemaEnv&&(y=y.schema),y===void 0)throw new lSA.default(o.opts.uriResolver,o.baseId,U)}let F=(d=y?.properties)===null||d===void 0?void 0:d[s];if(typeof F!="object")throw new Error(`discriminator: oneOf subschemas (or referenced schemas) must have "properties/${s}"`);Q=Q&&(E||u(y)),v(F,x)}if(!Q)throw new Error(`discriminator: "${s}" must be required`);return B;function u({required:x}){return Array.isArray(x)&&x.includes(s)}function v(x,y){if(x.const)L(x.const,y);else if(x.enum)for(let F of x.enum)L(F,y);else throw new Error(`discriminator: "properties/${s}" must have "const" or "enum"`)}function L(x,y){if(typeof x!="string"||x in B)throw new Error(`discriminator: "${s}" values must be unique strings`);B[x]=y}}}};mL.default=CSA});var uAA=Le((tme,dSA)=>{dSA.exports={$schema:"http://json-schema.org/draft-07/schema#",$id:"http://json-schema.org/draft-07/schema#",title:"Core schema meta-schema",definitions:{schemaArray:{type:"array",minItems:1,items:{$ref:"#"}},nonNegativeInteger:{type:"integer",minimum:0},nonNegativeIntegerDefault0:{allOf:[{$ref:"#/definitions/nonNegativeInteger"},{default:0}]},simpleTypes:{enum:["array","boolean","integer","null","number","object","string"]},stringArray:{type:"array",items:{type:"string"},uniqueItems:!0,default:[]}},type:["object","boolean"],properties:{$id:{type:"string",format:"uri-reference"},$schema:{type:"string",format:"uri"},$ref:{type:"string",format:"uri-reference"},$comment:{type:"string"},title:{type:"string"},description:{type:"string"},default:!0,readOnly:{type:"boolean",default:!1},examples:{type:"array",items:!0},multipleOf:{type:"number",exclusiveMinimum:0},maximum:{type:"number"},exclusiveMaximum:{type:"number"},minimum:{type:"number"},exclusiveMinimum:{type:"number"},maxLength:{$ref:"#/definitions/nonNegativeInteger"},minLength:{$ref:"#/definitions/nonNegativeIntegerDefault0"},pattern:{type:"string",format:"regex"},additionalItems:{$ref:"#"},items:{anyOf:[{$ref:"#"},{$ref:"#/definitions/schemaArray"}],default:!0},maxItems:{$ref:"#/definitions/nonNegativeInteger"},minItems:{$ref:"#/definitions/nonNegativeIntegerDefault0"},uniqueItems:{type:"boolean",default:!1},contains:{$ref:"#"},maxProperties:{$ref:"#/definitions/nonNegativeInteger"},minProperties:{$ref:"#/definitions/nonNegativeIntegerDefault0"},required:{$ref:"#/definitions/stringArray"},additionalProperties:{$ref:"#"},definitions:{type:"object",additionalProperties:{$ref:"#"},default:{}},properties:{type:"object",additionalProperties:{$ref:"#"},default:{}},patternProperties:{type:"object",additionalProperties:{$ref:"#"},propertyNames:{format:"regex"},default:{}},dependencies:{type:"object",additionalProperties:{anyOf:[{$ref:"#"},{$ref:"#/definitions/stringArray"}]}},propertyNames:{$ref:"#"},const:!0,enum:{type:"array",items:!0,minItems:1,uniqueItems:!0},type:{anyOf:[{$ref:"#/definitions/simpleTypes"},{type:"array",items:{$ref:"#/definitions/simpleTypes"},minItems:1,uniqueItems:!0}]},format:{type:"string"},contentMediaType:{type:"string"},contentEncoding:{type:"string"},if:{$ref:"#"},then:{$ref:"#"},else:{$ref:"#"},allOf:{$ref:"#/definitions/schemaArray"},anyOf:{$ref:"#/definitions/schemaArray"},oneOf:{$ref:"#/definitions/schemaArray"},not:{$ref:"#"}},default:!0}});var mAA=Le((Ro,pL)=>{"use strict";Object.defineProperty(Ro,"__esModule",{value:!0});Ro.MissingRefError=Ro.ValidationError=Ro.CodeGen=Ro.Name=Ro.nil=Ro.stringify=Ro.str=Ro._=Ro.KeywordCxt=Ro.Ajv=void 0;var BSA=B$(),ESA=dAA(),hSA=QAA(),fAA=uAA(),QSA=["/properties"],H5="http://json-schema.org/draft-07/schema",sE=class extends BSA.default{_addVocabularies(){super._addVocabularies(),ESA.default.forEach(e=>this.addVocabulary(e)),this.opts.discriminator&&this.addKeyword(hSA.default)}_addDefaultMetaSchema(){if(super._addDefaultMetaSchema(),!this.opts.meta)return;let e=this.opts.$data?this.$dataMetaSchema(fAA,QSA):fAA;this.addMetaSchema(e,H5,!1),this.refs["http://json-schema.org/schema"]=H5}defaultMeta(){return this.opts.defaultMeta=super.defaultMeta()||(this.getSchema(H5)?H5:void 0)}};Ro.Ajv=sE;pL.exports=Ro=sE;pL.exports.Ajv=sE;Object.defineProperty(Ro,"__esModule",{value:!0});Ro.default=sE;var uSA=s4();Object.defineProperty(Ro,"KeywordCxt",{enumerable:!0,get:function(){return uSA.KeywordCxt}});var aE=Ji();Object.defineProperty(Ro,"_",{enumerable:!0,get:function(){return aE._}});Object.defineProperty(Ro,"str",{enumerable:!0,get:function(){return aE.str}});Object.defineProperty(Ro,"stringify",{enumerable:!0,get:function(){return aE.stringify}});Object.defineProperty(Ro,"nil",{enumerable:!0,get:function(){return aE.nil}});Object.defineProperty(Ro,"Name",{enumerable:!0,get:function(){return aE.Name}});Object.defineProperty(Ro,"CodeGen",{enumerable:!0,get:function(){return aE.CodeGen}});var fSA=w5();Object.defineProperty(Ro,"ValidationError",{enumerable:!0,get:function(){return fSA.default}});var mSA=a4();Object.defineProperty(Ro,"MissingRefError",{enumerable:!0,get:function(){return mSA.default}})});var pAA=Le(O5=>{"use strict";(function(t){"use strict";function e(M){return M!==null?Object.prototype.toString.call(M)==="[object Array]":!1}function A(M){return M!==null?Object.prototype.toString.call(M)==="[object Object]":!1}function i(M,G){if(M===G)return!0;var Y=Object.prototype.toString.call(M);if(Y!==Object.prototype.toString.call(G))return!1;if(e(M)===!0){if(M.length!==G.length)return!1;for(var AA=0;AA<M.length;AA++)if(i(M[AA],G[AA])===!1)return!1;return!0}if(A(M)===!0){var dA={};for(var WA in M)if(hasOwnProperty.call(M,WA)){if(i(M[WA],G[WA])===!1)return!1;dA[WA]=!0}for(var Qe in G)if(hasOwnProperty.call(G,Qe)&&dA[Qe]!==!0)return!1;return!0}return!1}function n(M){if(M===""||M===!1||M===null)return!0;if(e(M)&&M.length===0)return!0;if(A(M)){for(var G in M)if(M.hasOwnProperty(G))return!1;return!0}else return!1}function o(M){for(var G=Object.keys(M),Y=[],AA=0;AA<G.length;AA++)Y.push(M[G[AA]]);return Y}function r(M,G){var Y={};for(var AA in M)Y[AA]=M[AA];for(var dA in G)Y[dA]=G[dA];return Y}var s;typeof String.prototype.trimLeft=="function"?s=function(M){return M.trimLeft()}:s=function(M){return M.match(/^\s*(.*)/)[1]};var a=0,c=1,l=2,I=3,C=4,d=5,B=6,E=7,Q=8,u=9,v={0:"number",1:"any",2:"string",3:"array",4:"object",5:"boolean",6:"expression",7:"null",8:"Array<number>",9:"Array<string>"},L="EOF",x="UnquotedIdentifier",y="QuotedIdentifier",F="Rbracket",U="Rparen",T="Comma",N="Colon",K="Rbrace",H="Number",j="Current",IA="Expref",lA="Pipe",uA="Or",p="And",V="EQ",cA="GT",aA="LT",jA="GTE",VA="LTE",ce="NE",EA="Flatten",sA="Star",TA="Filter",Ke="Dot",Re="Not",hA="Lbrace",eA="Lbracket",RA="Lparen",oA="Literal",ne={".":Ke,"*":sA,",":T,":":N,"{":hA,"}":K,"]":F,"(":RA,")":U,"@":j},h={"<":!0,">":!0,"=":!0,"!":!0},f={" ":!0,"	":!0,"\n":!0};function w(M){return M>="a"&&M<="z"||M>="A"&&M<="Z"||M==="_"}function D(M){return M>="0"&&M<="9"||M==="-"}function O(M){return M>="a"&&M<="z"||M>="A"&&M<="Z"||M>="0"&&M<="9"||M==="_"}function Z(){}Z.prototype={tokenize:function(M){var G=[];this._current=0;for(var Y,AA,dA;this._current<M.length;)if(w(M[this._current]))Y=this._current,AA=this._consumeUnquotedIdentifier(M),G.push({type:x,value:AA,start:Y});else if(ne[M[this._current]]!==void 0)G.push({type:ne[M[this._current]],value:M[this._current],start:this._current}),this._current++;else if(D(M[this._current]))dA=this._consumeNumber(M),G.push(dA);else if(M[this._current]==="[")dA=this._consumeLBracket(M),G.push(dA);else if(M[this._current]==='"')Y=this._current,AA=this._consumeQuotedIdentifier(M),G.push({type:y,value:AA,start:Y});else if(M[this._current]==="'")Y=this._current,AA=this._consumeRawStringLiteral(M),G.push({type:oA,value:AA,start:Y});else if(M[this._current]==="`"){Y=this._current;var WA=this._consumeLiteral(M);G.push({type:oA,value:WA,start:Y})}else if(h[M[this._current]]!==void 0)G.push(this._consumeOperator(M));else if(f[M[this._current]]!==void 0)this._current++;else if(M[this._current]==="&")Y=this._current,this._current++,M[this._current]==="&"?(this._current++,G.push({type:p,value:"&&",start:Y})):G.push({type:IA,value:"&",start:Y});else if(M[this._current]==="|")Y=this._current,this._current++,M[this._current]==="|"?(this._current++,G.push({type:uA,value:"||",start:Y})):G.push({type:lA,value:"|",start:Y});else{var Qe=new Error("Unknown character:"+M[this._current]);throw Qe.name="LexerError",Qe}return G},_consumeUnquotedIdentifier:function(M){var G=this._current;for(this._current++;this._current<M.length&&O(M[this._current]);)this._current++;return M.slice(G,this._current)},_consumeQuotedIdentifier:function(M){var G=this._current;this._current++;for(var Y=M.length;M[this._current]!=='"'&&this._current<Y;){var AA=this._current;M[AA]==="\\"&&(M[AA+1]==="\\"||M[AA+1]==='"')?AA+=2:AA++,this._current=AA}return this._current++,JSON.parse(M.slice(G,this._current))},_consumeRawStringLiteral:function(M){var G=this._current;this._current++;for(var Y=M.length;M[this._current]!=="'"&&this._current<Y;){var AA=this._current;M[AA]==="\\"&&(M[AA+1]==="\\"||M[AA+1]==="'")?AA+=2:AA++,this._current=AA}this._current++;var dA=M.slice(G+1,this._current-1);return dA.replace("\\'","'")},_consumeNumber:function(M){var G=this._current;this._current++;for(var Y=M.length;D(M[this._current])&&this._current<Y;)this._current++;var AA=parseInt(M.slice(G,this._current));return{type:H,value:AA,start:G}},_consumeLBracket:function(M){var G=this._current;return this._current++,M[this._current]==="?"?(this._current++,{type:TA,value:"[?",start:G}):M[this._current]==="]"?(this._current++,{type:EA,value:"[]",start:G}):{type:eA,value:"[",start:G}},_consumeOperator:function(M){var G=this._current,Y=M[G];if(this._current++,Y==="!")return M[this._current]==="="?(this._current++,{type:ce,value:"!=",start:G}):{type:Re,value:"!",start:G};if(Y==="<")return M[this._current]==="="?(this._current++,{type:VA,value:"<=",start:G}):{type:aA,value:"<",start:G};if(Y===">")return M[this._current]==="="?(this._current++,{type:jA,value:">=",start:G}):{type:cA,value:">",start:G};if(Y==="="&&M[this._current]==="=")return this._current++,{type:V,value:"==",start:G}},_consumeLiteral:function(M){this._current++;for(var G=this._current,Y=M.length,AA;M[this._current]!=="`"&&this._current<Y;){var dA=this._current;M[dA]==="\\"&&(M[dA+1]==="\\"||M[dA+1]==="`")?dA+=2:dA++,this._current=dA}var WA=s(M.slice(G,this._current));return WA=WA.replace("\\`","`"),this._looksLikeJSON(WA)?AA=JSON.parse(WA):AA=JSON.parse('"'+WA+'"'),this._current++,AA},_looksLikeJSON:function(M){var G='[{"',Y=["true","false","null"],AA="-0123456789";if(M==="")return!1;if(G.indexOf(M[0])>=0)return!0;if(Y.indexOf(M)>=0)return!0;if(AA.indexOf(M[0])>=0)try{return JSON.parse(M),!0}catch{return!1}else return!1}};var q={};q[L]=0,q[x]=0,q[y]=0,q[F]=0,q[U]=0,q[T]=0,q[K]=0,q[H]=0,q[j]=0,q[IA]=0,q[lA]=1,q[uA]=2,q[p]=3,q[V]=5,q[cA]=5,q[aA]=5,q[jA]=5,q[VA]=5,q[ce]=5,q[EA]=9,q[sA]=20,q[TA]=21,q[Ke]=40,q[Re]=45,q[hA]=50,q[eA]=55,q[RA]=60;function CA(){}CA.prototype={parse:function(M){this._loadTokens(M),this.index=0;var G=this.expression(0);if(this._lookahead(0)!==L){var Y=this._lookaheadToken(0),AA=new Error("Unexpected token type: "+Y.type+", value: "+Y.value);throw AA.name="ParserError",AA}return G},_loadTokens:function(M){var G=new Z,Y=G.tokenize(M);Y.push({type:L,value:"",start:M.length}),this.tokens=Y},expression:function(M){var G=this._lookaheadToken(0);this._advance();for(var Y=this.nud(G),AA=this._lookahead(0);M<q[AA];)this._advance(),Y=this.led(AA,Y),AA=this._lookahead(0);return Y},_lookahead:function(M){return this.tokens[this.index+M].type},_lookaheadToken:function(M){return this.tokens[this.index+M]},_advance:function(){this.index++},nud:function(M){var G,Y,AA;switch(M.type){case oA:return{type:"Literal",value:M.value};case x:return{type:"Field",name:M.value};case y:var dA={type:"Field",name:M.value};if(this._lookahead(0)===RA)throw new Error("Quoted identifier not allowed for function names.");return dA;case Re:return Y=this.expression(q.Not),{type:"NotExpression",children:[Y]};case sA:return G={type:"Identity"},Y=null,this._lookahead(0)===F?Y={type:"Identity"}:Y=this._parseProjectionRHS(q.Star),{type:"ValueProjection",children:[G,Y]};case TA:return this.led(M.type,{type:"Identity"});case hA:return this._parseMultiselectHash();case EA:return G={type:EA,children:[{type:"Identity"}]},Y=this._parseProjectionRHS(q.Flatten),{type:"Projection",children:[G,Y]};case eA:return this._lookahead(0)===H||this._lookahead(0)===N?(Y=this._parseIndexExpression(),this._projectIfSlice({type:"Identity"},Y)):this._lookahead(0)===sA&&this._lookahead(1)===F?(this._advance(),this._advance(),Y=this._parseProjectionRHS(q.Star),{type:"Projection",children:[{type:"Identity"},Y]}):this._parseMultiselectList();case j:return{type:j};case IA:return AA=this.expression(q.Expref),{type:"ExpressionReference",children:[AA]};case RA:for(var WA=[];this._lookahead(0)!==U;)this._lookahead(0)===j?(AA={type:j},this._advance()):AA=this.expression(0),WA.push(AA);return this._match(U),WA[0];default:this._errorToken(M)}},led:function(M,G){var Y;switch(M){case Ke:var AA=q.Dot;return this._lookahead(0)!==sA?(Y=this._parseDotRHS(AA),{type:"Subexpression",children:[G,Y]}):(this._advance(),Y=this._parseProjectionRHS(AA),{type:"ValueProjection",children:[G,Y]});case lA:return Y=this.expression(q.Pipe),{type:lA,children:[G,Y]};case uA:return Y=this.expression(q.Or),{type:"OrExpression",children:[G,Y]};case p:return Y=this.expression(q.And),{type:"AndExpression",children:[G,Y]};case RA:for(var dA=G.name,WA=[],Qe,yA;this._lookahead(0)!==U;)this._lookahead(0)===j?(Qe={type:j},this._advance()):Qe=this.expression(0),this._lookahead(0)===T&&this._match(T),WA.push(Qe);return this._match(U),yA={type:"Function",name:dA,children:WA},yA;case TA:var DA=this.expression(0);return this._match(F),this._lookahead(0)===EA?Y={type:"Identity"}:Y=this._parseProjectionRHS(q.Filter),{type:"FilterProjection",children:[G,Y,DA]};case EA:var We={type:EA,children:[G]},be=this._parseProjectionRHS(q.Flatten);return{type:"Projection",children:[We,be]};case V:case ce:case cA:case jA:case aA:case VA:return this._parseComparator(G,M);case eA:var qA=this._lookaheadToken(0);return qA.type===H||qA.type===N?(Y=this._parseIndexExpression(),this._projectIfSlice(G,Y)):(this._match(sA),this._match(F),Y=this._parseProjectionRHS(q.Star),{type:"Projection",children:[G,Y]});default:this._errorToken(this._lookaheadToken(0))}},_match:function(M){if(this._lookahead(0)===M)this._advance();else{var G=this._lookaheadToken(0),Y=new Error("Expected "+M+", got: "+G.type);throw Y.name="ParserError",Y}},_errorToken:function(M){var G=new Error("Invalid token ("+M.type+'): "'+M.value+'"');throw G.name="ParserError",G},_parseIndexExpression:function(){if(this._lookahead(0)===N||this._lookahead(1)===N)return this._parseSliceExpression();var M={type:"Index",value:this._lookaheadToken(0).value};return this._advance(),this._match(F),M},_projectIfSlice:function(M,G){var Y={type:"IndexExpression",children:[M,G]};return G.type==="Slice"?{type:"Projection",children:[Y,this._parseProjectionRHS(q.Star)]}:Y},_parseSliceExpression:function(){for(var M=[null,null,null],G=0,Y=this._lookahead(0);Y!==F&&G<3;){if(Y===N)G++,this._advance();else if(Y===H)M[G]=this._lookaheadToken(0).value,this._advance();else{var AA=this._lookahead(0),dA=new Error("Syntax error, unexpected token: "+AA.value+"("+AA.type+")");throw dA.name="Parsererror",dA}Y=this._lookahead(0)}return this._match(F),{type:"Slice",children:M}},_parseComparator:function(M,G){var Y=this.expression(q[G]);return{type:"Comparator",name:G,children:[M,Y]}},_parseDotRHS:function(M){var G=this._lookahead(0),Y=[x,y,sA];if(Y.indexOf(G)>=0)return this.expression(M);if(G===eA)return this._match(eA),this._parseMultiselectList();if(G===hA)return this._match(hA),this._parseMultiselectHash()},_parseProjectionRHS:function(M){var G;if(q[this._lookahead(0)]<10)G={type:"Identity"};else if(this._lookahead(0)===eA)G=this.expression(M);else if(this._lookahead(0)===TA)G=this.expression(M);else if(this._lookahead(0)===Ke)this._match(Ke),G=this._parseDotRHS(M);else{var Y=this._lookaheadToken(0),AA=new Error("Sytanx error, unexpected token: "+Y.value+"("+Y.type+")");throw AA.name="ParserError",AA}return G},_parseMultiselectList:function(){for(var M=[];this._lookahead(0)!==F;){var G=this.expression(0);if(M.push(G),this._lookahead(0)===T&&(this._match(T),this._lookahead(0)===F))throw new Error("Unexpected token Rbracket")}return this._match(F),{type:"MultiSelectList",children:M}},_parseMultiselectHash:function(){for(var M=[],G=[x,y],Y,AA,dA,WA;;){if(Y=this._lookaheadToken(0),G.indexOf(Y.type)<0)throw new Error("Expecting an identifier token, got: "+Y.type);if(AA=Y.value,this._advance(),this._match(N),dA=this.expression(0),WA={type:"KeyValuePair",name:AA,value:dA},M.push(WA),this._lookahead(0)===T)this._match(T);else if(this._lookahead(0)===K){this._match(K);break}}return{type:"MultiSelectHash",children:M}}};function kA(M){this.runtime=M}kA.prototype={search:function(M,G){return this.visit(M,G)},visit:function(M,G){var Y,AA,dA,WA,Qe,yA,DA,We,be,qA;switch(M.type){case"Field":return G!==null&&A(G)?(yA=G[M.name],yA===void 0?null:yA):null;case"Subexpression":for(dA=this.visit(M.children[0],G),qA=1;qA<M.children.length;qA++)if(dA=this.visit(M.children[1],dA),dA===null)return null;return dA;case"IndexExpression":return DA=this.visit(M.children[0],G),We=this.visit(M.children[1],DA),We;case"Index":if(!e(G))return null;var It=M.value;return It<0&&(It=G.length+It),dA=G[It],dA===void 0&&(dA=null),dA;case"Slice":if(!e(G))return null;var Vi=M.children.slice(0),on=this.computeSliceParams(G.length,Vi),Hi=on[0],Ci=on[1],Zi=on[2];if(dA=[],Zi>0)for(qA=Hi;qA<Ci;qA+=Zi)dA.push(G[qA]);else for(qA=Hi;qA>Ci;qA+=Zi)dA.push(G[qA]);return dA;case"Projection":var Qi=this.visit(M.children[0],G);if(!e(Qi))return null;for(be=[],qA=0;qA<Qi.length;qA++)AA=this.visit(M.children[1],Qi[qA]),AA!==null&&be.push(AA);return be;case"ValueProjection":if(Qi=this.visit(M.children[0],G),!A(Qi))return null;be=[];var Ft=o(Qi);for(qA=0;qA<Ft.length;qA++)AA=this.visit(M.children[1],Ft[qA]),AA!==null&&be.push(AA);return be;case"FilterProjection":if(Qi=this.visit(M.children[0],G),!e(Qi))return null;var Tt=[],Ht=[];for(qA=0;qA<Qi.length;qA++)Y=this.visit(M.children[2],Qi[qA]),n(Y)||Tt.push(Qi[qA]);for(var zi=0;zi<Tt.length;zi++)AA=this.visit(M.children[1],Tt[zi]),AA!==null&&Ht.push(AA);return Ht;case"Comparator":switch(WA=this.visit(M.children[0],G),Qe=this.visit(M.children[1],G),M.name){case V:dA=i(WA,Qe);break;case ce:dA=!i(WA,Qe);break;case cA:dA=WA>Qe;break;case jA:dA=WA>=Qe;break;case aA:dA=WA<Qe;break;case VA:dA=WA<=Qe;break;default:throw new Error("Unknown comparator: "+M.name)}return dA;case EA:var ui=this.visit(M.children[0],G);if(!e(ui))return null;var Ye=[];for(qA=0;qA<ui.length;qA++)AA=ui[qA],e(AA)?Ye.push.apply(Ye,AA):Ye.push(AA);return Ye;case"Identity":return G;case"MultiSelectList":if(G===null)return null;for(be=[],qA=0;qA<M.children.length;qA++)be.push(this.visit(M.children[qA],G));return be;case"MultiSelectHash":if(G===null)return null;be={};var Ai;for(qA=0;qA<M.children.length;qA++)Ai=M.children[qA],be[Ai.name]=this.visit(Ai.value,G);return be;case"OrExpression":return Y=this.visit(M.children[0],G),n(Y)&&(Y=this.visit(M.children[1],G)),Y;case"AndExpression":return WA=this.visit(M.children[0],G),n(WA)===!0?WA:this.visit(M.children[1],G);case"NotExpression":return WA=this.visit(M.children[0],G),n(WA);case"Literal":return M.value;case lA:return DA=this.visit(M.children[0],G),this.visit(M.children[1],DA);case j:return G;case"Function":var ei=[];for(qA=0;qA<M.children.length;qA++)ei.push(this.visit(M.children[qA],G));return this.runtime.callFunction(M.name,ei);case"ExpressionReference":var Oi=M.children[0];return Oi.jmespathType=IA,Oi;default:throw new Error("Unknown node type: "+M.type)}},computeSliceParams:function(M,G){var Y=G[0],AA=G[1],dA=G[2],WA=[null,null,null];if(dA===null)dA=1;else if(dA===0){var Qe=new Error("Invalid slice, step cannot be 0");throw Qe.name="RuntimeError",Qe}var yA=dA<0;return Y===null?Y=yA?M-1:0:Y=this.capSliceRange(M,Y,dA),AA===null?AA=yA?-1:M:AA=this.capSliceRange(M,AA,dA),WA[0]=Y,WA[1]=AA,WA[2]=dA,WA},capSliceRange:function(M,G,Y){return G<0?(G+=M,G<0&&(G=Y<0?-1:0)):G>=M&&(G=Y<0?M-1:M),G}};function KA(M){this._interpreter=M,this.functionTable={abs:{_func:this._functionAbs,_signature:[{types:[a]}]},avg:{_func:this._functionAvg,_signature:[{types:[Q]}]},ceil:{_func:this._functionCeil,_signature:[{types:[a]}]},contains:{_func:this._functionContains,_signature:[{types:[l,I]},{types:[c]}]},ends_with:{_func:this._functionEndsWith,_signature:[{types:[l]},{types:[l]}]},floor:{_func:this._functionFloor,_signature:[{types:[a]}]},length:{_func:this._functionLength,_signature:[{types:[l,I,C]}]},map:{_func:this._functionMap,_signature:[{types:[B]},{types:[I]}]},max:{_func:this._functionMax,_signature:[{types:[Q,u]}]},merge:{_func:this._functionMerge,_signature:[{types:[C],variadic:!0}]},max_by:{_func:this._functionMaxBy,_signature:[{types:[I]},{types:[B]}]},sum:{_func:this._functionSum,_signature:[{types:[Q]}]},starts_with:{_func:this._functionStartsWith,_signature:[{types:[l]},{types:[l]}]},min:{_func:this._functionMin,_signature:[{types:[Q,u]}]},min_by:{_func:this._functionMinBy,_signature:[{types:[I]},{types:[B]}]},type:{_func:this._functionType,_signature:[{types:[c]}]},keys:{_func:this._functionKeys,_signature:[{types:[C]}]},values:{_func:this._functionValues,_signature:[{types:[C]}]},sort:{_func:this._functionSort,_signature:[{types:[u,Q]}]},sort_by:{_func:this._functionSortBy,_signature:[{types:[I]},{types:[B]}]},join:{_func:this._functionJoin,_signature:[{types:[l]},{types:[u]}]},reverse:{_func:this._functionReverse,_signature:[{types:[l,I]}]},to_array:{_func:this._functionToArray,_signature:[{types:[c]}]},to_string:{_func:this._functionToString,_signature:[{types:[c]}]},to_number:{_func:this._functionToNumber,_signature:[{types:[c]}]},not_null:{_func:this._functionNotNull,_signature:[{types:[c],variadic:!0}]}}}KA.prototype={callFunction:function(M,G){var Y=this.functionTable[M];if(Y===void 0)throw new Error("Unknown function: "+M+"()");return this._validateArgs(M,G,Y._signature),Y._func.call(this,G)},_validateArgs:function(M,G,Y){var AA;if(Y[Y.length-1].variadic){if(G.length<Y.length)throw AA=Y.length===1?" argument":" arguments",new Error("ArgumentError: "+M+"() takes at least"+Y.length+AA+" but received "+G.length)}else if(G.length!==Y.length)throw AA=Y.length===1?" argument":" arguments",new Error("ArgumentError: "+M+"() takes "+Y.length+AA+" but received "+G.length);for(var dA,WA,Qe,yA=0;yA<Y.length;yA++){Qe=!1,dA=Y[yA].types,WA=this._getTypeName(G[yA]);for(var DA=0;DA<dA.length;DA++)if(this._typeMatches(WA,dA[DA],G[yA])){Qe=!0;break}if(!Qe){var We=dA.map(function(be){return v[be]}).join(",");throw new Error("TypeError: "+M+"() expected argument "+(yA+1)+" to be type "+We+" but received type "+v[WA]+" instead.")}}},_typeMatches:function(M,G,Y){if(G===c)return!0;if(G===u||G===Q||G===I){if(G===I)return M===I;if(M===I){var AA;G===Q?AA=a:G===u&&(AA=l);for(var dA=0;dA<Y.length;dA++)if(!this._typeMatches(this._getTypeName(Y[dA]),AA,Y[dA]))return!1;return!0}}else return M===G},_getTypeName:function(M){switch(Object.prototype.toString.call(M)){case"[object String]":return l;case"[object Number]":return a;case"[object Array]":return I;case"[object Boolean]":return d;case"[object Null]":return E;case"[object Object]":return M.jmespathType===IA?B:C}},_functionStartsWith:function(M){return M[0].lastIndexOf(M[1])===0},_functionEndsWith:function(M){var G=M[0],Y=M[1];return G.indexOf(Y,G.length-Y.length)!==-1},_functionReverse:function(M){var G=this._getTypeName(M[0]);if(G===l){for(var Y=M[0],AA="",dA=Y.length-1;dA>=0;dA--)AA+=Y[dA];return AA}else{var WA=M[0].slice(0);return WA.reverse(),WA}},_functionAbs:function(M){return Math.abs(M[0])},_functionCeil:function(M){return Math.ceil(M[0])},_functionAvg:function(M){for(var G=0,Y=M[0],AA=0;AA<Y.length;AA++)G+=Y[AA];return G/Y.length},_functionContains:function(M){return M[0].indexOf(M[1])>=0},_functionFloor:function(M){return Math.floor(M[0])},_functionLength:function(M){return A(M[0])?Object.keys(M[0]).length:M[0].length},_functionMap:function(M){for(var G=[],Y=this._interpreter,AA=M[0],dA=M[1],WA=0;WA<dA.length;WA++)G.push(Y.visit(AA,dA[WA]));return G},_functionMerge:function(M){for(var G={},Y=0;Y<M.length;Y++){var AA=M[Y];for(var dA in AA)G[dA]=AA[dA]}return G},_functionMax:function(M){if(M[0].length>0){var G=this._getTypeName(M[0][0]);if(G===a)return Math.max.apply(Math,M[0]);for(var Y=M[0],AA=Y[0],dA=1;dA<Y.length;dA++)AA.localeCompare(Y[dA])<0&&(AA=Y[dA]);return AA}else return null},_functionMin:function(M){if(M[0].length>0){var G=this._getTypeName(M[0][0]);if(G===a)return Math.min.apply(Math,M[0]);for(var Y=M[0],AA=Y[0],dA=1;dA<Y.length;dA++)Y[dA].localeCompare(AA)<0&&(AA=Y[dA]);return AA}else return null},_functionSum:function(M){for(var G=0,Y=M[0],AA=0;AA<Y.length;AA++)G+=Y[AA];return G},_functionType:function(M){switch(this._getTypeName(M[0])){case a:return"number";case l:return"string";case I:return"array";case C:return"object";case d:return"boolean";case B:return"expref";case E:return"null"}},_functionKeys:function(M){return Object.keys(M[0])},_functionValues:function(M){for(var G=M[0],Y=Object.keys(G),AA=[],dA=0;dA<Y.length;dA++)AA.push(G[Y[dA]]);return AA},_functionJoin:function(M){var G=M[0],Y=M[1];return Y.join(G)},_functionToArray:function(M){return this._getTypeName(M[0])===I?M[0]:[M[0]]},_functionToString:function(M){return this._getTypeName(M[0])===l?M[0]:JSON.stringify(M[0])},_functionToNumber:function(M){var G=this._getTypeName(M[0]),Y;return G===a?M[0]:G===l&&(Y=+M[0],!isNaN(Y))?Y:null},_functionNotNull:function(M){for(var G=0;G<M.length;G++)if(this._getTypeName(M[G])!==E)return M[G];return null},_functionSort:function(M){var G=M[0].slice(0);return G.sort(),G},_functionSortBy:function(M){var G=M[0].slice(0);if(G.length===0)return G;var Y=this._interpreter,AA=M[1],dA=this._getTypeName(Y.visit(AA,G[0]));if([a,l].indexOf(dA)<0)throw new Error("TypeError");for(var WA=this,Qe=[],yA=0;yA<G.length;yA++)Qe.push([yA,G[yA]]);Qe.sort(function(We,be){var qA=Y.visit(AA,We[1]),It=Y.visit(AA,be[1]);if(WA._getTypeName(qA)!==dA)throw new Error("TypeError: expected "+dA+", received "+WA._getTypeName(qA));if(WA._getTypeName(It)!==dA)throw new Error("TypeError: expected "+dA+", received "+WA._getTypeName(It));return qA>It?1:qA<It?-1:We[0]-be[0]});for(var DA=0;DA<Qe.length;DA++)G[DA]=Qe[DA][1];return G},_functionMaxBy:function(M){for(var G=M[1],Y=M[0],AA=this.createKeyFunction(G,[a,l]),dA=-1/0,WA,Qe,yA=0;yA<Y.length;yA++)Qe=AA(Y[yA]),Qe>dA&&(dA=Qe,WA=Y[yA]);return WA},_functionMinBy:function(M){for(var G=M[1],Y=M[0],AA=this.createKeyFunction(G,[a,l]),dA=1/0,WA,Qe,yA=0;yA<Y.length;yA++)Qe=AA(Y[yA]),Qe<dA&&(dA=Qe,WA=Y[yA]);return WA},createKeyFunction:function(M,G){var Y=this,AA=this._interpreter,dA=function(WA){var Qe=AA.visit(M,WA);if(G.indexOf(Y._getTypeName(Qe))<0){var yA="TypeError: expected one of "+G+", received "+Y._getTypeName(Qe);throw new Error(yA)}return Qe};return dA}};function Ie(M){var G=new CA,Y=G.parse(M);return Y}function GA(M){var G=new Z;return G.tokenize(M)}function oe(M,G){var Y=new CA,AA=new KA,dA=new kA(AA);AA._interpreter=dA;var WA=Y.parse(G);return dA.search(WA,M)}t.tokenize=GA,t.compile=Ie,t.search=oe,t.strictDeepEqual=i})(typeof O5>"u"?O5.jmespath={}:O5)});function k7(t,e){return Object.is(t,e)}var yr=null,Sf=!1,S7=1,js=Symbol("SIGNAL");function vi(t){let e=yr;return yr=t,e}function R7(){return yr}var id={version:0,lastCleanEpoch:0,dirty:!1,producerNode:void 0,producerLastReadVersion:void 0,producerIndexOfThis:void 0,nextProducerIndex:0,liveConsumerNode:void 0,liveConsumerIndexOfThis:void 0,consumerAllowSignalWrites:!1,consumerIsAlwaysLive:!1,kind:"unknown",producerMustRecompute:()=>!1,producerRecomputeValue:()=>{},consumerMarkedDirty:()=>{},consumerOnSignalRead:()=>{}};function Nh(t){if(Sf)throw new Error("");if(yr===null)return;yr.consumerOnSignalRead(t);let e=yr.nextProducerIndex++;if(Nf(yr),e<yr.producerNode.length&&yr.producerNode[e]!==t&&Fh(yr)){let A=yr.producerNode[e];Ff(A,yr.producerIndexOfThis[e])}yr.producerNode[e]!==t&&(yr.producerNode[e]=t,yr.producerIndexOfThis[e]=Fh(yr)?LU(t,yr,e):0),yr.producerLastReadVersion[e]=t.version}function RU(){S7++}function L7(t){if(!(Fh(t)&&!t.dirty)&&!(!t.dirty&&t.lastCleanEpoch===S7)){if(!t.producerMustRecompute(t)&&!xf(t)){M7(t);return}t.producerRecomputeValue(t),M7(t)}}function x7(t){if(t.liveConsumerNode===void 0)return;let e=Sf;Sf=!0;try{for(let A of t.liveConsumerNode)A.dirty||lgA(A)}finally{Sf=e}}function F7(){return yr?.consumerAllowSignalWrites!==!1}function lgA(t){t.dirty=!0,x7(t),t.consumerMarkedDirty?.(t)}function M7(t){t.dirty=!1,t.lastCleanEpoch=S7}function _h(t){return t&&(t.nextProducerIndex=0),vi(t)}function Lf(t,e){if(vi(e),!(!t||t.producerNode===void 0||t.producerIndexOfThis===void 0||t.producerLastReadVersion===void 0)){if(Fh(t))for(let A=t.nextProducerIndex;A<t.producerNode.length;A++)Ff(t.producerNode[A],t.producerIndexOfThis[A]);for(;t.producerNode.length>t.nextProducerIndex;)t.producerNode.pop(),t.producerLastReadVersion.pop(),t.producerIndexOfThis.pop()}}function xf(t){Nf(t);for(let e=0;e<t.producerNode.length;e++){let A=t.producerNode[e],i=t.producerLastReadVersion[e];if(i!==A.version||(L7(A),i!==A.version))return!0}return!1}function Gh(t){if(Nf(t),Fh(t))for(let e=0;e<t.producerNode.length;e++)Ff(t.producerNode[e],t.producerIndexOfThis[e]);t.producerNode.length=t.producerLastReadVersion.length=t.producerIndexOfThis.length=0,t.liveConsumerNode&&(t.liveConsumerNode.length=t.liveConsumerIndexOfThis.length=0)}function LU(t,e,A){if(xU(t),t.liveConsumerNode.length===0&&FU(t))for(let i=0;i<t.producerNode.length;i++)t.producerIndexOfThis[i]=LU(t.producerNode[i],t,i);return t.liveConsumerIndexOfThis.push(A),t.liveConsumerNode.push(e)-1}function Ff(t,e){if(xU(t),t.liveConsumerNode.length===1&&FU(t))for(let i=0;i<t.producerNode.length;i++)Ff(t.producerNode[i],t.producerIndexOfThis[i]);let A=t.liveConsumerNode.length-1;if(t.liveConsumerNode[e]=t.liveConsumerNode[A],t.liveConsumerIndexOfThis[e]=t.liveConsumerIndexOfThis[A],t.liveConsumerNode.length--,t.liveConsumerIndexOfThis.length--,e<t.liveConsumerNode.length){let i=t.liveConsumerIndexOfThis[e],n=t.liveConsumerNode[e];Nf(n),n.producerIndexOfThis[i]=e}}function Fh(t){return t.consumerIsAlwaysLive||(t?.liveConsumerNode?.length??0)>0}function Nf(t){t.producerNode??=[],t.producerIndexOfThis??=[],t.producerLastReadVersion??=[]}function xU(t){t.liveConsumerNode??=[],t.liveConsumerIndexOfThis??=[]}function FU(t){return t.producerNode!==void 0}function _f(t,e){let A=Object.create(ggA);A.computation=t,e!==void 0&&(A.equal=e);let i=()=>{if(L7(A),Nh(A),A.value===Rf)throw A.error;return A.value};return i[js]=A,i}var v7=Symbol("UNSET"),b7=Symbol("COMPUTING"),Rf=Symbol("ERRORED"),ggA=Ne(nA({},id),{value:v7,dirty:!0,error:null,equal:k7,kind:"computed",producerMustRecompute(t){return t.value===v7||t.value===b7},producerRecomputeValue(t){if(t.value===b7)throw new Error("Detected cycle in computations.");let e=t.value;t.value=b7;let A=_h(t),i,n=!1;try{i=t.computation(),vi(null),n=e!==v7&&e!==Rf&&i!==Rf&&t.equal(e,i)}catch(o){i=Rf,t.error=o}finally{Lf(t,A)}if(n){t.value=e;return}t.value=i,t.version++}});function IgA(){throw new Error}var NU=IgA;function _U(t){NU(t)}function N7(t){NU=t}var CgA=null;function _7(t,e){let A=Object.create(Gf);A.value=t,e!==void 0&&(A.equal=e);let i=()=>(Nh(A),A.value);return i[js]=A,i}function Uh(t,e){F7()||_U(t),t.equal(t.value,e)||(t.value=e,dgA(t))}function G7(t,e){F7()||_U(t),Uh(t,e(t.value))}var Gf=Ne(nA({},id),{equal:k7,value:void 0,kind:"signal"});function dgA(t){t.version++,RU(),x7(t),CgA?.()}function U7(t){let e=vi(null);try{return t()}finally{vi(e)}}var K7;function Kh(){return K7}function Vg(t){let e=K7;return K7=t,e}var Uf=Symbol("NotFound");function Lt(t){return typeof t=="function"}function nd(t){let A=t(i=>{Error.call(i),i.stack=new Error().stack});return A.prototype=Object.create(Error.prototype),A.prototype.constructor=A,A}var Kf=nd(t=>function(A){t(this),this.message=A?`${A.length} errors occurred during unsubscription:
${A.map((i,n)=>`${n+1}) ${i.toString()}`).join(`
  `)}`:"",this.name="UnsubscriptionError",this.errors=A});function W1(t,e){if(t){let A=t.indexOf(e);0<=A&&t.splice(A,1)}}var _t=class t{constructor(e){this.initialTeardown=e,this.closed=!1,this._parentage=null,this._finalizers=null}unsubscribe(){let e;if(!this.closed){this.closed=!0;let{_parentage:A}=this;if(A)if(this._parentage=null,Array.isArray(A))for(let o of A)o.remove(this);else A.remove(this);let{initialTeardown:i}=this;if(Lt(i))try{i()}catch(o){e=o instanceof Kf?o.errors:[o]}let{_finalizers:n}=this;if(n){this._finalizers=null;for(let o of n)try{GU(o)}catch(r){e=e??[],r instanceof Kf?e=[...e,...r.errors]:e.push(r)}}if(e)throw new Kf(e)}}add(e){var A;if(e&&e!==this)if(this.closed)GU(e);else{if(e instanceof t){if(e.closed||e._hasParent(this))return;e._addParent(this)}(this._finalizers=(A=this._finalizers)!==null&&A!==void 0?A:[]).push(e)}}_hasParent(e){let{_parentage:A}=this;return A===e||Array.isArray(A)&&A.includes(e)}_addParent(e){let{_parentage:A}=this;this._parentage=Array.isArray(A)?(A.push(e),A):A?[A,e]:e}_removeParent(e){let{_parentage:A}=this;A===e?this._parentage=null:Array.isArray(A)&&W1(A,e)}remove(e){let{_finalizers:A}=this;A&&W1(A,e),e instanceof t&&e._removeParent(this)}};_t.EMPTY=(()=>{let t=new _t;return t.closed=!0,t})();var Y7=_t.EMPTY;function Yf(t){return t instanceof _t||t&&"closed"in t&&Lt(t.remove)&&Lt(t.add)&&Lt(t.unsubscribe)}function GU(t){Lt(t)?t():t.unsubscribe()}var jc={onUnhandledError:null,onStoppedNotification:null,Promise:void 0,useDeprecatedSynchronousErrorHandling:!1,useDeprecatedNextContext:!1};var od={setTimeout(t,e,...A){let{delegate:i}=od;return i?.setTimeout?i.setTimeout(t,e,...A):setTimeout(t,e,...A)},clearTimeout(t){let{delegate:e}=od;return(e?.clearTimeout||clearTimeout)(t)},delegate:void 0};function Jf(t){od.setTimeout(()=>{let{onUnhandledError:e}=jc;if(e)e(t);else throw t})}function Yh(){}var UU=J7("C",void 0,void 0);function KU(t){return J7("E",void 0,t)}function YU(t){return J7("N",t,void 0)}function J7(t,e,A){return{kind:t,value:e,error:A}}var X1=null;function rd(t){if(jc.useDeprecatedSynchronousErrorHandling){let e=!X1;if(e&&(X1={errorThrown:!1,error:null}),t(),e){let{errorThrown:A,error:i}=X1;if(X1=null,A)throw i}}else t()}function JU(t){jc.useDeprecatedSynchronousErrorHandling&&X1&&(X1.errorThrown=!0,X1.error=t)}var Zg=class extends _t{constructor(e){super(),this.isStopped=!1,e?(this.destination=e,Yf(e)&&e.add(this)):this.destination=fgA}static create(e,A,i){return new Wg(e,A,i)}next(e){this.isStopped?z7(YU(e),this):this._next(e)}error(e){this.isStopped?z7(KU(e),this):(this.isStopped=!0,this._error(e))}complete(){this.isStopped?z7(UU,this):(this.isStopped=!0,this._complete())}unsubscribe(){this.closed||(this.isStopped=!0,super.unsubscribe(),this.destination=null)}_next(e){this.destination.next(e)}_error(e){try{this.destination.error(e)}finally{this.unsubscribe()}}_complete(){try{this.destination.complete()}finally{this.unsubscribe()}}},QgA=Function.prototype.bind;function T7(t,e){return QgA.call(t,e)}var H7=class{constructor(e){this.partialObserver=e}next(e){let{partialObserver:A}=this;if(A.next)try{A.next(e)}catch(i){Tf(i)}}error(e){let{partialObserver:A}=this;if(A.error)try{A.error(e)}catch(i){Tf(i)}else Tf(e)}complete(){let{partialObserver:e}=this;if(e.complete)try{e.complete()}catch(A){Tf(A)}}},Wg=class extends Zg{constructor(e,A,i){super();let n;if(Lt(e)||!e)n={next:e??void 0,error:A??void 0,complete:i??void 0};else{let o;this&&jc.useDeprecatedNextContext?(o=Object.create(e),o.unsubscribe=()=>this.unsubscribe(),n={next:e.next&&T7(e.next,o),error:e.error&&T7(e.error,o),complete:e.complete&&T7(e.complete,o)}):n=e}this.destination=new H7(n)}};function Tf(t){jc.useDeprecatedSynchronousErrorHandling?JU(t):Jf(t)}function ugA(t){throw t}function z7(t,e){let{onStoppedNotification:A}=jc;A&&od.setTimeout(()=>A(t,e))}var fgA={closed:!0,next:Yh,error:ugA,complete:Yh};var sd=typeof Symbol=="function"&&Symbol.observable||"@@observable";function Rs(t){return t}function O7(...t){return P7(t)}function P7(t){return t.length===0?Rs:t.length===1?t[0]:function(A){return t.reduce((i,n)=>n(i),A)}}var Ze=(()=>{class t{constructor(A){A&&(this._subscribe=A)}lift(A){let i=new t;return i.source=this,i.operator=A,i}subscribe(A,i,n){let o=pgA(A)?A:new Wg(A,i,n);return rd(()=>{let{operator:r,source:s}=this;o.add(r?r.call(o,s):s?this._subscribe(o):this._trySubscribe(o))}),o}_trySubscribe(A){try{return this._subscribe(A)}catch(i){A.error(i)}}forEach(A,i){return i=TU(i),new i((n,o)=>{let r=new Wg({next:s=>{try{A(s)}catch(a){o(a),r.unsubscribe()}},error:o,complete:n});this.subscribe(r)})}_subscribe(A){var i;return(i=this.source)===null||i===void 0?void 0:i.subscribe(A)}[sd](){return this}pipe(...A){return P7(A)(this)}toPromise(A){return A=TU(A),new A((i,n)=>{let o;this.subscribe(r=>o=r,r=>n(r),()=>i(o))})}}return t.create=e=>new t(e),t})();function TU(t){var e;return(e=t??jc.Promise)!==null&&e!==void 0?e:Promise}function mgA(t){return t&&Lt(t.next)&&Lt(t.error)&&Lt(t.complete)}function pgA(t){return t&&t instanceof Zg||mgA(t)&&Yf(t)}function j7(t){return Lt(t?.lift)}function qt(t){return e=>{if(j7(e))return e.lift(function(A){try{return t(A,this)}catch(i){this.error(i)}});throw new TypeError("Unable to lift unknown Observable type")}}function zt(t,e,A,i,n){return new q7(t,e,A,i,n)}var q7=class extends Zg{constructor(e,A,i,n,o,r){super(e),this.onFinalize=o,this.shouldUnsubscribe=r,this._next=A?function(s){try{A(s)}catch(a){e.error(a)}}:super._next,this._error=n?function(s){try{n(s)}catch(a){e.error(a)}finally{this.unsubscribe()}}:super._error,this._complete=i?function(){try{i()}catch(s){e.error(s)}finally{this.unsubscribe()}}:super._complete}unsubscribe(){var e;if(!this.shouldUnsubscribe||this.shouldUnsubscribe()){let{closed:A}=this;super.unsubscribe(),!A&&((e=this.onFinalize)===null||e===void 0||e.call(this))}}};function ad(){return qt((t,e)=>{let A=null;t._refCount++;let i=zt(e,void 0,void 0,void 0,()=>{if(!t||t._refCount<=0||0<--t._refCount){A=null;return}let n=t._connection,o=A;A=null,n&&(!o||n===o)&&n.unsubscribe(),e.unsubscribe()});t.subscribe(i),i.closed||(A=t.connect())})}var r2=class extends Ze{constructor(e,A){super(),this.source=e,this.subjectFactory=A,this._subject=null,this._refCount=0,this._connection=null,j7(e)&&(this.lift=e.lift)}_subscribe(e){return this.getSubject().subscribe(e)}getSubject(){let e=this._subject;return(!e||e.isStopped)&&(this._subject=this.subjectFactory()),this._subject}_teardown(){this._refCount=0;let{_connection:e}=this;this._subject=this._connection=null,e?.unsubscribe()}connect(){let e=this._connection;if(!e){e=this._connection=new _t;let A=this.getSubject();e.add(this.source.subscribe(zt(A,void 0,()=>{this._teardown(),A.complete()},i=>{this._teardown(),A.error(i)},()=>this._teardown()))),e.closed&&(this._connection=null,e=_t.EMPTY)}return e}refCount(){return ad()(this)}};var zU=nd(t=>function(){t(this),this.name="ObjectUnsubscribedError",this.message="object unsubscribed"});var HA=(()=>{class t extends Ze{constructor(){super(),this.closed=!1,this.currentObservers=null,this.observers=[],this.isStopped=!1,this.hasError=!1,this.thrownError=null}lift(A){let i=new cd(this,this);return i.operator=A,i}_throwIfClosed(){if(this.closed)throw new zU}next(A){rd(()=>{if(this._throwIfClosed(),!this.isStopped){this.currentObservers||(this.currentObservers=Array.from(this.observers));for(let i of this.currentObservers)i.next(A)}})}error(A){rd(()=>{if(this._throwIfClosed(),!this.isStopped){this.hasError=this.isStopped=!0,this.thrownError=A;let{observers:i}=this;for(;i.length;)i.shift().error(A)}})}complete(){rd(()=>{if(this._throwIfClosed(),!this.isStopped){this.isStopped=!0;let{observers:A}=this;for(;A.length;)A.shift().complete()}})}unsubscribe(){this.isStopped=this.closed=!0,this.observers=this.currentObservers=null}get observed(){var A;return((A=this.observers)===null||A===void 0?void 0:A.length)>0}_trySubscribe(A){return this._throwIfClosed(),super._trySubscribe(A)}_subscribe(A){return this._throwIfClosed(),this._checkFinalizedStatuses(A),this._innerSubscribe(A)}_innerSubscribe(A){let{hasError:i,isStopped:n,observers:o}=this;return i||n?Y7:(this.currentObservers=null,o.push(A),new _t(()=>{this.currentObservers=null,W1(o,A)}))}_checkFinalizedStatuses(A){let{hasError:i,thrownError:n,isStopped:o}=this;i?A.error(n):o&&A.complete()}asObservable(){let A=new Ze;return A.source=this,A}}return t.create=(e,A)=>new cd(e,A),t})(),cd=class extends HA{constructor(e,A){super(),this.destination=e,this.source=A}next(e){var A,i;(i=(A=this.destination)===null||A===void 0?void 0:A.next)===null||i===void 0||i.call(A,e)}error(e){var A,i;(i=(A=this.destination)===null||A===void 0?void 0:A.error)===null||i===void 0||i.call(A,e)}complete(){var e,A;(A=(e=this.destination)===null||e===void 0?void 0:e.complete)===null||A===void 0||A.call(e)}_subscribe(e){var A,i;return(i=(A=this.source)===null||A===void 0?void 0:A.subscribe(e))!==null&&i!==void 0?i:Y7}};var li=class extends HA{constructor(e){super(),this._value=e}get value(){return this.getValue()}_subscribe(e){let A=super._subscribe(e);return!A.closed&&e.next(this._value),A}getValue(){let{hasError:e,thrownError:A,_value:i}=this;if(e)throw A;return this._throwIfClosed(),i}next(e){super.next(this._value=e)}};var Jh={now(){return(Jh.delegate||Date).now()},delegate:void 0};var qc=class extends HA{constructor(e=1/0,A=1/0,i=Jh){super(),this._bufferSize=e,this._windowTime=A,this._timestampProvider=i,this._buffer=[],this._infiniteTimeWindow=!0,this._infiniteTimeWindow=A===1/0,this._bufferSize=Math.max(1,e),this._windowTime=Math.max(1,A)}next(e){let{isStopped:A,_buffer:i,_infiniteTimeWindow:n,_timestampProvider:o,_windowTime:r}=this;A||(i.push(e),!n&&i.push(o.now()+r)),this._trimBuffer(),super.next(e)}_subscribe(e){this._throwIfClosed(),this._trimBuffer();let A=this._innerSubscribe(e),{_infiniteTimeWindow:i,_buffer:n}=this,o=n.slice();for(let r=0;r<o.length&&!e.closed;r+=i?1:2)e.next(o[r]);return this._checkFinalizedStatuses(e),A}_trimBuffer(){let{_bufferSize:e,_timestampProvider:A,_buffer:i,_infiniteTimeWindow:n}=this,o=(n?1:2)*e;if(e<1/0&&o<i.length&&i.splice(0,i.length-o),!n){let r=A.now(),s=0;for(let a=1;a<i.length&&i[a]<=r;a+=2)s=a;s&&i.splice(0,s+1)}}};var zf=class extends _t{constructor(e,A){super()}schedule(e,A=0){return this}};var Th={setInterval(t,e,...A){let{delegate:i}=Th;return i?.setInterval?i.setInterval(t,e,...A):setInterval(t,e,...A)},clearInterval(t){let{delegate:e}=Th;return(e?.clearInterval||clearInterval)(t)},delegate:void 0};var Hf=class extends zf{constructor(e,A){super(e,A),this.scheduler=e,this.work=A,this.pending=!1}schedule(e,A=0){var i;if(this.closed)return this;this.state=e;let n=this.id,o=this.scheduler;return n!=null&&(this.id=this.recycleAsyncId(o,n,A)),this.pending=!0,this.delay=A,this.id=(i=this.id)!==null&&i!==void 0?i:this.requestAsyncId(o,this.id,A),this}requestAsyncId(e,A,i=0){return Th.setInterval(e.flush.bind(e,this),i)}recycleAsyncId(e,A,i=0){if(i!=null&&this.delay===i&&this.pending===!1)return A;A!=null&&Th.clearInterval(A)}execute(e,A){if(this.closed)return new Error("executing a cancelled action");this.pending=!1;let i=this._execute(e,A);if(i)return i;this.pending===!1&&this.id!=null&&(this.id=this.recycleAsyncId(this.scheduler,this.id,null))}_execute(e,A){let i=!1,n;try{this.work(e)}catch(o){i=!0,n=o||new Error("Scheduled action threw falsy error")}if(i)return this.unsubscribe(),n}unsubscribe(){if(!this.closed){let{id:e,scheduler:A}=this,{actions:i}=A;this.work=this.state=this.scheduler=null,this.pending=!1,W1(i,this),e!=null&&(this.id=this.recycleAsyncId(A,e,null)),this.delay=null,super.unsubscribe()}}};var ld=class t{constructor(e,A=t.now){this.schedulerActionCtor=e,this.now=A}schedule(e,A=0,i){return new this.schedulerActionCtor(this,e).schedule(i,A)}};ld.now=Jh.now;var Of=class extends ld{constructor(e,A=ld.now){super(e,A),this.actions=[],this._active=!1}flush(e){let{actions:A}=this;if(this._active){A.push(e);return}let i;this._active=!0;do if(i=e.execute(e.state,e.delay))break;while(e=A.shift());if(this._active=!1,i){for(;e=A.shift();)e.unsubscribe();throw i}}};var zh=new Of(Hf),HU=zh;var Ar=new Ze(t=>t.complete());function Pf(t){return t&&Lt(t.schedule)}function V7(t){return t[t.length-1]}function jf(t){return Lt(V7(t))?t.pop():void 0}function Kl(t){return Pf(V7(t))?t.pop():void 0}function OU(t,e){return typeof V7(t)=="number"?t.pop():e}function jU(t,e,A,i){function n(o){return o instanceof A?o:new A(function(r){r(o)})}return new(A||(A=Promise))(function(o,r){function s(l){try{c(i.next(l))}catch(I){r(I)}}function a(l){try{c(i.throw(l))}catch(I){r(I)}}function c(l){l.done?o(l.value):n(l.value).then(s,a)}c((i=i.apply(t,e||[])).next())})}function PU(t){var e=typeof Symbol=="function"&&Symbol.iterator,A=e&&t[e],i=0;if(A)return A.call(t);if(t&&typeof t.length=="number")return{next:function(){return t&&i>=t.length&&(t=void 0),{value:t&&t[i++],done:!t}}};throw new TypeError(e?"Object is not iterable.":"Symbol.iterator is not defined.")}function $1(t){return this instanceof $1?(this.v=t,this):new $1(t)}function qU(t,e,A){if(!Symbol.asyncIterator)throw new TypeError("Symbol.asyncIterator is not defined.");var i=A.apply(t,e||[]),n,o=[];return n=Object.create((typeof AsyncIterator=="function"?AsyncIterator:Object).prototype),s("next"),s("throw"),s("return",r),n[Symbol.asyncIterator]=function(){return this},n;function r(d){return function(B){return Promise.resolve(B).then(d,I)}}function s(d,B){i[d]&&(n[d]=function(E){return new Promise(function(Q,u){o.push([d,E,Q,u])>1||a(d,E)})},B&&(n[d]=B(n[d])))}function a(d,B){try{c(i[d](B))}catch(E){C(o[0][3],E)}}function c(d){d.value instanceof $1?Promise.resolve(d.value.v).then(l,I):C(o[0][2],d)}function l(d){a("next",d)}function I(d){a("throw",d)}function C(d,B){d(B),o.shift(),o.length&&a(o[0][0],o[0][1])}}function VU(t){if(!Symbol.asyncIterator)throw new TypeError("Symbol.asyncIterator is not defined.");var e=t[Symbol.asyncIterator],A;return e?e.call(t):(t=typeof PU=="function"?PU(t):t[Symbol.iterator](),A={},i("next"),i("throw"),i("return"),A[Symbol.asyncIterator]=function(){return this},A);function i(o){A[o]=t[o]&&function(r){return new Promise(function(s,a){r=t[o](r),n(s,a,r.done,r.value)})}}function n(o,r,s,a){Promise.resolve(a).then(function(c){o({value:c,done:s})},r)}}var gd=t=>t&&typeof t.length=="number"&&typeof t!="function";function qf(t){return Lt(t?.then)}function Vf(t){return Lt(t[sd])}function Zf(t){return Symbol.asyncIterator&&Lt(t?.[Symbol.asyncIterator])}function Wf(t){return new TypeError(`You provided ${t!==null&&typeof t=="object"?"an invalid object":`'${t}'`} where a stream was expected. You can provide an Observable, Promise, ReadableStream, Array, AsyncIterable, or Iterable.`)}function wgA(){return typeof Symbol!="function"||!Symbol.iterator?"@@iterator":Symbol.iterator}var Xf=wgA();function $f(t){return Lt(t?.[Xf])}function Am(t){return qU(this,arguments,function*(){let A=t.getReader();try{for(;;){let{value:i,done:n}=yield $1(A.read());if(n)return yield $1(void 0);yield yield $1(i)}}finally{A.releaseLock()}})}function em(t){return Lt(t?.getReader)}function Gn(t){if(t instanceof Ze)return t;if(t!=null){if(Vf(t))return DgA(t);if(gd(t))return ygA(t);if(qf(t))return vgA(t);if(Zf(t))return ZU(t);if($f(t))return bgA(t);if(em(t))return MgA(t)}throw Wf(t)}function DgA(t){return new Ze(e=>{let A=t[sd]();if(Lt(A.subscribe))return A.subscribe(e);throw new TypeError("Provided object does not correctly implement Symbol.observable")})}function ygA(t){return new Ze(e=>{for(let A=0;A<t.length&&!e.closed;A++)e.next(t[A]);e.complete()})}function vgA(t){return new Ze(e=>{t.then(A=>{e.closed||(e.next(A),e.complete())},A=>e.error(A)).then(null,Jf)})}function bgA(t){return new Ze(e=>{for(let A of t)if(e.next(A),e.closed)return;e.complete()})}function ZU(t){return new Ze(e=>{kgA(t,e).catch(A=>e.error(A))})}function MgA(t){return ZU(Am(t))}function kgA(t,e){var A,i,n,o;return jU(this,void 0,void 0,function*(){try{for(A=VU(t);i=yield A.next(),!i.done;){let r=i.value;if(e.next(r),e.closed)return}}catch(r){n={error:r}}finally{try{i&&!i.done&&(o=A.return)&&(yield o.call(A))}finally{if(n)throw n.error}}e.complete()})}function qs(t,e,A,i=0,n=!1){let o=e.schedule(function(){A(),n?t.add(this.schedule(null,i)):this.unsubscribe()},i);if(t.add(o),!n)return o}function tm(t,e=0){return qt((A,i)=>{A.subscribe(zt(i,n=>qs(i,t,()=>i.next(n),e),()=>qs(i,t,()=>i.complete(),e),n=>qs(i,t,()=>i.error(n),e)))})}function im(t,e=0){return qt((A,i)=>{i.add(t.schedule(()=>A.subscribe(i),e))})}function WU(t,e){return Gn(t).pipe(im(e),tm(e))}function XU(t,e){return Gn(t).pipe(im(e),tm(e))}function $U(t,e){return new Ze(A=>{let i=0;return e.schedule(function(){i===t.length?A.complete():(A.next(t[i++]),A.closed||this.schedule())})})}function AK(t,e){return new Ze(A=>{let i;return qs(A,e,()=>{i=t[Xf](),qs(A,e,()=>{let n,o;try{({value:n,done:o}=i.next())}catch(r){A.error(r);return}o?A.complete():A.next(n)},0,!0)}),()=>Lt(i?.return)&&i.return()})}function nm(t,e){if(!t)throw new Error("Iterable cannot be null");return new Ze(A=>{qs(A,e,()=>{let i=t[Symbol.asyncIterator]();qs(A,e,()=>{i.next().then(n=>{n.done?A.complete():A.next(n.value)})},0,!0)})})}function eK(t,e){return nm(Am(t),e)}function tK(t,e){if(t!=null){if(Vf(t))return WU(t,e);if(gd(t))return $U(t,e);if(qf(t))return XU(t,e);if(Zf(t))return nm(t,e);if($f(t))return AK(t,e);if(em(t))return eK(t,e)}throw Wf(t)}function On(t,e){return e?tK(t,e):Gn(t)}function ve(...t){let e=Kl(t);return On(t,e)}function s2(t,e){let A=Lt(t)?t:()=>t,i=n=>n.error(A());return new Ze(e?n=>e.schedule(i,0,n):i)}function a2(t){return!!t&&(t instanceof Ze||Lt(t.lift)&&Lt(t.subscribe))}var Xg=nd(t=>function(){t(this),this.name="EmptyError",this.message="no elements in sequence"});function iK(t){return t instanceof Date&&!isNaN(t)}function Je(t,e){return qt((A,i)=>{let n=0;A.subscribe(zt(i,o=>{i.next(t.call(e,o,n++))}))})}var{isArray:SgA}=Array;function RgA(t,e){return SgA(e)?t(...e):t(e)}function Id(t){return Je(e=>RgA(t,e))}var{isArray:LgA}=Array,{getPrototypeOf:xgA,prototype:FgA,keys:NgA}=Object;function om(t){if(t.length===1){let e=t[0];if(LgA(e))return{args:e,keys:null};if(_gA(e)){let A=NgA(e);return{args:A.map(i=>e[i]),keys:A}}}return{args:t,keys:null}}function _gA(t){return t&&typeof t=="object"&&xgA(t)===FgA}function rm(t,e){return t.reduce((A,i,n)=>(A[i]=e[n],A),{})}function Ls(...t){let e=Kl(t),A=jf(t),{args:i,keys:n}=om(t);if(i.length===0)return On([],e);let o=new Ze(GgA(i,e,n?r=>rm(n,r):Rs));return A?o.pipe(Id(A)):o}function GgA(t,e,A=Rs){return i=>{nK(e,()=>{let{length:n}=t,o=new Array(n),r=n,s=n;for(let a=0;a<n;a++)nK(e,()=>{let c=On(t[a],e),l=!1;c.subscribe(zt(i,I=>{o[a]=I,l||(l=!0,s--),s||i.next(A(o.slice()))},()=>{--r||i.complete()}))},i)},i)}}function nK(t,e,A){t?qs(A,t,e):e()}function oK(t,e,A,i,n,o,r,s){let a=[],c=0,l=0,I=!1,C=()=>{I&&!a.length&&!c&&e.complete()},d=E=>c<i?B(E):a.push(E),B=E=>{o&&e.next(E),c++;let Q=!1;Gn(A(E,l++)).subscribe(zt(e,u=>{n?.(u),o?d(u):e.next(u)},()=>{Q=!0},void 0,()=>{if(Q)try{for(c--;a.length&&c<i;){let u=a.shift();r?qs(e,r,()=>B(u)):B(u)}C()}catch(u){e.error(u)}}))};return t.subscribe(zt(e,d,()=>{I=!0,C()})),()=>{s?.()}}function qo(t,e,A=1/0){return Lt(e)?qo((i,n)=>Je((o,r)=>e(i,o,n,r))(Gn(t(i,n))),A):(typeof e=="number"&&(A=e),qt((i,n)=>oK(i,n,t,A)))}function c2(t=1/0){return qo(Rs,t)}function rK(){return c2(1)}function l2(...t){return rK()(On(t,Kl(t)))}function Yl(t){return new Ze(e=>{Gn(t()).subscribe(e)})}function Hh(...t){let e=jf(t),{args:A,keys:i}=om(t),n=new Ze(o=>{let{length:r}=A;if(!r){o.complete();return}let s=new Array(r),a=r,c=r;for(let l=0;l<r;l++){let I=!1;Gn(A[l]).subscribe(zt(o,C=>{I||(I=!0,c--),s[l]=C},()=>a--,void 0,()=>{(!a||!I)&&(c||o.next(i?rm(i,s):s),o.complete())}))}});return e?n.pipe(Id(e)):n}var UgA=["addListener","removeListener"],KgA=["addEventListener","removeEventListener"],YgA=["on","off"];function Oh(t,e,A,i){if(Lt(A)&&(i=A,A=void 0),i)return Oh(t,e,A).pipe(Id(i));let[n,o]=zgA(t)?KgA.map(r=>s=>t[r](e,s,A)):JgA(t)?UgA.map(sK(t,e)):TgA(t)?YgA.map(sK(t,e)):[];if(!n&&gd(t))return qo(r=>Oh(r,e,A))(Gn(t));if(!n)throw new TypeError("Invalid event target");return new Ze(r=>{let s=(...a)=>r.next(1<a.length?a:a[0]);return n(s),()=>o(s)})}function sK(t,e){return A=>i=>t[A](e,i)}function JgA(t){return Lt(t.addListener)&&Lt(t.removeListener)}function TgA(t){return Lt(t.on)&&Lt(t.off)}function zgA(t){return Lt(t.addEventListener)&&Lt(t.removeEventListener)}function AI(t=0,e,A=HU){let i=-1;return e!=null&&(Pf(e)?A=e:i=e),new Ze(n=>{let o=iK(t)?+t-A.now():t;o<0&&(o=0);let r=0;return A.schedule(function(){n.closed||(n.next(r++),0<=i?this.schedule(void 0,i):n.complete())},o)})}function ho(...t){let e=Kl(t),A=OU(t,1/0),i=t;return i.length?i.length===1?Gn(i[0]):c2(A)(On(i,e)):Ar}function pt(t,e){return qt((A,i)=>{let n=0;A.subscribe(zt(i,o=>t.call(e,o,n++)&&i.next(o)))})}function aK(t){return qt((e,A)=>{let i=!1,n=null,o=null,r=!1,s=()=>{if(o?.unsubscribe(),o=null,i){i=!1;let c=n;n=null,A.next(c)}r&&A.complete()},a=()=>{o=null,r&&A.complete()};e.subscribe(zt(A,c=>{i=!0,n=c,o||Gn(t(c)).subscribe(o=zt(A,s,a))},()=>{r=!0,(!i||!o||o.closed)&&A.complete()}))})}function Cd(t,e=zh){return aK(()=>AI(t,e))}function dr(t){return qt((e,A)=>{let i=null,n=!1,o;i=e.subscribe(zt(A,void 0,void 0,r=>{o=Gn(t(r,dr(t)(e))),i?(i.unsubscribe(),i=null,o.subscribe(A)):n=!0})),n&&(i.unsubscribe(),i=null,o.subscribe(A))})}function cK(t,e,A,i,n){return(o,r)=>{let s=A,a=e,c=0;o.subscribe(zt(r,l=>{let I=c++;a=s?t(a,l,I):(s=!0,l),i&&r.next(a)},n&&(()=>{s&&r.next(a),r.complete()})))}}function Jl(t,e){return Lt(e)?qo(t,e,1):qo(t,1)}function Vc(t,e=zh){return qt((A,i)=>{let n=null,o=null,r=null,s=()=>{if(n){n.unsubscribe(),n=null;let c=o;o=null,i.next(c)}};function a(){let c=r+t,l=e.now();if(l<c){n=this.schedule(void 0,c-l),i.add(n);return}s()}A.subscribe(zt(i,c=>{o=c,r=e.now(),n||(n=e.schedule(a,t),i.add(n))},()=>{s(),i.complete()},void 0,()=>{o=n=null}))})}function g2(t){return qt((e,A)=>{let i=!1;e.subscribe(zt(A,n=>{i=!0,A.next(n)},()=>{i||A.next(t),A.complete()}))})}function Pn(t){return t<=0?()=>Ar:qt((e,A)=>{let i=0;e.subscribe(zt(A,n=>{++i<=t&&(A.next(n),t<=i&&A.complete())}))})}function dd(t){return Je(()=>t)}function Zc(t,e=Rs){return t=t??HgA,qt((A,i)=>{let n,o=!0;A.subscribe(zt(i,r=>{let s=e(r);(o||!t(n,s))&&(o=!1,n=s,i.next(r))}))})}function HgA(t,e){return t===e}function sm(t=OgA){return qt((e,A)=>{let i=!1;e.subscribe(zt(A,n=>{i=!0,A.next(n)},()=>i?A.complete():A.error(t())))})}function OgA(){return new Xg}function Tl(t){return qt((e,A)=>{try{e.subscribe(A)}finally{A.add(t)}})}function zl(t,e){let A=arguments.length>=2;return i=>i.pipe(t?pt((n,o)=>t(n,o,i)):Rs,Pn(1),A?g2(e):sm(()=>new Xg))}function Bd(t){return t<=0?()=>Ar:qt((e,A)=>{let i=[];e.subscribe(zt(A,n=>{i.push(n),t<i.length&&i.shift()},()=>{for(let n of i)A.next(n);A.complete()},void 0,()=>{i=null}))})}function Z7(t,e){let A=arguments.length>=2;return i=>i.pipe(t?pt((n,o)=>t(n,o,i)):Rs,Bd(1),A?g2(e):sm(()=>new Xg))}function am(){return qt((t,e)=>{let A,i=!1;t.subscribe(zt(e,n=>{let o=A;A=n,i&&e.next([o,n]),i=!0}))})}function W7(t,e){return qt(cK(t,e,arguments.length>=2,!0))}function Ph(t={}){let{connector:e=()=>new HA,resetOnError:A=!0,resetOnComplete:i=!0,resetOnRefCountZero:n=!0}=t;return o=>{let r,s,a,c=0,l=!1,I=!1,C=()=>{s?.unsubscribe(),s=void 0},d=()=>{C(),r=a=void 0,l=I=!1},B=()=>{let E=r;d(),E?.unsubscribe()};return qt((E,Q)=>{c++,!I&&!l&&C();let u=a=a??e();Q.add(()=>{c--,c===0&&!I&&!l&&(s=X7(B,n))}),u.subscribe(Q),!r&&c>0&&(r=new Wg({next:v=>u.next(v),error:v=>{I=!0,C(),s=X7(d,A,v),u.error(v)},complete:()=>{l=!0,C(),s=X7(d,i),u.complete()}}),Gn(E).subscribe(r))})(o)}}function X7(t,e,...A){if(e===!0){t();return}if(e===!1)return;let i=new Wg({next:()=>{i.unsubscribe(),t()}});return Gn(e(...A)).subscribe(i)}function $g(t,e,A){let i,n=!1;return t&&typeof t=="object"?{bufferSize:i=1/0,windowTime:e=1/0,refCount:n=!1,scheduler:A}=t:i=t??1/0,Ph({connector:()=>new qc(i,e,A),resetOnError:!0,resetOnComplete:!1,resetOnRefCountZero:n})}function eI(t){return pt((e,A)=>t<=A)}function Qo(...t){let e=Kl(t);return qt((A,i)=>{(e?l2(t,A,e):l2(t,A)).subscribe(i)})}function no(t,e){return qt((A,i)=>{let n=null,o=0,r=!1,s=()=>r&&!n&&i.complete();A.subscribe(zt(i,a=>{n?.unsubscribe();let c=0,l=o++;Gn(t(a,l)).subscribe(n=zt(i,I=>i.next(e?e(a,I,l,c++):I),()=>{n=null,s()}))},()=>{r=!0,s()}))})}function wt(t){return qt((e,A)=>{Gn(t).subscribe(zt(A,()=>A.complete(),Yh)),!A.closed&&e.subscribe(A)})}function $7(t,e=!1){return qt((A,i)=>{let n=0;A.subscribe(zt(i,o=>{let r=t(o,n++);(r||e)&&i.next(o),!r&&i.complete()}))})}function oo(t,e,A){let i=Lt(t)||e||A?{next:t,error:e,complete:A}:t;return i?qt((n,o)=>{var r;(r=i.subscribe)===null||r===void 0||r.call(i);let s=!0;n.subscribe(zt(o,a=>{var c;(c=i.next)===null||c===void 0||c.call(i,a),o.next(a)},()=>{var a;s=!1,(a=i.complete)===null||a===void 0||a.call(i),o.complete()},a=>{var c;s=!1,(c=i.error)===null||c===void 0||c.call(i,a),o.error(a)},()=>{var a,c;s&&((a=i.unsubscribe)===null||a===void 0||a.call(i)),(c=i.finalize)===null||c===void 0||c.call(i)}))}):Rs}var tY="https://angular.dev/best-practices/security#preventing-cross-site-scripting-xss",ZA=class extends Error{code;constructor(e,A){super(w9(e,A)),this.code=e}};function PgA(t){return`NG0${Math.abs(t)}`}function w9(t,e){return`${PgA(t)}${e?": "+e:""}`}var iY=Symbol("InputSignalNode#UNSET"),jgA=Ne(nA({},Gf),{transformFn:void 0,applyValueToInputSignal(t,e){Uh(t,e)}});function nY(t,e){let A=Object.create(jgA);A.value=t,A.transformFn=e?.transform;function i(){if(Nh(A),A.value===iY){let n=null;throw new ZA(-950,n)}return A.value}return i[js]=A,i}function oQ(t){return{toString:t}.toString()}var cm="__parameters__";function qgA(t){return function(...A){if(t){let i=t(...A);for(let n in i)this[n]=i[n]}}}function oY(t,e,A){return oQ(()=>{let i=qgA(e);function n(...o){if(this instanceof n)return i.apply(this,o),this;let r=new n(...o);return s.annotation=r,s;function s(a,c,l){let I=a.hasOwnProperty(cm)?a[cm]:Object.defineProperty(a,cm,{value:[]})[cm];for(;I.length<=l;)I.push(null);return(I[l]=I[l]||[]).push(r),a}}return n.prototype.ngMetadataName=t,n.annotationCls=n,n})}var Ws=globalThis;function ro(t){for(let e in t)if(t[e]===ro)return e;throw Error("Could not find renamed property on target object.")}function VgA(t,e){for(let A in e)e.hasOwnProperty(A)&&!t.hasOwnProperty(A)&&(t[A]=e[A])}function Zs(t){if(typeof t=="string")return t;if(Array.isArray(t))return`[${t.map(Zs).join(", ")}]`;if(t==null)return""+t;let e=t.overriddenName||t.name;if(e)return`${e}`;let A=t.toString();if(A==null)return""+A;let i=A.indexOf(`
`);return i>=0?A.slice(0,i):A}function dv(t,e){return t?e?`${t} ${e}`:t:e||""}var ZgA=ro({__forward_ref__:ro});function nr(t){return t.__forward_ref__=nr,t.toString=function(){return Zs(this())},t}function Wr(t){return rY(t)?t():t}function rY(t){return typeof t=="function"&&t.hasOwnProperty(ZgA)&&t.__forward_ref__===nr}function SA(t){return{token:t.token,providedIn:t.providedIn||null,factory:t.factory,value:void 0}}function le(t){return{providers:t.providers||[],imports:t.imports||[]}}function Zm(t){return lK(t,aY)||lK(t,cY)}function sY(t){return Zm(t)!==null}function lK(t,e){return t.hasOwnProperty(e)?t[e]:null}function WgA(t){let e=t&&(t[aY]||t[cY]);return e||null}function gK(t){return t&&(t.hasOwnProperty(IK)||t.hasOwnProperty(XgA))?t[IK]:null}var aY=ro({\u0275prov:ro}),IK=ro({\u0275inj:ro}),cY=ro({ngInjectableDef:ro}),XgA=ro({ngInjectorDef:ro}),BA=class{_desc;ngMetadataName="InjectionToken";\u0275prov;constructor(e,A){this._desc=e,this.\u0275prov=void 0,typeof A=="number"?this.__NG_ELEMENT_ID__=A:A!==void 0&&(this.\u0275prov=SA({token:this,providedIn:A.providedIn||"root",factory:A.factory}))}get multi(){return this}toString(){return`InjectionToken ${this._desc}`}};function lY(t){return t&&!!t.\u0275providers}var $gA=ro({\u0275cmp:ro}),A0A=ro({\u0275dir:ro}),e0A=ro({\u0275pipe:ro}),t0A=ro({\u0275mod:ro}),fm=ro({\u0275fac:ro}),Zh=ro({__NG_ELEMENT_ID__:ro}),CK=ro({__NG_ENV_ID__:ro});function nI(t){return typeof t=="string"?t:t==null?"":String(t)}function i0A(t){return typeof t=="function"?t.name||t.toString():typeof t=="object"&&t!=null&&typeof t.type=="function"?t.type.name||t.type.toString():nI(t)}function gY(t,e){throw new ZA(-200,t)}function D9(t,e){throw new ZA(-201,!1)}var _i=function(t){return t[t.Default=0]="Default",t[t.Host=1]="Host",t[t.Self=2]="Self",t[t.SkipSelf=4]="SkipSelf",t[t.Optional=8]="Optional",t}(_i||{}),Bv;function IY(){return Bv}function Vs(t){let e=Bv;return Bv=t,e}function CY(t,e,A){let i=Zm(t);if(i&&i.providedIn=="root")return i.value===void 0?i.value=i.factory():i.value;if(A&_i.Optional)return null;if(e!==void 0)return e;D9(t,"Injector")}var n0A={},tI=n0A,Ev="__NG_DI_FLAG__",mm=class{injector;constructor(e){this.injector=e}retrieve(e,A){let i=A;return this.injector.get(e,i.optional?Uf:tI,i)}},pm="ngTempTokenPath",o0A="ngTokenPath",r0A=/\n/gm,s0A="\u0275",dK="__source";function a0A(t,e=_i.Default){if(Kh()===void 0)throw new ZA(-203,!1);if(Kh()===null)return CY(t,void 0,e);{let A=Kh(),i;return A instanceof mm?i=A.injector:i=A,i.get(t,e&_i.Optional?null:void 0,e)}}function he(t,e=_i.Default){return(IY()||a0A)(Wr(t),e)}function m(t,e=_i.Default){return he(t,Wm(e))}function Wm(t){return typeof t>"u"||typeof t=="number"?t:0|(t.optional&&8)|(t.host&&1)|(t.self&&2)|(t.skipSelf&&4)}function hv(t){let e=[];for(let A=0;A<t.length;A++){let i=Wr(t[A]);if(Array.isArray(i)){if(i.length===0)throw new ZA(900,!1);let n,o=_i.Default;for(let r=0;r<i.length;r++){let s=i[r],a=c0A(s);typeof a=="number"?a===-1?n=s.token:o|=a:n=s}e.push(he(n,o))}else e.push(he(i))}return e}function dY(t,e){return t[Ev]=e,t.prototype[Ev]=e,t}function c0A(t){return t[Ev]}function l0A(t,e,A,i){let n=t[pm];throw e[dK]&&n.unshift(e[dK]),t.message=g0A(`
`+t.message,n,A,i),t[o0A]=n,t[pm]=null,t}function g0A(t,e,A,i=null){t=t&&t.charAt(0)===`
`&&t.charAt(1)==s0A?t.slice(2):t;let n=Zs(e);if(Array.isArray(e))n=e.map(Zs).join(" -> ");else if(typeof e=="object"){let o=[];for(let r in e)if(e.hasOwnProperty(r)){let s=e[r];o.push(r+":"+(typeof s=="string"?JSON.stringify(s):Zs(s)))}n=`{${o.join(", ")}}`}return`${A}${i?"("+i+")":""}[${n}]: ${t.replace(r0A,`
  `)}`}var hI=dY(oY("Optional"),8);var rQ=dY(oY("SkipSelf"),4);function oI(t,e){let A=t.hasOwnProperty(fm);return A?t[fm]:null}function I0A(t,e,A){if(t.length!==e.length)return!1;for(let i=0;i<t.length;i++){let n=t[i],o=e[i];if(A&&(n=A(n),o=A(o)),o!==n)return!1}return!0}function C0A(t){return t.flat(Number.POSITIVE_INFINITY)}function y9(t,e){t.forEach(A=>Array.isArray(A)?y9(A,e):e(A))}function BY(t,e,A){e>=t.length?t.push(A):t.splice(e,0,A)}function wm(t,e){return e>=t.length-1?t.pop():t.splice(e,1)[0]}function d0A(t,e){let A=[];for(let i=0;i<t;i++)A.push(e);return A}function B0A(t,e,A,i){let n=t.length;if(n==e)t.push(A,i);else if(n===1)t.push(i,t[0]),t[0]=A;else{for(n--,t.push(t[n-1],t[n]);n>e;){let o=n-2;t[n]=t[o],n--}t[e]=A,t[e+1]=i}}function Xm(t,e,A){let i=sQ(t,e);return i>=0?t[i|1]=A:(i=~i,B0A(t,i,e,A)),i}function Av(t,e){let A=sQ(t,e);if(A>=0)return t[A|1]}function sQ(t,e){return E0A(t,e,1)}function E0A(t,e,A){let i=0,n=t.length>>A;for(;n!==i;){let o=i+(n-i>>1),r=t[o<<A];if(e===r)return o<<A;r>e?n=o:i=o+1}return~(n<<A)}var Ol={},xs=[],pd=new BA(""),EY=new BA("",-1),hY=new BA(""),Dm=class{get(e,A=tI){if(A===tI){let i=new Error(`NullInjectorError: No provider for ${Zs(e)}!`);throw i.name="NullInjectorError",i}return A}};function QY(t,e){let A=t[t0A]||null;if(!A&&e===!0)throw new Error(`Type ${Zs(t)} does not have '\u0275mod' property.`);return A}function d2(t){return t[$gA]||null}function uY(t){return t[A0A]||null}function h0A(t){return t[e0A]||null}function aQ(t){return{\u0275providers:t}}function Q0A(...t){return{\u0275providers:fY(!0,t),\u0275fromNgModule:!0}}function fY(t,...e){let A=[],i=new Set,n,o=r=>{A.push(r)};return y9(e,r=>{let s=r;Qv(s,o,[],i)&&(n||=[],n.push(s))}),n!==void 0&&mY(n,o),A}function mY(t,e){for(let A=0;A<t.length;A++){let{ngModule:i,providers:n}=t[A];v9(n,o=>{e(o,i)})}}function Qv(t,e,A,i){if(t=Wr(t),!t)return!1;let n=null,o=gK(t),r=!o&&d2(t);if(!o&&!r){let a=t.ngModule;if(o=gK(a),o)n=a;else return!1}else{if(r&&!r.standalone)return!1;n=t}let s=i.has(n);if(r){if(s)return!1;if(i.add(n),r.dependencies){let a=typeof r.dependencies=="function"?r.dependencies():r.dependencies;for(let c of a)Qv(c,e,A,i)}}else if(o){if(o.imports!=null&&!s){i.add(n);let c;try{y9(o.imports,l=>{Qv(l,e,A,i)&&(c||=[],c.push(l))})}finally{}c!==void 0&&mY(c,e)}if(!s){let c=oI(n)||(()=>new n);e({provide:n,useFactory:c,deps:xs},n),e({provide:hY,useValue:n,multi:!0},n),e({provide:pd,useValue:()=>he(n),multi:!0},n)}let a=o.providers;if(a!=null&&!s){let c=t;v9(a,l=>{e(l,c)})}}else return!1;return n!==t&&t.providers!==void 0}function v9(t,e){for(let A of t)lY(A)&&(A=A.\u0275providers),Array.isArray(A)?v9(A,e):e(A)}var u0A=ro({provide:String,useValue:ro});function pY(t){return t!==null&&typeof t=="object"&&u0A in t}function f0A(t){return!!(t&&t.useExisting)}function m0A(t){return!!(t&&t.useFactory)}function wd(t){return typeof t=="function"}function p0A(t){return!!t.useClass}var $m=new BA(""),Bm={},BK={},ev;function Ap(){return ev===void 0&&(ev=new Dm),ev}var Br=class{},Xh=class extends Br{parent;source;scopes;records=new Map;_ngOnDestroyHooks=new Set;_onDestroyHooks=[];get destroyed(){return this._destroyed}_destroyed=!1;injectorDefTypes;constructor(e,A,i,n){super(),this.parent=A,this.source=i,this.scopes=n,fv(e,r=>this.processProvider(r)),this.records.set(EY,Ed(void 0,this)),n.has("environment")&&this.records.set(Br,Ed(void 0,this));let o=this.records.get($m);o!=null&&typeof o.value=="string"&&this.scopes.add(o.value),this.injectorDefTypes=new Set(this.get(hY,xs,_i.Self))}retrieve(e,A){let i=A;return this.get(e,i.optional?Uf:tI,i)}destroy(){qh(this),this._destroyed=!0;let e=vi(null);try{for(let i of this._ngOnDestroyHooks)i.ngOnDestroy();let A=this._onDestroyHooks;this._onDestroyHooks=[];for(let i of A)i()}finally{this.records.clear(),this._ngOnDestroyHooks.clear(),this.injectorDefTypes.clear(),vi(e)}}onDestroy(e){return qh(this),this._onDestroyHooks.push(e),()=>this.removeOnDestroy(e)}runInContext(e){qh(this);let A=Vg(this),i=Vs(void 0),n;try{return e()}finally{Vg(A),Vs(i)}}get(e,A=tI,i=_i.Default){if(qh(this),e.hasOwnProperty(CK))return e[CK](this);i=Wm(i);let n,o=Vg(this),r=Vs(void 0);try{if(!(i&_i.SkipSelf)){let a=this.records.get(e);if(a===void 0){let c=b0A(e)&&Zm(e);c&&this.injectableDefInScope(c)?a=Ed(uv(e),Bm):a=null,this.records.set(e,a)}if(a!=null)return this.hydrate(e,a)}let s=i&_i.Self?Ap():this.parent;return A=i&_i.Optional&&A===tI?null:A,s.get(e,A)}catch(s){if(s.name==="NullInjectorError"){if((s[pm]=s[pm]||[]).unshift(Zs(e)),o)throw s;return l0A(s,e,"R3InjectorError",this.source)}else throw s}finally{Vs(r),Vg(o)}}resolveInjectorInitializers(){let e=vi(null),A=Vg(this),i=Vs(void 0),n;try{let o=this.get(pd,xs,_i.Self);for(let r of o)r()}finally{Vg(A),Vs(i),vi(e)}}toString(){let e=[],A=this.records;for(let i of A.keys())e.push(Zs(i));return`R3Injector[${e.join(", ")}]`}processProvider(e){e=Wr(e);let A=wd(e)?e:Wr(e&&e.provide),i=D0A(e);if(!wd(e)&&e.multi===!0){let n=this.records.get(A);n||(n=Ed(void 0,Bm,!0),n.factory=()=>hv(n.multi),this.records.set(A,n)),A=e,n.multi.push(e)}this.records.set(A,i)}hydrate(e,A){let i=vi(null);try{return A.value===BK?gY(Zs(e)):A.value===Bm&&(A.value=BK,A.value=A.factory()),typeof A.value=="object"&&A.value&&v0A(A.value)&&this._ngOnDestroyHooks.add(A.value),A.value}finally{vi(i)}}injectableDefInScope(e){if(!e.providedIn)return!1;let A=Wr(e.providedIn);return typeof A=="string"?A==="any"||this.scopes.has(A):this.injectorDefTypes.has(A)}removeOnDestroy(e){let A=this._onDestroyHooks.indexOf(e);A!==-1&&this._onDestroyHooks.splice(A,1)}};function uv(t){let e=Zm(t),A=e!==null?e.factory:oI(t);if(A!==null)return A;if(t instanceof BA)throw new ZA(204,!1);if(t instanceof Function)return w0A(t);throw new ZA(204,!1)}function w0A(t){if(t.length>0)throw new ZA(204,!1);let A=WgA(t);return A!==null?()=>A.factory(t):()=>new t}function D0A(t){if(pY(t))return Ed(void 0,t.useValue);{let e=wY(t);return Ed(e,Bm)}}function wY(t,e,A){let i;if(wd(t)){let n=Wr(t);return oI(n)||uv(n)}else if(pY(t))i=()=>Wr(t.useValue);else if(m0A(t))i=()=>t.useFactory(...hv(t.deps||[]));else if(f0A(t))i=()=>he(Wr(t.useExisting));else{let n=Wr(t&&(t.useClass||t.provide));if(y0A(t))i=()=>new n(...hv(t.deps));else return oI(n)||uv(n)}return i}function qh(t){if(t.destroyed)throw new ZA(205,!1)}function Ed(t,e,A=!1){return{factory:t,value:e,multi:A?[]:void 0}}function y0A(t){return!!t.deps}function v0A(t){return t!==null&&typeof t=="object"&&typeof t.ngOnDestroy=="function"}function b0A(t){return typeof t=="function"||typeof t=="object"&&t instanceof BA}function fv(t,e){for(let A of t)Array.isArray(A)?fv(A,e):A&&lY(A)?fv(A.\u0275providers,e):e(A)}function $s(t,e){let A;t instanceof Xh?(qh(t),A=t):A=new mm(t);let i,n=Vg(A),o=Vs(void 0);try{return e()}finally{Vg(n),Vs(o)}}function DY(){return IY()!==void 0||Kh()!=null}function b9(t){if(!DY())throw new ZA(-203,!1)}function M0A(t){let e=Ws.ng;if(e&&e.\u0275compilerFacade)return e.\u0275compilerFacade;throw new Error("JIT compiler unavailable")}function k0A(t){return typeof t=="function"}var Zl=0,gi=1,Vt=2,Cs=3,$c=4,Aa=5,Dd=6,ym=7,vr=8,rI=9,A0=10,Uo=11,$h=12,EK=13,Sd=14,_a=15,sI=16,hd=17,e0=18,ep=19,yY=20,I2=21,tv=22,aI=23,Bc=24,fd=25,br=26,M9=1;var cI=7,vm=8,yd=9,Is=10;function C2(t){return Array.isArray(t)&&typeof t[M9]=="object"}function n0(t){return Array.isArray(t)&&t[M9]===!0}function k9(t){return(t.flags&4)!==0}function Rd(t){return t.componentOffset>-1}function tp(t){return(t.flags&1)===1}function Al(t){return!!t.template}function bm(t){return(t[Vt]&512)!==0}function Ld(t){return(t[Vt]&256)===256}var mv=class{previousValue;currentValue;firstChange;constructor(e,A,i){this.previousValue=e,this.currentValue=A,this.firstChange=i}isFirstChange(){return this.firstChange}};function vY(t,e,A,i){e!==null?e.applyValueToInputSignal(e,i):t[A]=i}var Kt=(()=>{let t=()=>bY;return t.ngInherit=!0,t})();function bY(t){return t.type.prototype.ngOnChanges&&(t.setInput=R0A),S0A}function S0A(){let t=kY(this),e=t?.current;if(e){let A=t.previous;if(A===Ol)t.previous=e;else for(let i in e)A[i]=e[i];t.current=null,this.ngOnChanges(e)}}function R0A(t,e,A,i,n){let o=this.declaredInputs[i],r=kY(t)||L0A(t,{previous:Ol,current:null}),s=r.current||(r.current={}),a=r.previous,c=a[o];s[o]=new mv(c&&c.currentValue,A,a===Ol),vY(t,e,n,A)}var MY="__ngSimpleChanges__";function kY(t){return t[MY]||null}function L0A(t,e){return t[MY]=e}var hK=null;var uo=function(t,e=null,A){hK?.(t,e,A)},SY="svg",x0A="math";function Pl(t){for(;Array.isArray(t);)t=t[Zl];return t}function F0A(t){for(;Array.isArray(t);){if(typeof t[M9]=="object")return t;t=t[Zl]}return null}function RY(t,e){return Pl(e[t])}function Wl(t,e){return Pl(e[t.index])}function S9(t,e){return t.data[e]}function R9(t,e){return t[e]}function jl(t,e){let A=e[t];return C2(A)?A:A[Zl]}function N0A(t){return(t[Vt]&4)===4}function L9(t){return(t[Vt]&128)===128}function _0A(t){return n0(t[Cs])}function B2(t,e){return e==null?null:t[e]}function LY(t){t[hd]=0}function xY(t){t[Vt]&1024||(t[Vt]|=1024,L9(t)&&xd(t))}function G0A(t,e){for(;t>0;)e=e[Sd],t--;return e}function ip(t){return!!(t[Vt]&9216||t[Bc]?.dirty)}function pv(t){t[A0].changeDetectionScheduler?.notify(8),t[Vt]&64&&(t[Vt]|=1024),ip(t)&&xd(t)}function xd(t){t[A0].changeDetectionScheduler?.notify(0);let e=lI(t);for(;e!==null&&!(e[Vt]&8192||(e[Vt]|=8192,!L9(e)));)e=lI(e)}function FY(t,e){if(Ld(t))throw new ZA(911,!1);t[I2]===null&&(t[I2]=[]),t[I2].push(e)}function U0A(t,e){if(t[I2]===null)return;let A=t[I2].indexOf(e);A!==-1&&t[I2].splice(A,1)}function lI(t){let e=t[Cs];return n0(e)?e[Cs]:e}function x9(t){return t[ym]??=[]}function F9(t){return t.cleanup??=[]}function K0A(t,e,A,i){let n=x9(e);n.push(A),t.firstCreatePass&&F9(t).push(i,n.length-1)}var di={lFrame:YY(null),bindingsEnabled:!0,skipHydrationRootTNode:null};var wv=!1;function Y0A(){return di.lFrame.elementDepthCount}function J0A(){di.lFrame.elementDepthCount++}function T0A(){di.lFrame.elementDepthCount--}function N9(){return di.bindingsEnabled}function NY(){return di.skipHydrationRootTNode!==null}function z0A(t){return di.skipHydrationRootTNode===t}function H0A(){di.skipHydrationRootTNode=null}function Ut(){return di.lFrame.lView}function yo(){return di.lFrame.tView}function LA(t){return di.lFrame.contextLView=t,t[vr]}function xA(t){return di.lFrame.contextLView=null,t}function Xr(){let t=_Y();for(;t!==null&&t.type===64;)t=t.parent;return t}function _Y(){return di.lFrame.currentTNode}function O0A(){let t=di.lFrame,e=t.currentTNode;return t.isParent?e:e.parent}function QI(t,e){let A=di.lFrame;A.currentTNode=t,A.isParent=e}function _9(){return di.lFrame.isParent}function G9(){di.lFrame.isParent=!1}function P0A(){return di.lFrame.contextLView}function GY(){return wv}function Mm(t){let e=wv;return wv=t,e}function cQ(){let t=di.lFrame,e=t.bindingRootIndex;return e===-1&&(e=t.bindingRootIndex=t.tView.bindingStartIndex),e}function j0A(){return di.lFrame.bindingIndex}function q0A(t){return di.lFrame.bindingIndex=t}function E2(){return di.lFrame.bindingIndex++}function U9(t){let e=di.lFrame,A=e.bindingIndex;return e.bindingIndex=e.bindingIndex+t,A}function V0A(){return di.lFrame.inI18n}function Z0A(t,e){let A=di.lFrame;A.bindingIndex=A.bindingRootIndex=t,Dv(e)}function W0A(){return di.lFrame.currentDirectiveIndex}function Dv(t){di.lFrame.currentDirectiveIndex=t}function K9(t){let e=di.lFrame.currentDirectiveIndex;return e===-1?null:t[e]}function Y9(){return di.lFrame.currentQueryIndex}function np(t){di.lFrame.currentQueryIndex=t}function X0A(t){let e=t[gi];return e.type===2?e.declTNode:e.type===1?t[Aa]:null}function UY(t,e,A){if(A&_i.SkipSelf){let n=e,o=t;for(;n=n.parent,n===null&&!(A&_i.Host);)if(n=X0A(o),n===null||(o=o[Sd],n.type&10))break;if(n===null)return!1;e=n,t=o}let i=di.lFrame=KY();return i.currentTNode=e,i.lView=t,!0}function J9(t){let e=KY(),A=t[gi];di.lFrame=e,e.currentTNode=A.firstChild,e.lView=t,e.tView=A,e.contextLView=t,e.bindingIndex=A.bindingStartIndex,e.inI18n=!1}function KY(){let t=di.lFrame,e=t===null?null:t.child;return e===null?YY(t):e}function YY(t){let e={currentTNode:null,isParent:!0,lView:null,tView:null,selectedIndex:-1,contextLView:null,elementDepthCount:0,currentNamespace:null,currentDirectiveIndex:-1,bindingRootIndex:-1,bindingIndex:-1,currentQueryIndex:0,parent:t,child:null,inI18n:!1};return t!==null&&(t.child=e),e}function JY(){let t=di.lFrame;return di.lFrame=t.parent,t.currentTNode=null,t.lView=null,t}var TY=JY;function T9(){let t=JY();t.isParent=!0,t.tView=null,t.selectedIndex=-1,t.contextLView=null,t.elementDepthCount=0,t.currentDirectiveIndex=-1,t.currentNamespace=null,t.bindingRootIndex=-1,t.bindingIndex=-1,t.currentQueryIndex=0}function $0A(t){return(di.lFrame.contextLView=G0A(t,di.lFrame.contextLView))[vr]}function o0(){return di.lFrame.selectedIndex}function gI(t){di.lFrame.selectedIndex=t}function lQ(){let t=di.lFrame;return S9(t.tView,t.selectedIndex)}function hr(){di.lFrame.currentNamespace=SY}function uI(){A2A()}function A2A(){di.lFrame.currentNamespace=null}function e2A(){return di.lFrame.currentNamespace}var zY=!0;function op(){return zY}function rp(t){zY=t}function t2A(t,e,A){let{ngOnChanges:i,ngOnInit:n,ngDoCheck:o}=e.type.prototype;if(i){let r=bY(e);(A.preOrderHooks??=[]).push(t,r),(A.preOrderCheckHooks??=[]).push(t,r)}n&&(A.preOrderHooks??=[]).push(0-t,n),o&&((A.preOrderHooks??=[]).push(t,o),(A.preOrderCheckHooks??=[]).push(t,o))}function z9(t,e){for(let A=e.directiveStart,i=e.directiveEnd;A<i;A++){let o=t.data[A].type.prototype,{ngAfterContentInit:r,ngAfterContentChecked:s,ngAfterViewInit:a,ngAfterViewChecked:c,ngOnDestroy:l}=o;r&&(t.contentHooks??=[]).push(-A,r),s&&((t.contentHooks??=[]).push(A,s),(t.contentCheckHooks??=[]).push(A,s)),a&&(t.viewHooks??=[]).push(-A,a),c&&((t.viewHooks??=[]).push(A,c),(t.viewCheckHooks??=[]).push(A,c)),l!=null&&(t.destroyHooks??=[]).push(A,l)}}function Em(t,e,A){HY(t,e,3,A)}function hm(t,e,A,i){(t[Vt]&3)===A&&HY(t,e,A,i)}function iv(t,e){let A=t[Vt];(A&3)===e&&(A&=16383,A+=1,t[Vt]=A)}function HY(t,e,A,i){let n=i!==void 0?t[hd]&65535:0,o=i??-1,r=e.length-1,s=0;for(let a=n;a<r;a++)if(typeof e[a+1]=="number"){if(s=e[a],i!=null&&s>=i)break}else e[a]<0&&(t[hd]+=65536),(s<o||o==-1)&&(i2A(t,A,e,a),t[hd]=(t[hd]&4294901760)+a+2),a++}function QK(t,e){uo(4,t,e);let A=vi(null);try{e.call(t)}finally{vi(A),uo(5,t,e)}}function i2A(t,e,A,i){let n=A[i]<0,o=A[i+1],r=n?-A[i]:A[i],s=t[r];n?t[Vt]>>14<t[hd]>>16&&(t[Vt]&3)===e&&(t[Vt]+=16384,QK(s,o)):QK(s,o)}var md=-1,II=class{factory;injectImpl;resolving=!1;canSeeViewProviders;multi;componentProviders;index;providerFactory;constructor(e,A,i){this.factory=e,this.canSeeViewProviders=A,this.injectImpl=i}};function n2A(t){return(t.flags&8)!==0}function o2A(t){return(t.flags&16)!==0}function r2A(t,e,A){let i=0;for(;i<A.length;){let n=A[i];if(typeof n=="number"){if(n!==0)break;i++;let o=A[i++],r=A[i++],s=A[i++];t.setAttribute(e,r,s,o)}else{let o=n,r=A[++i];s2A(o)?t.setProperty(e,o,r):t.setAttribute(e,o,r),i++}}return i}function OY(t){return t===3||t===4||t===6}function s2A(t){return t.charCodeAt(0)===64}function vd(t,e){if(!(e===null||e.length===0))if(t===null||t.length===0)t=e.slice();else{let A=-1;for(let i=0;i<e.length;i++){let n=e[i];typeof n=="number"?A=n:A===0||(A===-1||A===2?uK(t,A,n,null,e[++i]):uK(t,A,n,null,null))}}return t}function uK(t,e,A,i,n){let o=0,r=t.length;if(e===-1)r=-1;else for(;o<t.length;){let s=t[o++];if(typeof s=="number"){if(s===e){r=-1;break}else if(s>e){r=o-1;break}}}for(;o<t.length;){let s=t[o];if(typeof s=="number")break;if(s===A){n!==null&&(t[o+1]=n);return}o++,n!==null&&o++}r!==-1&&(t.splice(r,0,e),o=r+1),t.splice(o++,0,A),n!==null&&t.splice(o++,0,n)}function PY(t){return t!==md}function km(t){return t&32767}function a2A(t){return t>>16}function Sm(t,e){let A=a2A(t),i=e;for(;A>0;)i=i[Sd],A--;return i}var yv=!0;function Rm(t){let e=yv;return yv=t,e}var c2A=256,jY=c2A-1,qY=5,l2A=0,Hl={};function g2A(t,e,A){let i;typeof A=="string"?i=A.charCodeAt(0)||0:A.hasOwnProperty(Zh)&&(i=A[Zh]),i==null&&(i=A[Zh]=l2A++);let n=i&jY,o=1<<n;e.data[t+(n>>qY)]|=o}function Lm(t,e){let A=VY(t,e);if(A!==-1)return A;let i=e[gi];i.firstCreatePass&&(t.injectorIndex=e.length,nv(i.data,t),nv(e,null),nv(i.blueprint,null));let n=H9(t,e),o=t.injectorIndex;if(PY(n)){let r=km(n),s=Sm(n,e),a=s[gi].data;for(let c=0;c<8;c++)e[o+c]=s[r+c]|a[r+c]}return e[o+8]=n,o}function nv(t,e){t.push(0,0,0,0,0,0,0,0,e)}function VY(t,e){return t.injectorIndex===-1||t.parent&&t.parent.injectorIndex===t.injectorIndex||e[t.injectorIndex+8]===null?-1:t.injectorIndex}function H9(t,e){if(t.parent&&t.parent.injectorIndex!==-1)return t.parent.injectorIndex;let A=0,i=null,n=e;for(;n!==null;){if(i=AJ(n),i===null)return md;if(A++,n=n[Sd],i.injectorIndex!==-1)return i.injectorIndex|A<<16}return md}function vv(t,e,A){g2A(t,e,A)}function I2A(t,e){if(e==="class")return t.classes;if(e==="style")return t.styles;let A=t.attrs;if(A){let i=A.length,n=0;for(;n<i;){let o=A[n];if(OY(o))break;if(o===0)n=n+2;else if(typeof o=="number")for(n++;n<i&&typeof A[n]=="string";)n++;else{if(o===e)return A[n+1];n=n+2}}}return null}function ZY(t,e,A){if(A&_i.Optional||t!==void 0)return t;D9(e,"NodeInjector")}function WY(t,e,A,i){if(A&_i.Optional&&i===void 0&&(i=null),(A&(_i.Self|_i.Host))===0){let n=t[rI],o=Vs(void 0);try{return n?n.get(e,i,A&_i.Optional):CY(e,i,A&_i.Optional)}finally{Vs(o)}}return ZY(i,e,A)}function XY(t,e,A,i=_i.Default,n){if(t!==null){if(e[Vt]&2048&&!(i&_i.Self)){let r=E2A(t,e,A,i,Hl);if(r!==Hl)return r}let o=$Y(t,e,A,i,Hl);if(o!==Hl)return o}return WY(e,A,i,n)}function $Y(t,e,A,i,n){let o=d2A(A);if(typeof o=="function"){if(!UY(e,t,i))return i&_i.Host?ZY(n,A,i):WY(e,A,i,n);try{let r;if(r=o(i),r==null&&!(i&_i.Optional))D9(A);else return r}finally{TY()}}else if(typeof o=="number"){let r=null,s=VY(t,e),a=md,c=i&_i.Host?e[_a][Aa]:null;for((s===-1||i&_i.SkipSelf)&&(a=s===-1?H9(t,e):e[s+8],a===md||!mK(i,!1)?s=-1:(r=e[gi],s=km(a),e=Sm(a,e)));s!==-1;){let l=e[gi];if(fK(o,s,l.data)){let I=C2A(s,e,A,r,i,c);if(I!==Hl)return I}a=e[s+8],a!==md&&mK(i,e[gi].data[s+8]===c)&&fK(o,s,e)?(r=l,s=km(a),e=Sm(a,e)):s=-1}}return n}function C2A(t,e,A,i,n,o){let r=e[gi],s=r.data[t+8],a=i==null?Rd(s)&&yv:i!=r&&(s.type&3)!==0,c=n&_i.Host&&o===s,l=Qm(s,r,A,a,c);return l!==null?AQ(e,r,l,s):Hl}function Qm(t,e,A,i,n){let o=t.providerIndexes,r=e.data,s=o&1048575,a=t.directiveStart,c=t.directiveEnd,l=o>>20,I=i?s:s+l,C=n?s+l:c;for(let d=I;d<C;d++){let B=r[d];if(d<a&&A===B||d>=a&&B.type===A)return d}if(n){let d=r[a];if(d&&Al(d)&&d.type===A)return a}return null}function AQ(t,e,A,i){let n=t[A],o=e.data;if(n instanceof II){let r=n;r.resolving&&gY(i0A(o[A]));let s=Rm(r.canSeeViewProviders);r.resolving=!0;let a,c=r.injectImpl?Vs(r.injectImpl):null,l=UY(t,i,_i.Default);try{n=t[A]=r.factory(void 0,o,t,i),e.firstCreatePass&&A>=i.directiveStart&&t2A(A,o[A],e)}finally{c!==null&&Vs(c),Rm(s),r.resolving=!1,TY()}}return n}function d2A(t){if(typeof t=="string")return t.charCodeAt(0)||0;let e=t.hasOwnProperty(Zh)?t[Zh]:void 0;return typeof e=="number"?e>=0?e&jY:B2A:e}function fK(t,e,A){let i=1<<t;return!!(A[e+(t>>qY)]&i)}function mK(t,e){return!(t&_i.Self)&&!(t&_i.Host&&e)}var iI=class{_tNode;_lView;constructor(e,A){this._tNode=e,this._lView=A}get(e,A,i){return XY(this._tNode,this._lView,e,Wm(i),A)}};function B2A(){return new iI(Xr(),Ut())}function bi(t){return oQ(()=>{let e=t.prototype.constructor,A=e[fm]||bv(e),i=Object.prototype,n=Object.getPrototypeOf(t.prototype).constructor;for(;n&&n!==i;){let o=n[fm]||bv(n);if(o&&o!==A)return o;n=Object.getPrototypeOf(n)}return o=>new o})}function bv(t){return rY(t)?()=>{let e=bv(Wr(t));return e&&e()}:oI(t)}function E2A(t,e,A,i,n){let o=t,r=e;for(;o!==null&&r!==null&&r[Vt]&2048&&!bm(r);){let s=$Y(o,r,A,i|_i.Self,Hl);if(s!==Hl)return s;let a=o.parent;if(!a){let c=r[yY];if(c){let l=c.get(A,Hl,i);if(l!==Hl)return l}a=AJ(r),r=r[Sd]}o=a}return n}function AJ(t){let e=t[gi],A=e.type;return A===2?e.declTNode:A===1?t[Aa]:null}function O9(t){return I2A(Xr(),t)}function pK(t,e=null,A=null,i){let n=eJ(t,e,A,i);return n.resolveInjectorInitializers(),n}function eJ(t,e=null,A=null,i,n=new Set){let o=[A||xs,Q0A(t)];return i=i||(typeof t=="object"?void 0:Zs(t)),new Xh(o,e||Ap(),i||null,n)}var Dt=class t{static THROW_IF_NOT_FOUND=tI;static NULL=new Dm;static create(e,A){if(Array.isArray(e))return pK({name:""},A,e,"");{let i=e.name??"";return pK({name:i},e.parent,e.providers,i)}}static \u0275prov=SA({token:t,providedIn:"any",factory:()=>he(EY)});static __NG_ELEMENT_ID__=-1};var Er=class{attributeName;constructor(e){this.attributeName=e}__NG_ELEMENT_ID__=()=>O9(this.attributeName);toString(){return`HostAttributeToken ${this.attributeName}`}},h2A=new BA("");h2A.__NG_ELEMENT_ID__=t=>{let e=Xr();if(e===null)throw new ZA(204,!1);if(e.type&2)return e.value;if(t&_i.Optional)return null;throw new ZA(204,!1)};var tJ=!1,Fd=(()=>{class t{static __NG_ELEMENT_ID__=Q2A;static __NG_ENV_ID__=A=>A}return t})(),xm=class extends Fd{_lView;constructor(e){super(),this._lView=e}onDestroy(e){let A=this._lView;return Ld(A)?(e(),()=>{}):(FY(A,e),()=>U0A(A,e))}};function Q2A(){return new xm(Ut())}var CI=class{},P9=new BA("",{providedIn:"root",factory:()=>!1});var iJ=new BA(""),nJ=new BA(""),r0=(()=>{class t{taskId=0;pendingTasks=new Set;get _hasPendingTasks(){return this.hasPendingTasks.value}hasPendingTasks=new li(!1);add(){this._hasPendingTasks||this.hasPendingTasks.next(!0);let A=this.taskId++;return this.pendingTasks.add(A),A}has(A){return this.pendingTasks.has(A)}remove(A){this.pendingTasks.delete(A),this.pendingTasks.size===0&&this._hasPendingTasks&&this.hasPendingTasks.next(!1)}ngOnDestroy(){this.pendingTasks.clear(),this._hasPendingTasks&&this.hasPendingTasks.next(!1)}static \u0275prov=SA({token:t,providedIn:"root",factory:()=>new t})}return t})();var Mv=class extends HA{__isAsync;destroyRef=void 0;pendingTasks=void 0;constructor(e=!1){super(),this.__isAsync=e,DY()&&(this.destroyRef=m(Fd,{optional:!0})??void 0,this.pendingTasks=m(r0,{optional:!0})??void 0)}emit(e){let A=vi(null);try{super.next(e)}finally{vi(A)}}subscribe(e,A,i){let n=e,o=A||(()=>null),r=i;if(e&&typeof e=="object"){let a=e;n=a.next?.bind(a),o=a.error?.bind(a),r=a.complete?.bind(a)}this.__isAsync&&(o=this.wrapInTimeout(o),n&&(n=this.wrapInTimeout(n)),r&&(r=this.wrapInTimeout(r)));let s=super.subscribe({next:n,error:o,complete:r});return e instanceof _t&&e.add(s),s}wrapInTimeout(e){return A=>{let i=this.pendingTasks?.add();setTimeout(()=>{try{e(A)}finally{i!==void 0&&this.pendingTasks?.remove(i)}})}}},XA=Mv;function eQ(...t){}function oJ(t){let e,A;function i(){t=eQ;try{A!==void 0&&typeof cancelAnimationFrame=="function"&&cancelAnimationFrame(A),e!==void 0&&clearTimeout(e)}catch{}}return e=setTimeout(()=>{t(),i()}),typeof requestAnimationFrame=="function"&&(A=requestAnimationFrame(()=>{t(),i()})),()=>i()}function wK(t){return queueMicrotask(()=>t()),()=>{t=eQ}}var j9="isAngularZone",Fm=j9+"_ID",u2A=0,de=class t{hasPendingMacrotasks=!1;hasPendingMicrotasks=!1;isStable=!0;onUnstable=new XA(!1);onMicrotaskEmpty=new XA(!1);onStable=new XA(!1);onError=new XA(!1);constructor(e){let{enableLongStackTrace:A=!1,shouldCoalesceEventChangeDetection:i=!1,shouldCoalesceRunChangeDetection:n=!1,scheduleInRootZone:o=tJ}=e;if(typeof Zone>"u")throw new ZA(908,!1);Zone.assertZonePatched();let r=this;r._nesting=0,r._outer=r._inner=Zone.current,Zone.TaskTrackingZoneSpec&&(r._inner=r._inner.fork(new Zone.TaskTrackingZoneSpec)),A&&Zone.longStackTraceZoneSpec&&(r._inner=r._inner.fork(Zone.longStackTraceZoneSpec)),r.shouldCoalesceEventChangeDetection=!n&&i,r.shouldCoalesceRunChangeDetection=n,r.callbackScheduled=!1,r.scheduleInRootZone=o,p2A(r)}static isInAngularZone(){return typeof Zone<"u"&&Zone.current.get(j9)===!0}static assertInAngularZone(){if(!t.isInAngularZone())throw new ZA(909,!1)}static assertNotInAngularZone(){if(t.isInAngularZone())throw new ZA(909,!1)}run(e,A,i){return this._inner.run(e,A,i)}runTask(e,A,i,n){let o=this._inner,r=o.scheduleEventTask("NgZoneEvent: "+n,e,f2A,eQ,eQ);try{return o.runTask(r,A,i)}finally{o.cancelTask(r)}}runGuarded(e,A,i){return this._inner.runGuarded(e,A,i)}runOutsideAngular(e){return this._outer.run(e)}},f2A={};function q9(t){if(t._nesting==0&&!t.hasPendingMicrotasks&&!t.isStable)try{t._nesting++,t.onMicrotaskEmpty.emit(null)}finally{if(t._nesting--,!t.hasPendingMicrotasks)try{t.runOutsideAngular(()=>t.onStable.emit(null))}finally{t.isStable=!0}}}function m2A(t){if(t.isCheckStableRunning||t.callbackScheduled)return;t.callbackScheduled=!0;function e(){oJ(()=>{t.callbackScheduled=!1,kv(t),t.isCheckStableRunning=!0,q9(t),t.isCheckStableRunning=!1})}t.scheduleInRootZone?Zone.root.run(()=>{e()}):t._outer.run(()=>{e()}),kv(t)}function p2A(t){let e=()=>{m2A(t)},A=u2A++;t._inner=t._inner.fork({name:"angular",properties:{[j9]:!0,[Fm]:A,[Fm+A]:!0},onInvokeTask:(i,n,o,r,s,a)=>{if(w2A(a))return i.invokeTask(o,r,s,a);try{return DK(t),i.invokeTask(o,r,s,a)}finally{(t.shouldCoalesceEventChangeDetection&&r.type==="eventTask"||t.shouldCoalesceRunChangeDetection)&&e(),yK(t)}},onInvoke:(i,n,o,r,s,a,c)=>{try{return DK(t),i.invoke(o,r,s,a,c)}finally{t.shouldCoalesceRunChangeDetection&&!t.callbackScheduled&&!D2A(a)&&e(),yK(t)}},onHasTask:(i,n,o,r)=>{i.hasTask(o,r),n===o&&(r.change=="microTask"?(t._hasPendingMicrotasks=r.microTask,kv(t),q9(t)):r.change=="macroTask"&&(t.hasPendingMacrotasks=r.macroTask))},onHandleError:(i,n,o,r)=>(i.handleError(o,r),t.runOutsideAngular(()=>t.onError.emit(r)),!1)})}function kv(t){t._hasPendingMicrotasks||(t.shouldCoalesceEventChangeDetection||t.shouldCoalesceRunChangeDetection)&&t.callbackScheduled===!0?t.hasPendingMicrotasks=!0:t.hasPendingMicrotasks=!1}function DK(t){t._nesting++,t.isStable&&(t.isStable=!1,t.onUnstable.emit(null))}function yK(t){t._nesting--,q9(t)}var Nm=class{hasPendingMicrotasks=!1;hasPendingMacrotasks=!1;isStable=!0;onUnstable=new XA;onMicrotaskEmpty=new XA;onStable=new XA;onError=new XA;run(e,A,i){return e.apply(A,i)}runGuarded(e,A,i){return e.apply(A,i)}runOutsideAngular(e){return e()}runTask(e,A,i,n){return e.apply(A,i)}};function w2A(t){return rJ(t,"__ignore_ng_zone__")}function D2A(t){return rJ(t,"__scheduler_tick__")}function rJ(t,e){return!Array.isArray(t)||t.length!==1?!1:t[0]?.data?.[e]===!0}function y2A(t="zone.js",e){return t==="noop"?new Nm:t==="zone.js"?new de(e):t}var Xs=class{_console=console;handleError(e){this._console.error("ERROR",e)}},v2A=new BA("",{providedIn:"root",factory:()=>{let t=m(de),e=m(Xs);return A=>t.runOutsideAngular(()=>e.handleError(A))}});function vK(t,e){return nY(t,e)}function b2A(t){return nY(iY,t)}var sJ=(vK.required=b2A,vK);function M2A(){return Nd(Xr(),Ut())}function Nd(t,e){return new te(Wl(t,e))}var te=(()=>{class t{nativeElement;constructor(A){this.nativeElement=A}static __NG_ELEMENT_ID__=M2A}return t})();function aJ(t){return t instanceof te?t.nativeElement:t}function h2(t){return typeof t=="function"&&t[js]!==void 0}function Ko(t,e){let A=_7(t,e?.equal),i=A[js];return A.set=n=>Uh(i,n),A.update=n=>G7(i,n),A.asReadonly=k2A.bind(A),A}function k2A(){let t=this[js];if(t.readonlyFn===void 0){let e=()=>this();e[js]=t,t.readonlyFn=e}return t.readonlyFn}function cJ(t){return h2(t)&&typeof t.set=="function"}function S2A(){return this._results[Symbol.iterator]()}var Ec=class{_emitDistinctChangesOnly;dirty=!0;_onDirty=void 0;_results=[];_changesDetected=!1;_changes=void 0;length=0;first=void 0;last=void 0;get changes(){return this._changes??=new HA}constructor(e=!1){this._emitDistinctChangesOnly=e}get(e){return this._results[e]}map(e){return this._results.map(e)}filter(e){return this._results.filter(e)}find(e){return this._results.find(e)}reduce(e,A){return this._results.reduce(e,A)}forEach(e){this._results.forEach(e)}some(e){return this._results.some(e)}toArray(){return this._results.slice()}toString(){return this._results.toString()}reset(e,A){this.dirty=!1;let i=C0A(e);(this._changesDetected=!I0A(this._results,i,A))&&(this._results=i,this.length=i.length,this.last=i[this.length-1],this.first=i[0])}notifyOnChanges(){this._changes!==void 0&&(this._changesDetected||!this._emitDistinctChangesOnly)&&this._changes.next(this)}onDirty(e){this._onDirty=e}setDirty(){this.dirty=!0,this._onDirty?.()}destroy(){this._changes!==void 0&&(this._changes.complete(),this._changes.unsubscribe())}[Symbol.iterator]=S2A};function lJ(t){return(t.flags&128)===128}var gJ=function(t){return t[t.OnPush=0]="OnPush",t[t.Default=1]="Default",t}(gJ||{}),IJ=new Map,R2A=0;function L2A(){return R2A++}function x2A(t){IJ.set(t[ep],t)}function Sv(t){IJ.delete(t[ep])}var bK="__ngContext__";function _d(t,e){C2(e)?(t[bK]=e[ep],x2A(e)):t[bK]=e}function CJ(t){return BJ(t[$h])}function dJ(t){return BJ(t[$c])}function BJ(t){for(;t!==null&&!n0(t);)t=t[$c];return t}var Rv;function EJ(t){Rv=t}function hJ(){if(Rv!==void 0)return Rv;if(typeof document<"u")return document;throw new ZA(210,!1)}var fI=new BA("",{providedIn:"root",factory:()=>F2A}),F2A="ng",V9=new BA(""),hc=new BA("",{providedIn:"platform",factory:()=>"unknown"});var mi=new BA(""),gQ=new BA("",{providedIn:"root",factory:()=>hJ().body?.querySelector("[ngCspNonce]")?.getAttribute("ngCspNonce")||null});var N2A="h",_2A="b";var QJ=!1,G2A=new BA("",{providedIn:"root",factory:()=>QJ});var Z9=function(t){return t[t.CHANGE_DETECTION=0]="CHANGE_DETECTION",t[t.AFTER_NEXT_RENDER=1]="AFTER_NEXT_RENDER",t}(Z9||{}),Gd=new BA(""),MK=new Set;function s0(t){MK.has(t)||(MK.add(t),performance?.mark?.("mark_feature_usage",{detail:{feature:t}}))}var W9=(()=>{class t{view;node;constructor(A,i){this.view=A,this.node=i}static __NG_ELEMENT_ID__=U2A}return t})();function U2A(){return new W9(Ut(),Xr())}var Qd=function(t){return t[t.EarlyRead=0]="EarlyRead",t[t.Write=1]="Write",t[t.MixedReadWrite=2]="MixedReadWrite",t[t.Read=3]="Read",t}(Qd||{}),uJ=(()=>{class t{impl=null;execute(){this.impl?.execute()}static \u0275prov=SA({token:t,providedIn:"root",factory:()=>new t})}return t})(),K2A=[Qd.EarlyRead,Qd.Write,Qd.MixedReadWrite,Qd.Read],Y2A=(()=>{class t{ngZone=m(de);scheduler=m(CI);errorHandler=m(Xs,{optional:!0});sequences=new Set;deferredRegistrations=new Set;executing=!1;constructor(){m(Gd,{optional:!0})}execute(){let A=this.sequences.size>0;A&&uo(16),this.executing=!0;for(let i of K2A)for(let n of this.sequences)if(!(n.erroredOrDestroyed||!n.hooks[i]))try{n.pipelinedValue=this.ngZone.runOutsideAngular(()=>this.maybeTrace(()=>{let o=n.hooks[i];return o(n.pipelinedValue)},n.snapshot))}catch(o){n.erroredOrDestroyed=!0,this.errorHandler?.handleError(o)}this.executing=!1;for(let i of this.sequences)i.afterRun(),i.once&&(this.sequences.delete(i),i.destroy());for(let i of this.deferredRegistrations)this.sequences.add(i);this.deferredRegistrations.size>0&&this.scheduler.notify(7),this.deferredRegistrations.clear(),A&&uo(17)}register(A){let{view:i}=A;i!==void 0?((i[fd]??=[]).push(A),xd(i),i[Vt]|=8192):this.executing?this.deferredRegistrations.add(A):this.addSequence(A)}addSequence(A){this.sequences.add(A),this.scheduler.notify(7)}unregister(A){this.executing&&this.sequences.has(A)?(A.erroredOrDestroyed=!0,A.pipelinedValue=void 0,A.once=!0):(this.sequences.delete(A),this.deferredRegistrations.delete(A))}maybeTrace(A,i){return i?i.run(Z9.AFTER_NEXT_RENDER,A):A()}static \u0275prov=SA({token:t,providedIn:"root",factory:()=>new t})}return t})(),Lv=class{impl;hooks;view;once;snapshot;erroredOrDestroyed=!1;pipelinedValue=void 0;unregisterOnDestroy;constructor(e,A,i,n,o,r=null){this.impl=e,this.hooks=A,this.view=i,this.once=n,this.snapshot=r,this.unregisterOnDestroy=o?.onDestroy(()=>this.destroy())}afterRun(){this.erroredOrDestroyed=!1,this.pipelinedValue=void 0,this.snapshot?.dispose(),this.snapshot=null}destroy(){this.impl.unregister(this),this.unregisterOnDestroy?.();let e=this.view?.[fd];e&&(this.view[fd]=e.filter(A=>A!==this))}};function IQ(t,e){!e?.injector&&b9(IQ);let A=e?.injector??m(Dt);return s0("NgAfterRender"),fJ(t,A,e,!1)}function Vo(t,e){!e?.injector&&b9(Vo);let A=e?.injector??m(Dt);return s0("NgAfterNextRender"),fJ(t,A,e,!0)}function J2A(t,e){if(t instanceof Function){let A=[void 0,void 0,void 0,void 0];return A[e]=t,A}else return[t.earlyRead,t.write,t.mixedReadWrite,t.read]}function fJ(t,e,A,i){let n=e.get(uJ);n.impl??=e.get(Y2A);let o=e.get(Gd,null,{optional:!0}),r=A?.phase??Qd.MixedReadWrite,s=A?.manualCleanup!==!0?e.get(Fd):null,a=e.get(W9,null,{optional:!0}),c=new Lv(n.impl,J2A(t,r),a?.view,i,s,o?.snapshot(null));return n.impl.register(c),c}var T2A=()=>null;function mJ(t,e,A=!1){return T2A(t,e,A)}function pJ(t,e){let A=t.contentQueries;if(A!==null){let i=vi(null);try{for(let n=0;n<A.length;n+=2){let o=A[n],r=A[n+1];if(r!==-1){let s=t.data[r];np(o),s.contentQueries(2,e[r],r)}}}finally{vi(i)}}}function xv(t,e,A){np(0);let i=vi(null);try{e(t,A)}finally{vi(i)}}function X9(t,e,A){if(k9(e)){let i=vi(null);try{let n=e.directiveStart,o=e.directiveEnd;for(let r=n;r<o;r++){let s=t.data[r];if(s.contentQueries){let a=A[r];s.contentQueries(1,a,r)}}}finally{vi(i)}}}var ql=function(t){return t[t.Emulated=0]="Emulated",t[t.None=2]="None",t[t.ShadowDom=3]="ShadowDom",t}(ql||{}),lm;function z2A(){if(lm===void 0&&(lm=null,Ws.trustedTypes))try{lm=Ws.trustedTypes.createPolicy("angular",{createHTML:t=>t,createScript:t=>t,createScriptURL:t=>t})}catch{}return lm}function sp(t){return z2A()?.createHTML(t)||t}var gm;function H2A(){if(gm===void 0&&(gm=null,Ws.trustedTypes))try{gm=Ws.trustedTypes.createPolicy("angular#unsafe-bypass",{createHTML:t=>t,createScript:t=>t,createScriptURL:t=>t})}catch{}return gm}function kK(t){return H2A()?.createHTML(t)||t}var t0=class{changingThisBreaksApplicationSecurity;constructor(e){this.changingThisBreaksApplicationSecurity=e}toString(){return`SafeValue must use [property]=binding: ${this.changingThisBreaksApplicationSecurity} (see ${tY})`}},Fv=class extends t0{getTypeName(){return"HTML"}},Nv=class extends t0{getTypeName(){return"Style"}},_v=class extends t0{getTypeName(){return"Script"}},Gv=class extends t0{getTypeName(){return"URL"}},Uv=class extends t0{getTypeName(){return"ResourceURL"}};function el(t){return t instanceof t0?t.changingThisBreaksApplicationSecurity:t}function Q2(t,e){let A=O2A(t);if(A!=null&&A!==e){if(A==="ResourceURL"&&e==="URL")return!0;throw new Error(`Required a safe ${e}, got a ${A} (see ${tY})`)}return A===e}function O2A(t){return t instanceof t0&&t.getTypeName()||null}function wJ(t){return new Fv(t)}function DJ(t){return new Nv(t)}function yJ(t){return new _v(t)}function vJ(t){return new Gv(t)}function bJ(t){return new Uv(t)}function P2A(t){let e=new Yv(t);return j2A()?new Kv(e):e}var Kv=class{inertDocumentHelper;constructor(e){this.inertDocumentHelper=e}getInertBodyElement(e){e="<body><remove></remove>"+e;try{let A=new window.DOMParser().parseFromString(sp(e),"text/html").body;return A===null?this.inertDocumentHelper.getInertBodyElement(e):(A.firstChild?.remove(),A)}catch{return null}}},Yv=class{defaultDoc;inertDocument;constructor(e){this.defaultDoc=e,this.inertDocument=this.defaultDoc.implementation.createHTMLDocument("sanitization-inert")}getInertBodyElement(e){let A=this.inertDocument.createElement("template");return A.innerHTML=sp(e),A}};function j2A(){try{return!!new window.DOMParser().parseFromString(sp(""),"text/html")}catch{return!1}}var q2A=/^(?!javascript:)(?:[a-z0-9+.-]+:|[^&:\/?#]*(?:[\/?#]|$))/i;function ap(t){return t=String(t),t.match(q2A)?t:"unsafe:"+t}function a0(t){let e={};for(let A of t.split(","))e[A]=!0;return e}function CQ(...t){let e={};for(let A of t)for(let i in A)A.hasOwnProperty(i)&&(e[i]=!0);return e}var MJ=a0("area,br,col,hr,img,wbr"),kJ=a0("colgroup,dd,dt,li,p,tbody,td,tfoot,th,thead,tr"),SJ=a0("rp,rt"),V2A=CQ(SJ,kJ),Z2A=CQ(kJ,a0("address,article,aside,blockquote,caption,center,del,details,dialog,dir,div,dl,figure,figcaption,footer,h1,h2,h3,h4,h5,h6,header,hgroup,hr,ins,main,map,menu,nav,ol,pre,section,summary,table,ul")),W2A=CQ(SJ,a0("a,abbr,acronym,audio,b,bdi,bdo,big,br,cite,code,del,dfn,em,font,i,img,ins,kbd,label,map,mark,picture,q,ruby,rp,rt,s,samp,small,source,span,strike,strong,sub,sup,time,track,tt,u,var,video")),SK=CQ(MJ,Z2A,W2A,V2A),RJ=a0("background,cite,href,itemtype,longdesc,poster,src,xlink:href"),X2A=a0("abbr,accesskey,align,alt,autoplay,axis,bgcolor,border,cellpadding,cellspacing,class,clear,color,cols,colspan,compact,controls,coords,datetime,default,dir,download,face,headers,height,hidden,hreflang,hspace,ismap,itemscope,itemprop,kind,label,lang,language,loop,media,muted,nohref,nowrap,open,preload,rel,rev,role,rows,rowspan,rules,scope,scrolling,shape,size,sizes,span,srclang,srcset,start,summary,tabindex,target,title,translate,type,usemap,valign,value,vspace,width"),$2A=a0("aria-activedescendant,aria-atomic,aria-autocomplete,aria-busy,aria-checked,aria-colcount,aria-colindex,aria-colspan,aria-controls,aria-current,aria-describedby,aria-details,aria-disabled,aria-dropeffect,aria-errormessage,aria-expanded,aria-flowto,aria-grabbed,aria-haspopup,aria-hidden,aria-invalid,aria-keyshortcuts,aria-label,aria-labelledby,aria-level,aria-live,aria-modal,aria-multiline,aria-multiselectable,aria-orientation,aria-owns,aria-placeholder,aria-posinset,aria-pressed,aria-readonly,aria-relevant,aria-required,aria-roledescription,aria-rowcount,aria-rowindex,aria-rowspan,aria-selected,aria-setsize,aria-sort,aria-valuemax,aria-valuemin,aria-valuenow,aria-valuetext"),A1A=CQ(RJ,X2A,$2A),e1A=a0("script,style,template"),Jv=class{sanitizedSomething=!1;buf=[];sanitizeChildren(e){let A=e.firstChild,i=!0,n=[];for(;A;){if(A.nodeType===Node.ELEMENT_NODE?i=this.startElement(A):A.nodeType===Node.TEXT_NODE?this.chars(A.nodeValue):this.sanitizedSomething=!0,i&&A.firstChild){n.push(A),A=n1A(A);continue}for(;A;){A.nodeType===Node.ELEMENT_NODE&&this.endElement(A);let o=i1A(A);if(o){A=o;break}A=n.pop()}}return this.buf.join("")}startElement(e){let A=RK(e).toLowerCase();if(!SK.hasOwnProperty(A))return this.sanitizedSomething=!0,!e1A.hasOwnProperty(A);this.buf.push("<"),this.buf.push(A);let i=e.attributes;for(let n=0;n<i.length;n++){let o=i.item(n),r=o.name,s=r.toLowerCase();if(!A1A.hasOwnProperty(s)){this.sanitizedSomething=!0;continue}let a=o.value;RJ[s]&&(a=ap(a)),this.buf.push(" ",r,'="',LK(a),'"')}return this.buf.push(">"),!0}endElement(e){let A=RK(e).toLowerCase();SK.hasOwnProperty(A)&&!MJ.hasOwnProperty(A)&&(this.buf.push("</"),this.buf.push(A),this.buf.push(">"))}chars(e){this.buf.push(LK(e))}};function t1A(t,e){return(t.compareDocumentPosition(e)&Node.DOCUMENT_POSITION_CONTAINED_BY)!==Node.DOCUMENT_POSITION_CONTAINED_BY}function i1A(t){let e=t.nextSibling;if(e&&t!==e.previousSibling)throw LJ(e);return e}function n1A(t){let e=t.firstChild;if(e&&t1A(t,e))throw LJ(e);return e}function RK(t){let e=t.nodeName;return typeof e=="string"?e:"FORM"}function LJ(t){return new Error(`Failed to sanitize html because the element is clobbered: ${t.outerHTML}`)}var o1A=/[\uD800-\uDBFF][\uDC00-\uDFFF]/g,r1A=/([^\#-~ |!])/g;function LK(t){return t.replace(/&/g,"&amp;").replace(o1A,function(e){let A=e.charCodeAt(0),i=e.charCodeAt(1);return"&#"+((A-55296)*1024+(i-56320)+65536)+";"}).replace(r1A,function(e){return"&#"+e.charCodeAt(0)+";"}).replace(/</g,"&lt;").replace(/>/g,"&gt;")}var Im;function $9(t,e){let A=null;try{Im=Im||P2A(t);let i=e?String(e):"";A=Im.getInertBodyElement(i);let n=5,o=i;do{if(n===0)throw new Error("Failed to sanitize html because the input is unstable");n--,i=o,o=A.innerHTML,A=Im.getInertBodyElement(i)}while(i!==o);let s=new Jv().sanitizeChildren(xK(A)||A);return sp(s)}finally{if(A){let i=xK(A)||A;for(;i.firstChild;)i.firstChild.remove()}}}function xK(t){return"content"in t&&s1A(t)?t.content:null}function s1A(t){return t.nodeType===Node.ELEMENT_NODE&&t.nodeName==="TEMPLATE"}var Kr=function(t){return t[t.NONE=0]="NONE",t[t.HTML=1]="HTML",t[t.STYLE=2]="STYLE",t[t.SCRIPT=3]="SCRIPT",t[t.URL=4]="URL",t[t.RESOURCE_URL=5]="RESOURCE_URL",t}(Kr||{});function mI(t){let e=xJ();return e?kK(e.sanitize(Kr.HTML,t)||""):Q2(t,"HTML")?kK(el(t)):$9(hJ(),nI(t))}function Ka(t){let e=xJ();return e?e.sanitize(Kr.URL,t)||"":Q2(t,"URL")?el(t):ap(nI(t))}function xJ(){let t=Ut();return t&&t[A0].sanitizer}var a1A=/^>|^->|<!--|-->|--!>|<!-$/g,c1A=/(<|>)/g,l1A="\u200B$1\u200B";function g1A(t){return t.replace(a1A,e=>e.replace(c1A,l1A))}function cp(t){return t.ownerDocument.defaultView}function Ud(t){return t.ownerDocument}function FJ(t){return t instanceof Function?t():t}function I1A(t,e,A){let i=t.length;for(;;){let n=t.indexOf(e,A);if(n===-1)return n;if(n===0||t.charCodeAt(n-1)<=32){let o=e.length;if(n+o===i||t.charCodeAt(n+o)<=32)return n}A=n+1}}var NJ="ng-template";function C1A(t,e,A,i){let n=0;if(i){for(;n<e.length&&typeof e[n]=="string";n+=2)if(e[n]==="class"&&I1A(e[n+1].toLowerCase(),A,0)!==-1)return!0}else if(Ab(t))return!1;if(n=e.indexOf(1,n),n>-1){let o;for(;++n<e.length&&typeof(o=e[n])=="string";)if(o.toLowerCase()===A)return!0}return!1}function Ab(t){return t.type===4&&t.value!==NJ}function d1A(t,e,A){let i=t.type===4&&!A?NJ:t.value;return e===i}function B1A(t,e,A){let i=4,n=t.attrs,o=n!==null?Q1A(n):0,r=!1;for(let s=0;s<e.length;s++){let a=e[s];if(typeof a=="number"){if(!r&&!Wc(i)&&!Wc(a))return!1;if(r&&Wc(a))continue;r=!1,i=a|i&1;continue}if(!r)if(i&4){if(i=2|i&1,a!==""&&!d1A(t,a,A)||a===""&&e.length===1){if(Wc(i))return!1;r=!0}}else if(i&8){if(n===null||!C1A(t,n,a,A)){if(Wc(i))return!1;r=!0}}else{let c=e[++s],l=E1A(a,n,Ab(t),A);if(l===-1){if(Wc(i))return!1;r=!0;continue}if(c!==""){let I;if(l>o?I="":I=n[l+1].toLowerCase(),i&2&&c!==I){if(Wc(i))return!1;r=!0}}}}return Wc(i)||r}function Wc(t){return(t&1)===0}function E1A(t,e,A,i){if(e===null)return-1;let n=0;if(i||!A){let o=!1;for(;n<e.length;){let r=e[n];if(r===t)return n;if(r===3||r===6)o=!0;else if(r===1||r===2){let s=e[++n];for(;typeof s=="string";)s=e[++n];continue}else{if(r===4)break;if(r===0){n+=4;continue}}n+=o?1:2}return-1}else return u1A(e,t)}function _J(t,e,A=!1){for(let i=0;i<e.length;i++)if(B1A(t,e[i],A))return!0;return!1}function h1A(t){let e=t.attrs;if(e!=null){let A=e.indexOf(5);if((A&1)===0)return e[A+1]}return null}function Q1A(t){for(let e=0;e<t.length;e++){let A=t[e];if(OY(A))return e}return t.length}function u1A(t,e){let A=t.indexOf(4);if(A>-1)for(A++;A<t.length;){let i=t[A];if(typeof i=="number")return-1;if(i===e)return A;A++}return-1}function f1A(t,e){A:for(let A=0;A<e.length;A++){let i=e[A];if(t.length===i.length){for(let n=0;n<t.length;n++)if(t[n]!==i[n])continue A;return!0}}return!1}function FK(t,e){return t?":not("+e.trim()+")":e}function m1A(t){let e=t[0],A=1,i=2,n="",o=!1;for(;A<t.length;){let r=t[A];if(typeof r=="string")if(i&2){let s=t[++A];n+="["+r+(s.length>0?'="'+s+'"':"")+"]"}else i&8?n+="."+r:i&4&&(n+=" "+r);else n!==""&&!Wc(r)&&(e+=FK(o,n),n=""),i=r,o=o||!Wc(i);A++}return n!==""&&(e+=FK(o,n)),e}function p1A(t){return t.map(m1A).join(",")}function w1A(t){let e=[],A=[],i=1,n=2;for(;i<t.length;){let o=t[i];if(typeof o=="string")n===2?o!==""&&e.push(o,t[++i]):n===8&&A.push(o);else{if(!Wc(n))break;n=o}i++}return A.length&&e.push(1,...A),e}var Ya={};function D1A(t,e){return t.createText(e)}function y1A(t,e,A){t.setValue(e,A)}function v1A(t,e){return t.createComment(g1A(e))}function GJ(t,e,A){return t.createElement(e,A)}function _m(t,e,A,i,n){t.insertBefore(e,A,i,n)}function UJ(t,e,A){t.appendChild(e,A)}function NK(t,e,A,i,n){i!==null?_m(t,e,A,i,n):UJ(t,e,A)}function b1A(t,e,A){t.removeChild(null,e,A)}function M1A(t,e,A){t.setAttribute(e,"style",A)}function k1A(t,e,A){A===""?t.removeAttribute(e,"class"):t.setAttribute(e,"class",A)}function KJ(t,e,A){let{mergedAttrs:i,classes:n,styles:o}=A;i!==null&&r2A(t,e,i),n!==null&&k1A(t,e,n),o!==null&&M1A(t,e,o)}function eb(t,e,A,i,n,o,r,s,a,c,l){let I=br+i,C=I+n,d=S1A(I,C),B=typeof c=="function"?c():c;return d[gi]={type:t,blueprint:d,template:A,queries:null,viewQuery:s,declTNode:e,data:d.slice().fill(null,I),bindingStartIndex:I,expandoStartIndex:C,hostBindingOpCodes:null,firstCreatePass:!0,firstUpdatePass:!0,staticViewQueries:!1,staticContentQueries:!1,preOrderHooks:null,preOrderCheckHooks:null,contentHooks:null,contentCheckHooks:null,viewHooks:null,viewCheckHooks:null,destroyHooks:null,cleanup:null,contentQueries:null,components:null,directiveRegistry:typeof o=="function"?o():o,pipeRegistry:typeof r=="function"?r():r,firstChild:null,schemas:a,consts:B,incompleteFirstPass:!1,ssrId:l}}function S1A(t,e){let A=[];for(let i=0;i<e;i++)A.push(i<t?null:Ya);return A}function R1A(t){let e=t.tView;return e===null||e.incompleteFirstPass?t.tView=eb(1,null,t.template,t.decls,t.vars,t.directiveDefs,t.pipeDefs,t.viewQuery,t.schemas,t.consts,t.id):e}function tb(t,e,A,i,n,o,r,s,a,c,l){let I=e.blueprint.slice();return I[Zl]=n,I[Vt]=i|4|128|8|64|1024,(c!==null||t&&t[Vt]&2048)&&(I[Vt]|=2048),LY(I),I[Cs]=I[Sd]=t,I[vr]=A,I[A0]=r||t&&t[A0],I[Uo]=s||t&&t[Uo],I[rI]=a||t&&t[rI]||null,I[Aa]=o,I[ep]=L2A(),I[Dd]=l,I[yY]=c,I[_a]=e.type==2?t[_a]:I,I}function L1A(t,e,A){let i=Wl(e,t),n=R1A(A),o=t[A0].rendererFactory,r=ib(t,tb(t,n,null,YJ(A),i,e,null,o.createRenderer(i,A),null,null,null));return t[e.index]=r}function YJ(t){let e=16;return t.signals?e=4096:t.onPush&&(e=64),e}function JJ(t,e,A,i){if(A===0)return-1;let n=e.length;for(let o=0;o<A;o++)e.push(i),t.blueprint.push(i),t.data.push(null);return n}function ib(t,e){return t[$h]?t[EK][$c]=e:t[$h]=e,t[EK]=e,e}function _(t=1){TJ(yo(),Ut(),o0()+t,!1)}function TJ(t,e,A,i){if(!i)if((e[Vt]&3)===3){let o=t.preOrderCheckHooks;o!==null&&Em(e,o,A)}else{let o=t.preOrderHooks;o!==null&&hm(e,o,0,A)}gI(A)}var lp=function(t){return t[t.None=0]="None",t[t.SignalBased=1]="SignalBased",t[t.HasDecoratorInputTransform=2]="HasDecoratorInputTransform",t}(lp||{});function Tv(t,e,A,i){let n=vi(null);try{let[o,r,s]=t.inputs[A],a=null;(r&lp.SignalBased)!==0&&(a=e[o][js]),a!==null&&a.transformFn!==void 0?i=a.transformFn(i):s!==null&&(i=s.call(e,i)),t.setInput!==null?t.setInput(e,a,i,A,o):vY(e,a,o,i)}finally{vi(n)}}function zJ(t,e,A,i,n){let o=o0(),r=i&2;try{gI(-1),r&&e.length>br&&TJ(t,e,br,!1),uo(r?2:0,n),A(i,n)}finally{gI(o),uo(r?3:1,n)}}function gp(t,e,A){U1A(t,e,A),(A.flags&64)===64&&K1A(t,e,A)}function nb(t,e,A=Wl){let i=e.localNames;if(i!==null){let n=e.index+1;for(let o=0;o<i.length;o+=2){let r=i[o+1],s=r===-1?A(e,t):t[r];t[n++]=s}}}function x1A(t,e,A,i){let o=i.get(G2A,QJ)||A===ql.ShadowDom,r=t.selectRootElement(e,o);return F1A(r),r}function F1A(t){N1A(t)}var N1A=()=>null;function _1A(t){return t==="class"?"className":t==="for"?"htmlFor":t==="formaction"?"formAction":t==="innerHtml"?"innerHTML":t==="readonly"?"readOnly":t==="tabindex"?"tabIndex":t}function Ip(t,e,A,i,n,o,r,s){if(!s&&rb(e,t,A,i,n)){Rd(e)&&G1A(A,e.index);return}if(e.type&3){let a=Wl(e,A);i=_1A(i),n=r!=null?r(n,e.value||"",i):n,o.setProperty(a,i,n)}else e.type&12}function G1A(t,e){let A=jl(e,t);A[Vt]&16||(A[Vt]|=64)}function U1A(t,e,A){let i=A.directiveStart,n=A.directiveEnd;Rd(A)&&L1A(e,A,t.data[i+A.componentOffset]),t.firstCreatePass||Lm(A,e);let o=A.initialInputs;for(let r=i;r<n;r++){let s=t.data[r],a=AQ(e,t,r,A);if(_d(a,e),o!==null&&z1A(e,r-i,a,s,A,o),Al(s)){let c=jl(A.index,e);c[vr]=AQ(e,t,r,A)}}}function K1A(t,e,A){let i=A.directiveStart,n=A.directiveEnd,o=A.index,r=W0A();try{gI(o);for(let s=i;s<n;s++){let a=t.data[s],c=e[s];Dv(s),(a.hostBindings!==null||a.hostVars!==0||a.hostAttrs!==null)&&Y1A(a,c)}}finally{gI(-1),Dv(r)}}function Y1A(t,e){t.hostBindings!==null&&t.hostBindings(1,e)}function ob(t,e){let A=t.directiveRegistry,i=null;if(A)for(let n=0;n<A.length;n++){let o=A[n];_J(e,o.selectors,!1)&&(i??=[],Al(o)?i.unshift(o):i.push(o))}return i}function J1A(t,e,A,i,n,o){let r=Wl(t,e);T1A(e[Uo],r,o,t.value,A,i,n)}function T1A(t,e,A,i,n,o,r){if(o==null)t.removeAttribute(e,n,A);else{let s=r==null?nI(o):r(o,i||"",n);t.setAttribute(e,n,s,A)}}function z1A(t,e,A,i,n,o){let r=o[e];if(r!==null)for(let s=0;s<r.length;s+=2){let a=r[s],c=r[s+1];Tv(i,A,a,c)}}function HJ(t,e,A){return(t===null||Al(t))&&(A=F0A(A[e.index])),A[Uo]}function H1A(t,e){let A=t[rI],i=A?A.get(Xs,null):null;i&&i.handleError(e)}function rb(t,e,A,i,n){let o=t.inputs?.[i],r=t.hostDirectiveInputs?.[i],s=!1;if(r)for(let a=0;a<r.length;a+=2){let c=r[a],l=r[a+1],I=e.data[c];Tv(I,A[c],l,n),s=!0}if(o)for(let a of o){let c=A[a],l=e.data[a];Tv(l,c,i,n),s=!0}return s}function O1A(t,e){let A=jl(e,t),i=A[gi];P1A(i,A);let n=A[Zl];n!==null&&A[Dd]===null&&(A[Dd]=mJ(n,A[rI])),uo(18),sb(i,A,A[vr]),uo(19,A[vr])}function P1A(t,e){for(let A=e.length;A<t.blueprint.length;A++)e.push(t.blueprint[A])}function sb(t,e,A){J9(e);try{let i=t.viewQuery;i!==null&&xv(1,i,A);let n=t.template;n!==null&&zJ(t,e,n,1,A),t.firstCreatePass&&(t.firstCreatePass=!1),e[e0]?.finishViewCreation(t),t.staticContentQueries&&pJ(t,e),t.staticViewQueries&&xv(2,t.viewQuery,A);let o=t.components;o!==null&&j1A(e,o)}catch(i){throw t.firstCreatePass&&(t.incompleteFirstPass=!0,t.firstCreatePass=!1),i}finally{e[Vt]&=-5,T9()}}function j1A(t,e){for(let A=0;A<e.length;A++)O1A(t,e[A])}function dQ(t,e,A,i){let n=vi(null);try{let o=e.tView,s=t[Vt]&4096?4096:16,a=tb(t,o,A,s,null,e,null,null,i?.injector??null,i?.embeddedViewInjector??null,i?.dehydratedView??null),c=t[e.index];a[sI]=c;let l=t[e0];return l!==null&&(a[e0]=l.createEmbeddedView(o)),sb(o,a,A),a}finally{vi(n)}}function bd(t,e){return!e||e.firstChild===null||lJ(t)}var q1A;function ab(t,e){return q1A(t,e)}var Vl=function(t){return t[t.Important=1]="Important",t[t.DashCase=2]="DashCase",t}(Vl||{});function cb(t){return(t.flags&32)===32}function ud(t,e,A,i,n){if(i!=null){let o,r=!1;n0(i)?o=i:C2(i)&&(r=!0,i=i[Zl]);let s=Pl(i);t===0&&A!==null?n==null?UJ(e,A,s):_m(e,A,s,n||null,!0):t===1&&A!==null?_m(e,A,s,n||null,!0):t===2?b1A(e,s,r):t===3&&e.destroyNode(s),o!=null&&nIA(e,t,o,A,n)}}function V1A(t,e){OJ(t,e),e[Zl]=null,e[Aa]=null}function Z1A(t,e,A,i,n,o){i[Zl]=n,i[Aa]=e,Bp(t,i,A,1,n,o)}function OJ(t,e){e[A0].changeDetectionScheduler?.notify(9),Bp(t,e,e[Uo],2,null,null)}function W1A(t){let e=t[$h];if(!e)return ov(t[gi],t);for(;e;){let A=null;if(C2(e))A=e[$h];else{let i=e[Is];i&&(A=i)}if(!A){for(;e&&!e[$c]&&e!==t;)C2(e)&&ov(e[gi],e),e=e[Cs];e===null&&(e=t),C2(e)&&ov(e[gi],e),A=e&&e[$c]}e=A}}function lb(t,e){let A=t[yd],i=A.indexOf(e);A.splice(i,1)}function Cp(t,e){if(Ld(e))return;let A=e[Uo];A.destroyNode&&Bp(t,e,A,3,null,null),W1A(e)}function ov(t,e){if(Ld(e))return;let A=vi(null);try{e[Vt]&=-129,e[Vt]|=256,e[Bc]&&Gh(e[Bc]),$1A(t,e),X1A(t,e),e[gi].type===1&&e[Uo].destroy();let i=e[sI];if(i!==null&&n0(e[Cs])){i!==e[Cs]&&lb(i,e);let n=e[e0];n!==null&&n.detachView(t)}Sv(e)}finally{vi(A)}}function X1A(t,e){let A=t.cleanup,i=e[ym];if(A!==null)for(let r=0;r<A.length-1;r+=2)if(typeof A[r]=="string"){let s=A[r+3];s>=0?i[s]():i[-s].unsubscribe(),r+=2}else{let s=i[A[r+1]];A[r].call(s)}i!==null&&(e[ym]=null);let n=e[I2];if(n!==null){e[I2]=null;for(let r=0;r<n.length;r++){let s=n[r];s()}}let o=e[aI];if(o!==null){e[aI]=null;for(let r of o)r.destroy()}}function $1A(t,e){let A;if(t!=null&&(A=t.destroyHooks)!=null)for(let i=0;i<A.length;i+=2){let n=e[A[i]];if(!(n instanceof II)){let o=A[i+1];if(Array.isArray(o))for(let r=0;r<o.length;r+=2){let s=n[o[r]],a=o[r+1];uo(4,s,a);try{a.call(s)}finally{uo(5,s,a)}}else{uo(4,n,o);try{o.call(n)}finally{uo(5,n,o)}}}}}function PJ(t,e,A){return AIA(t,e.parent,A)}function AIA(t,e,A){let i=e;for(;i!==null&&i.type&168;)e=i,i=e.parent;if(i===null)return A[Zl];if(Rd(i)){let{encapsulation:n}=t.data[i.directiveStart+i.componentOffset];if(n===ql.None||n===ql.Emulated)return null}return Wl(i,A)}function jJ(t,e,A){return tIA(t,e,A)}function eIA(t,e,A){return t.type&40?Wl(t,A):null}var tIA=eIA,_K;function dp(t,e,A,i){let n=PJ(t,i,e),o=e[Uo],r=i.parent||e[Aa],s=jJ(r,i,e);if(n!=null)if(Array.isArray(A))for(let a=0;a<A.length;a++)NK(o,n,A[a],s,!1);else NK(o,n,A,s,!1);_K!==void 0&&_K(o,i,e,A,n)}function Vh(t,e){if(e!==null){let A=e.type;if(A&3)return Wl(e,t);if(A&4)return zv(-1,t[e.index]);if(A&8){let i=e.child;if(i!==null)return Vh(t,i);{let n=t[e.index];return n0(n)?zv(-1,n):Pl(n)}}else{if(A&128)return Vh(t,e.next);if(A&32)return ab(e,t)()||Pl(t[e.index]);{let i=qJ(t,e);if(i!==null){if(Array.isArray(i))return i[0];let n=lI(t[_a]);return Vh(n,i)}else return Vh(t,e.next)}}}return null}function qJ(t,e){if(e!==null){let i=t[_a][Aa],n=e.projection;return i.projection[n]}return null}function zv(t,e){let A=Is+t+1;if(A<e.length){let i=e[A],n=i[gi].firstChild;if(n!==null)return Vh(i,n)}return e[cI]}function gb(t,e,A,i,n,o,r){for(;A!=null;){if(A.type===128){A=A.next;continue}let s=i[A.index],a=A.type;if(r&&e===0&&(s&&_d(Pl(s),i),A.flags|=2),!cb(A))if(a&8)gb(t,e,A.child,i,n,o,!1),ud(e,t,n,s,o);else if(a&32){let c=ab(A,i),l;for(;l=c();)ud(e,t,n,l,o);ud(e,t,n,s,o)}else a&16?VJ(t,e,i,A,n,o):ud(e,t,n,s,o);A=r?A.projectionNext:A.next}}function Bp(t,e,A,i,n,o){gb(A,i,t.firstChild,e,n,o,!1)}function iIA(t,e,A){let i=e[Uo],n=PJ(t,A,e),o=A.parent||e[Aa],r=jJ(o,A,e);VJ(i,0,e,A,n,r)}function VJ(t,e,A,i,n,o){let r=A[_a],a=r[Aa].projection[i.projection];if(Array.isArray(a))for(let c=0;c<a.length;c++){let l=a[c];ud(e,t,n,l,o)}else{let c=a,l=r[Cs];lJ(i)&&(c.flags|=128),gb(t,e,c,l,n,o,!0)}}function nIA(t,e,A,i,n){let o=A[cI],r=Pl(A);o!==r&&ud(e,t,i,o,n);for(let s=Is;s<A.length;s++){let a=A[s];Bp(a[gi],a,t,e,i,o)}}function oIA(t,e,A,i,n){if(e)n?t.addClass(A,i):t.removeClass(A,i);else{let o=i.indexOf("-")===-1?void 0:Vl.DashCase;n==null?t.removeStyle(A,i,o):(typeof n=="string"&&n.endsWith("!important")&&(n=n.slice(0,-10),o|=Vl.Important),t.setStyle(A,i,n,o))}}function Gm(t,e,A,i,n=!1){for(;A!==null;){if(A.type===128){A=n?A.projectionNext:A.next;continue}let o=e[A.index];o!==null&&i.push(Pl(o)),n0(o)&&rIA(o,i);let r=A.type;if(r&8)Gm(t,e,A.child,i);else if(r&32){let s=ab(A,e),a;for(;a=s();)i.push(a)}else if(r&16){let s=qJ(e,A);if(Array.isArray(s))i.push(...s);else{let a=lI(e[_a]);Gm(a[gi],a,s,i,!0)}}A=n?A.projectionNext:A.next}return i}function rIA(t,e){for(let A=Is;A<t.length;A++){let i=t[A],n=i[gi].firstChild;n!==null&&Gm(i[gi],i,n,e)}t[cI]!==t[Zl]&&e.push(t[cI])}function ZJ(t){if(t[fd]!==null){for(let e of t[fd])e.impl.addSequence(e);t[fd].length=0}}var WJ=[];function sIA(t){return t[Bc]??aIA(t)}function aIA(t){let e=WJ.pop()??Object.create(lIA);return e.lView=t,e}function cIA(t){t.lView[Bc]!==t&&(t.lView=null,WJ.push(t))}var lIA=Ne(nA({},id),{consumerIsAlwaysLive:!0,kind:"template",consumerMarkedDirty:t=>{xd(t.lView)},consumerOnSignalRead(){this.lView[Bc]=this}});function gIA(t){let e=t[Bc]??Object.create(IIA);return e.lView=t,e}var IIA=Ne(nA({},id),{consumerIsAlwaysLive:!0,kind:"template",consumerMarkedDirty:t=>{let e=lI(t.lView);for(;e&&!XJ(e[gi]);)e=lI(e);e&&xY(e)},consumerOnSignalRead(){this.lView[Bc]=this}});function XJ(t){return t.type!==2}function $J(t){if(t[aI]===null)return;let e=!0;for(;e;){let A=!1;for(let i of t[aI])i.dirty&&(A=!0,i.zone===null||Zone.current===i.zone?i.run():i.zone.run(()=>i.run()));e=A&&!!(t[Vt]&8192)}}var CIA=100;function AT(t,e=!0,A=0){let n=t[A0].rendererFactory,o=!1;o||n.begin?.();try{dIA(t,A)}catch(r){throw e&&H1A(t,r),r}finally{o||n.end?.()}}function dIA(t,e){let A=GY();try{Mm(!0),Hv(t,e);let i=0;for(;ip(t);){if(i===CIA)throw new ZA(103,!1);i++,Hv(t,1)}}finally{Mm(A)}}function BIA(t,e,A,i){if(Ld(e))return;let n=e[Vt],o=!1,r=!1;J9(e);let s=!0,a=null,c=null;o||(XJ(t)?(c=sIA(e),a=_h(c)):R7()===null?(s=!1,c=gIA(e),a=_h(c)):e[Bc]&&(Gh(e[Bc]),e[Bc]=null));try{LY(e),q0A(t.bindingStartIndex),A!==null&&zJ(t,e,A,2,i);let l=(n&3)===3;if(!o)if(l){let d=t.preOrderCheckHooks;d!==null&&Em(e,d,null)}else{let d=t.preOrderHooks;d!==null&&hm(e,d,0,null),iv(e,0)}if(r||EIA(e),$J(e),eT(e,0),t.contentQueries!==null&&pJ(t,e),!o)if(l){let d=t.contentCheckHooks;d!==null&&Em(e,d)}else{let d=t.contentHooks;d!==null&&hm(e,d,1),iv(e,1)}QIA(t,e);let I=t.components;I!==null&&iT(e,I,0);let C=t.viewQuery;if(C!==null&&xv(2,C,i),!o)if(l){let d=t.viewCheckHooks;d!==null&&Em(e,d)}else{let d=t.viewHooks;d!==null&&hm(e,d,2),iv(e,2)}if(t.firstUpdatePass===!0&&(t.firstUpdatePass=!1),e[tv]){for(let d of e[tv])d();e[tv]=null}o||(ZJ(e),e[Vt]&=-73)}catch(l){throw o||xd(e),l}finally{c!==null&&(Lf(c,a),s&&cIA(c)),T9()}}function eT(t,e){for(let A=CJ(t);A!==null;A=dJ(A))for(let i=Is;i<A.length;i++){let n=A[i];tT(n,e)}}function EIA(t){for(let e=CJ(t);e!==null;e=dJ(e)){if(!(e[Vt]&2))continue;let A=e[yd];for(let i=0;i<A.length;i++){let n=A[i];xY(n)}}}function hIA(t,e,A){uo(18);let i=jl(e,t);tT(i,A),uo(19,i[vr])}function tT(t,e){L9(t)&&Hv(t,e)}function Hv(t,e){let i=t[gi],n=t[Vt],o=t[Bc],r=!!(e===0&&n&16);if(r||=!!(n&64&&e===0),r||=!!(n&1024),r||=!!(o?.dirty&&xf(o)),r||=!1,o&&(o.dirty=!1),t[Vt]&=-9217,r)BIA(i,t,i.template,t[vr]);else if(n&8192){$J(t),eT(t,1);let s=i.components;s!==null&&iT(t,s,1),ZJ(t)}}function iT(t,e,A){for(let i=0;i<e.length;i++)hIA(t,e[i],A)}function QIA(t,e){let A=t.hostBindingOpCodes;if(A!==null)try{for(let i=0;i<A.length;i++){let n=A[i];if(n<0)gI(~n);else{let o=n,r=A[++i],s=A[++i];Z0A(r,o);let a=e[o];uo(24,a),s(2,a),uo(25,a)}}}finally{gI(-1)}}function Ib(t,e){let A=GY()?64:1088;for(t[A0].changeDetectionScheduler?.notify(e);t;){t[Vt]|=A;let i=lI(t);if(bm(t)&&!i)return t;t=i}return null}function nT(t,e,A,i){return[t,!0,0,e,null,i,null,A,null,null]}function oT(t,e){let A=Is+e;if(A<t.length)return t[A]}function BQ(t,e,A,i=!0){let n=e[gi];if(uIA(n,e,t,A),i){let r=zv(A,t),s=e[Uo],a=s.parentNode(t[cI]);a!==null&&Z1A(n,t[Aa],s,e,a,r)}let o=e[Dd];o!==null&&o.firstChild!==null&&(o.firstChild=null)}function rT(t,e){let A=tQ(t,e);return A!==void 0&&Cp(A[gi],A),A}function tQ(t,e){if(t.length<=Is)return;let A=Is+e,i=t[A];if(i){let n=i[sI];n!==null&&n!==t&&lb(n,i),e>0&&(t[A-1][$c]=i[$c]);let o=wm(t,Is+e);V1A(i[gi],i);let r=o[e0];r!==null&&r.detachView(o[gi]),i[Cs]=null,i[$c]=null,i[Vt]&=-129}return i}function uIA(t,e,A,i){let n=Is+i,o=A.length;i>0&&(A[n-1][$c]=e),i<o-Is?(e[$c]=A[n],BY(A,Is+i,e)):(A.push(e),e[$c]=null),e[Cs]=A;let r=e[sI];r!==null&&A!==r&&sT(r,e);let s=e[e0];s!==null&&s.insertView(t),pv(e),e[Vt]|=128}function sT(t,e){let A=t[yd],i=e[Cs];if(C2(i))t[Vt]|=2;else{let n=i[Cs][_a];e[_a]!==n&&(t[Vt]|=2)}A===null?t[yd]=[e]:A.push(e)}var iQ=class{_lView;_cdRefInjectingView;notifyErrorHandler;_appRef=null;_attachedToViewContainer=!1;get rootNodes(){let e=this._lView,A=e[gi];return Gm(A,e,A.firstChild,[])}constructor(e,A,i=!0){this._lView=e,this._cdRefInjectingView=A,this.notifyErrorHandler=i}get context(){return this._lView[vr]}set context(e){this._lView[vr]=e}get destroyed(){return Ld(this._lView)}destroy(){if(this._appRef)this._appRef.detachView(this);else if(this._attachedToViewContainer){let e=this._lView[Cs];if(n0(e)){let A=e[vm],i=A?A.indexOf(this):-1;i>-1&&(tQ(e,i),wm(A,i))}this._attachedToViewContainer=!1}Cp(this._lView[gi],this._lView)}onDestroy(e){FY(this._lView,e)}markForCheck(){Ib(this._cdRefInjectingView||this._lView,4)}detach(){this._lView[Vt]&=-129}reattach(){pv(this._lView),this._lView[Vt]|=128}detectChanges(){this._lView[Vt]|=1024,AT(this._lView,this.notifyErrorHandler)}checkNoChanges(){}attachToViewContainerRef(){if(this._appRef)throw new ZA(902,!1);this._attachedToViewContainer=!0}detachFromAppRef(){this._appRef=null;let e=bm(this._lView),A=this._lView[sI];A!==null&&!e&&lb(A,this._lView),OJ(this._lView[gi],this._lView)}attachToAppRef(e){if(this._attachedToViewContainer)throw new ZA(902,!1);this._appRef=e;let A=bm(this._lView),i=this._lView[sI];i!==null&&!A&&sT(i,this._lView),pv(this._lView)}};var vn=(()=>{class t{static __NG_ELEMENT_ID__=pIA}return t})(),fIA=vn,mIA=class extends fIA{_declarationLView;_declarationTContainer;elementRef;constructor(e,A,i){super(),this._declarationLView=e,this._declarationTContainer=A,this.elementRef=i}get ssrId(){return this._declarationTContainer.tView?.ssrId||null}createEmbeddedView(e,A){return this.createEmbeddedViewImpl(e,A)}createEmbeddedViewImpl(e,A,i){let n=dQ(this._declarationLView,this._declarationTContainer,e,{embeddedViewInjector:A,dehydratedView:i});return new iQ(n)}};function pIA(){return Ep(Xr(),Ut())}function Ep(t,e){return t.type&4?new mIA(e,t,Nd(t,e)):null}function EQ(t,e,A,i,n){let o=t.data[e];if(o===null)o=wIA(t,e,A,i,n),V0A()&&(o.flags|=32);else if(o.type&64){o.type=A,o.value=i,o.attrs=n;let r=O0A();o.injectorIndex=r===null?-1:r.injectorIndex}return QI(o,!0),o}function wIA(t,e,A,i,n){let o=_Y(),r=_9(),s=r?o:o&&o.parent,a=t.data[e]=yIA(t,s,A,e,i,n);return DIA(t,a,o,r),a}function DIA(t,e,A,i){t.firstChild===null&&(t.firstChild=e),A!==null&&(i?A.child==null&&e.parent!==null&&(A.child=e):A.next===null&&(A.next=e,e.prev=A))}function yIA(t,e,A,i,n,o){let r=e?e.injectorIndex:-1,s=0;return NY()&&(s|=128),{type:A,index:i,insertBeforeIndex:null,injectorIndex:r,directiveStart:-1,directiveEnd:-1,directiveStylingLast:-1,componentOffset:-1,propertyBindings:null,flags:s,providerIndexes:0,value:n,attrs:o,mergedAttrs:null,localNames:null,initialInputs:null,inputs:null,hostDirectiveInputs:null,outputs:null,hostDirectiveOutputs:null,directiveToIndex:null,tView:null,next:null,prev:null,projectionNext:null,child:null,parent:e,projection:null,styles:null,stylesWithoutHost:null,residualStyles:void 0,classes:null,classesWithoutHost:null,residualClasses:void 0,classBindings:0,styleBindings:0}}var Kte=new RegExp(`^(\\d+)*(${_2A}|${N2A})*(.*)`);var vIA=()=>null;function Md(t,e){return vIA(t,e)}var bIA=class{},aT=class{},Ov=class{resolveComponentFactory(e){throw Error(`No component factory found for ${Zs(e)}.`)}},hp=class{static NULL=new Ov},ds=class{},Gi=(()=>{class t{destroyNode=null;static __NG_ELEMENT_ID__=()=>MIA()}return t})();function MIA(){let t=Ut(),e=Xr(),A=jl(e.index,t);return(C2(A)?A:t)[Uo]}var kIA=(()=>{class t{static \u0275prov=SA({token:t,providedIn:"root",factory:()=>null})}return t})();var rv={},Pv=class{injector;parentInjector;constructor(e,A){this.injector=e,this.parentInjector=A}get(e,A,i){i=Wm(i);let n=this.injector.get(e,rv,i);return n!==rv||A===rv?n:this.parentInjector.get(e,A,i)}};function jv(t,e,A){let i=A?t.styles:null,n=A?t.classes:null,o=0;if(e!==null)for(let r=0;r<e.length;r++){let s=e[r];if(typeof s=="number")o=s;else if(o==1)n=dv(n,s);else if(o==2){let a=s,c=e[++r];i=dv(i,a+": "+c+";")}}A?t.styles=i:t.stylesWithoutHost=i,A?t.classes=n:t.classesWithoutHost=n}function zA(t,e=_i.Default){let A=Ut();if(A===null)return he(t,e);let i=Xr();return XY(i,A,Wr(t),e)}function cT(){let t="invalid";throw new Error(t)}function Cb(t,e,A,i,n){let o=i===null?null:{"":-1},r=n(t,A);if(r!==null){let s,a=null,c=null,l=RIA(r);l===null?s=r:[s,a,c]=l,FIA(t,e,A,s,o,a,c)}o!==null&&i!==null&&SIA(A,i,o)}function SIA(t,e,A){let i=t.localNames=[];for(let n=0;n<e.length;n+=2){let o=A[e[n+1]];if(o==null)throw new ZA(-301,!1);i.push(e[n],o)}}function RIA(t){let e=null,A=!1;for(let r=0;r<t.length;r++){let s=t[r];if(r===0&&Al(s)&&(e=s),s.findHostDirectiveDefs!==null){A=!0;break}}if(!A)return null;let i=null,n=null,o=null;for(let r of t)r.findHostDirectiveDefs!==null&&(i??=[],n??=new Map,o??=new Map,LIA(r,i,o,n)),r===e&&(i??=[],i.push(r));return i!==null?(i.push(...e===null?t:t.slice(1)),[i,n,o]):null}function LIA(t,e,A,i){let n=e.length;t.findHostDirectiveDefs(t,e,i),A.set(t,[n,e.length-1])}function xIA(t,e,A){e.componentOffset=A,(t.components??=[]).push(e.index)}function FIA(t,e,A,i,n,o,r){let s=i.length,a=!1;for(let C=0;C<s;C++){let d=i[C];!a&&Al(d)&&(a=!0,xIA(t,A,C)),vv(Lm(A,e),t,d.type)}YIA(A,t.data.length,s);for(let C=0;C<s;C++){let d=i[C];d.providersResolver&&d.providersResolver(d)}let c=!1,l=!1,I=JJ(t,e,s,null);s>0&&(A.directiveToIndex=new Map);for(let C=0;C<s;C++){let d=i[C];if(A.mergedAttrs=vd(A.mergedAttrs,d.hostAttrs),_IA(t,A,e,I,d),KIA(I,d,n),r!==null&&r.has(d)){let[E,Q]=r.get(d);A.directiveToIndex.set(d.type,[I,E+A.directiveStart,Q+A.directiveStart])}else(o===null||!o.has(d))&&A.directiveToIndex.set(d.type,I);d.contentQueries!==null&&(A.flags|=4),(d.hostBindings!==null||d.hostAttrs!==null||d.hostVars!==0)&&(A.flags|=64);let B=d.type.prototype;!c&&(B.ngOnChanges||B.ngOnInit||B.ngDoCheck)&&((t.preOrderHooks??=[]).push(A.index),c=!0),!l&&(B.ngOnChanges||B.ngDoCheck)&&((t.preOrderCheckHooks??=[]).push(A.index),l=!0),I++}NIA(t,A,o)}function NIA(t,e,A){for(let i=e.directiveStart;i<e.directiveEnd;i++){let n=t.data[i];if(A===null||!A.has(n))GK(0,e,n,i),GK(1,e,n,i),KK(e,i,!1);else{let o=A.get(n);UK(0,e,o,i),UK(1,e,o,i),KK(e,i,!0)}}}function GK(t,e,A,i){let n=t===0?A.inputs:A.outputs;for(let o in n)if(n.hasOwnProperty(o)){let r;t===0?r=e.inputs??={}:r=e.outputs??={},r[o]??=[],r[o].push(i),lT(e,o)}}function UK(t,e,A,i){let n=t===0?A.inputs:A.outputs;for(let o in n)if(n.hasOwnProperty(o)){let r=n[o],s;t===0?s=e.hostDirectiveInputs??={}:s=e.hostDirectiveOutputs??={},s[r]??=[],s[r].push(i,o),lT(e,r)}}function lT(t,e){e==="class"?t.flags|=8:e==="style"&&(t.flags|=16)}function KK(t,e,A){let{attrs:i,inputs:n,hostDirectiveInputs:o}=t;if(i===null||!A&&n===null||A&&o===null||Ab(t)){t.initialInputs??=[],t.initialInputs.push(null);return}let r=null,s=0;for(;s<i.length;){let a=i[s];if(a===0){s+=4;continue}else if(a===5){s+=2;continue}else if(typeof a=="number")break;if(!A&&n.hasOwnProperty(a)){let c=n[a];for(let l of c)if(l===e){r??=[],r.push(a,i[s+1]);break}}else if(A&&o.hasOwnProperty(a)){let c=o[a];for(let l=0;l<c.length;l+=2)if(c[l]===e){r??=[],r.push(c[l+1],i[s+1]);break}}s+=2}t.initialInputs??=[],t.initialInputs.push(r)}function _IA(t,e,A,i,n){t.data[i]=n;let o=n.factory||(n.factory=oI(n.type,!0)),r=new II(o,Al(n),zA);t.blueprint[i]=r,A[i]=r,GIA(t,e,i,JJ(t,A,n.hostVars,Ya),n)}function GIA(t,e,A,i,n){let o=n.hostBindings;if(o){let r=t.hostBindingOpCodes;r===null&&(r=t.hostBindingOpCodes=[]);let s=~e.index;UIA(r)!=s&&r.push(s),r.push(A,i,o)}}function UIA(t){let e=t.length;for(;e>0;){let A=t[--e];if(typeof A=="number"&&A<0)return A}return 0}function KIA(t,e,A){if(A){if(e.exportAs)for(let i=0;i<e.exportAs.length;i++)A[e.exportAs[i]]=t;Al(e)&&(A[""]=t)}}function YIA(t,e,A){t.flags|=1,t.directiveStart=e,t.directiveEnd=e+A,t.providerIndexes=e}function gT(t,e,A,i,n,o,r,s){let a=e.consts,c=B2(a,r),l=EQ(e,t,2,i,c);return o&&Cb(e,A,l,B2(a,s),n),l.mergedAttrs=vd(l.mergedAttrs,l.attrs),l.attrs!==null&&jv(l,l.attrs,!1),l.mergedAttrs!==null&&jv(l,l.mergedAttrs,!0),e.queries!==null&&e.queries.elementStart(e,l),l}function IT(t,e){z9(t,e),k9(e)&&t.queries.elementEnd(e)}var Um=class extends hp{ngModule;constructor(e){super(),this.ngModule=e}resolveComponentFactory(e){let A=d2(e);return new dI(A,this.ngModule)}};function JIA(t){return Object.keys(t).map(e=>{let[A,i,n]=t[e],o={propName:A,templateName:e,isSignal:(i&lp.SignalBased)!==0};return n&&(o.transform=n),o})}function TIA(t){return Object.keys(t).map(e=>({propName:t[e],templateName:e}))}function zIA(t,e,A){let i=e instanceof Br?e:e?.injector;return i&&t.getStandaloneInjector!==null&&(i=t.getStandaloneInjector(i)||i),i?new Pv(A,i):A}function HIA(t){let e=t.get(ds,null);if(e===null)throw new ZA(407,!1);let A=t.get(kIA,null),i=t.get(CI,null);return{rendererFactory:e,sanitizer:A,changeDetectionScheduler:i}}function OIA(t,e){let A=(t.selectors[0][0]||"div").toLowerCase();return GJ(e,A,A==="svg"?SY:A==="math"?x0A:null)}var dI=class extends aT{componentDef;ngModule;selector;componentType;ngContentSelectors;isBoundToModule;cachedInputs=null;cachedOutputs=null;get inputs(){return this.cachedInputs??=JIA(this.componentDef.inputs),this.cachedInputs}get outputs(){return this.cachedOutputs??=TIA(this.componentDef.outputs),this.cachedOutputs}constructor(e,A){super(),this.componentDef=e,this.ngModule=A,this.componentType=e.type,this.selector=p1A(e.selectors),this.ngContentSelectors=e.ngContentSelectors??[],this.isBoundToModule=!!A}create(e,A,i,n){uo(22);let o=vi(null);try{let r=this.componentDef,s=i?["ng-version","19.2.9"]:w1A(this.componentDef.selectors[0]),a=eb(0,null,null,1,0,null,null,null,null,[s],null),c=zIA(r,n||this.ngModule,e),l=HIA(c),I=l.rendererFactory.createRenderer(null,r),C=i?x1A(I,i,r.encapsulation,c):OIA(r,I),d=tb(null,a,null,512|YJ(r),null,null,l,I,c,null,mJ(C,c,!0));d[br]=C,J9(d);let B=null;try{let E=gT(br,a,d,"#host",()=>[this.componentDef],!0,0);C&&(KJ(I,C,E),_d(C,d)),gp(a,d,E),X9(a,E,d),IT(a,E),A!==void 0&&PIA(E,this.ngContentSelectors,A),B=jl(E.index,d),d[vr]=B[vr],sb(a,d,null)}catch(E){throw B!==null&&Sv(B),Sv(d),E}finally{uo(23),T9()}return new qv(this.componentType,d)}finally{vi(o)}}},qv=class extends bIA{_rootLView;instance;hostView;changeDetectorRef;componentType;location;previousInputValues=null;_tNode;constructor(e,A){super(),this._rootLView=A,this._tNode=S9(A[gi],br),this.location=Nd(this._tNode,A),this.instance=jl(this._tNode.index,A)[vr],this.hostView=this.changeDetectorRef=new iQ(A,void 0,!1),this.componentType=e}setInput(e,A){let i=this._tNode;if(this.previousInputValues??=new Map,this.previousInputValues.has(e)&&Object.is(this.previousInputValues.get(e),A))return;let n=this._rootLView,o=rb(i,n[gi],n,e,A);this.previousInputValues.set(e,A);let r=jl(i.index,n);Ib(r,1)}get injector(){return new iI(this._tNode,this._rootLView)}destroy(){this.hostView.destroy()}onDestroy(e){this.hostView.onDestroy(e)}};function PIA(t,e,A){let i=t.projection=[];for(let n=0;n<e.length;n++){let o=A[n];i.push(o!=null&&o.length?Array.from(o):null)}}var Un=(()=>{class t{static __NG_ELEMENT_ID__=jIA}return t})();function jIA(){let t=Xr();return dT(t,Ut())}var qIA=Un,CT=class extends qIA{_lContainer;_hostTNode;_hostLView;constructor(e,A,i){super(),this._lContainer=e,this._hostTNode=A,this._hostLView=i}get element(){return Nd(this._hostTNode,this._hostLView)}get injector(){return new iI(this._hostTNode,this._hostLView)}get parentInjector(){let e=H9(this._hostTNode,this._hostLView);if(PY(e)){let A=Sm(e,this._hostLView),i=km(e),n=A[gi].data[i+8];return new iI(n,A)}else return new iI(null,this._hostLView)}clear(){for(;this.length>0;)this.remove(this.length-1)}get(e){let A=YK(this._lContainer);return A!==null&&A[e]||null}get length(){return this._lContainer.length-Is}createEmbeddedView(e,A,i){let n,o;typeof i=="number"?n=i:i!=null&&(n=i.index,o=i.injector);let r=Md(this._lContainer,e.ssrId),s=e.createEmbeddedViewImpl(A||{},o,r);return this.insertImpl(s,n,bd(this._hostTNode,r)),s}createComponent(e,A,i,n,o){let r=e&&!k0A(e),s;if(r)s=A;else{let B=A||{};s=B.index,i=B.injector,n=B.projectableNodes,o=B.environmentInjector||B.ngModuleRef}let a=r?e:new dI(d2(e)),c=i||this.parentInjector;if(!o&&a.ngModule==null){let E=(r?c:this.parentInjector).get(Br,null);E&&(o=E)}let l=d2(a.componentType??{}),I=Md(this._lContainer,l?.id??null),C=I?.firstChild??null,d=a.create(c,n,C,o);return this.insertImpl(d.hostView,s,bd(this._hostTNode,I)),d}insert(e,A){return this.insertImpl(e,A,!0)}insertImpl(e,A,i){let n=e._lView;if(_0A(n)){let s=this.indexOf(e);if(s!==-1)this.detach(s);else{let a=n[Cs],c=new CT(a,a[Aa],a[Cs]);c.detach(c.indexOf(e))}}let o=this._adjustIndex(A),r=this._lContainer;return BQ(r,n,o,i),e.attachToViewContainerRef(),BY(sv(r),o,e),e}move(e,A){return this.insert(e,A)}indexOf(e){let A=YK(this._lContainer);return A!==null?A.indexOf(e):-1}remove(e){let A=this._adjustIndex(e,-1),i=tQ(this._lContainer,A);i&&(wm(sv(this._lContainer),A),Cp(i[gi],i))}detach(e){let A=this._adjustIndex(e,-1),i=tQ(this._lContainer,A);return i&&wm(sv(this._lContainer),A)!=null?new iQ(i):null}_adjustIndex(e,A=0){return e??this.length+A}};function YK(t){return t[vm]}function sv(t){return t[vm]||(t[vm]=[])}function dT(t,e){let A,i=e[t.index];return n0(i)?A=i:(A=nT(i,e,null,t),e[t.index]=A,ib(e,A)),ZIA(A,e,t,i),new CT(A,t,e)}function VIA(t,e){let A=t[Uo],i=A.createComment(""),n=Wl(e,t),o=A.parentNode(n);return _m(A,o,i,A.nextSibling(n),!1),i}var ZIA=$IA,WIA=()=>!1;function XIA(t,e,A){return WIA(t,e,A)}function $IA(t,e,A,i){if(t[cI])return;let n;A.type&8?n=Pl(i):n=VIA(e,A),t[cI]=n}var Vv=class t{queryList;matches=null;constructor(e){this.queryList=e}clone(){return new t(this.queryList)}setDirty(){this.queryList.setDirty()}},Zv=class t{queries;constructor(e=[]){this.queries=e}createEmbeddedView(e){let A=e.queries;if(A!==null){let i=e.contentQueries!==null?e.contentQueries[0]:A.length,n=[];for(let o=0;o<i;o++){let r=A.getByIndex(o),s=this.queries[r.indexInDeclarationView];n.push(s.clone())}return new t(n)}return null}insertView(e){this.dirtyQueriesWithMatches(e)}detachView(e){this.dirtyQueriesWithMatches(e)}finishViewCreation(e){this.dirtyQueriesWithMatches(e)}dirtyQueriesWithMatches(e){for(let A=0;A<this.queries.length;A++)Bb(e,A).matches!==null&&this.queries[A].setDirty()}},Km=class{flags;read;predicate;constructor(e,A,i=null){this.flags=A,this.read=i,typeof e=="string"?this.predicate=oCA(e):this.predicate=e}},Wv=class t{queries;constructor(e=[]){this.queries=e}elementStart(e,A){for(let i=0;i<this.queries.length;i++)this.queries[i].elementStart(e,A)}elementEnd(e){for(let A=0;A<this.queries.length;A++)this.queries[A].elementEnd(e)}embeddedTView(e){let A=null;for(let i=0;i<this.length;i++){let n=A!==null?A.length:0,o=this.getByIndex(i).embeddedTView(e,n);o&&(o.indexInDeclarationView=i,A!==null?A.push(o):A=[o])}return A!==null?new t(A):null}template(e,A){for(let i=0;i<this.queries.length;i++)this.queries[i].template(e,A)}getByIndex(e){return this.queries[e]}get length(){return this.queries.length}track(e){this.queries.push(e)}},Xv=class t{metadata;matches=null;indexInDeclarationView=-1;crossesNgTemplate=!1;_declarationNodeIndex;_appliesToNextNode=!0;constructor(e,A=-1){this.metadata=e,this._declarationNodeIndex=A}elementStart(e,A){this.isApplyingToNode(A)&&this.matchTNode(e,A)}elementEnd(e){this._declarationNodeIndex===e.index&&(this._appliesToNextNode=!1)}template(e,A){this.elementStart(e,A)}embeddedTView(e,A){return this.isApplyingToNode(e)?(this.crossesNgTemplate=!0,this.addMatch(-e.index,A),new t(this.metadata)):null}isApplyingToNode(e){if(this._appliesToNextNode&&(this.metadata.flags&1)!==1){let A=this._declarationNodeIndex,i=e.parent;for(;i!==null&&i.type&8&&i.index!==A;)i=i.parent;return A===(i!==null?i.index:-1)}return this._appliesToNextNode}matchTNode(e,A){let i=this.metadata.predicate;if(Array.isArray(i))for(let n=0;n<i.length;n++){let o=i[n];this.matchTNodeWithReadOption(e,A,ACA(A,o)),this.matchTNodeWithReadOption(e,A,Qm(A,e,o,!1,!1))}else i===vn?A.type&4&&this.matchTNodeWithReadOption(e,A,-1):this.matchTNodeWithReadOption(e,A,Qm(A,e,i,!1,!1))}matchTNodeWithReadOption(e,A,i){if(i!==null){let n=this.metadata.read;if(n!==null)if(n===te||n===Un||n===vn&&A.type&4)this.addMatch(A.index,-2);else{let o=Qm(A,e,n,!1,!1);o!==null&&this.addMatch(A.index,o)}else this.addMatch(A.index,i)}}addMatch(e,A){this.matches===null?this.matches=[e,A]:this.matches.push(e,A)}};function ACA(t,e){let A=t.localNames;if(A!==null){for(let i=0;i<A.length;i+=2)if(A[i]===e)return A[i+1]}return null}function eCA(t,e){return t.type&11?Nd(t,e):t.type&4?Ep(t,e):null}function tCA(t,e,A,i){return A===-1?eCA(e,t):A===-2?iCA(t,e,i):AQ(t,t[gi],A,e)}function iCA(t,e,A){if(A===te)return Nd(e,t);if(A===vn)return Ep(e,t);if(A===Un)return dT(e,t)}function BT(t,e,A,i){let n=e[e0].queries[i];if(n.matches===null){let o=t.data,r=A.matches,s=[];for(let a=0;r!==null&&a<r.length;a+=2){let c=r[a];if(c<0)s.push(null);else{let l=o[c];s.push(tCA(e,l,r[a+1],A.metadata.read))}}n.matches=s}return n.matches}function $v(t,e,A,i){let n=t.queries.getByIndex(A),o=n.matches;if(o!==null){let r=BT(t,e,n,A);for(let s=0;s<o.length;s+=2){let a=o[s];if(a>0)i.push(r[s/2]);else{let c=o[s+1],l=e[-a];for(let I=Is;I<l.length;I++){let C=l[I];C[sI]===C[Cs]&&$v(C[gi],C,c,i)}if(l[yd]!==null){let I=l[yd];for(let C=0;C<I.length;C++){let d=I[C];$v(d[gi],d,c,i)}}}}}return i}function db(t,e){return t[e0].queries[e].queryList}function ET(t,e,A){let i=new Ec((A&4)===4);return K0A(t,e,i,i.destroy),(e[e0]??=new Zv).queries.push(new Vv(i))-1}function nCA(t,e,A){let i=yo();return i.firstCreatePass&&(QT(i,new Km(t,e,A),-1),(e&2)===2&&(i.staticViewQueries=!0)),ET(i,Ut(),e)}function hT(t,e,A,i){let n=yo();if(n.firstCreatePass){let o=Xr();QT(n,new Km(e,A,i),o.index),rCA(n,t),(A&2)===2&&(n.staticContentQueries=!0)}return ET(n,Ut(),A)}function oCA(t){return t.split(",").map(e=>e.trim())}function QT(t,e,A){t.queries===null&&(t.queries=new Wv),t.queries.track(new Xv(e,A))}function rCA(t,e){let A=t.contentQueries||(t.contentQueries=[]),i=A.length?A[A.length-1]:-1;e!==i&&A.push(t.queries.length-1,e)}function Bb(t,e){return t.queries.getByIndex(e)}function uT(t,e){let A=t[gi],i=Bb(A,e);return i.crossesNgTemplate?$v(A,t,e,[]):BT(A,t,i,e)}function fT(t,e,A){let i,n=_f(()=>{i._dirtyCounter();let o=lCA(i,t);if(e&&o===void 0)throw new ZA(-951,!1);return o});return i=n[js],i._dirtyCounter=Ko(0),i._flatValue=void 0,n}function sCA(t){return fT(!0,!1,t)}function aCA(t){return fT(!0,!0,t)}function cCA(t,e){let A=t[js];A._lView=Ut(),A._queryIndex=e,A._queryList=db(A._lView,e),A._queryList.onDirty(()=>A._dirtyCounter.update(i=>i+1))}function lCA(t,e){let A=t._lView,i=t._queryIndex;if(A===void 0||i===void 0||A[Vt]&4)return e?void 0:xs;let n=db(A,i),o=uT(A,i);return n.reset(o,aJ),e?n.first:n._changesDetected||t._flatValue===void 0?t._flatValue=n.toArray():t._flatValue}function JK(t,e){return sCA(e)}function gCA(t,e){return aCA(e)}var mT=(JK.required=gCA,JK);function ICA(t){let e=[],A=new Map;function i(n){let o=A.get(n);if(!o){let r=t(n);A.set(n,o=r.then(ECA))}return o}return Ym.forEach((n,o)=>{let r=[];n.templateUrl&&r.push(i(n.templateUrl).then(c=>{n.template=c}));let s=typeof n.styles=="string"?[n.styles]:n.styles||[];if(n.styles=s,n.styleUrl&&n.styleUrls?.length)throw new Error("@Component cannot define both `styleUrl` and `styleUrls`. Use `styleUrl` if the component has one stylesheet, or `styleUrls` if it has multiple");if(n.styleUrls?.length){let c=n.styles.length,l=n.styleUrls;n.styleUrls.forEach((I,C)=>{s.push(""),r.push(i(I).then(d=>{s[c+C]=d,l.splice(l.indexOf(I),1),l.length==0&&(n.styleUrls=void 0)}))})}else n.styleUrl&&r.push(i(n.styleUrl).then(c=>{s.push(c),n.styleUrl=void 0}));let a=Promise.all(r).then(()=>hCA(o));e.push(a)}),dCA(),Promise.all(e).then(()=>{})}var Ym=new Map,CCA=new Set;function dCA(){let t=Ym;return Ym=new Map,t}function BCA(){return Ym.size===0}function ECA(t){return typeof t=="string"?t:t.text()}function hCA(t){CCA.delete(t)}var i0=class{},Eb=class{};var Jm=class extends i0{ngModuleType;_parent;_bootstrapComponents=[];_r3Injector;instance;destroyCbs=[];componentFactoryResolver=new Um(this);constructor(e,A,i,n=!0){super(),this.ngModuleType=e,this._parent=A;let o=QY(e);this._bootstrapComponents=FJ(o.bootstrap),this._r3Injector=eJ(e,A,[{provide:i0,useValue:this},{provide:hp,useValue:this.componentFactoryResolver},...i],Zs(e),new Set(["environment"])),n&&this.resolveInjectorInitializers()}resolveInjectorInitializers(){this._r3Injector.resolveInjectorInitializers(),this.instance=this._r3Injector.get(this.ngModuleType)}get injector(){return this._r3Injector}destroy(){let e=this._r3Injector;!e.destroyed&&e.destroy(),this.destroyCbs.forEach(A=>A()),this.destroyCbs=null}onDestroy(e){this.destroyCbs.push(e)}},Tm=class extends Eb{moduleType;constructor(e){super(),this.moduleType=e}create(e){return new Jm(this.moduleType,e,[])}};function QCA(t,e,A){return new Jm(t,e,A,!1)}var A9=class extends i0{injector;componentFactoryResolver=new Um(this);instance=null;constructor(e){super();let A=new Xh([...e.providers,{provide:i0,useValue:this},{provide:hp,useValue:this.componentFactoryResolver}],e.parent||Ap(),e.debugName,new Set(["environment"]));this.injector=A,e.runEnvironmentInitializers&&A.resolveInjectorInitializers()}destroy(){this.injector.destroy()}onDestroy(e){this.injector.onDestroy(e)}};function hQ(t,e,A=null){return new A9({providers:t,parent:e,debugName:A,runEnvironmentInitializers:!0}).injector}var uCA=(()=>{class t{_injector;cachedInjectors=new Map;constructor(A){this._injector=A}getOrCreateStandaloneInjector(A){if(!A.standalone)return null;if(!this.cachedInjectors.has(A)){let i=fY(!1,A.type),n=i.length>0?hQ([i],this._injector,`Standalone[${A.type.name}]`):null;this.cachedInjectors.set(A,n)}return this.cachedInjectors.get(A)}ngOnDestroy(){try{for(let A of this.cachedInjectors.values())A!==null&&A.destroy()}finally{this.cachedInjectors.clear()}}static \u0275prov=SA({token:t,providedIn:"environment",factory:()=>new t(he(Br))})}return t})();function YA(t){return oQ(()=>{let e=pT(t),A=Ne(nA({},e),{decls:t.decls,vars:t.vars,template:t.template,consts:t.consts||null,ngContentSelectors:t.ngContentSelectors,onPush:t.changeDetection===gJ.OnPush,directiveDefs:null,pipeDefs:null,dependencies:e.standalone&&t.dependencies||null,getStandaloneInjector:e.standalone?n=>n.get(uCA).getOrCreateStandaloneInjector(A):null,getExternalStyles:null,signals:t.signals??!1,data:t.data||{},encapsulation:t.encapsulation||ql.Emulated,styles:t.styles||xs,_:null,schemas:t.schemas||null,tView:null,id:""});e.standalone&&s0("NgStandalone"),wT(A);let i=t.dependencies;return A.directiveDefs=TK(i,!1),A.pipeDefs=TK(i,!0),A.id=DCA(A),A})}function fCA(t){return d2(t)||uY(t)}function mCA(t){return t!==null}function ge(t){return oQ(()=>({type:t.type,bootstrap:t.bootstrap||xs,declarations:t.declarations||xs,imports:t.imports||xs,exports:t.exports||xs,transitiveCompileScopes:null,schemas:t.schemas||null,id:t.id||null}))}function pCA(t,e){if(t==null)return Ol;let A={};for(let i in t)if(t.hasOwnProperty(i)){let n=t[i],o,r,s,a;Array.isArray(n)?(s=n[0],o=n[1],r=n[2]??o,a=n[3]||null):(o=n,r=n,s=lp.None,a=null),A[o]=[i,s,a],e[o]=r}return A}function wCA(t){if(t==null)return Ol;let e={};for(let A in t)t.hasOwnProperty(A)&&(e[t[A]]=A);return e}function OA(t){return oQ(()=>{let e=pT(t);return wT(e),e})}function Qp(t){return{type:t.type,name:t.name,factory:null,pure:t.pure!==!1,standalone:t.standalone??!0,onDestroy:t.type.prototype.ngOnDestroy||null}}function pT(t){let e={};return{type:t.type,providersResolver:null,factory:null,hostBindings:t.hostBindings||null,hostVars:t.hostVars||0,hostAttrs:t.hostAttrs||null,contentQueries:t.contentQueries||null,declaredInputs:e,inputConfig:t.inputs||Ol,exportAs:t.exportAs||null,standalone:t.standalone??!0,signals:t.signals===!0,selectors:t.selectors||xs,viewQuery:t.viewQuery||null,features:t.features||null,setInput:null,findHostDirectiveDefs:null,hostDirectives:null,inputs:pCA(t.inputs,e),outputs:wCA(t.outputs),debugInfo:null}}function wT(t){t.features?.forEach(e=>e(t))}function TK(t,e){if(!t)return null;let A=e?h0A:fCA;return()=>(typeof t=="function"?t():t).map(i=>A(i)).filter(mCA)}function DCA(t){let e=0,A=typeof t.consts=="function"?"":t.consts,i=[t.selectors,t.ngContentSelectors,t.hostVars,t.hostAttrs,A,t.vars,t.decls,t.encapsulation,t.standalone,t.signals,t.exportAs,JSON.stringify(t.inputs),JSON.stringify(t.outputs),Object.getOwnPropertyNames(t.type.prototype),!!t.contentQueries,!!t.viewQuery];for(let o of i.join("|"))e=Math.imul(31,e)+o.charCodeAt(0)<<0;return e+=2147483648,"c"+e}function yCA(t){return Object.getPrototypeOf(t.prototype).constructor}function et(t){let e=yCA(t.type),A=!0,i=[t];for(;e;){let n;if(Al(t))n=e.\u0275cmp||e.\u0275dir;else{if(e.\u0275cmp)throw new ZA(903,!1);n=e.\u0275dir}if(n){if(A){i.push(n);let r=t;r.inputs=av(t.inputs),r.declaredInputs=av(t.declaredInputs),r.outputs=av(t.outputs);let s=n.hostBindings;s&&SCA(t,s);let a=n.viewQuery,c=n.contentQueries;if(a&&MCA(t,a),c&&kCA(t,c),vCA(t,n),VgA(t.outputs,n.outputs),Al(n)&&n.data.animation){let l=t.data;l.animation=(l.animation||[]).concat(n.data.animation)}}let o=n.features;if(o)for(let r=0;r<o.length;r++){let s=o[r];s&&s.ngInherit&&s(t),s===et&&(A=!1)}}e=Object.getPrototypeOf(e)}bCA(i)}function vCA(t,e){for(let A in e.inputs){if(!e.inputs.hasOwnProperty(A)||t.inputs.hasOwnProperty(A))continue;let i=e.inputs[A];i!==void 0&&(t.inputs[A]=i,t.declaredInputs[A]=e.declaredInputs[A])}}function bCA(t){let e=0,A=null;for(let i=t.length-1;i>=0;i--){let n=t[i];n.hostVars=e+=n.hostVars,n.hostAttrs=vd(n.hostAttrs,A=vd(A,n.hostAttrs))}}function av(t){return t===Ol?{}:t===xs?[]:t}function MCA(t,e){let A=t.viewQuery;A?t.viewQuery=(i,n)=>{e(i,n),A(i,n)}:t.viewQuery=e}function kCA(t,e){let A=t.contentQueries;A?t.contentQueries=(i,n,o)=>{e(i,n,o),A(i,n,o)}:t.contentQueries=e}function SCA(t,e){let A=t.hostBindings;A?t.hostBindings=(i,n)=>{e(i,n),A(i,n)}:t.hostBindings=e}function DT(t){let e=A=>{let i=Array.isArray(t);A.hostDirectives===null?(A.findHostDirectiveDefs=yT,A.hostDirectives=i?t.map(e9):[t]):i?A.hostDirectives.unshift(...t.map(e9)):A.hostDirectives.unshift(t)};return e.ngInherit=!0,e}function yT(t,e,A){if(t.hostDirectives!==null)for(let i of t.hostDirectives)if(typeof i=="function"){let n=i();for(let o of n)zK(e9(o),e,A)}else zK(i,e,A)}function zK(t,e,A){let i=uY(t.directive);RCA(i.declaredInputs,t.inputs),yT(i,e,A),A.set(i,t),e.push(i)}function e9(t){return typeof t=="function"?{directive:Wr(t),inputs:Ol,outputs:Ol}:{directive:Wr(t.directive),inputs:HK(t.inputs),outputs:HK(t.outputs)}}function HK(t){if(t===void 0||t.length===0)return Ol;let e={};for(let A=0;A<t.length;A+=2)e[t[A]]=t[A+1];return e}function RCA(t,e){for(let A in e)if(e.hasOwnProperty(A)){let i=e[A],n=t[A];t[i]=n}}function vT(t){return hb(t)?Array.isArray(t)||!(t instanceof Map)&&Symbol.iterator in t:!1}function LCA(t,e){if(Array.isArray(t))for(let A=0;A<t.length;A++)e(t[A]);else{let A=t[Symbol.iterator](),i;for(;!(i=A.next()).done;)e(i.value)}}function hb(t){return t!==null&&(typeof t=="function"||typeof t=="object")}function Qb(t,e,A){return t[e]=A}function xCA(t,e){return t[e]}function Ga(t,e,A){let i=t[e];return Object.is(i,A)?!1:(t[e]=A,!0)}function bT(t,e,A,i){let n=Ga(t,e,A);return Ga(t,e+1,i)||n}function FCA(t,e,A,i,n,o,r,s,a){let c=e.consts,l=EQ(e,t,4,r||null,s||null);N9()&&Cb(e,A,l,B2(c,a),ob),l.mergedAttrs=vd(l.mergedAttrs,l.attrs),z9(e,l);let I=l.tView=eb(2,l,i,n,o,e.directiveRegistry,e.pipeRegistry,null,e.schemas,c,null);return e.queries!==null&&(e.queries.template(e,l),I.queries=e.queries.embeddedTView(l)),l}function zm(t,e,A,i,n,o,r,s,a,c){let l=A+br,I=e.firstCreatePass?FCA(l,e,t,i,n,o,r,s,a):e.data[l];QI(I,!1);let C=NCA(e,t,I,A);op()&&dp(e,t,C,I),_d(C,t);let d=nT(C,t,C,I);return t[l]=d,ib(t,d),XIA(d,I,t),tp(I)&&gp(e,t,I),a!=null&&nb(t,I,c),I}function NA(t,e,A,i,n,o,r,s){let a=Ut(),c=yo(),l=B2(c.consts,o);return zm(a,c,t,e,A,i,n,l,r,s),NA}var NCA=_CA;function _CA(t,e,A,i){return rp(!0),e[Uo].createComment("")}var ub=(()=>{class t{log(A){console.log(A)}warn(A){console.warn(A)}static \u0275fac=function(i){return new(i||t)};static \u0275prov=SA({token:t,factory:t.\u0275fac,providedIn:"platform"})}return t})();var fb=new BA(""),QQ=new BA(""),up=(()=>{class t{_ngZone;registry;_isZoneStable=!0;_callbacks=[];taskTrackingZone=null;constructor(A,i,n){this._ngZone=A,this.registry=i,mb||(GCA(n),n.addToWindow(i)),this._watchAngularEvents(),A.run(()=>{this.taskTrackingZone=typeof Zone>"u"?null:Zone.current.get("TaskTrackingZone")})}_watchAngularEvents(){this._ngZone.onUnstable.subscribe({next:()=>{this._isZoneStable=!1}}),this._ngZone.runOutsideAngular(()=>{this._ngZone.onStable.subscribe({next:()=>{de.assertNotInAngularZone(),queueMicrotask(()=>{this._isZoneStable=!0,this._runCallbacksIfReady()})}})})}isStable(){return this._isZoneStable&&!this._ngZone.hasPendingMacrotasks}_runCallbacksIfReady(){if(this.isStable())queueMicrotask(()=>{for(;this._callbacks.length!==0;){let A=this._callbacks.pop();clearTimeout(A.timeoutId),A.doneCb()}});else{let A=this.getPendingTasks();this._callbacks=this._callbacks.filter(i=>i.updateCb&&i.updateCb(A)?(clearTimeout(i.timeoutId),!1):!0)}}getPendingTasks(){return this.taskTrackingZone?this.taskTrackingZone.macroTasks.map(A=>({source:A.source,creationLocation:A.creationLocation,data:A.data})):[]}addCallback(A,i,n){let o=-1;i&&i>0&&(o=setTimeout(()=>{this._callbacks=this._callbacks.filter(r=>r.timeoutId!==o),A()},i)),this._callbacks.push({doneCb:A,timeoutId:o,updateCb:n})}whenStable(A,i,n){if(n&&!this.taskTrackingZone)throw new Error('Task tracking zone is required when passing an update callback to whenStable(). Is "zone.js/plugins/task-tracking" loaded?');this.addCallback(A,i,n),this._runCallbacksIfReady()}registerApplication(A){this.registry.registerApplication(A,this)}unregisterApplication(A){this.registry.unregisterApplication(A)}findProviders(A,i,n){return[]}static \u0275fac=function(i){return new(i||t)(he(de),he(fp),he(QQ))};static \u0275prov=SA({token:t,factory:t.\u0275fac})}return t})(),fp=(()=>{class t{_applications=new Map;registerApplication(A,i){this._applications.set(A,i)}unregisterApplication(A){this._applications.delete(A)}unregisterAllApplications(){this._applications.clear()}getTestability(A){return this._applications.get(A)||null}getAllTestabilities(){return Array.from(this._applications.values())}getAllRootElements(){return Array.from(this._applications.keys())}findTestabilityInTree(A,i=!0){return mb?.findTestabilityInTree(this,A,i)??null}static \u0275fac=function(i){return new(i||t)};static \u0275prov=SA({token:t,factory:t.\u0275fac,providedIn:"platform"})}return t})();function GCA(t){mb=t}var mb,MT=(()=>{class t{static \u0275prov=SA({token:t,providedIn:"root",factory:()=>new t9})}return t})(),t9=class{queuedEffectCount=0;queues=new Map;schedule(e){this.enqueue(e)}remove(e){let A=e.zone,i=this.queues.get(A);i.has(e)&&(i.delete(e),this.queuedEffectCount--)}enqueue(e){let A=e.zone;this.queues.has(A)||this.queues.set(A,new Set);let i=this.queues.get(A);i.has(e)||(this.queuedEffectCount++,i.add(e))}flush(){for(;this.queuedEffectCount>0;)for(let[e,A]of this.queues)e===null?this.flushQueue(A):e.run(()=>this.flushQueue(A))}flushQueue(e){for(let A of e)e.delete(A),this.queuedEffectCount--,A.run()}};function u2(t){return!!t&&typeof t.then=="function"}function pb(t){return!!t&&typeof t.subscribe=="function"}var kT=new BA("");function wb(t){return aQ([{provide:kT,multi:!0,useValue:t}])}var ST=(()=>{class t{resolve;reject;initialized=!1;done=!1;donePromise=new Promise((A,i)=>{this.resolve=A,this.reject=i});appInits=m(kT,{optional:!0})??[];injector=m(Dt);constructor(){}runInitializers(){if(this.initialized)return;let A=[];for(let n of this.appInits){let o=$s(this.injector,n);if(u2(o))A.push(o);else if(pb(o)){let r=new Promise((s,a)=>{o.subscribe({complete:s,error:a})});A.push(r)}}let i=()=>{this.done=!0,this.resolve()};Promise.all(A).then(()=>{i()}).catch(n=>{this.reject(n)}),A.length===0&&i(),this.initialized=!0}static \u0275fac=function(i){return new(i||t)};static \u0275prov=SA({token:t,factory:t.\u0275fac,providedIn:"root"})}return t})(),Db=new BA("");function UCA(){N7(()=>{throw new ZA(600,!1)})}function KCA(t){return t.isBoundToModule}var YCA=10;function RT(t,e){return Array.isArray(e)?e.reduce(RT,t):nA(nA({},t),e)}var Ua=(()=>{class t{_runningTick=!1;_destroyed=!1;_destroyListeners=[];_views=[];internalErrorHandler=m(v2A);afterRenderManager=m(uJ);zonelessEnabled=m(P9);rootEffectScheduler=m(MT);dirtyFlags=0;tracingSnapshot=null;externalTestViews=new Set;afterTick=new HA;get allViews(){return[...this.externalTestViews.keys(),...this._views]}get destroyed(){return this._destroyed}componentTypes=[];components=[];isStable=m(r0).hasPendingTasks.pipe(Je(A=>!A));constructor(){m(Gd,{optional:!0})}whenStable(){let A;return new Promise(i=>{A=this.isStable.subscribe({next:n=>{n&&i()}})}).finally(()=>{A.unsubscribe()})}_injector=m(Br);_rendererFactory=null;get injector(){return this._injector}bootstrap(A,i){return this.bootstrapImpl(A,i)}bootstrapImpl(A,i,n=Dt.NULL){uo(10);let o=A instanceof aT;if(!this._injector.get(ST).done){let d="";throw new ZA(405,d)}let s;o?s=A:s=this._injector.get(hp).resolveComponentFactory(A),this.componentTypes.push(s.componentType);let a=KCA(s)?void 0:this._injector.get(i0),c=i||s.selector,l=s.create(n,[],c,a),I=l.location.nativeElement,C=l.injector.get(fb,null);return C?.registerApplication(I),l.onDestroy(()=>{this.detachView(l.hostView),um(this.components,l),C?.unregisterApplication(I)}),this._loadComponent(l),uo(11,l),l}tick(){this.zonelessEnabled||(this.dirtyFlags|=1),this._tick()}_tick(){uo(12),this.tracingSnapshot!==null?this.tracingSnapshot.run(Z9.CHANGE_DETECTION,this.tickImpl):this.tickImpl()}tickImpl=()=>{if(this._runningTick)throw new ZA(101,!1);let A=vi(null);try{this._runningTick=!0,this.synchronize()}catch(i){this.internalErrorHandler(i)}finally{this._runningTick=!1,this.tracingSnapshot?.dispose(),this.tracingSnapshot=null,vi(A),this.afterTick.next(),uo(13)}};synchronize(){this._rendererFactory===null&&!this._injector.destroyed&&(this._rendererFactory=this._injector.get(ds,null,{optional:!0}));let A=0;for(;this.dirtyFlags!==0&&A++<YCA;)uo(14),this.synchronizeOnce(),uo(15)}synchronizeOnce(){if(this.dirtyFlags&16&&(this.dirtyFlags&=-17,this.rootEffectScheduler.flush()),this.dirtyFlags&7){let A=!!(this.dirtyFlags&1);this.dirtyFlags&=-8,this.dirtyFlags|=8;for(let{_lView:i,notifyErrorHandler:n}of this.allViews)JCA(i,n,A,this.zonelessEnabled);if(this.dirtyFlags&=-5,this.syncDirtyFlagsWithViews(),this.dirtyFlags&23)return}else this._rendererFactory?.begin?.(),this._rendererFactory?.end?.();this.dirtyFlags&8&&(this.dirtyFlags&=-9,this.afterRenderManager.execute()),this.syncDirtyFlagsWithViews()}syncDirtyFlagsWithViews(){if(this.allViews.some(({_lView:A})=>ip(A))){this.dirtyFlags|=2;return}else this.dirtyFlags&=-8}attachView(A){let i=A;this._views.push(i),i.attachToAppRef(this)}detachView(A){let i=A;um(this._views,i),i.detachFromAppRef()}_loadComponent(A){this.attachView(A.hostView),this.tick(),this.components.push(A),this._injector.get(Db,[]).forEach(n=>n(A))}ngOnDestroy(){if(!this._destroyed)try{this._destroyListeners.forEach(A=>A()),this._views.slice().forEach(A=>A.destroy())}finally{this._destroyed=!0,this._views=[],this._destroyListeners=[]}}onDestroy(A){return this._destroyListeners.push(A),()=>um(this._destroyListeners,A)}destroy(){if(this._destroyed)throw new ZA(406,!1);let A=this._injector;A.destroy&&!A.destroyed&&A.destroy()}get viewCount(){return this._views.length}static \u0275fac=function(i){return new(i||t)};static \u0275prov=SA({token:t,factory:t.\u0275fac,providedIn:"root"})}return t})();function um(t,e){let A=t.indexOf(e);A>-1&&t.splice(A,1)}function JCA(t,e,A,i){if(!A&&!ip(t))return;AT(t,e,A&&!i?0:1)}function _e(t,e,A,i){let n=Ut(),o=E2();if(Ga(n,o,e)){let r=yo(),s=lQ();J1A(s,n,t,e,A,i)}return _e}function LT(t,e,A,i){return Ga(t,E2(),A)?e+nI(A)+i:Ya}function TCA(t,e,A,i,n,o){let r=j0A(),s=bT(t,r,A,n);return U9(2),s?e+nI(A)+i+nI(n)+o:Ya}function Cm(t,e){return t<<17|e<<2}function BI(t){return t>>17&32767}function zCA(t){return(t&2)==2}function HCA(t,e){return t&131071|e<<17}function i9(t){return t|2}function kd(t){return(t&131068)>>2}function cv(t,e){return t&-131069|e<<2}function OCA(t){return(t&1)===1}function n9(t){return t|1}function PCA(t,e,A,i,n,o){let r=o?e.classBindings:e.styleBindings,s=BI(r),a=kd(r);t[i]=A;let c=!1,l;if(Array.isArray(A)){let I=A;l=I[1],(l===null||sQ(I,l)>0)&&(c=!0)}else l=A;if(n)if(a!==0){let C=BI(t[s+1]);t[i+1]=Cm(C,s),C!==0&&(t[C+1]=cv(t[C+1],i)),t[s+1]=HCA(t[s+1],i)}else t[i+1]=Cm(s,0),s!==0&&(t[s+1]=cv(t[s+1],i)),s=i;else t[i+1]=Cm(a,0),s===0?s=i:t[a+1]=cv(t[a+1],i),a=i;c&&(t[i+1]=i9(t[i+1])),OK(t,l,i,!0),OK(t,l,i,!1),jCA(e,l,t,i,o),r=Cm(s,a),o?e.classBindings=r:e.styleBindings=r}function jCA(t,e,A,i,n){let o=n?t.residualClasses:t.residualStyles;o!=null&&typeof e=="string"&&sQ(o,e)>=0&&(A[i+1]=n9(A[i+1]))}function OK(t,e,A,i){let n=t[A+1],o=e===null,r=i?BI(n):kd(n),s=!1;for(;r!==0&&(s===!1||o);){let a=t[r],c=t[r+1];qCA(a,e)&&(s=!0,t[r+1]=i?n9(c):i9(c)),r=i?BI(c):kd(c)}s&&(t[A+1]=i?i9(n):n9(n))}function qCA(t,e){return t===null||e==null||(Array.isArray(t)?t[1]:t)===e?!0:Array.isArray(t)&&typeof e=="string"?sQ(t,e)>=0:!1}var Xc={textEnd:0,key:0,keyEnd:0,value:0,valueEnd:0};function VCA(t){return t.substring(Xc.key,Xc.keyEnd)}function ZCA(t){return WCA(t),xT(t,FT(t,0,Xc.textEnd))}function xT(t,e){let A=Xc.textEnd;return A===e?-1:(e=Xc.keyEnd=XCA(t,Xc.key=e,A),FT(t,e,A))}function WCA(t){Xc.key=0,Xc.keyEnd=0,Xc.value=0,Xc.valueEnd=0,Xc.textEnd=t.length}function FT(t,e,A){for(;e<A&&t.charCodeAt(e)<=32;)e++;return e}function XCA(t,e,A){for(;e<A&&t.charCodeAt(e)>32;)e++;return e}function vA(t,e,A){let i=Ut(),n=E2();if(Ga(i,n,e)){let o=yo(),r=lQ();Ip(o,r,i,t,e,i[Uo],A,!1)}return vA}function o9(t,e,A,i,n){rb(e,t,A,n?"class":"style",i)}function so(t,e,A){return _T(t,e,A,!1),so}function ue(t,e){return _T(t,e,null,!0),ue}function vo(t){GT(ndA,NT,t,!0)}function NT(t,e){for(let A=ZCA(e);A>=0;A=xT(e,A))Xm(t,VCA(e),!0)}function _T(t,e,A,i){let n=Ut(),o=yo(),r=U9(2);if(o.firstUpdatePass&&KT(o,t,r,i),e!==Ya&&Ga(n,r,e)){let s=o.data[o0()];YT(o,s,n,n[Uo],t,n[r+1]=rdA(e,A),i,r)}}function GT(t,e,A,i){let n=yo(),o=U9(2);n.firstUpdatePass&&KT(n,null,o,i);let r=Ut();if(A!==Ya&&Ga(r,o,A)){let s=n.data[o0()];if(JT(s,i)&&!UT(n,o)){let a=i?s.classesWithoutHost:s.stylesWithoutHost;a!==null&&(A=dv(a,A||"")),o9(n,s,r,A,i)}else odA(n,s,r,r[Uo],r[o+1],r[o+1]=idA(t,e,A),i,o)}}function UT(t,e){return e>=t.expandoStartIndex}function KT(t,e,A,i){let n=t.data;if(n[A+1]===null){let o=n[o0()],r=UT(t,A);JT(o,i)&&e===null&&!r&&(e=!1),e=$CA(n,o,e,i),PCA(n,o,e,A,r,i)}}function $CA(t,e,A,i){let n=K9(t),o=i?e.residualClasses:e.residualStyles;if(n===null)(i?e.classBindings:e.styleBindings)===0&&(A=lv(null,t,e,A,i),A=nQ(A,e.attrs,i),o=null);else{let r=e.directiveStylingLast;if(r===-1||t[r]!==n)if(A=lv(n,t,e,A,i),o===null){let a=AdA(t,e,i);a!==void 0&&Array.isArray(a)&&(a=lv(null,t,e,a[1],i),a=nQ(a,e.attrs,i),edA(t,e,i,a))}else o=tdA(t,e,i)}return o!==void 0&&(i?e.residualClasses=o:e.residualStyles=o),A}function AdA(t,e,A){let i=A?e.classBindings:e.styleBindings;if(kd(i)!==0)return t[BI(i)]}function edA(t,e,A,i){let n=A?e.classBindings:e.styleBindings;t[BI(n)]=i}function tdA(t,e,A){let i,n=e.directiveEnd;for(let o=1+e.directiveStylingLast;o<n;o++){let r=t[o].hostAttrs;i=nQ(i,r,A)}return nQ(i,e.attrs,A)}function lv(t,e,A,i,n){let o=null,r=A.directiveEnd,s=A.directiveStylingLast;for(s===-1?s=A.directiveStart:s++;s<r&&(o=e[s],i=nQ(i,o.hostAttrs,n),o!==t);)s++;return t!==null&&(A.directiveStylingLast=s),i}function nQ(t,e,A){let i=A?1:2,n=-1;if(e!==null)for(let o=0;o<e.length;o++){let r=e[o];typeof r=="number"?n=r:n===i&&(Array.isArray(t)||(t=t===void 0?[]:["",t]),Xm(t,r,A?!0:e[++o]))}return t===void 0?null:t}function idA(t,e,A){if(A==null||A==="")return xs;let i=[],n=el(A);if(Array.isArray(n))for(let o=0;o<n.length;o++)t(i,n[o],!0);else if(typeof n=="object")for(let o in n)n.hasOwnProperty(o)&&t(i,o,n[o]);else typeof n=="string"&&e(i,n);return i}function ndA(t,e,A){let i=String(e);i!==""&&!i.includes(" ")&&Xm(t,i,A)}function odA(t,e,A,i,n,o,r,s){n===Ya&&(n=xs);let a=0,c=0,l=0<n.length?n[0]:null,I=0<o.length?o[0]:null;for(;l!==null||I!==null;){let C=a<n.length?n[a+1]:void 0,d=c<o.length?o[c+1]:void 0,B=null,E;l===I?(a+=2,c+=2,C!==d&&(B=I,E=d)):I===null||l!==null&&l<I?(a+=2,B=l):(c+=2,B=I,E=d),B!==null&&YT(t,e,A,i,B,E,r,s),l=a<n.length?n[a]:null,I=c<o.length?o[c]:null}}function YT(t,e,A,i,n,o,r,s){if(!(e.type&3))return;let a=t.data,c=a[s+1],l=OCA(c)?PK(a,e,A,n,kd(c),r):void 0;if(!Hm(l)){Hm(o)||zCA(c)&&(o=PK(a,null,A,n,s,r));let I=RY(o0(),A);oIA(i,r,I,n,o)}}function PK(t,e,A,i,n,o){let r=e===null,s;for(;n>0;){let a=t[n],c=Array.isArray(a),l=c?a[1]:a,I=l===null,C=A[n+1];C===Ya&&(C=I?xs:void 0);let d=I?Av(C,i):l===i?C:void 0;if(c&&!Hm(d)&&(d=Av(a,i)),Hm(d)&&(s=d,r))return s;let B=t[n+1];n=r?BI(B):kd(B)}if(e!==null){let a=o?e.residualClasses:e.residualStyles;a!=null&&(s=Av(a,i))}return s}function Hm(t){return t!==void 0}function rdA(t,e){return t==null||t===""||(typeof e=="string"?t=t+e:typeof t=="object"&&(t=Zs(el(t)))),t}function JT(t,e){return(t.flags&(e?8:16))!==0}function TT(t,e,A){let i=Ut(),n=LT(i,t,e,A);GT(Xm,NT,n,!0)}var r9=class{destroy(e){}updateValue(e,A){}swap(e,A){let i=Math.min(e,A),n=Math.max(e,A),o=this.detach(n);if(n-i>1){let r=this.detach(i);this.attach(i,o),this.attach(n,r)}else this.attach(i,o)}move(e,A){this.attach(A,this.detach(e))}};function gv(t,e,A,i,n){return t===A&&Object.is(e,i)?1:Object.is(n(t,e),n(A,i))?-1:0}function sdA(t,e,A){let i,n,o=0,r=t.length-1,s=void 0;if(Array.isArray(e)){let a=e.length-1;for(;o<=r&&o<=a;){let c=t.at(o),l=e[o],I=gv(o,c,o,l,A);if(I!==0){I<0&&t.updateValue(o,l),o++;continue}let C=t.at(r),d=e[a],B=gv(r,C,a,d,A);if(B!==0){B<0&&t.updateValue(r,d),r--,a--;continue}let E=A(o,c),Q=A(r,C),u=A(o,l);if(Object.is(u,Q)){let v=A(a,d);Object.is(v,E)?(t.swap(o,r),t.updateValue(r,d),a--,r--):t.move(r,o),t.updateValue(o,l),o++;continue}if(i??=new Om,n??=qK(t,o,r,A),s9(t,i,o,u))t.updateValue(o,l),o++,r++;else if(n.has(u))i.set(E,t.detach(o)),r--;else{let v=t.create(o,e[o]);t.attach(o,v),o++,r++}}for(;o<=a;)jK(t,i,A,o,e[o]),o++}else if(e!=null){let a=e[Symbol.iterator](),c=a.next();for(;!c.done&&o<=r;){let l=t.at(o),I=c.value,C=gv(o,l,o,I,A);if(C!==0)C<0&&t.updateValue(o,I),o++,c=a.next();else{i??=new Om,n??=qK(t,o,r,A);let d=A(o,I);if(s9(t,i,o,d))t.updateValue(o,I),o++,r++,c=a.next();else if(!n.has(d))t.attach(o,t.create(o,I)),o++,r++,c=a.next();else{let B=A(o,l);i.set(B,t.detach(o)),r--}}}for(;!c.done;)jK(t,i,A,t.length,c.value),c=a.next()}for(;o<=r;)t.destroy(t.detach(r--));i?.forEach(a=>{t.destroy(a)})}function s9(t,e,A,i){return e!==void 0&&e.has(i)?(t.attach(A,e.get(i)),e.delete(i),!0):!1}function jK(t,e,A,i,n){if(s9(t,e,i,A(i,n)))t.updateValue(i,n);else{let o=t.create(i,n);t.attach(i,o)}}function qK(t,e,A,i){let n=new Set;for(let o=e;o<=A;o++)n.add(i(o,t.at(o)));return n}var Om=class{kvMap=new Map;_vMap=void 0;has(e){return this.kvMap.has(e)}delete(e){if(!this.has(e))return!1;let A=this.kvMap.get(e);return this._vMap!==void 0&&this._vMap.has(A)?(this.kvMap.set(e,this._vMap.get(A)),this._vMap.delete(A)):this.kvMap.delete(e),!0}get(e){return this.kvMap.get(e)}set(e,A){if(this.kvMap.has(e)){let i=this.kvMap.get(e);this._vMap===void 0&&(this._vMap=new Map);let n=this._vMap;for(;n.has(i);)i=n.get(i);n.set(i,A)}else this.kvMap.set(e,A)}forEach(e){for(let[A,i]of this.kvMap)if(e(i,A),this._vMap!==void 0){let n=this._vMap;for(;n.has(i);)i=n.get(i),e(i,A)}}};function FA(t,e){s0("NgControlFlow");let A=Ut(),i=E2(),n=A[i]!==Ya?A[i]:-1,o=n!==-1?Pm(A,br+n):void 0,r=0;if(Ga(A,i,t)){let s=vi(null);try{if(o!==void 0&&rT(o,r),t!==-1){let a=br+t,c=Pm(A,a),l=g9(A[gi],a),I=Md(c,l.tView.ssrId),C=dQ(A,l,e,{dehydratedView:I});BQ(c,C,r,bd(l,I))}}finally{vi(s)}}else if(o!==void 0){let s=oT(o,r);s!==void 0&&(s[vr]=e)}}var a9=class{lContainer;$implicit;$index;constructor(e,A,i){this.lContainer=e,this.$implicit=A,this.$index=i}get $count(){return this.lContainer.length-Is}};function Kd(t){return t}function Kn(t,e){return e}var c9=class{hasEmptyBlock;trackByFn;liveCollection;constructor(e,A,i){this.hasEmptyBlock=e,this.trackByFn=A,this.liveCollection=i}};function ln(t,e,A,i,n,o,r,s,a,c,l,I,C){s0("NgControlFlow");let d=Ut(),B=yo(),E=a!==void 0,Q=Ut(),u=s?r.bind(Q[_a][vr]):r,v=new c9(E,u);Q[br+t]=v,zm(d,B,t+1,e,A,i,n,B2(B.consts,o)),E&&zm(d,B,t+2,a,c,l,I,B2(B.consts,C))}var l9=class extends r9{lContainer;hostLView;templateTNode;operationsCounter=void 0;needsIndexUpdate=!1;constructor(e,A,i){super(),this.lContainer=e,this.hostLView=A,this.templateTNode=i}get length(){return this.lContainer.length-Is}at(e){return this.getLView(e)[vr].$implicit}attach(e,A){let i=A[Dd];this.needsIndexUpdate||=e!==this.length,BQ(this.lContainer,A,e,bd(this.templateTNode,i))}detach(e){return this.needsIndexUpdate||=e!==this.length-1,adA(this.lContainer,e)}create(e,A){let i=Md(this.lContainer,this.templateTNode.tView.ssrId),n=dQ(this.hostLView,this.templateTNode,new a9(this.lContainer,A,e),{dehydratedView:i});return this.operationsCounter?.recordCreate(),n}destroy(e){Cp(e[gi],e),this.operationsCounter?.recordDestroy()}updateValue(e,A){this.getLView(e)[vr].$implicit=A}reset(){this.needsIndexUpdate=!1,this.operationsCounter?.reset()}updateIndexes(){if(this.needsIndexUpdate)for(let e=0;e<this.length;e++)this.getLView(e)[vr].$index=e}getLView(e){return cdA(this.lContainer,e)}};function gn(t){let e=vi(null),A=o0();try{let i=Ut(),n=i[gi],o=i[A],r=A+1,s=Pm(i,r);if(o.liveCollection===void 0){let c=g9(n,r);o.liveCollection=new l9(s,i,c)}else o.liveCollection.reset();let a=o.liveCollection;if(sdA(a,t,o.trackByFn),a.updateIndexes(),o.hasEmptyBlock){let c=E2(),l=a.length===0;if(Ga(i,c,l)){let I=A+2,C=Pm(i,I);if(l){let d=g9(n,I),B=Md(C,d.tView.ssrId),E=dQ(i,d,void 0,{dehydratedView:B});BQ(C,E,0,bd(d,B))}else rT(C,0)}}}finally{vi(e)}}function Pm(t,e){return t[e]}function adA(t,e){return tQ(t,e)}function cdA(t,e){return oT(t,e)}function g9(t,e){return S9(t,e)}function S(t,e,A,i){let n=Ut(),o=yo(),r=br+t,s=n[Uo],a=o.firstCreatePass?gT(r,o,n,e,ob,N9(),A,i):o.data[r],c=ldA(o,n,a,s,e,t);n[r]=c;let l=tp(a);return QI(a,!0),KJ(s,c,a),!cb(a)&&op()&&dp(o,n,c,a),(Y0A()===0||l)&&_d(c,n),J0A(),l&&(gp(o,n,a),X9(o,a,n)),i!==null&&nb(n,a),S}function R(){let t=Xr();_9()?G9():(t=t.parent,QI(t,!1));let e=t;z0A(e)&&H0A(),T0A();let A=yo();return A.firstCreatePass&&IT(A,e),e.classesWithoutHost!=null&&n2A(e)&&o9(A,e,Ut(),e.classesWithoutHost,!0),e.stylesWithoutHost!=null&&o2A(e)&&o9(A,e,Ut(),e.stylesWithoutHost,!1),R}function UA(t,e,A,i){return S(t,e,A,i),R(),UA}var ldA=(t,e,A,i,n,o)=>(rp(!0),GJ(i,n,e2A()));function gdA(t,e,A,i,n){let o=e.consts,r=B2(o,i),s=EQ(e,t,8,"ng-container",r);r!==null&&jv(s,r,!0);let a=B2(o,n);return N9()&&Cb(e,A,s,a,ob),s.mergedAttrs=vd(s.mergedAttrs,s.attrs),e.queries!==null&&e.queries.elementStart(e,s),s}function f2(t,e,A){let i=Ut(),n=yo(),o=t+br,r=n.firstCreatePass?gdA(o,n,i,e,A):n.data[o];QI(r,!0);let s=IdA(n,i,r,t);return i[o]=s,op()&&dp(n,i,s,r),_d(s,i),tp(r)&&(gp(n,i,r),X9(n,r,i)),A!=null&&nb(i,r),f2}function m2(){let t=Xr(),e=yo();return _9()?G9():(t=t.parent,QI(t,!1)),e.firstCreatePass&&(z9(e,t),k9(t)&&e.queries.elementEnd(t)),m2}function Mr(t,e,A){return f2(t,e,A),m2(),Mr}var IdA=(t,e,A,i)=>(rp(!0),v1A(e[Uo],""));function De(){return Ut()}function Fs(t,e,A){let i=Ut(),n=E2();if(Ga(i,n,e)){let o=yo(),r=lQ();Ip(o,r,i,t,e,i[Uo],A,!0)}return Fs}function yb(t,e,A){let i=Ut(),n=E2();if(Ga(i,n,e)){let o=yo(),r=lQ(),s=K9(o.data),a=HJ(s,r,i);Ip(o,r,i,t,e,a,A,!0)}return yb}var jm="en-US";var CdA=jm;function ddA(t){typeof t=="string"&&(CdA=t.toLowerCase().replace(/_/g,"-"))}function VK(t,e,A){return function i(n){if(n===Function)return A;let o=Rd(t)?jl(t.index,e):e;Ib(o,5);let r=e[vr],s=ZK(e,r,A,n),a=i.__ngNextListenerFn__;for(;a;)s=ZK(e,r,a,n)&&s,a=a.__ngNextListenerFn__;return s}}function ZK(t,e,A,i){let n=vi(null);try{return uo(6,e,A),A(i)!==!1}catch(o){return BdA(t,o),!1}finally{uo(7,e,A),vi(n)}}function BdA(t,e){let A=t[rI],i=A?A.get(Xs,null):null;i&&i.handleError(e)}function WK(t,e,A,i,n,o){let r=e[A],s=e[gi],c=s.data[A].outputs[i],l=r[c],I=s.firstCreatePass?F9(s):null,C=x9(e),d=l.subscribe(o),B=C.length;C.push(o,d),I&&I.push(n,t.index,B,-(B+1))}var EdA=new Map;function mA(t,e,A,i){let n=Ut(),o=yo(),r=Xr();return bb(o,n,n[Uo],r,t,e,i),mA}function vb(t,e){let A=Xr(),i=Ut(),n=yo(),o=K9(n.data),r=HJ(o,A,i);return bb(n,i,r,A,t,e),vb}function hdA(t,e,A,i){let n=t.cleanup;if(n!=null)for(let o=0;o<n.length-1;o+=2){let r=n[o];if(r===A&&n[o+1]===i){let s=e[ym],a=n[o+2];return s.length>a?s[a]:null}typeof r=="string"&&(o+=2)}return null}function bb(t,e,A,i,n,o,r){let s=tp(i),c=t.firstCreatePass?F9(t):null,l=x9(e),I=!0;if(i.type&3||r){let C=Wl(i,e),d=r?r(C):C,B=l.length,E=r?u=>r(Pl(u[i.index])):i.index,Q=null;if(!r&&s&&(Q=hdA(t,e,n,i.index)),Q!==null){let u=Q.__ngLastListenerFn__||Q;u.__ngNextListenerFn__=o,Q.__ngLastListenerFn__=o,I=!1}else{o=VK(i,e,o);let u=e[rI].get(fI);EdA.get(u)?.(d,n,o);let L=A.listen(d,n,o);l.push(o,L),c&&c.push(n,E,B,B+1)}}else o=VK(i,e,o);if(I){let C=i.outputs?.[n],d=i.hostDirectiveOutputs?.[n];if(d&&d.length)for(let B=0;B<d.length;B+=2){let E=d[B],Q=d[B+1];WK(i,e,E,Q,n,o)}if(C&&C.length)for(let B of C)WK(i,e,B,n,n,o)}}function P(t=1){return $0A(t)}function QdA(t,e){let A=null,i=h1A(t);for(let n=0;n<e.length;n++){let o=e[n];if(o==="*"){A=n;continue}if(i===null?_J(t,o,!0):f1A(i,o))return n}return A}function Yt(t){let e=Ut()[_a][Aa];if(!e.projection){let A=t?t.length:1,i=e.projection=d0A(A,null),n=i.slice(),o=e.child;for(;o!==null;){if(o.type!==128){let r=t?QdA(o,t):0;r!==null&&(n[r]?n[r].projectionNext=o:i[r]=o,n[r]=o)}o=o.next}}}function xe(t,e=0,A,i,n,o){let r=Ut(),s=yo(),a=i?t+1:null;a!==null&&zm(r,s,a,i,n,o,null,A);let c=EQ(s,br+t,16,null,A||null);c.projection===null&&(c.projection=e),G9();let I=!r[Dd]||NY();r[_a][Aa].projection[c.projection]===null&&a!==null?udA(r,s,a):I&&!cb(c)&&iIA(s,r,c)}function udA(t,e,A){let i=br+A,n=e.data[i],o=t[i],r=Md(o,n.tView.ssrId),s=dQ(t,n,void 0,{dehydratedView:r});BQ(o,s,0,bd(n,r))}function Ii(t,e,A,i){hT(t,e,A,i)}function Ge(t,e,A){nCA(t,e,A)}function $A(t){let e=Ut(),A=yo(),i=Y9();np(i+1);let n=Bb(A,i);if(t.dirty&&N0A(e)===((n.metadata.flags&2)===2)){if(n.matches===null)t.reset([]);else{let o=uT(e,i);t.reset(o,aJ),t.notifyOnChanges()}return!0}return!1}function Ae(){return db(Ut(),Y9())}function zT(t,e,A,i,n){cCA(e,hT(t,A,i,n))}function HT(t=1){np(Y9()+t)}function fdA(t,e,A,i){A>=t.data.length&&(t.data[A]=null,t.blueprint[A]=null),e[A]=i}function or(t){let e=P0A();return R9(e,br+t)}function tA(t,e=""){let A=Ut(),i=yo(),n=t+br,o=i.firstCreatePass?EQ(i,n,1,e,null):i.data[n],r=mdA(i,A,o,e,t);A[n]=r,op()&&dp(i,A,r,o),QI(o,!1)}var mdA=(t,e,A,i,n)=>(rp(!0),D1A(e[Uo],i));function Mt(t){return ot("",t,""),Mt}function ot(t,e,A){let i=Ut(),n=LT(i,t,e,A);return n!==Ya&&OT(i,o0(),n),ot}function Mb(t,e,A,i,n){let o=Ut(),r=TCA(o,t,e,A,i,n);return r!==Ya&&OT(o,o0(),r),Mb}function OT(t,e,A){let i=RY(e,t);y1A(t[Uo],i,A)}function ea(t,e,A){cJ(e)&&(e=e());let i=Ut(),n=E2();if(Ga(i,n,e)){let o=yo(),r=lQ();Ip(o,r,i,t,e,i[Uo],A,!1)}return ea}function Ja(t,e){let A=cJ(t);return A&&t.set(e),A}function ta(t,e){let A=Ut(),i=yo(),n=Xr();return bb(i,A,A[Uo],n,t,e),ta}function pdA(t,e,A){let i=yo();if(i.firstCreatePass){let n=Al(t);I9(A,i.data,i.blueprint,n,!0),I9(e,i.data,i.blueprint,n,!1)}}function I9(t,e,A,i,n){if(t=Wr(t),Array.isArray(t))for(let o=0;o<t.length;o++)I9(t[o],e,A,i,n);else{let o=yo(),r=Ut(),s=Xr(),a=wd(t)?t:Wr(t.provide),c=wY(t),l=s.providerIndexes&1048575,I=s.directiveStart,C=s.providerIndexes>>20;if(wd(t)||!t.multi){let d=new II(c,n,zA),B=Cv(a,e,n?l:l+C,I);B===-1?(vv(Lm(s,r),o,a),Iv(o,t,e.length),e.push(a),s.directiveStart++,s.directiveEnd++,n&&(s.providerIndexes+=1048576),A.push(d),r.push(d)):(A[B]=d,r[B]=d)}else{let d=Cv(a,e,l+C,I),B=Cv(a,e,l,l+C),E=d>=0&&A[d],Q=B>=0&&A[B];if(n&&!Q||!n&&!E){vv(Lm(s,r),o,a);let u=ydA(n?DdA:wdA,A.length,n,i,c);!n&&Q&&(A[B].providerFactory=u),Iv(o,t,e.length,0),e.push(a),s.directiveStart++,s.directiveEnd++,n&&(s.providerIndexes+=1048576),A.push(u),r.push(u)}else{let u=PT(A[n?B:d],c,!n&&i);Iv(o,t,d>-1?d:B,u)}!n&&i&&Q&&A[B].componentProviders++}}}function Iv(t,e,A,i){let n=wd(e),o=p0A(e);if(n||o){let a=(o?Wr(e.useClass):e).prototype.ngOnDestroy;if(a){let c=t.destroyHooks||(t.destroyHooks=[]);if(!n&&e.multi){let l=c.indexOf(A);l===-1?c.push(A,[i,a]):c[l+1].push(i,a)}else c.push(A,a)}}}function PT(t,e,A){return A&&t.componentProviders++,t.multi.push(e)-1}function Cv(t,e,A,i){for(let n=A;n<i;n++)if(e[n]===t)return n;return-1}function wdA(t,e,A,i){return C9(this.multi,[])}function DdA(t,e,A,i){let n=this.multi,o;if(this.providerFactory){let r=this.providerFactory.componentProviders,s=AQ(A,A[gi],this.providerFactory.index,i);o=s.slice(0,r),C9(n,o);for(let a=r;a<s.length;a++)o.push(s[a])}else o=[],C9(n,o);return o}function C9(t,e){for(let A=0;A<t.length;A++){let i=t[A];e.push(i())}return e}function ydA(t,e,A,i,n){let o=new II(t,A,zA);return o.multi=[],o.index=e,o.componentProviders=0,PT(o,n,i&&!A),o}function ct(t,e=[]){return A=>{A.providersResolver=(i,n)=>pdA(i,n?n(t):t,e)}}function jT(t,e,A){let i=cQ()+t,n=Ut();return n[i]===Ya?Qb(n,i,A?e.call(A):e()):xCA(n,i)}function Yr(t,e,A,i){return VT(Ut(),cQ(),t,e,A,i)}function p2(t,e,A,i,n){return ZT(Ut(),cQ(),t,e,A,i,n)}function qT(t,e){let A=t[e];return A===Ya?void 0:A}function VT(t,e,A,i,n,o){let r=e+A;return Ga(t,r,n)?Qb(t,r+1,o?i.call(o,n):i(n)):qT(t,r+1)}function ZT(t,e,A,i,n,o,r){let s=e+A;return bT(t,s,n,o)?Qb(t,s+2,r?i.call(r,n,o):i(n,o)):qT(t,s+2)}function Ta(t,e){let A=yo(),i,n=t+br;A.firstCreatePass?(i=vdA(e,A.pipeRegistry),A.data[n]=i,i.onDestroy&&(A.destroyHooks??=[]).push(n,i.onDestroy)):i=A.data[n];let o=i.factory||(i.factory=oI(i.type,!0)),r,s=Vs(zA);try{let a=Rm(!1),c=o();return Rm(a),fdA(A,Ut(),n,c),c}finally{Vs(s)}}function vdA(t,e){if(e)for(let A=e.length-1;A>=0;A--){let i=e[A];if(t===i.name)return i}}function w2(t,e,A){let i=t+br,n=Ut(),o=R9(n,i);return WT(n,i)?VT(n,cQ(),e,o.transform,A,o):o.transform(A)}function uQ(t,e,A,i){let n=t+br,o=Ut(),r=R9(o,n);return WT(o,n)?ZT(o,cQ(),e,r.transform,A,i,r):r.transform(A,i)}function WT(t,e){return t[gi].data[e].pure}function fQ(t,e){return Ep(t,e)}var dm=null;function bdA(t){dm!==null&&(t.defaultEncapsulation!==dm.defaultEncapsulation||t.preserveWhitespaces!==dm.preserveWhitespaces)||(dm=t)}var EI=class{full;major;minor;patch;constructor(e){this.full=e;let A=e.split(".");this.major=A[0],this.minor=A[1],this.patch=A.slice(2).join(".")}},kb=new EI("19.2.9"),d9=class{ngModuleFactory;componentFactories;constructor(e,A){this.ngModuleFactory=e,this.componentFactories=A}},XT=(()=>{class t{compileModuleSync(A){return new Tm(A)}compileModuleAsync(A){return Promise.resolve(this.compileModuleSync(A))}compileModuleAndAllComponentsSync(A){let i=this.compileModuleSync(A),n=QY(A),o=FJ(n.declarations).reduce((r,s)=>{let a=d2(s);return a&&r.push(new dI(a)),r},[]);return new d9(i,o)}compileModuleAndAllComponentsAsync(A){return Promise.resolve(this.compileModuleAndAllComponentsSync(A))}clearCache(){}clearCacheFor(A){}getModuleId(A){}static \u0275fac=function(i){return new(i||t)};static \u0275prov=SA({token:t,factory:t.\u0275fac,providedIn:"root"})}return t})(),MdA=new BA("");function kdA(t,e,A){let i=new Tm(A);return Promise.resolve(i)}function XK(t){for(let e=t.length-1;e>=0;e--)if(t[e]!==void 0)return t[e]}var SdA=(()=>{class t{zone=m(de);changeDetectionScheduler=m(CI);applicationRef=m(Ua);_onMicrotaskEmptySubscription;initialize(){this._onMicrotaskEmptySubscription||(this._onMicrotaskEmptySubscription=this.zone.onMicrotaskEmpty.subscribe({next:()=>{this.changeDetectionScheduler.runningTick||this.zone.run(()=>{this.applicationRef.tick()})}}))}ngOnDestroy(){this._onMicrotaskEmptySubscription?.unsubscribe()}static \u0275fac=function(i){return new(i||t)};static \u0275prov=SA({token:t,factory:t.\u0275fac,providedIn:"root"})}return t})();function RdA({ngZoneFactory:t,ignoreChangesOutsideZone:e,scheduleInRootZone:A}){return t??=()=>new de(Ne(nA({},$T()),{scheduleInRootZone:A})),[{provide:de,useFactory:t},{provide:pd,multi:!0,useFactory:()=>{let i=m(SdA,{optional:!0});return()=>i.initialize()}},{provide:pd,multi:!0,useFactory:()=>{let i=m(LdA);return()=>{i.initialize()}}},e===!0?{provide:iJ,useValue:!0}:[],{provide:nJ,useValue:A??tJ}]}function $T(t){return{enableLongStackTrace:!1,shouldCoalesceEventChangeDetection:t?.eventCoalescing??!1,shouldCoalesceRunChangeDetection:t?.runCoalescing??!1}}var LdA=(()=>{class t{subscription=new _t;initialized=!1;zone=m(de);pendingTasks=m(r0);initialize(){if(this.initialized)return;this.initialized=!0;let A=null;!this.zone.isStable&&!this.zone.hasPendingMacrotasks&&!this.zone.hasPendingMicrotasks&&(A=this.pendingTasks.add()),this.zone.runOutsideAngular(()=>{this.subscription.add(this.zone.onStable.subscribe(()=>{de.assertNotInAngularZone(),queueMicrotask(()=>{A!==null&&!this.zone.hasPendingMacrotasks&&!this.zone.hasPendingMicrotasks&&(this.pendingTasks.remove(A),A=null)})}))}),this.subscription.add(this.zone.onUnstable.subscribe(()=>{de.assertInAngularZone(),A??=this.pendingTasks.add()}))}ngOnDestroy(){this.subscription.unsubscribe()}static \u0275fac=function(i){return new(i||t)};static \u0275prov=SA({token:t,factory:t.\u0275fac,providedIn:"root"})}return t})();var xdA=(()=>{class t{appRef=m(Ua);taskService=m(r0);ngZone=m(de);zonelessEnabled=m(P9);tracing=m(Gd,{optional:!0});disableScheduling=m(iJ,{optional:!0})??!1;zoneIsDefined=typeof Zone<"u"&&!!Zone.root.run;schedulerTickApplyArgs=[{data:{__scheduler_tick__:!0}}];subscriptions=new _t;angularZoneId=this.zoneIsDefined?this.ngZone._inner?.get(Fm):null;scheduleInRootZone=!this.zonelessEnabled&&this.zoneIsDefined&&(m(nJ,{optional:!0})??!1);cancelScheduledCallback=null;useMicrotaskScheduler=!1;runningTick=!1;pendingRenderTaskId=null;constructor(){this.subscriptions.add(this.appRef.afterTick.subscribe(()=>{this.runningTick||this.cleanup()})),this.subscriptions.add(this.ngZone.onUnstable.subscribe(()=>{this.runningTick||this.cleanup()})),this.disableScheduling||=!this.zonelessEnabled&&(this.ngZone instanceof Nm||!this.zoneIsDefined)}notify(A){if(!this.zonelessEnabled&&A===5)return;let i=!1;switch(A){case 0:{this.appRef.dirtyFlags|=2;break}case 3:case 2:case 4:case 5:case 1:{this.appRef.dirtyFlags|=4;break}case 6:{this.appRef.dirtyFlags|=2,i=!0;break}case 12:{this.appRef.dirtyFlags|=16,i=!0;break}case 13:{this.appRef.dirtyFlags|=2,i=!0;break}case 11:{i=!0;break}case 9:case 8:case 7:case 10:default:this.appRef.dirtyFlags|=8}if(this.appRef.tracingSnapshot=this.tracing?.snapshot(this.appRef.tracingSnapshot)??null,!this.shouldScheduleTick(i))return;let n=this.useMicrotaskScheduler?wK:oJ;this.pendingRenderTaskId=this.taskService.add(),this.scheduleInRootZone?this.cancelScheduledCallback=Zone.root.run(()=>n(()=>this.tick())):this.cancelScheduledCallback=this.ngZone.runOutsideAngular(()=>n(()=>this.tick()))}shouldScheduleTick(A){return!(this.disableScheduling&&!A||this.appRef.destroyed||this.pendingRenderTaskId!==null||this.runningTick||this.appRef._runningTick||!this.zonelessEnabled&&this.zoneIsDefined&&Zone.current.get(Fm+this.angularZoneId))}tick(){if(this.runningTick||this.appRef.destroyed)return;if(this.appRef.dirtyFlags===0){this.cleanup();return}!this.zonelessEnabled&&this.appRef.dirtyFlags&7&&(this.appRef.dirtyFlags|=1);let A=this.taskService.add();try{this.ngZone.run(()=>{this.runningTick=!0,this.appRef._tick()},void 0,this.schedulerTickApplyArgs)}catch(i){throw this.taskService.remove(A),i}finally{this.cleanup()}this.useMicrotaskScheduler=!0,wK(()=>{this.useMicrotaskScheduler=!1,this.taskService.remove(A)})}ngOnDestroy(){this.subscriptions.unsubscribe(),this.cleanup()}cleanup(){if(this.runningTick=!1,this.cancelScheduledCallback?.(),this.cancelScheduledCallback=null,this.pendingRenderTaskId!==null){let A=this.pendingRenderTaskId;this.pendingRenderTaskId=null,this.taskService.remove(A)}}static \u0275fac=function(i){return new(i||t)};static \u0275prov=SA({token:t,factory:t.\u0275fac,providedIn:"root"})}return t})();function FdA(){return typeof $localize<"u"&&$localize.locale||jm}var mp=new BA("",{providedIn:"root",factory:()=>m(mp,_i.Optional|_i.SkipSelf)||FdA()});var qm=new BA(""),NdA=new BA("");function jh(t){return!t.moduleRef}function _dA(t){let e=jh(t)?t.r3Injector:t.moduleRef.injector,A=e.get(de);return A.run(()=>{jh(t)?t.r3Injector.resolveInjectorInitializers():t.moduleRef.resolveInjectorInitializers();let i=e.get(Xs,null),n;if(A.runOutsideAngular(()=>{n=A.onError.subscribe({next:o=>{i.handleError(o)}})}),jh(t)){let o=()=>e.destroy(),r=t.platformInjector.get(qm);r.add(o),e.onDestroy(()=>{n.unsubscribe(),r.delete(o)})}else{let o=()=>t.moduleRef.destroy(),r=t.platformInjector.get(qm);r.add(o),t.moduleRef.onDestroy(()=>{um(t.allPlatformModules,t.moduleRef),n.unsubscribe(),r.delete(o)})}return UdA(i,A,()=>{let o=e.get(ST);return o.runInitializers(),o.donePromise.then(()=>{let r=e.get(mp,jm);if(ddA(r||jm),!e.get(NdA,!0))return jh(t)?e.get(Ua):(t.allPlatformModules.push(t.moduleRef),t.moduleRef);if(jh(t)){let a=e.get(Ua);return t.rootComponent!==void 0&&a.bootstrap(t.rootComponent),a}else return GdA(t.moduleRef,t.allPlatformModules),t.moduleRef})})})}function GdA(t,e){let A=t.injector.get(Ua);if(t._bootstrapComponents.length>0)t._bootstrapComponents.forEach(i=>A.bootstrap(i));else if(t.instance.ngDoBootstrap)t.instance.ngDoBootstrap(A);else throw new ZA(-403,!1);e.push(t)}function UdA(t,e,A){try{let i=A();return u2(i)?i.catch(n=>{throw e.runOutsideAngular(()=>t.handleError(n)),n}):i}catch(i){throw e.runOutsideAngular(()=>t.handleError(i)),i}}var Az=(()=>{class t{_injector;_modules=[];_destroyListeners=[];_destroyed=!1;constructor(A){this._injector=A}bootstrapModuleFactory(A,i){let n=i?.scheduleInRootZone,o=()=>y2A(i?.ngZone,Ne(nA({},$T({eventCoalescing:i?.ngZoneEventCoalescing,runCoalescing:i?.ngZoneRunCoalescing})),{scheduleInRootZone:n})),r=i?.ignoreChangesOutsideZone,s=[RdA({ngZoneFactory:o,ignoreChangesOutsideZone:r}),{provide:CI,useExisting:xdA}],a=QCA(A.moduleType,this.injector,s);return _dA({moduleRef:a,allPlatformModules:this._modules,platformInjector:this.injector})}bootstrapModule(A,i=[]){let n=RT({},i);return kdA(this.injector,n,A).then(o=>this.bootstrapModuleFactory(o,n))}onDestroy(A){this._destroyListeners.push(A)}get injector(){return this._injector}destroy(){if(this._destroyed)throw new ZA(404,!1);this._modules.slice().forEach(i=>i.destroy()),this._destroyListeners.forEach(i=>i());let A=this._injector.get(qm,null);A&&(A.forEach(i=>i()),A.clear()),this._destroyed=!0}get destroyed(){return this._destroyed}static \u0275fac=function(i){return new(i||t)(he(Dt))};static \u0275prov=SA({token:t,factory:t.\u0275fac,providedIn:"platform"})}return t})(),Wh=null,ez=new BA("");function KdA(t){if(Wh&&!Wh.get(ez,!1))throw new ZA(400,!1);UCA(),Wh=t;let e=t.get(Az);return TdA(t),e}function Sb(t,e,A=[]){let i=`Platform: ${e}`,n=new BA(i);return(o=[])=>{let r=tz();if(!r||r.injector.get(ez,!1)){let s=[...A,...o,{provide:n,useValue:!0}];t?t(s):KdA(YdA(s,i))}return JdA(n)}}function YdA(t=[],e){return Dt.create({name:e,providers:[{provide:$m,useValue:"platform"},{provide:qm,useValue:new Set([()=>Wh=null])},...t]})}function JdA(t){let e=tz();if(!e)throw new ZA(401,!1);return e}function tz(){return Wh?.get(Az)??null}function TdA(t){let e=t.get(V9,null);$s(t,()=>{e?.forEach(A=>A())})}var lt=(()=>{class t{static __NG_ELEMENT_ID__=zdA}return t})();function zdA(t){return HdA(Xr(),Ut(),(t&16)===16)}function HdA(t,e,A){if(Rd(t)&&!A){let i=jl(t.index,e);return new iQ(i,i)}else if(t.type&175){let i=e[_a];return new iQ(i,e)}return null}var B9=class{constructor(){}supports(e){return vT(e)}create(e){return new E9(e)}},OdA=(t,e)=>e,E9=class{length=0;collection;_linkedRecords=null;_unlinkedRecords=null;_previousItHead=null;_itHead=null;_itTail=null;_additionsHead=null;_additionsTail=null;_movesHead=null;_movesTail=null;_removalsHead=null;_removalsTail=null;_identityChangesHead=null;_identityChangesTail=null;_trackByFn;constructor(e){this._trackByFn=e||OdA}forEachItem(e){let A;for(A=this._itHead;A!==null;A=A._next)e(A)}forEachOperation(e){let A=this._itHead,i=this._removalsHead,n=0,o=null;for(;A||i;){let r=!i||A&&A.currentIndex<$K(i,n,o)?A:i,s=$K(r,n,o),a=r.currentIndex;if(r===i)n--,i=i._nextRemoved;else if(A=A._next,r.previousIndex==null)n++;else{o||(o=[]);let c=s-n,l=a-n;if(c!=l){for(let C=0;C<c;C++){let d=C<o.length?o[C]:o[C]=0,B=d+C;l<=B&&B<c&&(o[C]=d+1)}let I=r.previousIndex;o[I]=l-c}}s!==a&&e(r,s,a)}}forEachPreviousItem(e){let A;for(A=this._previousItHead;A!==null;A=A._nextPrevious)e(A)}forEachAddedItem(e){let A;for(A=this._additionsHead;A!==null;A=A._nextAdded)e(A)}forEachMovedItem(e){let A;for(A=this._movesHead;A!==null;A=A._nextMoved)e(A)}forEachRemovedItem(e){let A;for(A=this._removalsHead;A!==null;A=A._nextRemoved)e(A)}forEachIdentityChange(e){let A;for(A=this._identityChangesHead;A!==null;A=A._nextIdentityChange)e(A)}diff(e){if(e==null&&(e=[]),!vT(e))throw new ZA(900,!1);return this.check(e)?this:null}onDestroy(){}check(e){this._reset();let A=this._itHead,i=!1,n,o,r;if(Array.isArray(e)){this.length=e.length;for(let s=0;s<this.length;s++)o=e[s],r=this._trackByFn(s,o),A===null||!Object.is(A.trackById,r)?(A=this._mismatch(A,o,r,s),i=!0):(i&&(A=this._verifyReinsertion(A,o,r,s)),Object.is(A.item,o)||this._addIdentityChange(A,o)),A=A._next}else n=0,LCA(e,s=>{r=this._trackByFn(n,s),A===null||!Object.is(A.trackById,r)?(A=this._mismatch(A,s,r,n),i=!0):(i&&(A=this._verifyReinsertion(A,s,r,n)),Object.is(A.item,s)||this._addIdentityChange(A,s)),A=A._next,n++}),this.length=n;return this._truncate(A),this.collection=e,this.isDirty}get isDirty(){return this._additionsHead!==null||this._movesHead!==null||this._removalsHead!==null||this._identityChangesHead!==null}_reset(){if(this.isDirty){let e;for(e=this._previousItHead=this._itHead;e!==null;e=e._next)e._nextPrevious=e._next;for(e=this._additionsHead;e!==null;e=e._nextAdded)e.previousIndex=e.currentIndex;for(this._additionsHead=this._additionsTail=null,e=this._movesHead;e!==null;e=e._nextMoved)e.previousIndex=e.currentIndex;this._movesHead=this._movesTail=null,this._removalsHead=this._removalsTail=null,this._identityChangesHead=this._identityChangesTail=null}}_mismatch(e,A,i,n){let o;return e===null?o=this._itTail:(o=e._prev,this._remove(e)),e=this._unlinkedRecords===null?null:this._unlinkedRecords.get(i,null),e!==null?(Object.is(e.item,A)||this._addIdentityChange(e,A),this._reinsertAfter(e,o,n)):(e=this._linkedRecords===null?null:this._linkedRecords.get(i,n),e!==null?(Object.is(e.item,A)||this._addIdentityChange(e,A),this._moveAfter(e,o,n)):e=this._addAfter(new h9(A,i),o,n)),e}_verifyReinsertion(e,A,i,n){let o=this._unlinkedRecords===null?null:this._unlinkedRecords.get(i,null);return o!==null?e=this._reinsertAfter(o,e._prev,n):e.currentIndex!=n&&(e.currentIndex=n,this._addToMoves(e,n)),e}_truncate(e){for(;e!==null;){let A=e._next;this._addToRemovals(this._unlink(e)),e=A}this._unlinkedRecords!==null&&this._unlinkedRecords.clear(),this._additionsTail!==null&&(this._additionsTail._nextAdded=null),this._movesTail!==null&&(this._movesTail._nextMoved=null),this._itTail!==null&&(this._itTail._next=null),this._removalsTail!==null&&(this._removalsTail._nextRemoved=null),this._identityChangesTail!==null&&(this._identityChangesTail._nextIdentityChange=null)}_reinsertAfter(e,A,i){this._unlinkedRecords!==null&&this._unlinkedRecords.remove(e);let n=e._prevRemoved,o=e._nextRemoved;return n===null?this._removalsHead=o:n._nextRemoved=o,o===null?this._removalsTail=n:o._prevRemoved=n,this._insertAfter(e,A,i),this._addToMoves(e,i),e}_moveAfter(e,A,i){return this._unlink(e),this._insertAfter(e,A,i),this._addToMoves(e,i),e}_addAfter(e,A,i){return this._insertAfter(e,A,i),this._additionsTail===null?this._additionsTail=this._additionsHead=e:this._additionsTail=this._additionsTail._nextAdded=e,e}_insertAfter(e,A,i){let n=A===null?this._itHead:A._next;return e._next=n,e._prev=A,n===null?this._itTail=e:n._prev=e,A===null?this._itHead=e:A._next=e,this._linkedRecords===null&&(this._linkedRecords=new Vm),this._linkedRecords.put(e),e.currentIndex=i,e}_remove(e){return this._addToRemovals(this._unlink(e))}_unlink(e){this._linkedRecords!==null&&this._linkedRecords.remove(e);let A=e._prev,i=e._next;return A===null?this._itHead=i:A._next=i,i===null?this._itTail=A:i._prev=A,e}_addToMoves(e,A){return e.previousIndex===A||(this._movesTail===null?this._movesTail=this._movesHead=e:this._movesTail=this._movesTail._nextMoved=e),e}_addToRemovals(e){return this._unlinkedRecords===null&&(this._unlinkedRecords=new Vm),this._unlinkedRecords.put(e),e.currentIndex=null,e._nextRemoved=null,this._removalsTail===null?(this._removalsTail=this._removalsHead=e,e._prevRemoved=null):(e._prevRemoved=this._removalsTail,this._removalsTail=this._removalsTail._nextRemoved=e),e}_addIdentityChange(e,A){return e.item=A,this._identityChangesTail===null?this._identityChangesTail=this._identityChangesHead=e:this._identityChangesTail=this._identityChangesTail._nextIdentityChange=e,e}},h9=class{item;trackById;currentIndex=null;previousIndex=null;_nextPrevious=null;_prev=null;_next=null;_prevDup=null;_nextDup=null;_prevRemoved=null;_nextRemoved=null;_nextAdded=null;_nextMoved=null;_nextIdentityChange=null;constructor(e,A){this.item=e,this.trackById=A}},Q9=class{_head=null;_tail=null;add(e){this._head===null?(this._head=this._tail=e,e._nextDup=null,e._prevDup=null):(this._tail._nextDup=e,e._prevDup=this._tail,e._nextDup=null,this._tail=e)}get(e,A){let i;for(i=this._head;i!==null;i=i._nextDup)if((A===null||A<=i.currentIndex)&&Object.is(i.trackById,e))return i;return null}remove(e){let A=e._prevDup,i=e._nextDup;return A===null?this._head=i:A._nextDup=i,i===null?this._tail=A:i._prevDup=A,this._head===null}},Vm=class{map=new Map;put(e){let A=e.trackById,i=this.map.get(A);i||(i=new Q9,this.map.set(A,i)),i.add(e)}get(e,A){let i=e,n=this.map.get(i);return n?n.get(e,A):null}remove(e){let A=e.trackById;return this.map.get(A).remove(e)&&this.map.delete(A),e}get isEmpty(){return this.map.size===0}clear(){this.map.clear()}};function $K(t,e,A){let i=t.previousIndex;if(i===null)return i;let n=0;return A&&i<A.length&&(n=A[i]),i+e+n}var u9=class{constructor(){}supports(e){return e instanceof Map||hb(e)}create(){return new f9}},f9=class{_records=new Map;_mapHead=null;_appendAfter=null;_previousMapHead=null;_changesHead=null;_changesTail=null;_additionsHead=null;_additionsTail=null;_removalsHead=null;_removalsTail=null;get isDirty(){return this._additionsHead!==null||this._changesHead!==null||this._removalsHead!==null}forEachItem(e){let A;for(A=this._mapHead;A!==null;A=A._next)e(A)}forEachPreviousItem(e){let A;for(A=this._previousMapHead;A!==null;A=A._nextPrevious)e(A)}forEachChangedItem(e){let A;for(A=this._changesHead;A!==null;A=A._nextChanged)e(A)}forEachAddedItem(e){let A;for(A=this._additionsHead;A!==null;A=A._nextAdded)e(A)}forEachRemovedItem(e){let A;for(A=this._removalsHead;A!==null;A=A._nextRemoved)e(A)}diff(e){if(!e)e=new Map;else if(!(e instanceof Map||hb(e)))throw new ZA(900,!1);return this.check(e)?this:null}onDestroy(){}check(e){this._reset();let A=this._mapHead;if(this._appendAfter=null,this._forEach(e,(i,n)=>{if(A&&A.key===n)this._maybeAddToChanges(A,i),this._appendAfter=A,A=A._next;else{let o=this._getOrCreateRecordForKey(n,i);A=this._insertBeforeOrAppend(A,o)}}),A){A._prev&&(A._prev._next=null),this._removalsHead=A;for(let i=A;i!==null;i=i._nextRemoved)i===this._mapHead&&(this._mapHead=null),this._records.delete(i.key),i._nextRemoved=i._next,i.previousValue=i.currentValue,i.currentValue=null,i._prev=null,i._next=null}return this._changesTail&&(this._changesTail._nextChanged=null),this._additionsTail&&(this._additionsTail._nextAdded=null),this.isDirty}_insertBeforeOrAppend(e,A){if(e){let i=e._prev;return A._next=e,A._prev=i,e._prev=A,i&&(i._next=A),e===this._mapHead&&(this._mapHead=A),this._appendAfter=e,e}return this._appendAfter?(this._appendAfter._next=A,A._prev=this._appendAfter):this._mapHead=A,this._appendAfter=A,null}_getOrCreateRecordForKey(e,A){if(this._records.has(e)){let n=this._records.get(e);this._maybeAddToChanges(n,A);let o=n._prev,r=n._next;return o&&(o._next=r),r&&(r._prev=o),n._next=null,n._prev=null,n}let i=new m9(e);return this._records.set(e,i),i.currentValue=A,this._addToAdditions(i),i}_reset(){if(this.isDirty){let e;for(this._previousMapHead=this._mapHead,e=this._previousMapHead;e!==null;e=e._next)e._nextPrevious=e._next;for(e=this._changesHead;e!==null;e=e._nextChanged)e.previousValue=e.currentValue;for(e=this._additionsHead;e!=null;e=e._nextAdded)e.previousValue=e.currentValue;this._changesHead=this._changesTail=null,this._additionsHead=this._additionsTail=null,this._removalsHead=null}}_maybeAddToChanges(e,A){Object.is(A,e.currentValue)||(e.previousValue=e.currentValue,e.currentValue=A,this._addToChanges(e))}_addToAdditions(e){this._additionsHead===null?this._additionsHead=this._additionsTail=e:(this._additionsTail._nextAdded=e,this._additionsTail=e)}_addToChanges(e){this._changesHead===null?this._changesHead=this._changesTail=e:(this._changesTail._nextChanged=e,this._changesTail=e)}_forEach(e,A){e instanceof Map?e.forEach(A):Object.keys(e).forEach(i=>A(e[i],i))}},m9=class{key;previousValue=null;currentValue=null;_nextPrevious=null;_next=null;_prev=null;_nextAdded=null;_nextRemoved=null;_nextChanged=null;constructor(e){this.key=e}};function AY(){return new Xl([new B9])}var Xl=(()=>{class t{factories;static \u0275prov=SA({token:t,providedIn:"root",factory:AY});constructor(A){this.factories=A}static create(A,i){if(i!=null){let n=i.factories.slice();A=A.concat(n)}return new t(A)}static extend(A){return{provide:t,useFactory:i=>t.create(A,i||AY()),deps:[[t,new rQ,new hI]]}}find(A){let i=this.factories.find(n=>n.supports(A));if(i!=null)return i;throw new ZA(901,!1)}}return t})();function eY(){return new pp([new u9])}var pp=(()=>{class t{static \u0275prov=SA({token:t,providedIn:"root",factory:eY});factories;constructor(A){this.factories=A}static create(A,i){if(i){let n=i.factories.slice();A=A.concat(n)}return new t(A)}static extend(A){return{provide:t,useFactory:i=>t.create(A,i||eY()),deps:[[t,new rQ,new hI]]}}find(A){let i=this.factories.find(n=>n.supports(A));if(i)return i;throw new ZA(901,!1)}}return t})();var iz=Sb(null,"core",[]),nz=(()=>{class t{constructor(A){}static \u0275fac=function(i){return new(i||t)(he(Ua))};static \u0275mod=ge({type:t});static \u0275inj=le({})}return t})();function ae(t){return typeof t=="boolean"?t:t!=null&&t!=="false"}function Mi(t,e=NaN){return!isNaN(parseFloat(t))&&!isNaN(Number(t))?Number(t):e}function ia(t){return U7(t)}function c0(t,e){return _f(t,e?.equal)}var p9=class{[js];constructor(e){this[js]=e}destroy(){this[js].destroy()}};function mQ(t,e){!e?.injector&&b9(mQ);let A=e?.injector??m(Dt),i=e?.manualCleanup!==!0?A.get(Fd):null,n,o=A.get(W9,null,{optional:!0}),r=A.get(CI);return o!==null&&!e?.forceRoot?(n=qdA(o.view,r,t),i instanceof xm&&i._lView===o.view&&(i=null)):n=VdA(t,A.get(MT),r),n.injector=A,i!==null&&(n.onDestroyFn=i.onDestroy(()=>n.destroy())),new p9(n)}var oz=Ne(nA({},id),{consumerIsAlwaysLive:!0,consumerAllowSignalWrites:!0,dirty:!0,hasRun:!1,cleanupFns:void 0,zone:null,kind:"effect",onDestroyFn:eQ,run(){if(this.dirty=!1,this.hasRun&&!xf(this))return;this.hasRun=!0;let t=i=>(this.cleanupFns??=[]).push(i),e=_h(this),A=Mm(!1);try{this.maybeCleanup(),this.fn(t)}finally{Mm(A),Lf(this,e)}},maybeCleanup(){if(this.cleanupFns?.length)try{for(;this.cleanupFns.length;)this.cleanupFns.pop()()}finally{this.cleanupFns=[]}}}),PdA=Ne(nA({},oz),{consumerMarkedDirty(){this.scheduler.schedule(this),this.notifier.notify(12)},destroy(){Gh(this),this.onDestroyFn(),this.maybeCleanup(),this.scheduler.remove(this)}}),jdA=Ne(nA({},oz),{consumerMarkedDirty(){this.view[Vt]|=8192,xd(this.view),this.notifier.notify(13)},destroy(){Gh(this),this.onDestroyFn(),this.maybeCleanup(),this.view[aI]?.delete(this)}});function qdA(t,e,A){let i=Object.create(jdA);return i.view=t,i.zone=typeof Zone<"u"?Zone.current:null,i.notifier=e,i.fn=A,t[aI]??=new Set,t[aI].add(i),i.consumerMarkedDirty(i),i}function VdA(t,e,A){let i=Object.create(PdA);return i.fn=t,i.scheduler=e,i.notifier=A,i.zone=typeof Zone<"u"?Zone.current:null,i.scheduler.schedule(i),i.notifier.notify(12),i}function wp(t,e){let A=d2(t),i=e.elementInjector||Ap();return new dI(A).create(i,e.projectableNodes,e.hostElement,e.environmentInjector)}function rz(t){let e=d2(t);if(!e)return null;let A=new dI(e);return{get selector(){return A.selector},get type(){return A.componentType},get inputs(){return A.inputs},get outputs(){return A.outputs},get ngContentSelectors(){return A.ngContentSelectors},get isStandalone(){return e.standalone},get isSignal(){return e.signals}}}var tt=new BA("");var cz=null;function za(){return cz}function Rb(t){cz??=t}var pQ=class{},wQ=(()=>{class t{historyGo(A){throw new Error("")}static \u0275fac=function(i){return new(i||t)};static \u0275prov=SA({token:t,factory:()=>m(lz),providedIn:"platform"})}return t})(),Lb=new BA(""),lz=(()=>{class t extends wQ{_location;_history;_doc=m(tt);constructor(){super(),this._location=window.location,this._history=window.history}getBaseHrefFromDOM(){return za().getBaseHref(this._doc)}onPopState(A){let i=za().getGlobalEventTarget(this._doc,"window");return i.addEventListener("popstate",A,!1),()=>i.removeEventListener("popstate",A)}onHashChange(A){let i=za().getGlobalEventTarget(this._doc,"window");return i.addEventListener("hashchange",A,!1),()=>i.removeEventListener("hashchange",A)}get href(){return this._location.href}get protocol(){return this._location.protocol}get hostname(){return this._location.hostname}get port(){return this._location.port}get pathname(){return this._location.pathname}get search(){return this._location.search}get hash(){return this._location.hash}set pathname(A){this._location.pathname=A}pushState(A,i,n){this._history.pushState(A,i,n)}replaceState(A,i,n){this._history.replaceState(A,i,n)}forward(){this._history.forward()}back(){this._history.back()}historyGo(A=0){this._history.go(A)}getState(){return this._history.state}static \u0275fac=function(i){return new(i||t)};static \u0275prov=SA({token:t,factory:()=>new t,providedIn:"platform"})}return t})();function Dp(t,e){return t?e?t.endsWith("/")?e.startsWith("/")?t+e.slice(1):t+e:e.startsWith("/")?t+e:`${t}/${e}`:t:e}function sz(t){let e=t.search(/#|\?|$/);return t[e-1]==="/"?t.slice(0,e-1)+t.slice(e):t}function tl(t){return t&&t[0]!=="?"?`?${t}`:t}var l0=(()=>{class t{historyGo(A){throw new Error("")}static \u0275fac=function(i){return new(i||t)};static \u0275prov=SA({token:t,factory:()=>m(vp),providedIn:"root"})}return t})(),yp=new BA(""),vp=(()=>{class t extends l0{_platformLocation;_baseHref;_removeListenerFns=[];constructor(A,i){super(),this._platformLocation=A,this._baseHref=i??this._platformLocation.getBaseHrefFromDOM()??m(tt).location?.origin??""}ngOnDestroy(){for(;this._removeListenerFns.length;)this._removeListenerFns.pop()()}onPopState(A){this._removeListenerFns.push(this._platformLocation.onPopState(A),this._platformLocation.onHashChange(A))}getBaseHref(){return this._baseHref}prepareExternalUrl(A){return Dp(this._baseHref,A)}path(A=!1){let i=this._platformLocation.pathname+tl(this._platformLocation.search),n=this._platformLocation.hash;return n&&A?`${i}${n}`:i}pushState(A,i,n,o){let r=this.prepareExternalUrl(n+tl(o));this._platformLocation.pushState(A,i,r)}replaceState(A,i,n,o){let r=this.prepareExternalUrl(n+tl(o));this._platformLocation.replaceState(A,i,r)}forward(){this._platformLocation.forward()}back(){this._platformLocation.back()}getState(){return this._platformLocation.getState()}historyGo(A=0){this._platformLocation.historyGo?.(A)}static \u0275fac=function(i){return new(i||t)(he(wQ),he(yp,8))};static \u0275prov=SA({token:t,factory:t.\u0275fac,providedIn:"root"})}return t})(),Qc=(()=>{class t{_subject=new HA;_basePath;_locationStrategy;_urlChangeListeners=[];_urlChangeSubscription=null;constructor(A){this._locationStrategy=A;let i=this._locationStrategy.getBaseHref();this._basePath=XdA(sz(az(i))),this._locationStrategy.onPopState(n=>{this._subject.next({url:this.path(!0),pop:!0,state:n.state,type:n.type})})}ngOnDestroy(){this._urlChangeSubscription?.unsubscribe(),this._urlChangeListeners=[]}path(A=!1){return this.normalize(this._locationStrategy.path(A))}getState(){return this._locationStrategy.getState()}isCurrentPathEqualTo(A,i=""){return this.path()==this.normalize(A+tl(i))}normalize(A){return t.stripTrailingSlash(WdA(this._basePath,az(A)))}prepareExternalUrl(A){return A&&A[0]!=="/"&&(A="/"+A),this._locationStrategy.prepareExternalUrl(A)}go(A,i="",n=null){this._locationStrategy.pushState(n,"",A,i),this._notifyUrlChangeListeners(this.prepareExternalUrl(A+tl(i)),n)}replaceState(A,i="",n=null){this._locationStrategy.replaceState(n,"",A,i),this._notifyUrlChangeListeners(this.prepareExternalUrl(A+tl(i)),n)}forward(){this._locationStrategy.forward()}back(){this._locationStrategy.back()}historyGo(A=0){this._locationStrategy.historyGo?.(A)}onUrlChange(A){return this._urlChangeListeners.push(A),this._urlChangeSubscription??=this.subscribe(i=>{this._notifyUrlChangeListeners(i.url,i.state)}),()=>{let i=this._urlChangeListeners.indexOf(A);this._urlChangeListeners.splice(i,1),this._urlChangeListeners.length===0&&(this._urlChangeSubscription?.unsubscribe(),this._urlChangeSubscription=null)}}_notifyUrlChangeListeners(A="",i){this._urlChangeListeners.forEach(n=>n(A,i))}subscribe(A,i,n){return this._subject.subscribe({next:A,error:i??void 0,complete:n??void 0})}static normalizeQueryParams=tl;static joinWithSlash=Dp;static stripTrailingSlash=sz;static \u0275fac=function(i){return new(i||t)(he(l0))};static \u0275prov=SA({token:t,factory:()=>ZdA(),providedIn:"root"})}return t})();function ZdA(){return new Qc(he(l0))}function WdA(t,e){if(!t||!e.startsWith(t))return e;let A=e.substring(t.length);return A===""||["/",";","?","#"].includes(A[0])?A:e}function az(t){return t.replace(/\/index.html$/,"")}function XdA(t){if(new RegExp("^(https?:)?//").test(t)){let[,A]=t.split(/\/\/[^\/]+/);return A}return t}var _b=(()=>{class t extends l0{_platformLocation;_baseHref="";_removeListenerFns=[];constructor(A,i){super(),this._platformLocation=A,i!=null&&(this._baseHref=i)}ngOnDestroy(){for(;this._removeListenerFns.length;)this._removeListenerFns.pop()()}onPopState(A){this._removeListenerFns.push(this._platformLocation.onPopState(A),this._platformLocation.onHashChange(A))}getBaseHref(){return this._baseHref}path(A=!1){let i=this._platformLocation.hash??"#";return i.length>0?i.substring(1):i}prepareExternalUrl(A){let i=Dp(this._baseHref,A);return i.length>0?"#"+i:i}pushState(A,i,n,o){let r=this.prepareExternalUrl(n+tl(o))||this._platformLocation.pathname;this._platformLocation.pushState(A,i,r)}replaceState(A,i,n,o){let r=this.prepareExternalUrl(n+tl(o))||this._platformLocation.pathname;this._platformLocation.replaceState(A,i,r)}forward(){this._platformLocation.forward()}back(){this._platformLocation.back()}getState(){return this._platformLocation.getState()}historyGo(A=0){this._platformLocation.historyGo?.(A)}static \u0275fac=function(i){return new(i||t)(he(wQ),he(yp,8))};static \u0275prov=SA({token:t,factory:t.\u0275fac})}return t})();var xb=/\s+/,gz=[],Ha=(()=>{class t{_ngEl;_renderer;initialClasses=gz;rawClass;stateMap=new Map;constructor(A,i){this._ngEl=A,this._renderer=i}set klass(A){this.initialClasses=A!=null?A.trim().split(xb):gz}set ngClass(A){this.rawClass=typeof A=="string"?A.trim().split(xb):A}ngDoCheck(){for(let i of this.initialClasses)this._updateState(i,!0);let A=this.rawClass;if(Array.isArray(A)||A instanceof Set)for(let i of A)this._updateState(i,!0);else if(A!=null)for(let i of Object.keys(A))this._updateState(i,!!A[i]);this._applyStateDiff()}_updateState(A,i){let n=this.stateMap.get(A);n!==void 0?(n.enabled!==i&&(n.changed=!0,n.enabled=i),n.touched=!0):this.stateMap.set(A,{enabled:i,changed:!0,touched:!0})}_applyStateDiff(){for(let A of this.stateMap){let i=A[0],n=A[1];n.changed?(this._toggleClass(i,n.enabled),n.changed=!1):n.touched||(n.enabled&&this._toggleClass(i,!1),this.stateMap.delete(i)),n.touched=!1}}_toggleClass(A,i){A=A.trim(),A.length>0&&A.split(xb).forEach(n=>{i?this._renderer.addClass(this._ngEl.nativeElement,n):this._renderer.removeClass(this._ngEl.nativeElement,n)})}static \u0275fac=function(i){return new(i||t)(zA(te),zA(Gi))};static \u0275dir=OA({type:t,selectors:[["","ngClass",""]],inputs:{klass:[0,"class","klass"],ngClass:"ngClass"}})}return t})();var bp=class{$implicit;ngForOf;index;count;constructor(e,A,i,n){this.$implicit=e,this.ngForOf=A,this.index=i,this.count=n}get first(){return this.index===0}get last(){return this.index===this.count-1}get even(){return this.index%2===0}get odd(){return!this.even}},kp=(()=>{class t{_viewContainer;_template;_differs;set ngForOf(A){this._ngForOf=A,this._ngForOfDirty=!0}set ngForTrackBy(A){this._trackByFn=A}get ngForTrackBy(){return this._trackByFn}_ngForOf=null;_ngForOfDirty=!0;_differ=null;_trackByFn;constructor(A,i,n){this._viewContainer=A,this._template=i,this._differs=n}set ngForTemplate(A){A&&(this._template=A)}ngDoCheck(){if(this._ngForOfDirty){this._ngForOfDirty=!1;let A=this._ngForOf;!this._differ&&A&&(this._differ=this._differs.find(A).create(this.ngForTrackBy))}if(this._differ){let A=this._differ.diff(this._ngForOf);A&&this._applyChanges(A)}}_applyChanges(A){let i=this._viewContainer;A.forEachOperation((n,o,r)=>{if(n.previousIndex==null)i.createEmbeddedView(this._template,new bp(n.item,this._ngForOf,-1,-1),r===null?void 0:r);else if(r==null)i.remove(o===null?void 0:o);else if(o!==null){let s=i.get(o);i.move(s,r),Iz(s,n)}});for(let n=0,o=i.length;n<o;n++){let s=i.get(n).context;s.index=n,s.count=o,s.ngForOf=this._ngForOf}A.forEachIdentityChange(n=>{let o=i.get(n.currentIndex);Iz(o,n)})}static ngTemplateContextGuard(A,i){return!0}static \u0275fac=function(i){return new(i||t)(zA(Un),zA(vn),zA(Xl))};static \u0275dir=OA({type:t,selectors:[["","ngFor","","ngForOf",""]],inputs:{ngForOf:"ngForOf",ngForTrackBy:"ngForTrackBy",ngForTemplate:"ngForTemplate"}})}return t})();function Iz(t,e){t.context.$implicit=e.item}var DQ=(()=>{class t{_viewContainer;_context=new Mp;_thenTemplateRef=null;_elseTemplateRef=null;_thenViewRef=null;_elseViewRef=null;constructor(A,i){this._viewContainer=A,this._thenTemplateRef=i}set ngIf(A){this._context.$implicit=this._context.ngIf=A,this._updateView()}set ngIfThen(A){Cz(A,!1),this._thenTemplateRef=A,this._thenViewRef=null,this._updateView()}set ngIfElse(A){Cz(A,!1),this._elseTemplateRef=A,this._elseViewRef=null,this._updateView()}_updateView(){this._context.$implicit?this._thenViewRef||(this._viewContainer.clear(),this._elseViewRef=null,this._thenTemplateRef&&(this._thenViewRef=this._viewContainer.createEmbeddedView(this._thenTemplateRef,this._context))):this._elseViewRef||(this._viewContainer.clear(),this._thenViewRef=null,this._elseTemplateRef&&(this._elseViewRef=this._viewContainer.createEmbeddedView(this._elseTemplateRef,this._context)))}static ngIfUseIfTypeGuard;static ngTemplateGuard_ngIf;static ngTemplateContextGuard(A,i){return!0}static \u0275fac=function(i){return new(i||t)(zA(Un),zA(vn))};static \u0275dir=OA({type:t,selectors:[["","ngIf",""]],inputs:{ngIf:"ngIf",ngIfThen:"ngIfThen",ngIfElse:"ngIfElse"}})}return t})(),Mp=class{$implicit=null;ngIf=null};function Cz(t,e){if(t&&!t.createEmbeddedView)throw new ZA(2020,!1)}var yQ=(()=>{class t{_ngEl;_differs;_renderer;_ngStyle=null;_differ=null;constructor(A,i,n){this._ngEl=A,this._differs=i,this._renderer=n}set ngStyle(A){this._ngStyle=A,!this._differ&&A&&(this._differ=this._differs.find(A).create())}ngDoCheck(){if(this._differ){let A=this._differ.diff(this._ngStyle);A&&this._applyChanges(A)}}_setStyle(A,i){let[n,o]=A.split("."),r=n.indexOf("-")===-1?void 0:Vl.DashCase;i!=null?this._renderer.setStyle(this._ngEl.nativeElement,n,o?`${i}${o}`:i,r):this._renderer.removeStyle(this._ngEl.nativeElement,n,r)}_applyChanges(A){A.forEachRemovedItem(i=>this._setStyle(i.key,null)),A.forEachAddedItem(i=>this._setStyle(i.key,i.currentValue)),A.forEachChangedItem(i=>this._setStyle(i.key,i.currentValue))}static \u0275fac=function(i){return new(i||t)(zA(te),zA(pp),zA(Gi))};static \u0275dir=OA({type:t,selectors:[["","ngStyle",""]],inputs:{ngStyle:"ngStyle"}})}return t})(),vQ=(()=>{class t{_viewContainerRef;_viewRef=null;ngTemplateOutletContext=null;ngTemplateOutlet=null;ngTemplateOutletInjector=null;constructor(A){this._viewContainerRef=A}ngOnChanges(A){if(this._shouldRecreateView(A)){let i=this._viewContainerRef;if(this._viewRef&&i.remove(i.indexOf(this._viewRef)),!this.ngTemplateOutlet){this._viewRef=null;return}let n=this._createContextForwardProxy();this._viewRef=i.createEmbeddedView(this.ngTemplateOutlet,n,{injector:this.ngTemplateOutletInjector??void 0})}}_shouldRecreateView(A){return!!A.ngTemplateOutlet||!!A.ngTemplateOutletInjector}_createContextForwardProxy(){return new Proxy({},{set:(A,i,n)=>this.ngTemplateOutletContext?Reflect.set(this.ngTemplateOutletContext,i,n):!1,get:(A,i,n)=>{if(this.ngTemplateOutletContext)return Reflect.get(this.ngTemplateOutletContext,i,n)}})}static \u0275fac=function(i){return new(i||t)(zA(Un))};static \u0275dir=OA({type:t,selectors:[["","ngTemplateOutlet",""]],inputs:{ngTemplateOutletContext:"ngTemplateOutletContext",ngTemplateOutlet:"ngTemplateOutlet",ngTemplateOutletInjector:"ngTemplateOutletInjector"},features:[Kt]})}return t})();function $dA(t,e){return new ZA(2100,!1)}var Fb=class{createSubscription(e,A){return ia(()=>e.subscribe({next:A,error:i=>{throw i}}))}dispose(e){ia(()=>e.unsubscribe())}},Nb=class{createSubscription(e,A){return e.then(A,i=>{throw i})}dispose(e){}},ABA=new Nb,eBA=new Fb,bQ=(()=>{class t{_ref;_latestValue=null;markForCheckOnValueUpdate=!0;_subscription=null;_obj=null;_strategy=null;constructor(A){this._ref=A}ngOnDestroy(){this._subscription&&this._dispose(),this._ref=null}transform(A){if(!this._obj){if(A)try{this.markForCheckOnValueUpdate=!1,this._subscribe(A)}finally{this.markForCheckOnValueUpdate=!0}return this._latestValue}return A!==this._obj?(this._dispose(),this.transform(A)):this._latestValue}_subscribe(A){this._obj=A,this._strategy=this._selectStrategy(A),this._subscription=this._strategy.createSubscription(A,i=>this._updateLatestValue(A,i))}_selectStrategy(A){if(u2(A))return ABA;if(pb(A))return eBA;throw $dA(t,A)}_dispose(){this._strategy.dispose(this._subscription),this._latestValue=null,this._subscription=null,this._obj=null}_updateLatestValue(A,i){A===this._obj&&(this._latestValue=i,this.markForCheckOnValueUpdate&&this._ref?.markForCheck())}static \u0275fac=function(i){return new(i||t)(zA(lt,16))};static \u0275pipe=Qp({name:"async",type:t,pure:!1})}return t})();function tBA(t,e){return{key:t,value:e}}var MQ=(()=>{class t{differs;constructor(A){this.differs=A}differ;keyValues=[];compareFn=dz;transform(A,i=dz){if(!A||!(A instanceof Map)&&typeof A!="object")return null;this.differ??=this.differs.find(A).create();let n=this.differ.diff(A),o=i!==this.compareFn;return n&&(this.keyValues=[],n.forEachItem(r=>{this.keyValues.push(tBA(r.key,r.currentValue))})),(n||o)&&(i&&this.keyValues.sort(i),this.compareFn=i),this.keyValues}static \u0275fac=function(i){return new(i||t)(zA(pp,16))};static \u0275pipe=Qp({name:"keyvalue",type:t,pure:!1})}return t})();function dz(t,e){let A=t.key,i=e.key;if(A===i)return 0;if(A==null)return 1;if(i==null)return-1;if(typeof A=="string"&&typeof i=="string")return A<i?-1:1;if(typeof A=="number"&&typeof i=="number")return A-i;if(typeof A=="boolean"&&typeof i=="boolean")return A<i?-1:1;let n=String(A),o=String(i);return n==o?0:n<o?-1:1}var g0=(()=>{class t{static \u0275fac=function(i){return new(i||t)};static \u0275mod=ge({type:t});static \u0275inj=le({})}return t})();function kQ(t,e){e=encodeURIComponent(e);for(let A of t.split(";")){let i=A.indexOf("="),[n,o]=i==-1?[A,""]:[A.slice(0,i),A.slice(i+1)];if(n.trim()===e)return decodeURIComponent(o)}return null}var Sp="browser",Bz="server";function $l(t){return t===Sp}function Rp(t){return t===Bz}var pI=class{};var Ez=(()=>{class t{static \u0275prov=SA({token:t,providedIn:"root",factory:()=>new Gb(m(tt),window)})}return t})(),Gb=class{document;window;offset=()=>[0,0];constructor(e,A){this.document=e,this.window=A}setOffset(e){Array.isArray(e)?this.offset=()=>e:this.offset=e}getScrollPosition(){return[this.window.scrollX,this.window.scrollY]}scrollToPosition(e){this.window.scrollTo(e[0],e[1])}scrollToAnchor(e){let A=iBA(this.document,e);A&&(this.scrollToElement(A),A.focus())}setHistoryScrollRestoration(e){this.window.history.scrollRestoration=e}scrollToElement(e){let A=e.getBoundingClientRect(),i=A.left+this.window.pageXOffset,n=A.top+this.window.pageYOffset,o=this.offset();this.window.scrollTo(i-o[0],n-o[1])}};function iBA(t,e){let A=t.getElementById(e)||t.getElementsByName(e)[0];if(A)return A;if(typeof t.createTreeWalker=="function"&&t.body&&typeof t.body.attachShadow=="function"){let i=t.createTreeWalker(t.body,NodeFilter.SHOW_ELEMENT),n=i.currentNode;for(;n;){let o=n.shadowRoot;if(o){let r=o.getElementById(e)||o.querySelector(`[name="${e}"]`);if(r)return r}n=i.nextNode()}}return null}var Fp=new BA(""),Jb=(()=>{class t{_zone;_plugins;_eventNameToPlugin=new Map;constructor(A,i){this._zone=i,A.forEach(n=>{n.manager=this}),this._plugins=A.slice().reverse()}addEventListener(A,i,n,o){return this._findPluginFor(i).addEventListener(A,i,n,o)}getZone(){return this._zone}_findPluginFor(A){let i=this._eventNameToPlugin.get(A);if(i)return i;if(i=this._plugins.find(o=>o.supports(A)),!i)throw new ZA(5101,!1);return this._eventNameToPlugin.set(A,i),i}static \u0275fac=function(i){return new(i||t)(he(Fp),he(de))};static \u0275prov=SA({token:t,factory:t.\u0275fac})}return t})(),SQ=class{_doc;constructor(e){this._doc=e}manager},Lp="ng-app-id";function hz(t){for(let e of t)e.remove()}function Qz(t,e){let A=e.createElement("style");return A.textContent=t,A}function nBA(t,e,A,i){let n=t.head?.querySelectorAll(`style[${Lp}="${e}"],link[${Lp}="${e}"]`);if(n)for(let o of n)o.removeAttribute(Lp),o instanceof HTMLLinkElement?i.set(o.href.slice(o.href.lastIndexOf("/")+1),{usage:0,elements:[o]}):o.textContent&&A.set(o.textContent,{usage:0,elements:[o]})}function Kb(t,e){let A=e.createElement("link");return A.setAttribute("rel","stylesheet"),A.setAttribute("href",t),A}var Tb=(()=>{class t{doc;appId;nonce;inline=new Map;external=new Map;hosts=new Set;isServer;constructor(A,i,n,o={}){this.doc=A,this.appId=i,this.nonce=n,this.isServer=Rp(o),nBA(A,i,this.inline,this.external),this.hosts.add(A.head)}addStyles(A,i){for(let n of A)this.addUsage(n,this.inline,Qz);i?.forEach(n=>this.addUsage(n,this.external,Kb))}removeStyles(A,i){for(let n of A)this.removeUsage(n,this.inline);i?.forEach(n=>this.removeUsage(n,this.external))}addUsage(A,i,n){let o=i.get(A);o?o.usage++:i.set(A,{usage:1,elements:[...this.hosts].map(r=>this.addElement(r,n(A,this.doc)))})}removeUsage(A,i){let n=i.get(A);n&&(n.usage--,n.usage<=0&&(hz(n.elements),i.delete(A)))}ngOnDestroy(){for(let[,{elements:A}]of[...this.inline,...this.external])hz(A);this.hosts.clear()}addHost(A){this.hosts.add(A);for(let[i,{elements:n}]of this.inline)n.push(this.addElement(A,Qz(i,this.doc)));for(let[i,{elements:n}]of this.external)n.push(this.addElement(A,Kb(i,this.doc)))}removeHost(A){this.hosts.delete(A)}addElement(A,i){return this.nonce&&i.setAttribute("nonce",this.nonce),this.isServer&&i.setAttribute(Lp,this.appId),A.appendChild(i)}static \u0275fac=function(i){return new(i||t)(he(tt),he(fI),he(gQ,8),he(hc))};static \u0275prov=SA({token:t,factory:t.\u0275fac})}return t})(),Ub={svg:"http://www.w3.org/2000/svg",xhtml:"http://www.w3.org/1999/xhtml",xlink:"http://www.w3.org/1999/xlink",xml:"http://www.w3.org/XML/1998/namespace",xmlns:"http://www.w3.org/2000/xmlns/",math:"http://www.w3.org/1998/Math/MathML"},zb=/%COMP%/g;var fz="%COMP%",oBA=`_nghost-${fz}`,rBA=`_ngcontent-${fz}`,sBA=!0,aBA=new BA("",{providedIn:"root",factory:()=>sBA});function cBA(t){return rBA.replace(zb,t)}function lBA(t){return oBA.replace(zb,t)}function mz(t,e){return e.map(A=>A.replace(zb,t))}var xQ=(()=>{class t{eventManager;sharedStylesHost;appId;removeStylesOnCompDestroy;doc;platformId;ngZone;nonce;tracingService;rendererByCompId=new Map;defaultRenderer;platformIsServer;constructor(A,i,n,o,r,s,a,c=null,l=null){this.eventManager=A,this.sharedStylesHost=i,this.appId=n,this.removeStylesOnCompDestroy=o,this.doc=r,this.platformId=s,this.ngZone=a,this.nonce=c,this.tracingService=l,this.platformIsServer=Rp(s),this.defaultRenderer=new RQ(A,r,a,this.platformIsServer,this.tracingService)}createRenderer(A,i){if(!A||!i)return this.defaultRenderer;this.platformIsServer&&i.encapsulation===ql.ShadowDom&&(i=Ne(nA({},i),{encapsulation:ql.Emulated}));let n=this.getOrCreateRenderer(A,i);return n instanceof xp?n.applyToHost(A):n instanceof LQ&&n.applyStyles(),n}getOrCreateRenderer(A,i){let n=this.rendererByCompId,o=n.get(i.id);if(!o){let r=this.doc,s=this.ngZone,a=this.eventManager,c=this.sharedStylesHost,l=this.removeStylesOnCompDestroy,I=this.platformIsServer,C=this.tracingService;switch(i.encapsulation){case ql.Emulated:o=new xp(a,c,i,this.appId,l,r,s,I,C);break;case ql.ShadowDom:return new Yb(a,c,A,i,r,s,this.nonce,I,C);default:o=new LQ(a,c,i,l,r,s,I,C);break}n.set(i.id,o)}return o}ngOnDestroy(){this.rendererByCompId.clear()}componentReplaced(A){this.rendererByCompId.delete(A)}static \u0275fac=function(i){return new(i||t)(he(Jb),he(Tb),he(fI),he(aBA),he(tt),he(hc),he(de),he(gQ),he(Gd,8))};static \u0275prov=SA({token:t,factory:t.\u0275fac})}return t})(),RQ=class{eventManager;doc;ngZone;platformIsServer;tracingService;data=Object.create(null);throwOnSyntheticProps=!0;constructor(e,A,i,n,o){this.eventManager=e,this.doc=A,this.ngZone=i,this.platformIsServer=n,this.tracingService=o}destroy(){}destroyNode=null;createElement(e,A){return A?this.doc.createElementNS(Ub[A]||A,e):this.doc.createElement(e)}createComment(e){return this.doc.createComment(e)}createText(e){return this.doc.createTextNode(e)}appendChild(e,A){(uz(e)?e.content:e).appendChild(A)}insertBefore(e,A,i){e&&(uz(e)?e.content:e).insertBefore(A,i)}removeChild(e,A){A.remove()}selectRootElement(e,A){let i=typeof e=="string"?this.doc.querySelector(e):e;if(!i)throw new ZA(-5104,!1);return A||(i.textContent=""),i}parentNode(e){return e.parentNode}nextSibling(e){return e.nextSibling}setAttribute(e,A,i,n){if(n){A=n+":"+A;let o=Ub[n];o?e.setAttributeNS(o,A,i):e.setAttribute(A,i)}else e.setAttribute(A,i)}removeAttribute(e,A,i){if(i){let n=Ub[i];n?e.removeAttributeNS(n,A):e.removeAttribute(`${i}:${A}`)}else e.removeAttribute(A)}addClass(e,A){e.classList.add(A)}removeClass(e,A){e.classList.remove(A)}setStyle(e,A,i,n){n&(Vl.DashCase|Vl.Important)?e.style.setProperty(A,i,n&Vl.Important?"important":""):e.style[A]=i}removeStyle(e,A,i){i&Vl.DashCase?e.style.removeProperty(A):e.style[A]=""}setProperty(e,A,i){e!=null&&(e[A]=i)}setValue(e,A){e.nodeValue=A}listen(e,A,i,n){if(typeof e=="string"&&(e=za().getGlobalEventTarget(this.doc,e),!e))throw new ZA(5102,!1);let o=this.decoratePreventDefault(i);return this.tracingService?.wrapEventListener&&(o=this.tracingService.wrapEventListener(e,A,o)),this.eventManager.addEventListener(e,A,o,n)}decoratePreventDefault(e){return A=>{if(A==="__ngUnwrap__")return e;(this.platformIsServer?this.ngZone.runGuarded(()=>e(A)):e(A))===!1&&A.preventDefault()}}};function uz(t){return t.tagName==="TEMPLATE"&&t.content!==void 0}var Yb=class extends RQ{sharedStylesHost;hostEl;shadowRoot;constructor(e,A,i,n,o,r,s,a,c){super(e,o,r,a,c),this.sharedStylesHost=A,this.hostEl=i,this.shadowRoot=i.attachShadow({mode:"open"}),this.sharedStylesHost.addHost(this.shadowRoot);let l=n.styles;l=mz(n.id,l);for(let C of l){let d=document.createElement("style");s&&d.setAttribute("nonce",s),d.textContent=C,this.shadowRoot.appendChild(d)}let I=n.getExternalStyles?.();if(I)for(let C of I){let d=Kb(C,o);s&&d.setAttribute("nonce",s),this.shadowRoot.appendChild(d)}}nodeOrShadowRoot(e){return e===this.hostEl?this.shadowRoot:e}appendChild(e,A){return super.appendChild(this.nodeOrShadowRoot(e),A)}insertBefore(e,A,i){return super.insertBefore(this.nodeOrShadowRoot(e),A,i)}removeChild(e,A){return super.removeChild(null,A)}parentNode(e){return this.nodeOrShadowRoot(super.parentNode(this.nodeOrShadowRoot(e)))}destroy(){this.sharedStylesHost.removeHost(this.shadowRoot)}},LQ=class extends RQ{sharedStylesHost;removeStylesOnCompDestroy;styles;styleUrls;constructor(e,A,i,n,o,r,s,a,c){super(e,o,r,s,a),this.sharedStylesHost=A,this.removeStylesOnCompDestroy=n;let l=i.styles;this.styles=c?mz(c,l):l,this.styleUrls=i.getExternalStyles?.(c)}applyStyles(){this.sharedStylesHost.addStyles(this.styles,this.styleUrls)}destroy(){this.removeStylesOnCompDestroy&&this.sharedStylesHost.removeStyles(this.styles,this.styleUrls)}},xp=class extends LQ{contentAttr;hostAttr;constructor(e,A,i,n,o,r,s,a,c){let l=n+"-"+i.id;super(e,A,i,o,r,s,a,c,l),this.contentAttr=cBA(l),this.hostAttr=lBA(l)}applyToHost(e){this.applyStyles(),this.setAttribute(e,this.hostAttr,"")}createElement(e,A){let i=super.createElement(e,A);return super.setAttribute(i,this.contentAttr,""),i}};var Np=class t extends pQ{supportsDOMEvents=!0;static makeCurrent(){Rb(new t)}onAndCancel(e,A,i,n){return e.addEventListener(A,i,n),()=>{e.removeEventListener(A,i,n)}}dispatchEvent(e,A){e.dispatchEvent(A)}remove(e){e.remove()}createElement(e,A){return A=A||this.getDefaultDocument(),A.createElement(e)}createHtmlDocument(){return document.implementation.createHTMLDocument("fakeTitle")}getDefaultDocument(){return document}isElementNode(e){return e.nodeType===Node.ELEMENT_NODE}isShadowRoot(e){return e instanceof DocumentFragment}getGlobalEventTarget(e,A){return A==="window"?window:A==="document"?e:A==="body"?e.body:null}getBaseHref(e){let A=gBA();return A==null?null:IBA(A)}resetBaseElement(){FQ=null}getUserAgent(){return window.navigator.userAgent}getCookie(e){return kQ(document.cookie,e)}},FQ=null;function gBA(){return FQ=FQ||document.querySelector("base"),FQ?FQ.getAttribute("href"):null}function IBA(t){return new URL(t,document.baseURI).pathname}var _p=class{addToWindow(e){Ws.getAngularTestability=(i,n=!0)=>{let o=e.findTestabilityInTree(i,n);if(o==null)throw new ZA(5103,!1);return o},Ws.getAllAngularTestabilities=()=>e.getAllTestabilities(),Ws.getAllAngularRootElements=()=>e.getAllRootElements();let A=i=>{let n=Ws.getAllAngularTestabilities(),o=n.length,r=function(){o--,o==0&&i()};n.forEach(s=>{s.whenStable(r)})};Ws.frameworkStabilizers||(Ws.frameworkStabilizers=[]),Ws.frameworkStabilizers.push(A)}findTestabilityInTree(e,A,i){if(A==null)return null;let n=e.getTestability(A);return n??(i?za().isShadowRoot(A)?this.findTestabilityInTree(e,A.host,!0):this.findTestabilityInTree(e,A.parentElement,!0):null)}},CBA=(()=>{class t{build(){return new XMLHttpRequest}static \u0275fac=function(i){return new(i||t)};static \u0275prov=SA({token:t,factory:t.\u0275fac})}return t})(),wz=(()=>{class t extends SQ{constructor(A){super(A)}supports(A){return!0}addEventListener(A,i,n,o){return A.addEventListener(i,n,o),()=>this.removeEventListener(A,i,n,o)}removeEventListener(A,i,n,o){return A.removeEventListener(i,n,o)}static \u0275fac=function(i){return new(i||t)(he(tt))};static \u0275prov=SA({token:t,factory:t.\u0275fac})}return t})(),pz=["alt","control","meta","shift"],dBA={"\b":"Backspace","	":"Tab","\x7F":"Delete","\x1B":"Escape",Del:"Delete",Esc:"Escape",Left:"ArrowLeft",Right:"ArrowRight",Up:"ArrowUp",Down:"ArrowDown",Menu:"ContextMenu",Scroll:"ScrollLock",Win:"OS"},BBA={alt:t=>t.altKey,control:t=>t.ctrlKey,meta:t=>t.metaKey,shift:t=>t.shiftKey},Dz=(()=>{class t extends SQ{constructor(A){super(A)}supports(A){return t.parseEventName(A)!=null}addEventListener(A,i,n,o){let r=t.parseEventName(i),s=t.eventCallback(r.fullKey,n,this.manager.getZone());return this.manager.getZone().runOutsideAngular(()=>za().onAndCancel(A,r.domEventName,s,o))}static parseEventName(A){let i=A.toLowerCase().split("."),n=i.shift();if(i.length===0||!(n==="keydown"||n==="keyup"))return null;let o=t._normalizeKey(i.pop()),r="",s=i.indexOf("code");if(s>-1&&(i.splice(s,1),r="code."),pz.forEach(c=>{let l=i.indexOf(c);l>-1&&(i.splice(l,1),r+=c+".")}),r+=o,i.length!=0||o.length===0)return null;let a={};return a.domEventName=n,a.fullKey=r,a}static matchEventFullKeyCode(A,i){let n=dBA[A.key]||A.key,o="";return i.indexOf("code.")>-1&&(n=A.code,o="code."),n==null||!n?!1:(n=n.toLowerCase(),n===" "?n="space":n==="."&&(n="dot"),pz.forEach(r=>{if(r!==n){let s=BBA[r];s(A)&&(o+=r+".")}}),o+=n,o===i)}static eventCallback(A,i,n){return o=>{t.matchEventFullKeyCode(o,A)&&n.runGuarded(()=>i(o))}}static _normalizeKey(A){return A==="esc"?"escape":A}static \u0275fac=function(i){return new(i||t)(he(tt))};static \u0275prov=SA({token:t,factory:t.\u0275fac})}return t})();function EBA(){Np.makeCurrent()}function hBA(){return new Xs}function QBA(){return EJ(document),document}var uBA=[{provide:hc,useValue:Sp},{provide:V9,useValue:EBA,multi:!0},{provide:tt,useFactory:QBA}],Gp=Sb(iz,"browser",uBA);var fBA=[{provide:QQ,useClass:_p},{provide:fb,useClass:up,deps:[de,fp,QQ]},{provide:up,useClass:up,deps:[de,fp,QQ]}],mBA=[{provide:$m,useValue:"root"},{provide:Xs,useFactory:hBA},{provide:Fp,useClass:wz,multi:!0,deps:[tt]},{provide:Fp,useClass:Dz,multi:!0,deps:[tt]},xQ,Tb,Jb,{provide:ds,useExisting:xQ},{provide:pI,useClass:CBA},[]],NQ=(()=>{class t{constructor(){}static \u0275fac=function(i){return new(i||t)};static \u0275mod=ge({type:t});static \u0275inj=le({providers:[...mBA,...fBA],imports:[g0,nz]})}return t})();var Jd=class{},_Q=class{},y2=class t{headers;normalizedNames=new Map;lazyInit;lazyUpdate=null;constructor(e){e?typeof e=="string"?this.lazyInit=()=>{this.headers=new Map,e.split(`
`).forEach(A=>{let i=A.indexOf(":");if(i>0){let n=A.slice(0,i),o=A.slice(i+1).trim();this.addHeaderEntry(n,o)}})}:typeof Headers<"u"&&e instanceof Headers?(this.headers=new Map,e.forEach((A,i)=>{this.addHeaderEntry(i,A)})):this.lazyInit=()=>{this.headers=new Map,Object.entries(e).forEach(([A,i])=>{this.setHeaderEntries(A,i)})}:this.headers=new Map}has(e){return this.init(),this.headers.has(e.toLowerCase())}get(e){this.init();let A=this.headers.get(e.toLowerCase());return A&&A.length>0?A[0]:null}keys(){return this.init(),Array.from(this.normalizedNames.values())}getAll(e){return this.init(),this.headers.get(e.toLowerCase())||null}append(e,A){return this.clone({name:e,value:A,op:"a"})}set(e,A){return this.clone({name:e,value:A,op:"s"})}delete(e,A){return this.clone({name:e,value:A,op:"d"})}maybeSetNormalizedName(e,A){this.normalizedNames.has(A)||this.normalizedNames.set(A,e)}init(){this.lazyInit&&(this.lazyInit instanceof t?this.copyFrom(this.lazyInit):this.lazyInit(),this.lazyInit=null,this.lazyUpdate&&(this.lazyUpdate.forEach(e=>this.applyUpdate(e)),this.lazyUpdate=null))}copyFrom(e){e.init(),Array.from(e.headers.keys()).forEach(A=>{this.headers.set(A,e.headers.get(A)),this.normalizedNames.set(A,e.normalizedNames.get(A))})}clone(e){let A=new t;return A.lazyInit=this.lazyInit&&this.lazyInit instanceof t?this.lazyInit:this,A.lazyUpdate=(this.lazyUpdate||[]).concat([e]),A}applyUpdate(e){let A=e.name.toLowerCase();switch(e.op){case"a":case"s":let i=e.value;if(typeof i=="string"&&(i=[i]),i.length===0)return;this.maybeSetNormalizedName(e.name,A);let n=(e.op==="a"?this.headers.get(A):void 0)||[];n.push(...i),this.headers.set(A,n);break;case"d":let o=e.value;if(!o)this.headers.delete(A),this.normalizedNames.delete(A);else{let r=this.headers.get(A);if(!r)return;r=r.filter(s=>o.indexOf(s)===-1),r.length===0?(this.headers.delete(A),this.normalizedNames.delete(A)):this.headers.set(A,r)}break}}addHeaderEntry(e,A){let i=e.toLowerCase();this.maybeSetNormalizedName(e,i),this.headers.has(i)?this.headers.get(i).push(A):this.headers.set(i,[A])}setHeaderEntries(e,A){let i=(Array.isArray(A)?A:[A]).map(o=>o.toString()),n=e.toLowerCase();this.headers.set(n,i),this.maybeSetNormalizedName(e,n)}forEach(e){this.init(),Array.from(this.normalizedNames.keys()).forEach(A=>e(this.normalizedNames.get(A),this.headers.get(A)))}};var Kp=class{encodeKey(e){return yz(e)}encodeValue(e){return yz(e)}decodeKey(e){return decodeURIComponent(e)}decodeValue(e){return decodeURIComponent(e)}};function pBA(t,e){let A=new Map;return t.length>0&&t.replace(/^\?/,"").split("&").forEach(n=>{let o=n.indexOf("="),[r,s]=o==-1?[e.decodeKey(n),""]:[e.decodeKey(n.slice(0,o)),e.decodeValue(n.slice(o+1))],a=A.get(r)||[];a.push(s),A.set(r,a)}),A}var wBA=/%(\d[a-f0-9])/gi,DBA={40:"@","3A":":",24:"$","2C":",","3B":";","3D":"=","3F":"?","2F":"/"};function yz(t){return encodeURIComponent(t).replace(wBA,(e,A)=>DBA[A]??e)}function Up(t){return`${t}`}var I0=class t{map;encoder;updates=null;cloneFrom=null;constructor(e={}){if(this.encoder=e.encoder||new Kp,e.fromString){if(e.fromObject)throw new ZA(2805,!1);this.map=pBA(e.fromString,this.encoder)}else e.fromObject?(this.map=new Map,Object.keys(e.fromObject).forEach(A=>{let i=e.fromObject[A],n=Array.isArray(i)?i.map(Up):[Up(i)];this.map.set(A,n)})):this.map=null}has(e){return this.init(),this.map.has(e)}get(e){this.init();let A=this.map.get(e);return A?A[0]:null}getAll(e){return this.init(),this.map.get(e)||null}keys(){return this.init(),Array.from(this.map.keys())}append(e,A){return this.clone({param:e,value:A,op:"a"})}appendAll(e){let A=[];return Object.keys(e).forEach(i=>{let n=e[i];Array.isArray(n)?n.forEach(o=>{A.push({param:i,value:o,op:"a"})}):A.push({param:i,value:n,op:"a"})}),this.clone(A)}set(e,A){return this.clone({param:e,value:A,op:"s"})}delete(e,A){return this.clone({param:e,value:A,op:"d"})}toString(){return this.init(),this.keys().map(e=>{let A=this.encoder.encodeKey(e);return this.map.get(e).map(i=>A+"="+this.encoder.encodeValue(i)).join("&")}).filter(e=>e!=="").join("&")}clone(e){let A=new t({encoder:this.encoder});return A.cloneFrom=this.cloneFrom||this,A.updates=(this.updates||[]).concat(e),A}init(){this.map===null&&(this.map=new Map),this.cloneFrom!==null&&(this.cloneFrom.init(),this.cloneFrom.keys().forEach(e=>this.map.set(e,this.cloneFrom.map.get(e))),this.updates.forEach(e=>{switch(e.op){case"a":case"s":let A=(e.op==="a"?this.map.get(e.param):void 0)||[];A.push(Up(e.value)),this.map.set(e.param,A);break;case"d":if(e.value!==void 0){let i=this.map.get(e.param)||[],n=i.indexOf(Up(e.value));n!==-1&&i.splice(n,1),i.length>0?this.map.set(e.param,i):this.map.delete(e.param)}else{this.map.delete(e.param);break}}}),this.cloneFrom=this.updates=null)}};var Yp=class{map=new Map;set(e,A){return this.map.set(e,A),this}get(e){return this.map.has(e)||this.map.set(e,e.defaultValue()),this.map.get(e)}delete(e){return this.map.delete(e),this}has(e){return this.map.has(e)}keys(){return this.map.keys()}};function yBA(t){switch(t){case"DELETE":case"GET":case"HEAD":case"OPTIONS":case"JSONP":return!1;default:return!0}}function vz(t){return typeof ArrayBuffer<"u"&&t instanceof ArrayBuffer}function bz(t){return typeof Blob<"u"&&t instanceof Blob}function Mz(t){return typeof FormData<"u"&&t instanceof FormData}function vBA(t){return typeof URLSearchParams<"u"&&t instanceof URLSearchParams}var kz="Content-Type",Sz="Accept",Lz="X-Request-URL",xz="text/plain",Fz="application/json",bBA=`${Fz}, ${xz}, */*`,Yd=class t{url;body=null;headers;context;reportProgress=!1;withCredentials=!1;responseType="json";method;params;urlWithParams;transferCache;constructor(e,A,i,n){this.url=A,this.method=e.toUpperCase();let o;if(yBA(this.method)||n?(this.body=i!==void 0?i:null,o=n):o=i,o&&(this.reportProgress=!!o.reportProgress,this.withCredentials=!!o.withCredentials,o.responseType&&(this.responseType=o.responseType),o.headers&&(this.headers=o.headers),o.context&&(this.context=o.context),o.params&&(this.params=o.params),this.transferCache=o.transferCache),this.headers??=new y2,this.context??=new Yp,!this.params)this.params=new I0,this.urlWithParams=A;else{let r=this.params.toString();if(r.length===0)this.urlWithParams=A;else{let s=A.indexOf("?"),a=s===-1?"?":s<A.length-1?"&":"";this.urlWithParams=A+a+r}}}serializeBody(){return this.body===null?null:typeof this.body=="string"||vz(this.body)||bz(this.body)||Mz(this.body)||vBA(this.body)?this.body:this.body instanceof I0?this.body.toString():typeof this.body=="object"||typeof this.body=="boolean"||Array.isArray(this.body)?JSON.stringify(this.body):this.body.toString()}detectContentTypeHeader(){return this.body===null||Mz(this.body)?null:bz(this.body)?this.body.type||null:vz(this.body)?null:typeof this.body=="string"?xz:this.body instanceof I0?"application/x-www-form-urlencoded;charset=UTF-8":typeof this.body=="object"||typeof this.body=="number"||typeof this.body=="boolean"?Fz:null}clone(e={}){let A=e.method||this.method,i=e.url||this.url,n=e.responseType||this.responseType,o=e.transferCache??this.transferCache,r=e.body!==void 0?e.body:this.body,s=e.withCredentials??this.withCredentials,a=e.reportProgress??this.reportProgress,c=e.headers||this.headers,l=e.params||this.params,I=e.context??this.context;return e.setHeaders!==void 0&&(c=Object.keys(e.setHeaders).reduce((C,d)=>C.set(d,e.setHeaders[d]),c)),e.setParams&&(l=Object.keys(e.setParams).reduce((C,d)=>C.set(d,e.setParams[d]),l)),new t(A,i,r,{params:l,headers:c,context:I,reportProgress:a,responseType:n,withCredentials:s,transferCache:o})}},wI=function(t){return t[t.Sent=0]="Sent",t[t.UploadProgress=1]="UploadProgress",t[t.ResponseHeader=2]="ResponseHeader",t[t.DownloadProgress=3]="DownloadProgress",t[t.Response=4]="Response",t[t.User=5]="User",t}(wI||{}),Td=class{headers;status;statusText;url;ok;type;constructor(e,A=200,i="OK"){this.headers=e.headers||new y2,this.status=e.status!==void 0?e.status:A,this.statusText=e.statusText||i,this.url=e.url||null,this.ok=this.status>=200&&this.status<300}},Jp=class t extends Td{constructor(e={}){super(e)}type=wI.ResponseHeader;clone(e={}){return new t({headers:e.headers||this.headers,status:e.status!==void 0?e.status:this.status,statusText:e.statusText||this.statusText,url:e.url||this.url||void 0})}},GQ=class t extends Td{body;constructor(e={}){super(e),this.body=e.body!==void 0?e.body:null}type=wI.Response;clone(e={}){return new t({body:e.body!==void 0?e.body:this.body,headers:e.headers||this.headers,status:e.status!==void 0?e.status:this.status,statusText:e.statusText||this.statusText,url:e.url||this.url||void 0})}},UQ=class extends Td{name="HttpErrorResponse";message;error;ok=!1;constructor(e){super(e,0,"Unknown Error"),this.status>=200&&this.status<300?this.message=`Http failure during parsing for ${e.url||"(unknown url)"}`:this.message=`Http failure response for ${e.url||"(unknown url)"}: ${e.status} ${e.statusText}`,this.error=e.error||null}},MBA=200,kBA=204;function Hb(t,e){return{body:e,headers:t.headers,context:t.context,observe:t.observe,params:t.params,reportProgress:t.reportProgress,responseType:t.responseType,withCredentials:t.withCredentials,transferCache:t.transferCache}}var Bs=(()=>{class t{handler;constructor(A){this.handler=A}request(A,i,n={}){let o;if(A instanceof Yd)o=A;else{let a;n.headers instanceof y2?a=n.headers:a=new y2(n.headers);let c;n.params&&(n.params instanceof I0?c=n.params:c=new I0({fromObject:n.params})),o=new Yd(A,i,n.body!==void 0?n.body:null,{headers:a,context:n.context,params:c,reportProgress:n.reportProgress,responseType:n.responseType||"json",withCredentials:n.withCredentials,transferCache:n.transferCache})}let r=ve(o).pipe(Jl(a=>this.handler.handle(a)));if(A instanceof Yd||n.observe==="events")return r;let s=r.pipe(pt(a=>a instanceof GQ));switch(n.observe||"body"){case"body":switch(o.responseType){case"arraybuffer":return s.pipe(Je(a=>{if(a.body!==null&&!(a.body instanceof ArrayBuffer))throw new ZA(2806,!1);return a.body}));case"blob":return s.pipe(Je(a=>{if(a.body!==null&&!(a.body instanceof Blob))throw new ZA(2807,!1);return a.body}));case"text":return s.pipe(Je(a=>{if(a.body!==null&&typeof a.body!="string")throw new ZA(2808,!1);return a.body}));case"json":default:return s.pipe(Je(a=>a.body))}case"response":return s;default:throw new ZA(2809,!1)}}delete(A,i={}){return this.request("DELETE",A,i)}get(A,i={}){return this.request("GET",A,i)}head(A,i={}){return this.request("HEAD",A,i)}jsonp(A,i){return this.request("JSONP",A,{params:new I0().append(i,"JSONP_CALLBACK"),observe:"body",responseType:"json"})}options(A,i={}){return this.request("OPTIONS",A,i)}patch(A,i,n={}){return this.request("PATCH",A,Hb(n,i))}post(A,i,n={}){return this.request("POST",A,Hb(n,i))}put(A,i,n={}){return this.request("PUT",A,Hb(n,i))}static \u0275fac=function(i){return new(i||t)(he(Jd))};static \u0275prov=SA({token:t,factory:t.\u0275fac})}return t})();var SBA=new BA("");function Nz(t,e){return e(t)}function RBA(t,e){return(A,i)=>e.intercept(A,{handle:n=>t(n,i)})}function LBA(t,e,A){return(i,n)=>$s(A,()=>e(i,o=>t(o,n)))}var _z=new BA(""),Pb=new BA(""),Gz=new BA(""),jb=new BA("",{providedIn:"root",factory:()=>!0});function xBA(){let t=null;return(e,A)=>{t===null&&(t=(m(_z,{optional:!0})??[]).reduceRight(RBA,Nz));let i=m(r0);if(m(jb)){let o=i.add();return t(e,A).pipe(Tl(()=>i.remove(o)))}else return t(e,A)}}var Tp=(()=>{class t extends Jd{backend;injector;chain=null;pendingTasks=m(r0);contributeToStability=m(jb);constructor(A,i){super(),this.backend=A,this.injector=i}handle(A){if(this.chain===null){let i=Array.from(new Set([...this.injector.get(Pb),...this.injector.get(Gz,[])]));this.chain=i.reduceRight((n,o)=>LBA(n,o,this.injector),Nz)}if(this.contributeToStability){let i=this.pendingTasks.add();return this.chain(A,n=>this.backend.handle(n)).pipe(Tl(()=>this.pendingTasks.remove(i)))}else return this.chain(A,i=>this.backend.handle(i))}static \u0275fac=function(i){return new(i||t)(he(_Q),he(Br))};static \u0275prov=SA({token:t,factory:t.\u0275fac})}return t})();var FBA=/^\)\]\}',?\n/,NBA=RegExp(`^${Lz}:`,"m");function _BA(t){return"responseURL"in t&&t.responseURL?t.responseURL:NBA.test(t.getAllResponseHeaders())?t.getResponseHeader(Lz):null}var Ob=(()=>{class t{xhrFactory;constructor(A){this.xhrFactory=A}handle(A){if(A.method==="JSONP")throw new ZA(-2800,!1);let i=this.xhrFactory;return(i.\u0275loadImpl?On(i.\u0275loadImpl()):ve(null)).pipe(no(()=>new Ze(o=>{let r=i.build();if(r.open(A.method,A.urlWithParams),A.withCredentials&&(r.withCredentials=!0),A.headers.forEach((E,Q)=>r.setRequestHeader(E,Q.join(","))),A.headers.has(Sz)||r.setRequestHeader(Sz,bBA),!A.headers.has(kz)){let E=A.detectContentTypeHeader();E!==null&&r.setRequestHeader(kz,E)}if(A.responseType){let E=A.responseType.toLowerCase();r.responseType=E!=="json"?E:"text"}let s=A.serializeBody(),a=null,c=()=>{if(a!==null)return a;let E=r.statusText||"OK",Q=new y2(r.getAllResponseHeaders()),u=_BA(r)||A.url;return a=new Jp({headers:Q,status:r.status,statusText:E,url:u}),a},l=()=>{let{headers:E,status:Q,statusText:u,url:v}=c(),L=null;Q!==kBA&&(L=typeof r.response>"u"?r.responseText:r.response),Q===0&&(Q=L?MBA:0);let x=Q>=200&&Q<300;if(A.responseType==="json"&&typeof L=="string"){let y=L;L=L.replace(FBA,"");try{L=L!==""?JSON.parse(L):null}catch(F){L=y,x&&(x=!1,L={error:F,text:L})}}x?(o.next(new GQ({body:L,headers:E,status:Q,statusText:u,url:v||void 0})),o.complete()):o.error(new UQ({error:L,headers:E,status:Q,statusText:u,url:v||void 0}))},I=E=>{let{url:Q}=c(),u=new UQ({error:E,status:r.status||0,statusText:r.statusText||"Unknown Error",url:Q||void 0});o.error(u)},C=!1,d=E=>{C||(o.next(c()),C=!0);let Q={type:wI.DownloadProgress,loaded:E.loaded};E.lengthComputable&&(Q.total=E.total),A.responseType==="text"&&r.responseText&&(Q.partialText=r.responseText),o.next(Q)},B=E=>{let Q={type:wI.UploadProgress,loaded:E.loaded};E.lengthComputable&&(Q.total=E.total),o.next(Q)};return r.addEventListener("load",l),r.addEventListener("error",I),r.addEventListener("timeout",I),r.addEventListener("abort",I),A.reportProgress&&(r.addEventListener("progress",d),s!==null&&r.upload&&r.upload.addEventListener("progress",B)),r.send(s),o.next({type:wI.Sent}),()=>{r.removeEventListener("error",I),r.removeEventListener("abort",I),r.removeEventListener("load",l),r.removeEventListener("timeout",I),A.reportProgress&&(r.removeEventListener("progress",d),s!==null&&r.upload&&r.upload.removeEventListener("progress",B)),r.readyState!==r.DONE&&r.abort()}})))}static \u0275fac=function(i){return new(i||t)(he(pI))};static \u0275prov=SA({token:t,factory:t.\u0275fac})}return t})(),Uz=new BA(""),GBA="XSRF-TOKEN",UBA=new BA("",{providedIn:"root",factory:()=>GBA}),KBA="X-XSRF-TOKEN",YBA=new BA("",{providedIn:"root",factory:()=>KBA}),KQ=class{},JBA=(()=>{class t{doc;platform;cookieName;lastCookieString="";lastToken=null;parseCount=0;constructor(A,i,n){this.doc=A,this.platform=i,this.cookieName=n}getToken(){if(this.platform==="server")return null;let A=this.doc.cookie||"";return A!==this.lastCookieString&&(this.parseCount++,this.lastToken=kQ(A,this.cookieName),this.lastCookieString=A),this.lastToken}static \u0275fac=function(i){return new(i||t)(he(tt),he(hc),he(UBA))};static \u0275prov=SA({token:t,factory:t.\u0275fac})}return t})();function TBA(t,e){let A=t.url.toLowerCase();if(!m(Uz)||t.method==="GET"||t.method==="HEAD"||A.startsWith("http://")||A.startsWith("https://"))return e(t);let i=m(KQ).getToken(),n=m(YBA);return i!=null&&!t.headers.has(n)&&(t=t.clone({headers:t.headers.set(n,i)})),e(t)}var qb=function(t){return t[t.Interceptors=0]="Interceptors",t[t.LegacyInterceptors=1]="LegacyInterceptors",t[t.CustomXsrfConfiguration=2]="CustomXsrfConfiguration",t[t.NoXsrfProtection=3]="NoXsrfProtection",t[t.JsonpSupport=4]="JsonpSupport",t[t.RequestsMadeViaParent=5]="RequestsMadeViaParent",t[t.Fetch=6]="Fetch",t}(qb||{});function zBA(t,e){return{\u0275kind:t,\u0275providers:e}}function Kz(...t){let e=[Bs,Ob,Tp,{provide:Jd,useExisting:Tp},{provide:_Q,useFactory:()=>m(SBA,{optional:!0})??m(Ob)},{provide:Pb,useValue:TBA,multi:!0},{provide:Uz,useValue:!0},{provide:KQ,useClass:JBA}];for(let A of t)e.push(...A.\u0275providers);return aQ(e)}var Rz=new BA("");function Yz(){return zBA(qb.LegacyInterceptors,[{provide:Rz,useFactory:xBA},{provide:Pb,useExisting:Rz,multi:!0}])}var Vb=(()=>{class t{static \u0275fac=function(i){return new(i||t)};static \u0275mod=ge({type:t});static \u0275inj=le({providers:[Kz(Yz())]})}return t})();var Jz=(()=>{class t{_doc;constructor(A){this._doc=A}getTitle(){return this._doc.title}setTitle(A){this._doc.title=A||""}static \u0275fac=function(i){return new(i||t)(he(tt))};static \u0275prov=SA({token:t,factory:t.\u0275fac,providedIn:"root"})}return t})();var il=(()=>{class t{static \u0275fac=function(i){return new(i||t)};static \u0275prov=SA({token:t,factory:function(i){let n=null;return i?n=new(i||t):n=he(HBA),n},providedIn:"root"})}return t})(),HBA=(()=>{class t extends il{_doc;constructor(A){super(),this._doc=A}sanitize(A,i){if(i==null)return null;switch(A){case Kr.NONE:return i;case Kr.HTML:return Q2(i,"HTML")?el(i):$9(this._doc,String(i)).toString();case Kr.STYLE:return Q2(i,"Style")?el(i):i;case Kr.SCRIPT:if(Q2(i,"Script"))return el(i);throw new ZA(5200,!1);case Kr.URL:return Q2(i,"URL")?el(i):ap(String(i));case Kr.RESOURCE_URL:if(Q2(i,"ResourceURL"))return el(i);throw new ZA(5201,!1);default:throw new ZA(5202,!1)}}bypassSecurityTrustHtml(A){return wJ(A)}bypassSecurityTrustStyle(A){return DJ(A)}bypassSecurityTrustScript(A){return yJ(A)}bypassSecurityTrustUrl(A){return vJ(A)}bypassSecurityTrustResourceUrl(A){return bJ(A)}static \u0275fac=function(i){return new(i||t)(he(tt))};static \u0275prov=SA({token:t,factory:t.\u0275fac,providedIn:"root"})}return t})();var Vz=(()=>{class t{_renderer;_elementRef;onChange=A=>{};onTouched=()=>{};constructor(A,i){this._renderer=A,this._elementRef=i}setProperty(A,i){this._renderer.setProperty(this._elementRef.nativeElement,A,i)}registerOnTouched(A){this.onTouched=A}registerOnChange(A){this.onChange=A}setDisabledState(A){this.setProperty("disabled",A)}static \u0275fac=function(i){return new(i||t)(zA(Gi),zA(te))};static \u0275dir=OA({type:t})}return t})(),OBA=(()=>{class t extends Vz{static \u0275fac=(()=>{let A;return function(n){return(A||(A=bi(t)))(n||t)}})();static \u0275dir=OA({type:t,features:[et]})}return t})(),uc=new BA("");var PBA={provide:uc,useExisting:nr(()=>fc),multi:!0};function jBA(){let t=za()?za().getUserAgent():"";return/android (\d+)/.test(t.toLowerCase())}var qBA=new BA(""),fc=(()=>{class t extends Vz{_compositionMode;_composing=!1;constructor(A,i,n){super(A,i),this._compositionMode=n,this._compositionMode==null&&(this._compositionMode=!jBA())}writeValue(A){let i=A??"";this.setProperty("value",i)}_handleInput(A){(!this._compositionMode||this._compositionMode&&!this._composing)&&this.onChange(A)}_compositionStart(){this._composing=!0}_compositionEnd(A){this._composing=!1,this._compositionMode&&this.onChange(A)}static \u0275fac=function(i){return new(i||t)(zA(Gi),zA(te),zA(qBA,8))};static \u0275dir=OA({type:t,selectors:[["input","formControlName","",3,"type","checkbox"],["textarea","formControlName",""],["input","formControl","",3,"type","checkbox"],["textarea","formControl",""],["input","ngModel","",3,"type","checkbox"],["textarea","ngModel",""],["","ngDefaultControl",""]],hostBindings:function(i,n){i&1&&mA("input",function(r){return n._handleInput(r.target.value)})("blur",function(){return n.onTouched()})("compositionstart",function(){return n._compositionStart()})("compositionend",function(r){return n._compositionEnd(r.target.value)})},standalone:!1,features:[ct([PBA]),et]})}return t})();function $b(t){return t==null||AM(t)===0}function AM(t){return t==null?null:Array.isArray(t)||typeof t=="string"?t.length:t instanceof Set?t.size:null}var d0=new BA(""),PQ=new BA(""),VBA=/^(?=.{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])?)*$/,Oa=class{static min(e){return ZBA(e)}static max(e){return WBA(e)}static required(e){return XBA(e)}static requiredTrue(e){return $BA(e)}static email(e){return AEA(e)}static minLength(e){return eEA(e)}static maxLength(e){return tEA(e)}static pattern(e){return iEA(e)}static nullValidator(e){return Zz()}static compose(e){return tH(e)}static composeAsync(e){return iH(e)}};function ZBA(t){return e=>{if(e.value==null||t==null)return null;let A=parseFloat(e.value);return!isNaN(A)&&A<t?{min:{min:t,actual:e.value}}:null}}function WBA(t){return e=>{if(e.value==null||t==null)return null;let A=parseFloat(e.value);return!isNaN(A)&&A>t?{max:{max:t,actual:e.value}}:null}}function XBA(t){return $b(t.value)?{required:!0}:null}function $BA(t){return t.value===!0?null:{required:!0}}function AEA(t){return $b(t.value)||VBA.test(t.value)?null:{email:!0}}function eEA(t){return e=>{let A=e.value?.length??AM(e.value);return A===null||A===0?null:A<t?{minlength:{requiredLength:t,actualLength:A}}:null}}function tEA(t){return e=>{let A=e.value?.length??AM(e.value);return A!==null&&A>t?{maxlength:{requiredLength:t,actualLength:A}}:null}}function iEA(t){if(!t)return Zz;let e,A;return typeof t=="string"?(A="",t.charAt(0)!=="^"&&(A+="^"),A+=t,t.charAt(t.length-1)!=="$"&&(A+="$"),e=new RegExp(A)):(A=t.toString(),e=t),i=>{if($b(i.value))return null;let n=i.value;return e.test(n)?null:{pattern:{requiredPattern:A,actualValue:n}}}}function Zz(t){return null}function Wz(t){return t!=null}function Xz(t){return u2(t)?On(t):t}function $z(t){let e={};return t.forEach(A=>{e=A!=null?nA(nA({},e),A):e}),Object.keys(e).length===0?null:e}function AH(t,e){return e.map(A=>A(t))}function nEA(t){return!t.validate}function eH(t){return t.map(e=>nEA(e)?e:A=>e.validate(A))}function tH(t){if(!t)return null;let e=t.filter(Wz);return e.length==0?null:function(A){return $z(AH(A,e))}}function eM(t){return t!=null?tH(eH(t)):null}function iH(t){if(!t)return null;let e=t.filter(Wz);return e.length==0?null:function(A){let i=AH(A,e).map(Xz);return Hh(i).pipe(Je($z))}}function tM(t){return t!=null?iH(eH(t)):null}function Tz(t,e){return t===null?[e]:Array.isArray(t)?[...t,e]:[t,e]}function nH(t){return t._rawValidators}function oH(t){return t._rawAsyncValidators}function Zb(t){return t?Array.isArray(t)?t:[t]:[]}function Hp(t,e){return Array.isArray(t)?t.includes(e):t===e}function zz(t,e){let A=Zb(e);return Zb(t).forEach(n=>{Hp(A,n)||A.push(n)}),A}function Hz(t,e){return Zb(e).filter(A=>!Hp(t,A))}var Op=class{get value(){return this.control?this.control.value:null}get valid(){return this.control?this.control.valid:null}get invalid(){return this.control?this.control.invalid:null}get pending(){return this.control?this.control.pending:null}get disabled(){return this.control?this.control.disabled:null}get enabled(){return this.control?this.control.enabled:null}get errors(){return this.control?this.control.errors:null}get pristine(){return this.control?this.control.pristine:null}get dirty(){return this.control?this.control.dirty:null}get touched(){return this.control?this.control.touched:null}get status(){return this.control?this.control.status:null}get untouched(){return this.control?this.control.untouched:null}get statusChanges(){return this.control?this.control.statusChanges:null}get valueChanges(){return this.control?this.control.valueChanges:null}get path(){return null}_composedValidatorFn;_composedAsyncValidatorFn;_rawValidators=[];_rawAsyncValidators=[];_setValidators(e){this._rawValidators=e||[],this._composedValidatorFn=eM(this._rawValidators)}_setAsyncValidators(e){this._rawAsyncValidators=e||[],this._composedAsyncValidatorFn=tM(this._rawAsyncValidators)}get validator(){return this._composedValidatorFn||null}get asyncValidator(){return this._composedAsyncValidatorFn||null}_onDestroyCallbacks=[];_registerOnDestroy(e){this._onDestroyCallbacks.push(e)}_invokeOnDestroyCallbacks(){this._onDestroyCallbacks.forEach(e=>e()),this._onDestroyCallbacks=[]}reset(e=void 0){this.control&&this.control.reset(e)}hasError(e,A){return this.control?this.control.hasError(e,A):!1}getError(e,A){return this.control?this.control.getError(e,A):null}},C0=class extends Op{name;get formDirective(){return null}get path(){return null}},Pa=class extends Op{_parent=null;name=null;valueAccessor=null},Pp=class{_cd;constructor(e){this._cd=e}get isTouched(){return this._cd?.control?._touched?.(),!!this._cd?.control?.touched}get isUntouched(){return!!this._cd?.control?.untouched}get isPristine(){return this._cd?.control?._pristine?.(),!!this._cd?.control?.pristine}get isDirty(){return!!this._cd?.control?.dirty}get isValid(){return this._cd?.control?._status?.(),!!this._cd?.control?.valid}get isInvalid(){return!!this._cd?.control?.invalid}get isPending(){return!!this._cd?.control?.pending}get isSubmitted(){return this._cd?._submitted?.(),!!this._cd?.submitted}},oEA={"[class.ng-untouched]":"isUntouched","[class.ng-touched]":"isTouched","[class.ng-pristine]":"isPristine","[class.ng-dirty]":"isDirty","[class.ng-valid]":"isValid","[class.ng-invalid]":"isInvalid","[class.ng-pending]":"isPending"},ore=Ne(nA({},oEA),{"[class.ng-submitted]":"isSubmitted"}),na=(()=>{class t extends Pp{constructor(A){super(A)}static \u0275fac=function(i){return new(i||t)(zA(Pa,2))};static \u0275dir=OA({type:t,selectors:[["","formControlName",""],["","ngModel",""],["","formControl",""]],hostVars:14,hostBindings:function(i,n){i&2&&ue("ng-untouched",n.isUntouched)("ng-touched",n.isTouched)("ng-pristine",n.isPristine)("ng-dirty",n.isDirty)("ng-valid",n.isValid)("ng-invalid",n.isInvalid)("ng-pending",n.isPending)},standalone:!1,features:[et]})}return t})(),rH=(()=>{class t extends Pp{constructor(A){super(A)}static \u0275fac=function(i){return new(i||t)(zA(C0,10))};static \u0275dir=OA({type:t,selectors:[["","formGroupName",""],["","formArrayName",""],["","ngModelGroup",""],["","formGroup",""],["form",3,"ngNoForm",""],["","ngForm",""]],hostVars:16,hostBindings:function(i,n){i&2&&ue("ng-untouched",n.isUntouched)("ng-touched",n.isTouched)("ng-pristine",n.isPristine)("ng-dirty",n.isDirty)("ng-valid",n.isValid)("ng-invalid",n.isInvalid)("ng-pending",n.isPending)("ng-submitted",n.isSubmitted)},standalone:!1,features:[et]})}return t})();var YQ="VALID",zp="INVALID",zd="PENDING",JQ="DISABLED",v2=class{},jp=class extends v2{value;source;constructor(e,A){super(),this.value=e,this.source=A}},zQ=class extends v2{pristine;source;constructor(e,A){super(),this.pristine=e,this.source=A}},HQ=class extends v2{touched;source;constructor(e,A){super(),this.touched=e,this.source=A}},Hd=class extends v2{status;source;constructor(e,A){super(),this.status=e,this.source=A}},qp=class extends v2{source;constructor(e){super(),this.source=e}},Vp=class extends v2{source;constructor(e){super(),this.source=e}};function iM(t){return($p(t)?t.validators:t)||null}function rEA(t){return Array.isArray(t)?eM(t):t||null}function nM(t,e){return($p(e)?e.asyncValidators:t)||null}function sEA(t){return Array.isArray(t)?tM(t):t||null}function $p(t){return t!=null&&!Array.isArray(t)&&typeof t=="object"}function sH(t,e,A){let i=t.controls;if(!(e?Object.keys(i):i).length)throw new ZA(1e3,"");if(!i[A])throw new ZA(1001,"")}function aH(t,e,A){t._forEachChild((i,n)=>{if(A[n]===void 0)throw new ZA(1002,"")})}var Od=class{_pendingDirty=!1;_hasOwnPendingAsyncValidator=null;_pendingTouched=!1;_onCollectionChange=()=>{};_updateOn;_parent=null;_asyncValidationSubscription;_composedValidatorFn;_composedAsyncValidatorFn;_rawValidators;_rawAsyncValidators;value;constructor(e,A){this._assignValidators(e),this._assignAsyncValidators(A)}get validator(){return this._composedValidatorFn}set validator(e){this._rawValidators=this._composedValidatorFn=e}get asyncValidator(){return this._composedAsyncValidatorFn}set asyncValidator(e){this._rawAsyncValidators=this._composedAsyncValidatorFn=e}get parent(){return this._parent}get status(){return ia(this.statusReactive)}set status(e){ia(()=>this.statusReactive.set(e))}_status=c0(()=>this.statusReactive());statusReactive=Ko(void 0);get valid(){return this.status===YQ}get invalid(){return this.status===zp}get pending(){return this.status==zd}get disabled(){return this.status===JQ}get enabled(){return this.status!==JQ}errors;get pristine(){return ia(this.pristineReactive)}set pristine(e){ia(()=>this.pristineReactive.set(e))}_pristine=c0(()=>this.pristineReactive());pristineReactive=Ko(!0);get dirty(){return!this.pristine}get touched(){return ia(this.touchedReactive)}set touched(e){ia(()=>this.touchedReactive.set(e))}_touched=c0(()=>this.touchedReactive());touchedReactive=Ko(!1);get untouched(){return!this.touched}_events=new HA;events=this._events.asObservable();valueChanges;statusChanges;get updateOn(){return this._updateOn?this._updateOn:this.parent?this.parent.updateOn:"change"}setValidators(e){this._assignValidators(e)}setAsyncValidators(e){this._assignAsyncValidators(e)}addValidators(e){this.setValidators(zz(e,this._rawValidators))}addAsyncValidators(e){this.setAsyncValidators(zz(e,this._rawAsyncValidators))}removeValidators(e){this.setValidators(Hz(e,this._rawValidators))}removeAsyncValidators(e){this.setAsyncValidators(Hz(e,this._rawAsyncValidators))}hasValidator(e){return Hp(this._rawValidators,e)}hasAsyncValidator(e){return Hp(this._rawAsyncValidators,e)}clearValidators(){this.validator=null}clearAsyncValidators(){this.asyncValidator=null}markAsTouched(e={}){let A=this.touched===!1;this.touched=!0;let i=e.sourceControl??this;this._parent&&!e.onlySelf&&this._parent.markAsTouched(Ne(nA({},e),{sourceControl:i})),A&&e.emitEvent!==!1&&this._events.next(new HQ(!0,i))}markAllAsTouched(e={}){this.markAsTouched({onlySelf:!0,emitEvent:e.emitEvent,sourceControl:this}),this._forEachChild(A=>A.markAllAsTouched(e))}markAsUntouched(e={}){let A=this.touched===!0;this.touched=!1,this._pendingTouched=!1;let i=e.sourceControl??this;this._forEachChild(n=>{n.markAsUntouched({onlySelf:!0,emitEvent:e.emitEvent,sourceControl:i})}),this._parent&&!e.onlySelf&&this._parent._updateTouched(e,i),A&&e.emitEvent!==!1&&this._events.next(new HQ(!1,i))}markAsDirty(e={}){let A=this.pristine===!0;this.pristine=!1;let i=e.sourceControl??this;this._parent&&!e.onlySelf&&this._parent.markAsDirty(Ne(nA({},e),{sourceControl:i})),A&&e.emitEvent!==!1&&this._events.next(new zQ(!1,i))}markAsPristine(e={}){let A=this.pristine===!1;this.pristine=!0,this._pendingDirty=!1;let i=e.sourceControl??this;this._forEachChild(n=>{n.markAsPristine({onlySelf:!0,emitEvent:e.emitEvent})}),this._parent&&!e.onlySelf&&this._parent._updatePristine(e,i),A&&e.emitEvent!==!1&&this._events.next(new zQ(!0,i))}markAsPending(e={}){this.status=zd;let A=e.sourceControl??this;e.emitEvent!==!1&&(this._events.next(new Hd(this.status,A)),this.statusChanges.emit(this.status)),this._parent&&!e.onlySelf&&this._parent.markAsPending(Ne(nA({},e),{sourceControl:A}))}disable(e={}){let A=this._parentMarkedDirty(e.onlySelf);this.status=JQ,this.errors=null,this._forEachChild(n=>{n.disable(Ne(nA({},e),{onlySelf:!0}))}),this._updateValue();let i=e.sourceControl??this;e.emitEvent!==!1&&(this._events.next(new jp(this.value,i)),this._events.next(new Hd(this.status,i)),this.valueChanges.emit(this.value),this.statusChanges.emit(this.status)),this._updateAncestors(Ne(nA({},e),{skipPristineCheck:A}),this),this._onDisabledChange.forEach(n=>n(!0))}enable(e={}){let A=this._parentMarkedDirty(e.onlySelf);this.status=YQ,this._forEachChild(i=>{i.enable(Ne(nA({},e),{onlySelf:!0}))}),this.updateValueAndValidity({onlySelf:!0,emitEvent:e.emitEvent}),this._updateAncestors(Ne(nA({},e),{skipPristineCheck:A}),this),this._onDisabledChange.forEach(i=>i(!1))}_updateAncestors(e,A){this._parent&&!e.onlySelf&&(this._parent.updateValueAndValidity(e),e.skipPristineCheck||this._parent._updatePristine({},A),this._parent._updateTouched({},A))}setParent(e){this._parent=e}getRawValue(){return this.value}updateValueAndValidity(e={}){if(this._setInitialStatus(),this._updateValue(),this.enabled){let i=this._cancelExistingSubscription();this.errors=this._runValidator(),this.status=this._calculateStatus(),(this.status===YQ||this.status===zd)&&this._runAsyncValidator(i,e.emitEvent)}let A=e.sourceControl??this;e.emitEvent!==!1&&(this._events.next(new jp(this.value,A)),this._events.next(new Hd(this.status,A)),this.valueChanges.emit(this.value),this.statusChanges.emit(this.status)),this._parent&&!e.onlySelf&&this._parent.updateValueAndValidity(Ne(nA({},e),{sourceControl:A}))}_updateTreeValidity(e={emitEvent:!0}){this._forEachChild(A=>A._updateTreeValidity(e)),this.updateValueAndValidity({onlySelf:!0,emitEvent:e.emitEvent})}_setInitialStatus(){this.status=this._allControlsDisabled()?JQ:YQ}_runValidator(){return this.validator?this.validator(this):null}_runAsyncValidator(e,A){if(this.asyncValidator){this.status=zd,this._hasOwnPendingAsyncValidator={emitEvent:A!==!1};let i=Xz(this.asyncValidator(this));this._asyncValidationSubscription=i.subscribe(n=>{this._hasOwnPendingAsyncValidator=null,this.setErrors(n,{emitEvent:A,shouldHaveEmitted:e})})}}_cancelExistingSubscription(){if(this._asyncValidationSubscription){this._asyncValidationSubscription.unsubscribe();let e=this._hasOwnPendingAsyncValidator?.emitEvent??!1;return this._hasOwnPendingAsyncValidator=null,e}return!1}setErrors(e,A={}){this.errors=e,this._updateControlsErrors(A.emitEvent!==!1,this,A.shouldHaveEmitted)}get(e){let A=e;return A==null||(Array.isArray(A)||(A=A.split(".")),A.length===0)?null:A.reduce((i,n)=>i&&i._find(n),this)}getError(e,A){let i=A?this.get(A):this;return i&&i.errors?i.errors[e]:null}hasError(e,A){return!!this.getError(e,A)}get root(){let e=this;for(;e._parent;)e=e._parent;return e}_updateControlsErrors(e,A,i){this.status=this._calculateStatus(),e&&this.statusChanges.emit(this.status),(e||i)&&this._events.next(new Hd(this.status,A)),this._parent&&this._parent._updateControlsErrors(e,A,i)}_initObservables(){this.valueChanges=new XA,this.statusChanges=new XA}_calculateStatus(){return this._allControlsDisabled()?JQ:this.errors?zp:this._hasOwnPendingAsyncValidator||this._anyControlsHaveStatus(zd)?zd:this._anyControlsHaveStatus(zp)?zp:YQ}_anyControlsHaveStatus(e){return this._anyControls(A=>A.status===e)}_anyControlsDirty(){return this._anyControls(e=>e.dirty)}_anyControlsTouched(){return this._anyControls(e=>e.touched)}_updatePristine(e,A){let i=!this._anyControlsDirty(),n=this.pristine!==i;this.pristine=i,this._parent&&!e.onlySelf&&this._parent._updatePristine(e,A),n&&this._events.next(new zQ(this.pristine,A))}_updateTouched(e={},A){this.touched=this._anyControlsTouched(),this._events.next(new HQ(this.touched,A)),this._parent&&!e.onlySelf&&this._parent._updateTouched(e,A)}_onDisabledChange=[];_registerOnCollectionChange(e){this._onCollectionChange=e}_setUpdateStrategy(e){$p(e)&&e.updateOn!=null&&(this._updateOn=e.updateOn)}_parentMarkedDirty(e){let A=this._parent&&this._parent.dirty;return!e&&!!A&&!this._parent._anyControlsDirty()}_find(e){return null}_assignValidators(e){this._rawValidators=Array.isArray(e)?e.slice():e,this._composedValidatorFn=rEA(this._rawValidators)}_assignAsyncValidators(e){this._rawAsyncValidators=Array.isArray(e)?e.slice():e,this._composedAsyncValidatorFn=sEA(this._rawAsyncValidators)}},Pd=class extends Od{constructor(e,A,i){super(iM(A),nM(i,A)),this.controls=e,this._initObservables(),this._setUpdateStrategy(A),this._setUpControls(),this.updateValueAndValidity({onlySelf:!0,emitEvent:!!this.asyncValidator})}controls;registerControl(e,A){return this.controls[e]?this.controls[e]:(this.controls[e]=A,A.setParent(this),A._registerOnCollectionChange(this._onCollectionChange),A)}addControl(e,A,i={}){this.registerControl(e,A),this.updateValueAndValidity({emitEvent:i.emitEvent}),this._onCollectionChange()}removeControl(e,A={}){this.controls[e]&&this.controls[e]._registerOnCollectionChange(()=>{}),delete this.controls[e],this.updateValueAndValidity({emitEvent:A.emitEvent}),this._onCollectionChange()}setControl(e,A,i={}){this.controls[e]&&this.controls[e]._registerOnCollectionChange(()=>{}),delete this.controls[e],A&&this.registerControl(e,A),this.updateValueAndValidity({emitEvent:i.emitEvent}),this._onCollectionChange()}contains(e){return this.controls.hasOwnProperty(e)&&this.controls[e].enabled}setValue(e,A={}){aH(this,!0,e),Object.keys(e).forEach(i=>{sH(this,!0,i),this.controls[i].setValue(e[i],{onlySelf:!0,emitEvent:A.emitEvent})}),this.updateValueAndValidity(A)}patchValue(e,A={}){e!=null&&(Object.keys(e).forEach(i=>{let n=this.controls[i];n&&n.patchValue(e[i],{onlySelf:!0,emitEvent:A.emitEvent})}),this.updateValueAndValidity(A))}reset(e={},A={}){this._forEachChild((i,n)=>{i.reset(e?e[n]:null,{onlySelf:!0,emitEvent:A.emitEvent})}),this._updatePristine(A,this),this._updateTouched(A,this),this.updateValueAndValidity(A)}getRawValue(){return this._reduceChildren({},(e,A,i)=>(e[i]=A.getRawValue(),e))}_syncPendingControls(){let e=this._reduceChildren(!1,(A,i)=>i._syncPendingControls()?!0:A);return e&&this.updateValueAndValidity({onlySelf:!0}),e}_forEachChild(e){Object.keys(this.controls).forEach(A=>{let i=this.controls[A];i&&e(i,A)})}_setUpControls(){this._forEachChild(e=>{e.setParent(this),e._registerOnCollectionChange(this._onCollectionChange)})}_updateValue(){this.value=this._reduceValue()}_anyControls(e){for(let[A,i]of Object.entries(this.controls))if(this.contains(A)&&e(i))return!0;return!1}_reduceValue(){let e={};return this._reduceChildren(e,(A,i,n)=>((i.enabled||this.disabled)&&(A[n]=i.value),A))}_reduceChildren(e,A){let i=e;return this._forEachChild((n,o)=>{i=A(i,n,o)}),i}_allControlsDisabled(){for(let e of Object.keys(this.controls))if(this.controls[e].enabled)return!1;return Object.keys(this.controls).length>0||this.disabled}_find(e){return this.controls.hasOwnProperty(e)?this.controls[e]:null}};var Wb=class extends Pd{};var jd=new BA("",{providedIn:"root",factory:()=>A6}),A6="always";function cH(t,e){return[...e.path,t]}function OQ(t,e,A=A6){oM(t,e),e.valueAccessor.writeValue(t.value),(t.disabled||A==="always")&&e.valueAccessor.setDisabledState?.(t.disabled),cEA(t,e),gEA(t,e),lEA(t,e),aEA(t,e)}function Zp(t,e,A=!0){let i=()=>{};e.valueAccessor&&(e.valueAccessor.registerOnChange(i),e.valueAccessor.registerOnTouched(i)),Xp(t,e),t&&(e._invokeOnDestroyCallbacks(),t._registerOnCollectionChange(()=>{}))}function Wp(t,e){t.forEach(A=>{A.registerOnValidatorChange&&A.registerOnValidatorChange(e)})}function aEA(t,e){if(e.valueAccessor.setDisabledState){let A=i=>{e.valueAccessor.setDisabledState(i)};t.registerOnDisabledChange(A),e._registerOnDestroy(()=>{t._unregisterOnDisabledChange(A)})}}function oM(t,e){let A=nH(t);e.validator!==null?t.setValidators(Tz(A,e.validator)):typeof A=="function"&&t.setValidators([A]);let i=oH(t);e.asyncValidator!==null?t.setAsyncValidators(Tz(i,e.asyncValidator)):typeof i=="function"&&t.setAsyncValidators([i]);let n=()=>t.updateValueAndValidity();Wp(e._rawValidators,n),Wp(e._rawAsyncValidators,n)}function Xp(t,e){let A=!1;if(t!==null){if(e.validator!==null){let n=nH(t);if(Array.isArray(n)&&n.length>0){let o=n.filter(r=>r!==e.validator);o.length!==n.length&&(A=!0,t.setValidators(o))}}if(e.asyncValidator!==null){let n=oH(t);if(Array.isArray(n)&&n.length>0){let o=n.filter(r=>r!==e.asyncValidator);o.length!==n.length&&(A=!0,t.setAsyncValidators(o))}}}let i=()=>{};return Wp(e._rawValidators,i),Wp(e._rawAsyncValidators,i),A}function cEA(t,e){e.valueAccessor.registerOnChange(A=>{t._pendingValue=A,t._pendingChange=!0,t._pendingDirty=!0,t.updateOn==="change"&&lH(t,e)})}function lEA(t,e){e.valueAccessor.registerOnTouched(()=>{t._pendingTouched=!0,t.updateOn==="blur"&&t._pendingChange&&lH(t,e),t.updateOn!=="submit"&&t.markAsTouched()})}function lH(t,e){t._pendingDirty&&t.markAsDirty(),t.setValue(t._pendingValue,{emitModelToViewChange:!1}),e.viewToModelUpdate(t._pendingValue),t._pendingChange=!1}function gEA(t,e){let A=(i,n)=>{e.valueAccessor.writeValue(i),n&&e.viewToModelUpdate(i)};t.registerOnChange(A),e._registerOnDestroy(()=>{t._unregisterOnChange(A)})}function gH(t,e){t==null,oM(t,e)}function IEA(t,e){return Xp(t,e)}function rM(t,e){if(!t.hasOwnProperty("model"))return!1;let A=t.model;return A.isFirstChange()?!0:!Object.is(e,A.currentValue)}function CEA(t){return Object.getPrototypeOf(t.constructor)===OBA}function IH(t,e){t._syncPendingControls(),e.forEach(A=>{let i=A.control;i.updateOn==="submit"&&i._pendingChange&&(A.viewToModelUpdate(i._pendingValue),i._pendingChange=!1)})}function sM(t,e){if(!e)return null;Array.isArray(e);let A,i,n;return e.forEach(o=>{o.constructor===fc?A=o:CEA(o)?i=o:n=o}),n||i||A||null}function dEA(t,e){let A=t.indexOf(e);A>-1&&t.splice(A,1)}var BEA={provide:C0,useExisting:nr(()=>jQ)},TQ=Promise.resolve(),jQ=(()=>{class t extends C0{callSetDisabledState;get submitted(){return ia(this.submittedReactive)}_submitted=c0(()=>this.submittedReactive());submittedReactive=Ko(!1);_directives=new Set;form;ngSubmit=new XA;options;constructor(A,i,n){super(),this.callSetDisabledState=n,this.form=new Pd({},eM(A),tM(i))}ngAfterViewInit(){this._setUpdateStrategy()}get formDirective(){return this}get control(){return this.form}get path(){return[]}get controls(){return this.form.controls}addControl(A){TQ.then(()=>{let i=this._findContainer(A.path);A.control=i.registerControl(A.name,A.control),OQ(A.control,A,this.callSetDisabledState),A.control.updateValueAndValidity({emitEvent:!1}),this._directives.add(A)})}getControl(A){return this.form.get(A.path)}removeControl(A){TQ.then(()=>{let i=this._findContainer(A.path);i&&i.removeControl(A.name),this._directives.delete(A)})}addFormGroup(A){TQ.then(()=>{let i=this._findContainer(A.path),n=new Pd({});gH(n,A),i.registerControl(A.name,n),n.updateValueAndValidity({emitEvent:!1})})}removeFormGroup(A){TQ.then(()=>{let i=this._findContainer(A.path);i&&i.removeControl(A.name)})}getFormGroup(A){return this.form.get(A.path)}updateModel(A,i){TQ.then(()=>{this.form.get(A.path).setValue(i)})}setValue(A){this.control.setValue(A)}onSubmit(A){return this.submittedReactive.set(!0),IH(this.form,this._directives),this.ngSubmit.emit(A),this.form._events.next(new qp(this.control)),A?.target?.method==="dialog"}onReset(){this.resetForm()}resetForm(A=void 0){this.form.reset(A),this.submittedReactive.set(!1),this.form._events.next(new Vp(this.form))}_setUpdateStrategy(){this.options&&this.options.updateOn!=null&&(this.form._updateOn=this.options.updateOn)}_findContainer(A){return A.pop(),A.length?this.form.get(A):this.form}static \u0275fac=function(i){return new(i||t)(zA(d0,10),zA(PQ,10),zA(jd,8))};static \u0275dir=OA({type:t,selectors:[["form",3,"ngNoForm","",3,"formGroup",""],["ng-form"],["","ngForm",""]],hostBindings:function(i,n){i&1&&mA("submit",function(r){return n.onSubmit(r)})("reset",function(){return n.onReset()})},inputs:{options:[0,"ngFormOptions","options"]},outputs:{ngSubmit:"ngSubmit"},exportAs:["ngForm"],standalone:!1,features:[ct([BEA]),et]})}return t})();function Oz(t,e){let A=t.indexOf(e);A>-1&&t.splice(A,1)}function Pz(t){return typeof t=="object"&&t!==null&&Object.keys(t).length===2&&"value"in t&&"disabled"in t}var vI=class extends Od{defaultValue=null;_onChange=[];_pendingValue;_pendingChange=!1;constructor(e=null,A,i){super(iM(A),nM(i,A)),this._applyFormState(e),this._setUpdateStrategy(A),this._initObservables(),this.updateValueAndValidity({onlySelf:!0,emitEvent:!!this.asyncValidator}),$p(A)&&(A.nonNullable||A.initialValueIsDefault)&&(Pz(e)?this.defaultValue=e.value:this.defaultValue=e)}setValue(e,A={}){this.value=this._pendingValue=e,this._onChange.length&&A.emitModelToViewChange!==!1&&this._onChange.forEach(i=>i(this.value,A.emitViewToModelChange!==!1)),this.updateValueAndValidity(A)}patchValue(e,A={}){this.setValue(e,A)}reset(e=this.defaultValue,A={}){this._applyFormState(e),this.markAsPristine(A),this.markAsUntouched(A),this.setValue(this.value,A),this._pendingChange=!1}_updateValue(){}_anyControls(e){return!1}_allControlsDisabled(){return this.disabled}registerOnChange(e){this._onChange.push(e)}_unregisterOnChange(e){Oz(this._onChange,e)}registerOnDisabledChange(e){this._onDisabledChange.push(e)}_unregisterOnDisabledChange(e){Oz(this._onDisabledChange,e)}_forEachChild(e){}_syncPendingControls(){return this.updateOn==="submit"&&(this._pendingDirty&&this.markAsDirty(),this._pendingTouched&&this.markAsTouched(),this._pendingChange)?(this.setValue(this._pendingValue,{onlySelf:!0,emitModelToViewChange:!1}),!0):!1}_applyFormState(e){Pz(e)?(this.value=this._pendingValue=e.value,e.disabled?this.disable({onlySelf:!0,emitEvent:!1}):this.enable({onlySelf:!0,emitEvent:!1})):this.value=this._pendingValue=e}};var EEA=t=>t instanceof vI;var hEA={provide:Pa,useExisting:nr(()=>ja)},jz=Promise.resolve(),ja=(()=>{class t extends Pa{_changeDetectorRef;callSetDisabledState;control=new vI;static ngAcceptInputType_isDisabled;_registered=!1;viewModel;name="";isDisabled;model;options;update=new XA;constructor(A,i,n,o,r,s){super(),this._changeDetectorRef=r,this.callSetDisabledState=s,this._parent=A,this._setValidators(i),this._setAsyncValidators(n),this.valueAccessor=sM(this,o)}ngOnChanges(A){if(this._checkForErrors(),!this._registered||"name"in A){if(this._registered&&(this._checkName(),this.formDirective)){let i=A.name.previousValue;this.formDirective.removeControl({name:i,path:this._getPath(i)})}this._setUpControl()}"isDisabled"in A&&this._updateDisabled(A),rM(A,this.viewModel)&&(this._updateValue(this.model),this.viewModel=this.model)}ngOnDestroy(){this.formDirective&&this.formDirective.removeControl(this)}get path(){return this._getPath(this.name)}get formDirective(){return this._parent?this._parent.formDirective:null}viewToModelUpdate(A){this.viewModel=A,this.update.emit(A)}_setUpControl(){this._setUpdateStrategy(),this._isStandalone()?this._setUpStandalone():this.formDirective.addControl(this),this._registered=!0}_setUpdateStrategy(){this.options&&this.options.updateOn!=null&&(this.control._updateOn=this.options.updateOn)}_isStandalone(){return!this._parent||!!(this.options&&this.options.standalone)}_setUpStandalone(){OQ(this.control,this,this.callSetDisabledState),this.control.updateValueAndValidity({emitEvent:!1})}_checkForErrors(){this._checkName()}_checkName(){this.options&&this.options.name&&(this.name=this.options.name),!this._isStandalone()&&this.name}_updateValue(A){jz.then(()=>{this.control.setValue(A,{emitViewToModelChange:!1}),this._changeDetectorRef?.markForCheck()})}_updateDisabled(A){let i=A.isDisabled.currentValue,n=i!==0&&ae(i);jz.then(()=>{n&&!this.control.disabled?this.control.disable():!n&&this.control.disabled&&this.control.enable(),this._changeDetectorRef?.markForCheck()})}_getPath(A){return this._parent?cH(A,this._parent):[A]}static \u0275fac=function(i){return new(i||t)(zA(C0,9),zA(d0,10),zA(PQ,10),zA(uc,10),zA(lt,8),zA(jd,8))};static \u0275dir=OA({type:t,selectors:[["","ngModel","",3,"formControlName","",3,"formControl",""]],inputs:{name:"name",isDisabled:[0,"disabled","isDisabled"],model:[0,"ngModel","model"],options:[0,"ngModelOptions","options"]},outputs:{update:"ngModelChange"},exportAs:["ngModel"],standalone:!1,features:[ct([hEA]),et,Kt]})}return t})();var CH=(()=>{class t{static \u0275fac=function(i){return new(i||t)};static \u0275dir=OA({type:t,selectors:[["form",3,"ngNoForm","",3,"ngNativeValidate",""]],hostAttrs:["novalidate",""],standalone:!1})}return t})();var aM=new BA(""),QEA={provide:Pa,useExisting:nr(()=>cM)},cM=(()=>{class t extends Pa{_ngModelWarningConfig;callSetDisabledState;viewModel;form;set isDisabled(A){}model;update=new XA;static _ngModelWarningSentOnce=!1;_ngModelWarningSent=!1;constructor(A,i,n,o,r){super(),this._ngModelWarningConfig=o,this.callSetDisabledState=r,this._setValidators(A),this._setAsyncValidators(i),this.valueAccessor=sM(this,n)}ngOnChanges(A){if(this._isControlChanged(A)){let i=A.form.previousValue;i&&Zp(i,this,!1),OQ(this.form,this,this.callSetDisabledState),this.form.updateValueAndValidity({emitEvent:!1})}rM(A,this.viewModel)&&(this.form.setValue(this.model),this.viewModel=this.model)}ngOnDestroy(){this.form&&Zp(this.form,this,!1)}get path(){return[]}get control(){return this.form}viewToModelUpdate(A){this.viewModel=A,this.update.emit(A)}_isControlChanged(A){return A.hasOwnProperty("form")}static \u0275fac=function(i){return new(i||t)(zA(d0,10),zA(PQ,10),zA(uc,10),zA(aM,8),zA(jd,8))};static \u0275dir=OA({type:t,selectors:[["","formControl",""]],inputs:{form:[0,"formControl","form"],isDisabled:[0,"disabled","isDisabled"],model:[0,"ngModel","model"]},outputs:{update:"ngModelChange"},exportAs:["ngForm"],standalone:!1,features:[ct([QEA]),et,Kt]})}return t})(),uEA={provide:C0,useExisting:nr(()=>bI)},bI=(()=>{class t extends C0{callSetDisabledState;get submitted(){return ia(this._submittedReactive)}set submitted(A){this._submittedReactive.set(A)}_submitted=c0(()=>this._submittedReactive());_submittedReactive=Ko(!1);_oldForm;_onCollectionChange=()=>this._updateDomValue();directives=[];form=null;ngSubmit=new XA;constructor(A,i,n){super(),this.callSetDisabledState=n,this._setValidators(A),this._setAsyncValidators(i)}ngOnChanges(A){A.hasOwnProperty("form")&&(this._updateValidators(),this._updateDomValue(),this._updateRegistrations(),this._oldForm=this.form)}ngOnDestroy(){this.form&&(Xp(this.form,this),this.form._onCollectionChange===this._onCollectionChange&&this.form._registerOnCollectionChange(()=>{}))}get formDirective(){return this}get control(){return this.form}get path(){return[]}addControl(A){let i=this.form.get(A.path);return OQ(i,A,this.callSetDisabledState),i.updateValueAndValidity({emitEvent:!1}),this.directives.push(A),i}getControl(A){return this.form.get(A.path)}removeControl(A){Zp(A.control||null,A,!1),dEA(this.directives,A)}addFormGroup(A){this._setUpFormContainer(A)}removeFormGroup(A){this._cleanUpFormContainer(A)}getFormGroup(A){return this.form.get(A.path)}addFormArray(A){this._setUpFormContainer(A)}removeFormArray(A){this._cleanUpFormContainer(A)}getFormArray(A){return this.form.get(A.path)}updateModel(A,i){this.form.get(A.path).setValue(i)}onSubmit(A){return this._submittedReactive.set(!0),IH(this.form,this.directives),this.ngSubmit.emit(A),this.form._events.next(new qp(this.control)),A?.target?.method==="dialog"}onReset(){this.resetForm()}resetForm(A=void 0){this.form.reset(A),this._submittedReactive.set(!1),this.form._events.next(new Vp(this.form))}_updateDomValue(){this.directives.forEach(A=>{let i=A.control,n=this.form.get(A.path);i!==n&&(Zp(i||null,A),EEA(n)&&(OQ(n,A,this.callSetDisabledState),A.control=n))}),this.form._updateTreeValidity({emitEvent:!1})}_setUpFormContainer(A){let i=this.form.get(A.path);gH(i,A),i.updateValueAndValidity({emitEvent:!1})}_cleanUpFormContainer(A){if(this.form){let i=this.form.get(A.path);i&&IEA(i,A)&&i.updateValueAndValidity({emitEvent:!1})}}_updateRegistrations(){this.form._registerOnCollectionChange(this._onCollectionChange),this._oldForm&&this._oldForm._registerOnCollectionChange(()=>{})}_updateValidators(){oM(this.form,this),this._oldForm&&Xp(this._oldForm,this)}static \u0275fac=function(i){return new(i||t)(zA(d0,10),zA(PQ,10),zA(jd,8))};static \u0275dir=OA({type:t,selectors:[["","formGroup",""]],hostBindings:function(i,n){i&1&&mA("submit",function(r){return n.onSubmit(r)})("reset",function(){return n.onReset()})},inputs:{form:[0,"formGroup","form"]},outputs:{ngSubmit:"ngSubmit"},exportAs:["ngForm"],standalone:!1,features:[ct([uEA]),et,Kt]})}return t})();var fEA={provide:Pa,useExisting:nr(()=>lM)},lM=(()=>{class t extends Pa{_ngModelWarningConfig;_added=!1;viewModel;control;name=null;set isDisabled(A){}model;update=new XA;static _ngModelWarningSentOnce=!1;_ngModelWarningSent=!1;constructor(A,i,n,o,r){super(),this._ngModelWarningConfig=r,this._parent=A,this._setValidators(i),this._setAsyncValidators(n),this.valueAccessor=sM(this,o)}ngOnChanges(A){this._added||this._setUpControl(),rM(A,this.viewModel)&&(this.viewModel=this.model,this.formDirective.updateModel(this,this.model))}ngOnDestroy(){this.formDirective&&this.formDirective.removeControl(this)}viewToModelUpdate(A){this.viewModel=A,this.update.emit(A)}get path(){return cH(this.name==null?this.name:this.name.toString(),this._parent)}get formDirective(){return this._parent?this._parent.formDirective:null}_setUpControl(){this.control=this.formDirective.addControl(this),this._added=!0}static \u0275fac=function(i){return new(i||t)(zA(C0,13),zA(d0,10),zA(PQ,10),zA(uc,10),zA(aM,8))};static \u0275dir=OA({type:t,selectors:[["","formControlName",""]],inputs:{name:[0,"formControlName","name"],isDisabled:[0,"disabled","isDisabled"],model:[0,"ngModel","model"]},outputs:{update:"ngModelChange"},standalone:!1,features:[ct([fEA]),et,Kt]})}return t})();var dH=(()=>{class t{static \u0275fac=function(i){return new(i||t)};static \u0275mod=ge({type:t});static \u0275inj=le({})}return t})(),Xb=class extends Od{constructor(e,A,i){super(iM(A),nM(i,A)),this.controls=e,this._initObservables(),this._setUpdateStrategy(A),this._setUpControls(),this.updateValueAndValidity({onlySelf:!0,emitEvent:!!this.asyncValidator})}controls;at(e){return this.controls[this._adjustIndex(e)]}push(e,A={}){this.controls.push(e),this._registerControl(e),this.updateValueAndValidity({emitEvent:A.emitEvent}),this._onCollectionChange()}insert(e,A,i={}){this.controls.splice(e,0,A),this._registerControl(A),this.updateValueAndValidity({emitEvent:i.emitEvent})}removeAt(e,A={}){let i=this._adjustIndex(e);i<0&&(i=0),this.controls[i]&&this.controls[i]._registerOnCollectionChange(()=>{}),this.controls.splice(i,1),this.updateValueAndValidity({emitEvent:A.emitEvent})}setControl(e,A,i={}){let n=this._adjustIndex(e);n<0&&(n=0),this.controls[n]&&this.controls[n]._registerOnCollectionChange(()=>{}),this.controls.splice(n,1),A&&(this.controls.splice(n,0,A),this._registerControl(A)),this.updateValueAndValidity({emitEvent:i.emitEvent}),this._onCollectionChange()}get length(){return this.controls.length}setValue(e,A={}){aH(this,!1,e),e.forEach((i,n)=>{sH(this,!1,n),this.at(n).setValue(i,{onlySelf:!0,emitEvent:A.emitEvent})}),this.updateValueAndValidity(A)}patchValue(e,A={}){e!=null&&(e.forEach((i,n)=>{this.at(n)&&this.at(n).patchValue(i,{onlySelf:!0,emitEvent:A.emitEvent})}),this.updateValueAndValidity(A))}reset(e=[],A={}){this._forEachChild((i,n)=>{i.reset(e[n],{onlySelf:!0,emitEvent:A.emitEvent})}),this._updatePristine(A,this),this._updateTouched(A,this),this.updateValueAndValidity(A)}getRawValue(){return this.controls.map(e=>e.getRawValue())}clear(e={}){this.controls.length<1||(this._forEachChild(A=>A._registerOnCollectionChange(()=>{})),this.controls.splice(0),this.updateValueAndValidity({emitEvent:e.emitEvent}))}_adjustIndex(e){return e<0?e+this.length:e}_syncPendingControls(){let e=this.controls.reduce((A,i)=>i._syncPendingControls()?!0:A,!1);return e&&this.updateValueAndValidity({onlySelf:!0}),e}_forEachChild(e){this.controls.forEach((A,i)=>{e(A,i)})}_updateValue(){this.value=this.controls.filter(e=>e.enabled||this.disabled).map(e=>e.value)}_anyControls(e){return this.controls.some(A=>A.enabled&&e(A))}_setUpControls(){this._forEachChild(e=>this._registerControl(e))}_allControlsDisabled(){for(let e of this.controls)if(e.enabled)return!1;return this.controls.length>0||this.disabled}_registerControl(e){e.setParent(this),e._registerOnCollectionChange(this._onCollectionChange)}_find(e){return this.at(e)??null}};function qz(t){return!!t&&(t.asyncValidators!==void 0||t.validators!==void 0||t.updateOn!==void 0)}var BH=(()=>{class t{useNonNullable=!1;get nonNullable(){let A=new t;return A.useNonNullable=!0,A}group(A,i=null){let n=this._reduceControls(A),o={};return qz(i)?o=i:i!==null&&(o.validators=i.validator,o.asyncValidators=i.asyncValidator),new Pd(n,o)}record(A,i=null){let n=this._reduceControls(A);return new Wb(n,i)}control(A,i,n){let o={};return this.useNonNullable?(qz(i)?o=i:(o.validators=i,o.asyncValidators=n),new vI(A,Ne(nA({},o),{nonNullable:!0}))):new vI(A,i,n)}array(A,i,n){let o=A.map(r=>this._createControl(r));return new Xb(o,i,n)}_reduceControls(A){let i={};return Object.keys(A).forEach(n=>{i[n]=this._createControl(A[n])}),i}_createControl(A){if(A instanceof vI)return A;if(A instanceof Od)return A;if(Array.isArray(A)){let i=A[0],n=A.length>1?A[1]:null,o=A.length>2?A[2]:null;return this.control(i,n,o)}else return this.control(A)}static \u0275fac=function(i){return new(i||t)};static \u0275prov=SA({token:t,factory:t.\u0275fac,providedIn:"root"})}return t})();var e6=(()=>{class t{static withConfig(A){return{ngModule:t,providers:[{provide:jd,useValue:A.callSetDisabledState??A6}]}}static \u0275fac=function(i){return new(i||t)};static \u0275mod=ge({type:t});static \u0275inj=le({imports:[dH]})}return t})(),EH=(()=>{class t{static withConfig(A){return{ngModule:t,providers:[{provide:aM,useValue:A.warnOnNgModelWithFormControl??"always"},{provide:jd,useValue:A.callSetDisabledState??A6}]}}static \u0275fac=function(i){return new(i||t)};static \u0275mod=ge({type:t});static \u0275inj=le({imports:[dH]})}return t})();var Bi="primary",ru=Symbol("RouteTitle"),BM=class{params;constructor(e){this.params=e||{}}has(e){return Object.prototype.hasOwnProperty.call(this.params,e)}get(e){if(this.has(e)){let A=this.params[e];return Array.isArray(A)?A[0]:A}return null}getAll(e){if(this.has(e)){let A=this.params[e];return Array.isArray(A)?A:[A]}return[]}get keys(){return Object.keys(this.params)}};function RI(t){return new BM(t)}function DH(t,e,A){let i=A.path.split("/");if(i.length>t.length||A.pathMatch==="full"&&(e.hasChildren()||i.length<t.length))return null;let n={};for(let o=0;o<i.length;o++){let r=i[o],s=t[o];if(r[0]===":")n[r.substring(1)]=s;else if(r!==s.path)return null}return{consumed:t.slice(0,i.length),posParams:n}}function mEA(t,e){if(t.length!==e.length)return!1;for(let A=0;A<t.length;++A)if(!Ag(t[A],e[A]))return!1;return!0}function Ag(t,e){let A=t?EM(t):void 0,i=e?EM(e):void 0;if(!A||!i||A.length!=i.length)return!1;let n;for(let o=0;o<A.length;o++)if(n=A[o],!yH(t[n],e[n]))return!1;return!0}function EM(t){return[...Object.keys(t),...Object.getOwnPropertySymbols(t)]}function yH(t,e){if(Array.isArray(t)&&Array.isArray(e)){if(t.length!==e.length)return!1;let A=[...t].sort(),i=[...e].sort();return A.every((n,o)=>i[o]===n)}else return t===e}function vH(t){return t.length>0?t[t.length-1]:null}function S2(t){return a2(t)?t:u2(t)?On(Promise.resolve(t)):ve(t)}var pEA={exact:MH,subset:kH},bH={exact:wEA,subset:DEA,ignored:()=>!0};function hH(t,e,A){return pEA[A.paths](t.root,e.root,A.matrixParams)&&bH[A.queryParams](t.queryParams,e.queryParams)&&!(A.fragment==="exact"&&t.fragment!==e.fragment)}function wEA(t,e){return Ag(t,e)}function MH(t,e,A){if(!kI(t.segments,e.segments)||!n6(t.segments,e.segments,A)||t.numberOfChildren!==e.numberOfChildren)return!1;for(let i in e.children)if(!t.children[i]||!MH(t.children[i],e.children[i],A))return!1;return!0}function DEA(t,e){return Object.keys(e).length<=Object.keys(t).length&&Object.keys(e).every(A=>yH(t[A],e[A]))}function kH(t,e,A){return SH(t,e,e.segments,A)}function SH(t,e,A,i){if(t.segments.length>A.length){let n=t.segments.slice(0,A.length);return!(!kI(n,A)||e.hasChildren()||!n6(n,A,i))}else if(t.segments.length===A.length){if(!kI(t.segments,A)||!n6(t.segments,A,i))return!1;for(let n in e.children)if(!t.children[n]||!kH(t.children[n],e.children[n],i))return!1;return!0}else{let n=A.slice(0,t.segments.length),o=A.slice(t.segments.length);return!kI(t.segments,n)||!n6(t.segments,n,i)||!t.children[Bi]?!1:SH(t.children[Bi],e,o,i)}}function n6(t,e,A){return e.every((i,n)=>bH[A](t[n].parameters,i.parameters))}var tg=class{root;queryParams;fragment;_queryParamMap;constructor(e=new bn([],{}),A={},i=null){this.root=e,this.queryParams=A,this.fragment=i}get queryParamMap(){return this._queryParamMap??=RI(this.queryParams),this._queryParamMap}toString(){return bEA.serialize(this)}},bn=class{segments;children;parent=null;constructor(e,A){this.segments=e,this.children=A,Object.values(A).forEach(i=>i.parent=this)}hasChildren(){return this.numberOfChildren>0}get numberOfChildren(){return Object.keys(this.children).length}toString(){return o6(this)}},b2=class{path;parameters;_parameterMap;constructor(e,A){this.path=e,this.parameters=A}get parameterMap(){return this._parameterMap??=RI(this.parameters),this._parameterMap}toString(){return LH(this)}};function yEA(t,e){return kI(t,e)&&t.every((A,i)=>Ag(A.parameters,e[i].parameters))}function kI(t,e){return t.length!==e.length?!1:t.every((A,i)=>A.path===e[i].path)}function vEA(t,e){let A=[];return Object.entries(t.children).forEach(([i,n])=>{i===Bi&&(A=A.concat(e(n,i)))}),Object.entries(t.children).forEach(([i,n])=>{i!==Bi&&(A=A.concat(e(n,i)))}),A}var LI=(()=>{class t{static \u0275fac=function(i){return new(i||t)};static \u0275prov=SA({token:t,factory:()=>new M2,providedIn:"root"})}return t})(),M2=class{parse(e){let A=new QM(e);return new tg(A.parseRootSegment(),A.parseQueryParams(),A.parseFragment())}serialize(e){let A=`/${qQ(e.root,!0)}`,i=SEA(e.queryParams),n=typeof e.fragment=="string"?`#${MEA(e.fragment)}`:"";return`${A}${i}${n}`}},bEA=new M2;function o6(t){return t.segments.map(e=>LH(e)).join("/")}function qQ(t,e){if(!t.hasChildren())return o6(t);if(e){let A=t.children[Bi]?qQ(t.children[Bi],!1):"",i=[];return Object.entries(t.children).forEach(([n,o])=>{n!==Bi&&i.push(`${n}:${qQ(o,!1)}`)}),i.length>0?`${A}(${i.join("//")})`:A}else{let A=vEA(t,(i,n)=>n===Bi?[qQ(t.children[Bi],!1)]:[`${n}:${qQ(i,!1)}`]);return Object.keys(t.children).length===1&&t.children[Bi]!=null?`${o6(t)}/${A[0]}`:`${o6(t)}/(${A.join("//")})`}}function RH(t){return encodeURIComponent(t).replace(/%40/g,"@").replace(/%3A/gi,":").replace(/%24/g,"$").replace(/%2C/gi,",")}function t6(t){return RH(t).replace(/%3B/gi,";")}function MEA(t){return encodeURI(t)}function hM(t){return RH(t).replace(/\(/g,"%28").replace(/\)/g,"%29").replace(/%26/gi,"&")}function r6(t){return decodeURIComponent(t)}function QH(t){return r6(t.replace(/\+/g,"%20"))}function LH(t){return`${hM(t.path)}${kEA(t.parameters)}`}function kEA(t){return Object.entries(t).map(([e,A])=>`;${hM(e)}=${hM(A)}`).join("")}function SEA(t){let e=Object.entries(t).map(([A,i])=>Array.isArray(i)?i.map(n=>`${t6(A)}=${t6(n)}`).join("&"):`${t6(A)}=${t6(i)}`).filter(A=>A);return e.length?`?${e.join("&")}`:""}var REA=/^[^\/()?;#]+/;function gM(t){let e=t.match(REA);return e?e[0]:""}var LEA=/^[^\/()?;=#]+/;function xEA(t){let e=t.match(LEA);return e?e[0]:""}var FEA=/^[^=?&#]+/;function NEA(t){let e=t.match(FEA);return e?e[0]:""}var _EA=/^[^&#]+/;function GEA(t){let e=t.match(_EA);return e?e[0]:""}var QM=class{url;remaining;constructor(e){this.url=e,this.remaining=e}parseRootSegment(){return this.consumeOptional("/"),this.remaining===""||this.peekStartsWith("?")||this.peekStartsWith("#")?new bn([],{}):new bn([],this.parseChildren())}parseQueryParams(){let e={};if(this.consumeOptional("?"))do this.parseQueryParam(e);while(this.consumeOptional("&"));return e}parseFragment(){return this.consumeOptional("#")?decodeURIComponent(this.remaining):null}parseChildren(){if(this.remaining==="")return{};this.consumeOptional("/");let e=[];for(this.peekStartsWith("(")||e.push(this.parseSegment());this.peekStartsWith("/")&&!this.peekStartsWith("//")&&!this.peekStartsWith("/(");)this.capture("/"),e.push(this.parseSegment());let A={};this.peekStartsWith("/(")&&(this.capture("/"),A=this.parseParens(!0));let i={};return this.peekStartsWith("(")&&(i=this.parseParens(!1)),(e.length>0||Object.keys(A).length>0)&&(i[Bi]=new bn(e,A)),i}parseSegment(){let e=gM(this.remaining);if(e===""&&this.peekStartsWith(";"))throw new ZA(4009,!1);return this.capture(e),new b2(r6(e),this.parseMatrixParams())}parseMatrixParams(){let e={};for(;this.consumeOptional(";");)this.parseParam(e);return e}parseParam(e){let A=xEA(this.remaining);if(!A)return;this.capture(A);let i="";if(this.consumeOptional("=")){let n=gM(this.remaining);n&&(i=n,this.capture(i))}e[r6(A)]=r6(i)}parseQueryParam(e){let A=NEA(this.remaining);if(!A)return;this.capture(A);let i="";if(this.consumeOptional("=")){let r=GEA(this.remaining);r&&(i=r,this.capture(i))}let n=QH(A),o=QH(i);if(e.hasOwnProperty(n)){let r=e[n];Array.isArray(r)||(r=[r],e[n]=r),r.push(o)}else e[n]=o}parseParens(e){let A={};for(this.capture("(");!this.consumeOptional(")")&&this.remaining.length>0;){let i=gM(this.remaining),n=this.remaining[i.length];if(n!=="/"&&n!==")"&&n!==";")throw new ZA(4010,!1);let o;i.indexOf(":")>-1?(o=i.slice(0,i.indexOf(":")),this.capture(o),this.capture(":")):e&&(o=Bi);let r=this.parseChildren();A[o]=Object.keys(r).length===1?r[Bi]:new bn([],r),this.consumeOptional("//")}return A}peekStartsWith(e){return this.remaining.startsWith(e)}consumeOptional(e){return this.peekStartsWith(e)?(this.remaining=this.remaining.substring(e.length),!0):!1}capture(e){if(!this.consumeOptional(e))throw new ZA(4011,!1)}};function xH(t){return t.segments.length>0?new bn([],{[Bi]:t}):t}function FH(t){let e={};for(let[i,n]of Object.entries(t.children)){let o=FH(n);if(i===Bi&&o.segments.length===0&&o.hasChildren())for(let[r,s]of Object.entries(o.children))e[r]=s;else(o.segments.length>0||o.hasChildren())&&(e[i]=o)}let A=new bn(t.segments,e);return UEA(A)}function UEA(t){if(t.numberOfChildren===1&&t.children[Bi]){let e=t.children[Bi];return new bn(t.segments.concat(e.segments),e.children)}return t}function Xd(t){return t instanceof tg}function NH(t,e,A=null,i=null){let n=_H(t);return GH(n,e,A,i)}function _H(t){let e;function A(o){let r={};for(let a of o.children){let c=A(a);r[a.outlet]=c}let s=new bn(o.url,r);return o===t&&(e=s),s}let i=A(t.root),n=xH(i);return e??n}function GH(t,e,A,i){let n=t;for(;n.parent;)n=n.parent;if(e.length===0)return IM(n,n,n,A,i);let o=KEA(e);if(o.toRoot())return IM(n,n,new bn([],{}),A,i);let r=YEA(o,n,t),s=r.processChildren?ZQ(r.segmentGroup,r.index,o.commands):KH(r.segmentGroup,r.index,o.commands);return IM(n,r.segmentGroup,s,A,i)}function a6(t){return typeof t=="object"&&t!=null&&!t.outlets&&!t.segmentPath}function XQ(t){return typeof t=="object"&&t!=null&&t.outlets}function IM(t,e,A,i,n){let o={};i&&Object.entries(i).forEach(([a,c])=>{o[a]=Array.isArray(c)?c.map(l=>`${l}`):`${c}`});let r;t===e?r=A:r=UH(t,e,A);let s=xH(FH(r));return new tg(s,o,n)}function UH(t,e,A){let i={};return Object.entries(t.children).forEach(([n,o])=>{o===e?i[n]=A:i[n]=UH(o,e,A)}),new bn(t.segments,i)}var c6=class{isAbsolute;numberOfDoubleDots;commands;constructor(e,A,i){if(this.isAbsolute=e,this.numberOfDoubleDots=A,this.commands=i,e&&i.length>0&&a6(i[0]))throw new ZA(4003,!1);let n=i.find(XQ);if(n&&n!==vH(i))throw new ZA(4004,!1)}toRoot(){return this.isAbsolute&&this.commands.length===1&&this.commands[0]=="/"}};function KEA(t){if(typeof t[0]=="string"&&t.length===1&&t[0]==="/")return new c6(!0,0,t);let e=0,A=!1,i=t.reduce((n,o,r)=>{if(typeof o=="object"&&o!=null){if(o.outlets){let s={};return Object.entries(o.outlets).forEach(([a,c])=>{s[a]=typeof c=="string"?c.split("/"):c}),[...n,{outlets:s}]}if(o.segmentPath)return[...n,o.segmentPath]}return typeof o!="string"?[...n,o]:r===0?(o.split("/").forEach((s,a)=>{a==0&&s==="."||(a==0&&s===""?A=!0:s===".."?e++:s!=""&&n.push(s))}),n):[...n,o]},[]);return new c6(A,e,i)}var Zd=class{segmentGroup;processChildren;index;constructor(e,A,i){this.segmentGroup=e,this.processChildren=A,this.index=i}};function YEA(t,e,A){if(t.isAbsolute)return new Zd(e,!0,0);if(!A)return new Zd(e,!1,NaN);if(A.parent===null)return new Zd(A,!0,0);let i=a6(t.commands[0])?0:1,n=A.segments.length-1+i;return JEA(A,n,t.numberOfDoubleDots)}function JEA(t,e,A){let i=t,n=e,o=A;for(;o>n;){if(o-=n,i=i.parent,!i)throw new ZA(4005,!1);n=i.segments.length}return new Zd(i,!1,n-o)}function TEA(t){return XQ(t[0])?t[0].outlets:{[Bi]:t}}function KH(t,e,A){if(t??=new bn([],{}),t.segments.length===0&&t.hasChildren())return ZQ(t,e,A);let i=zEA(t,e,A),n=A.slice(i.commandIndex);if(i.match&&i.pathIndex<t.segments.length){let o=new bn(t.segments.slice(0,i.pathIndex),{});return o.children[Bi]=new bn(t.segments.slice(i.pathIndex),t.children),ZQ(o,0,n)}else return i.match&&n.length===0?new bn(t.segments,{}):i.match&&!t.hasChildren()?uM(t,e,A):i.match?ZQ(t,0,n):uM(t,e,A)}function ZQ(t,e,A){if(A.length===0)return new bn(t.segments,{});{let i=TEA(A),n={};if(Object.keys(i).some(o=>o!==Bi)&&t.children[Bi]&&t.numberOfChildren===1&&t.children[Bi].segments.length===0){let o=ZQ(t.children[Bi],e,A);return new bn(t.segments,o.children)}return Object.entries(i).forEach(([o,r])=>{typeof r=="string"&&(r=[r]),r!==null&&(n[o]=KH(t.children[o],e,r))}),Object.entries(t.children).forEach(([o,r])=>{i[o]===void 0&&(n[o]=r)}),new bn(t.segments,n)}}function zEA(t,e,A){let i=0,n=e,o={match:!1,pathIndex:0,commandIndex:0};for(;n<t.segments.length;){if(i>=A.length)return o;let r=t.segments[n],s=A[i];if(XQ(s))break;let a=`${s}`,c=i<A.length-1?A[i+1]:null;if(n>0&&a===void 0)break;if(a&&c&&typeof c=="object"&&c.outlets===void 0){if(!fH(a,c,r))return o;i+=2}else{if(!fH(a,{},r))return o;i++}n++}return{match:!0,pathIndex:n,commandIndex:i}}function uM(t,e,A){let i=t.segments.slice(0,e),n=0;for(;n<A.length;){let o=A[n];if(XQ(o)){let a=HEA(o.outlets);return new bn(i,a)}if(n===0&&a6(A[0])){let a=t.segments[e];i.push(new b2(a.path,uH(A[0]))),n++;continue}let r=XQ(o)?o.outlets[Bi]:`${o}`,s=n<A.length-1?A[n+1]:null;r&&s&&a6(s)?(i.push(new b2(r,uH(s))),n+=2):(i.push(new b2(r,{})),n++)}return new bn(i,{})}function HEA(t){let e={};return Object.entries(t).forEach(([A,i])=>{typeof i=="string"&&(i=[i]),i!==null&&(e[A]=uM(new bn([],{}),0,i))}),e}function uH(t){let e={};return Object.entries(t).forEach(([A,i])=>e[A]=`${i}`),e}function fH(t,e,A){return t==A.path&&Ag(e,A.parameters)}var s6="imperative",kr=function(t){return t[t.NavigationStart=0]="NavigationStart",t[t.NavigationEnd=1]="NavigationEnd",t[t.NavigationCancel=2]="NavigationCancel",t[t.NavigationError=3]="NavigationError",t[t.RoutesRecognized=4]="RoutesRecognized",t[t.ResolveStart=5]="ResolveStart",t[t.ResolveEnd=6]="ResolveEnd",t[t.GuardsCheckStart=7]="GuardsCheckStart",t[t.GuardsCheckEnd=8]="GuardsCheckEnd",t[t.RouteConfigLoadStart=9]="RouteConfigLoadStart",t[t.RouteConfigLoadEnd=10]="RouteConfigLoadEnd",t[t.ChildActivationStart=11]="ChildActivationStart",t[t.ChildActivationEnd=12]="ChildActivationEnd",t[t.ActivationStart=13]="ActivationStart",t[t.ActivationEnd=14]="ActivationEnd",t[t.Scroll=15]="Scroll",t[t.NavigationSkipped=16]="NavigationSkipped",t}(kr||{}),Va=class{id;url;constructor(e,A){this.id=e,this.url=A}},k2=class extends Va{type=kr.NavigationStart;navigationTrigger;restoredState;constructor(e,A,i="imperative",n=null){super(e,A),this.navigationTrigger=i,this.restoredState=n}toString(){return`NavigationStart(id: ${this.id}, url: '${this.url}')`}},Za=class extends Va{urlAfterRedirects;type=kr.NavigationEnd;constructor(e,A,i){super(e,A),this.urlAfterRedirects=i}toString(){return`NavigationEnd(id: ${this.id}, url: '${this.url}', urlAfterRedirects: '${this.urlAfterRedirects}')`}},oa=function(t){return t[t.Redirect=0]="Redirect",t[t.SupersededByNewNavigation=1]="SupersededByNewNavigation",t[t.NoDataFromResolver=2]="NoDataFromResolver",t[t.GuardRejected=3]="GuardRejected",t}(oa||{}),$d=function(t){return t[t.IgnoredSameUrlNavigation=0]="IgnoredSameUrlNavigation",t[t.IgnoredByUrlHandlingStrategy=1]="IgnoredByUrlHandlingStrategy",t}($d||{}),eg=class extends Va{reason;code;type=kr.NavigationCancel;constructor(e,A,i,n){super(e,A),this.reason=i,this.code=n}toString(){return`NavigationCancel(id: ${this.id}, url: '${this.url}')`}},ig=class extends Va{reason;code;type=kr.NavigationSkipped;constructor(e,A,i,n){super(e,A),this.reason=i,this.code=n}},AB=class extends Va{error;target;type=kr.NavigationError;constructor(e,A,i,n){super(e,A),this.error=i,this.target=n}toString(){return`NavigationError(id: ${this.id}, url: '${this.url}', error: ${this.error})`}},$Q=class extends Va{urlAfterRedirects;state;type=kr.RoutesRecognized;constructor(e,A,i,n){super(e,A),this.urlAfterRedirects=i,this.state=n}toString(){return`RoutesRecognized(id: ${this.id}, url: '${this.url}', urlAfterRedirects: '${this.urlAfterRedirects}', state: ${this.state})`}},l6=class extends Va{urlAfterRedirects;state;type=kr.GuardsCheckStart;constructor(e,A,i,n){super(e,A),this.urlAfterRedirects=i,this.state=n}toString(){return`GuardsCheckStart(id: ${this.id}, url: '${this.url}', urlAfterRedirects: '${this.urlAfterRedirects}', state: ${this.state})`}},g6=class extends Va{urlAfterRedirects;state;shouldActivate;type=kr.GuardsCheckEnd;constructor(e,A,i,n,o){super(e,A),this.urlAfterRedirects=i,this.state=n,this.shouldActivate=o}toString(){return`GuardsCheckEnd(id: ${this.id}, url: '${this.url}', urlAfterRedirects: '${this.urlAfterRedirects}', state: ${this.state}, shouldActivate: ${this.shouldActivate})`}},I6=class extends Va{urlAfterRedirects;state;type=kr.ResolveStart;constructor(e,A,i,n){super(e,A),this.urlAfterRedirects=i,this.state=n}toString(){return`ResolveStart(id: ${this.id}, url: '${this.url}', urlAfterRedirects: '${this.urlAfterRedirects}', state: ${this.state})`}},C6=class extends Va{urlAfterRedirects;state;type=kr.ResolveEnd;constructor(e,A,i,n){super(e,A),this.urlAfterRedirects=i,this.state=n}toString(){return`ResolveEnd(id: ${this.id}, url: '${this.url}', urlAfterRedirects: '${this.urlAfterRedirects}', state: ${this.state})`}},d6=class{route;type=kr.RouteConfigLoadStart;constructor(e){this.route=e}toString(){return`RouteConfigLoadStart(path: ${this.route.path})`}},B6=class{route;type=kr.RouteConfigLoadEnd;constructor(e){this.route=e}toString(){return`RouteConfigLoadEnd(path: ${this.route.path})`}},E6=class{snapshot;type=kr.ChildActivationStart;constructor(e){this.snapshot=e}toString(){return`ChildActivationStart(path: '${this.snapshot.routeConfig&&this.snapshot.routeConfig.path||""}')`}},h6=class{snapshot;type=kr.ChildActivationEnd;constructor(e){this.snapshot=e}toString(){return`ChildActivationEnd(path: '${this.snapshot.routeConfig&&this.snapshot.routeConfig.path||""}')`}},Q6=class{snapshot;type=kr.ActivationStart;constructor(e){this.snapshot=e}toString(){return`ActivationStart(path: '${this.snapshot.routeConfig&&this.snapshot.routeConfig.path||""}')`}},u6=class{snapshot;type=kr.ActivationEnd;constructor(e){this.snapshot=e}toString(){return`ActivationEnd(path: '${this.snapshot.routeConfig&&this.snapshot.routeConfig.path||""}')`}},eB=class{routerEvent;position;anchor;type=kr.Scroll;constructor(e,A,i){this.routerEvent=e,this.position=A,this.anchor=i}toString(){let e=this.position?`${this.position[0]}, ${this.position[1]}`:null;return`Scroll(anchor: '${this.anchor}', position: '${e}')`}},Au=class{},tB=class{url;navigationBehaviorOptions;constructor(e,A){this.url=e,this.navigationBehaviorOptions=A}};function OEA(t,e){return t.providers&&!t._injector&&(t._injector=hQ(t.providers,e,`Route: ${t.path}`)),t._injector??e}function nl(t){return t.outlet||Bi}function PEA(t,e){let A=t.filter(i=>nl(i)===e);return A.push(...t.filter(i=>nl(i)!==e)),A}function su(t){if(!t)return null;if(t.routeConfig?._injector)return t.routeConfig._injector;for(let e=t.parent;e;e=e.parent){let A=e.routeConfig;if(A?._loadedInjector)return A._loadedInjector;if(A?._injector)return A._injector}return null}var f6=class{rootInjector;outlet=null;route=null;children;attachRef=null;get injector(){return su(this.route?.snapshot)??this.rootInjector}constructor(e){this.rootInjector=e,this.children=new xI(this.rootInjector)}},xI=(()=>{class t{rootInjector;contexts=new Map;constructor(A){this.rootInjector=A}onChildOutletCreated(A,i){let n=this.getOrCreateContext(A);n.outlet=i,this.contexts.set(A,n)}onChildOutletDestroyed(A){let i=this.getContext(A);i&&(i.outlet=null,i.attachRef=null)}onOutletDeactivated(){let A=this.contexts;return this.contexts=new Map,A}onOutletReAttached(A){this.contexts=A}getOrCreateContext(A){let i=this.getContext(A);return i||(i=new f6(this.rootInjector),this.contexts.set(A,i)),i}getContext(A){return this.contexts.get(A)||null}static \u0275fac=function(i){return new(i||t)(he(Br))};static \u0275prov=SA({token:t,factory:t.\u0275fac,providedIn:"root"})}return t})(),m6=class{_root;constructor(e){this._root=e}get root(){return this._root.value}parent(e){let A=this.pathFromRoot(e);return A.length>1?A[A.length-2]:null}children(e){let A=fM(e,this._root);return A?A.children.map(i=>i.value):[]}firstChild(e){let A=fM(e,this._root);return A&&A.children.length>0?A.children[0].value:null}siblings(e){let A=mM(e,this._root);return A.length<2?[]:A[A.length-2].children.map(n=>n.value).filter(n=>n!==e)}pathFromRoot(e){return mM(e,this._root).map(A=>A.value)}};function fM(t,e){if(t===e.value)return e;for(let A of e.children){let i=fM(t,A);if(i)return i}return null}function mM(t,e){if(t===e.value)return[e];for(let A of e.children){let i=mM(t,A);if(i.length)return i.unshift(e),i}return[]}var qa=class{value;children;constructor(e,A){this.value=e,this.children=A}toString(){return`TreeNode(${this.value})`}};function Vd(t){let e={};return t&&t.children.forEach(A=>e[A.value.outlet]=A),e}var eu=class extends m6{snapshot;constructor(e,A){super(e),this.snapshot=A,kM(this,e)}toString(){return this.snapshot.toString()}};function YH(t){let e=jEA(t),A=new li([new b2("",{})]),i=new li({}),n=new li({}),o=new li({}),r=new li(""),s=new ra(A,i,o,r,n,Bi,t,e.root);return s.snapshot=e.root,new eu(new qa(s,[]),e)}function jEA(t){let e={},A={},i={},n="",o=new SI([],e,i,n,A,Bi,t,null,{});return new tu("",new qa(o,[]))}var ra=class{urlSubject;paramsSubject;queryParamsSubject;fragmentSubject;dataSubject;outlet;component;snapshot;_futureSnapshot;_routerState;_paramMap;_queryParamMap;title;url;params;queryParams;fragment;data;constructor(e,A,i,n,o,r,s,a){this.urlSubject=e,this.paramsSubject=A,this.queryParamsSubject=i,this.fragmentSubject=n,this.dataSubject=o,this.outlet=r,this.component=s,this._futureSnapshot=a,this.title=this.dataSubject?.pipe(Je(c=>c[ru]))??ve(void 0),this.url=e,this.params=A,this.queryParams=i,this.fragment=n,this.data=o}get routeConfig(){return this._futureSnapshot.routeConfig}get root(){return this._routerState.root}get parent(){return this._routerState.parent(this)}get firstChild(){return this._routerState.firstChild(this)}get children(){return this._routerState.children(this)}get pathFromRoot(){return this._routerState.pathFromRoot(this)}get paramMap(){return this._paramMap??=this.params.pipe(Je(e=>RI(e))),this._paramMap}get queryParamMap(){return this._queryParamMap??=this.queryParams.pipe(Je(e=>RI(e))),this._queryParamMap}toString(){return this.snapshot?this.snapshot.toString():`Future(${this._futureSnapshot})`}};function p6(t,e,A="emptyOnly"){let i,{routeConfig:n}=t;return e!==null&&(A==="always"||n?.path===""||!e.component&&!e.routeConfig?.loadComponent)?i={params:nA(nA({},e.params),t.params),data:nA(nA({},e.data),t.data),resolve:nA(nA(nA(nA({},t.data),e.data),n?.data),t._resolvedData)}:i={params:nA({},t.params),data:nA({},t.data),resolve:nA(nA({},t.data),t._resolvedData??{})},n&&TH(n)&&(i.resolve[ru]=n.title),i}var SI=class{url;params;queryParams;fragment;data;outlet;component;routeConfig;_resolve;_resolvedData;_routerState;_paramMap;_queryParamMap;get title(){return this.data?.[ru]}constructor(e,A,i,n,o,r,s,a,c){this.url=e,this.params=A,this.queryParams=i,this.fragment=n,this.data=o,this.outlet=r,this.component=s,this.routeConfig=a,this._resolve=c}get root(){return this._routerState.root}get parent(){return this._routerState.parent(this)}get firstChild(){return this._routerState.firstChild(this)}get children(){return this._routerState.children(this)}get pathFromRoot(){return this._routerState.pathFromRoot(this)}get paramMap(){return this._paramMap??=RI(this.params),this._paramMap}get queryParamMap(){return this._queryParamMap??=RI(this.queryParams),this._queryParamMap}toString(){let e=this.url.map(i=>i.toString()).join("/"),A=this.routeConfig?this.routeConfig.path:"";return`Route(url:'${e}', path:'${A}')`}},tu=class extends m6{url;constructor(e,A){super(A),this.url=e,kM(this,A)}toString(){return JH(this._root)}};function kM(t,e){e.value._routerState=t,e.children.forEach(A=>kM(t,A))}function JH(t){let e=t.children.length>0?` { ${t.children.map(JH).join(", ")} } `:"";return`${t.value}${e}`}function CM(t){if(t.snapshot){let e=t.snapshot,A=t._futureSnapshot;t.snapshot=A,Ag(e.queryParams,A.queryParams)||t.queryParamsSubject.next(A.queryParams),e.fragment!==A.fragment&&t.fragmentSubject.next(A.fragment),Ag(e.params,A.params)||t.paramsSubject.next(A.params),mEA(e.url,A.url)||t.urlSubject.next(A.url),Ag(e.data,A.data)||t.dataSubject.next(A.data)}else t.snapshot=t._futureSnapshot,t.dataSubject.next(t._futureSnapshot.data)}function pM(t,e){let A=Ag(t.params,e.params)&&yEA(t.url,e.url),i=!t.parent!=!e.parent;return A&&!i&&(!t.parent||pM(t.parent,e.parent))}function TH(t){return typeof t.title=="string"||t.title===null}var zH=new BA(""),SM=(()=>{class t{activated=null;get activatedComponentRef(){return this.activated}_activatedRoute=null;name=Bi;activateEvents=new XA;deactivateEvents=new XA;attachEvents=new XA;detachEvents=new XA;routerOutletData=sJ(void 0);parentContexts=m(xI);location=m(Un);changeDetector=m(lt);inputBinder=m(au,{optional:!0});supportsBindingToComponentInputs=!0;ngOnChanges(A){if(A.name){let{firstChange:i,previousValue:n}=A.name;if(i)return;this.isTrackedInParentContexts(n)&&(this.deactivate(),this.parentContexts.onChildOutletDestroyed(n)),this.initializeOutletWithName()}}ngOnDestroy(){this.isTrackedInParentContexts(this.name)&&this.parentContexts.onChildOutletDestroyed(this.name),this.inputBinder?.unsubscribeFromRouteData(this)}isTrackedInParentContexts(A){return this.parentContexts.getContext(A)?.outlet===this}ngOnInit(){this.initializeOutletWithName()}initializeOutletWithName(){if(this.parentContexts.onChildOutletCreated(this.name,this),this.activated)return;let A=this.parentContexts.getContext(this.name);A?.route&&(A.attachRef?this.attach(A.attachRef,A.route):this.activateWith(A.route,A.injector))}get isActivated(){return!!this.activated}get component(){if(!this.activated)throw new ZA(4012,!1);return this.activated.instance}get activatedRoute(){if(!this.activated)throw new ZA(4012,!1);return this._activatedRoute}get activatedRouteData(){return this._activatedRoute?this._activatedRoute.snapshot.data:{}}detach(){if(!this.activated)throw new ZA(4012,!1);this.location.detach();let A=this.activated;return this.activated=null,this._activatedRoute=null,this.detachEvents.emit(A.instance),A}attach(A,i){this.activated=A,this._activatedRoute=i,this.location.insert(A.hostView),this.inputBinder?.bindActivatedRouteToOutletComponent(this),this.attachEvents.emit(A.instance)}deactivate(){if(this.activated){let A=this.component;this.activated.destroy(),this.activated=null,this._activatedRoute=null,this.deactivateEvents.emit(A)}}activateWith(A,i){if(this.isActivated)throw new ZA(4013,!1);this._activatedRoute=A;let n=this.location,r=A.snapshot.component,s=this.parentContexts.getOrCreateContext(this.name).children,a=new wM(A,s,n.injector,this.routerOutletData);this.activated=n.createComponent(r,{index:n.length,injector:a,environmentInjector:i}),this.changeDetector.markForCheck(),this.inputBinder?.bindActivatedRouteToOutletComponent(this),this.activateEvents.emit(this.activated.instance)}static \u0275fac=function(i){return new(i||t)};static \u0275dir=OA({type:t,selectors:[["router-outlet"]],inputs:{name:"name",routerOutletData:[1,"routerOutletData"]},outputs:{activateEvents:"activate",deactivateEvents:"deactivate",attachEvents:"attach",detachEvents:"detach"},exportAs:["outlet"],features:[Kt]})}return t})(),wM=class{route;childContexts;parent;outletData;constructor(e,A,i,n){this.route=e,this.childContexts=A,this.parent=i,this.outletData=n}get(e,A){return e===ra?this.route:e===xI?this.childContexts:e===zH?this.outletData:this.parent.get(e,A)}},au=new BA(""),RM=(()=>{class t{outletDataSubscriptions=new Map;bindActivatedRouteToOutletComponent(A){this.unsubscribeFromRouteData(A),this.subscribeToRouteData(A)}unsubscribeFromRouteData(A){this.outletDataSubscriptions.get(A)?.unsubscribe(),this.outletDataSubscriptions.delete(A)}subscribeToRouteData(A){let{activatedRoute:i}=A,n=Ls([i.queryParams,i.params,i.data]).pipe(no(([o,r,s],a)=>(s=nA(nA(nA({},o),r),s),a===0?ve(s):Promise.resolve(s)))).subscribe(o=>{if(!A.isActivated||!A.activatedComponentRef||A.activatedRoute!==i||i.component===null){this.unsubscribeFromRouteData(A);return}let r=rz(i.component);if(!r){this.unsubscribeFromRouteData(A);return}for(let{templateName:s}of r.inputs)A.activatedComponentRef.setInput(s,o[s])});this.outletDataSubscriptions.set(A,n)}static \u0275fac=function(i){return new(i||t)};static \u0275prov=SA({token:t,factory:t.\u0275fac})}return t})();function qEA(t,e,A){let i=iu(t,e._root,A?A._root:void 0);return new eu(i,e)}function iu(t,e,A){if(A&&t.shouldReuseRoute(e.value,A.value.snapshot)){let i=A.value;i._futureSnapshot=e.value;let n=VEA(t,e,A);return new qa(i,n)}else{if(t.shouldAttach(e.value)){let o=t.retrieve(e.value);if(o!==null){let r=o.route;return r.value._futureSnapshot=e.value,r.children=e.children.map(s=>iu(t,s)),r}}let i=ZEA(e.value),n=e.children.map(o=>iu(t,o));return new qa(i,n)}}function VEA(t,e,A){return e.children.map(i=>{for(let n of A.children)if(t.shouldReuseRoute(i.value,n.value.snapshot))return iu(t,i,n);return iu(t,i)})}function ZEA(t){return new ra(new li(t.url),new li(t.params),new li(t.queryParams),new li(t.fragment),new li(t.data),t.outlet,t.component,t)}var iB=class{redirectTo;navigationBehaviorOptions;constructor(e,A){this.redirectTo=e,this.navigationBehaviorOptions=A}},HH="ngNavigationCancelingError";function w6(t,e){let{redirectTo:A,navigationBehaviorOptions:i}=Xd(e)?{redirectTo:e,navigationBehaviorOptions:void 0}:e,n=OH(!1,oa.Redirect);return n.url=A,n.navigationBehaviorOptions=i,n}function OH(t,e){let A=new Error(`NavigationCancelingError: ${t||""}`);return A[HH]=!0,A.cancellationCode=e,A}function WEA(t){return PH(t)&&Xd(t.url)}function PH(t){return!!t&&t[HH]}var XEA=(t,e,A,i)=>Je(n=>(new DM(e,n.targetRouterState,n.currentRouterState,A,i).activate(t),n)),DM=class{routeReuseStrategy;futureState;currState;forwardEvent;inputBindingEnabled;constructor(e,A,i,n,o){this.routeReuseStrategy=e,this.futureState=A,this.currState=i,this.forwardEvent=n,this.inputBindingEnabled=o}activate(e){let A=this.futureState._root,i=this.currState?this.currState._root:null;this.deactivateChildRoutes(A,i,e),CM(this.futureState.root),this.activateChildRoutes(A,i,e)}deactivateChildRoutes(e,A,i){let n=Vd(A);e.children.forEach(o=>{let r=o.value.outlet;this.deactivateRoutes(o,n[r],i),delete n[r]}),Object.values(n).forEach(o=>{this.deactivateRouteAndItsChildren(o,i)})}deactivateRoutes(e,A,i){let n=e.value,o=A?A.value:null;if(n===o)if(n.component){let r=i.getContext(n.outlet);r&&this.deactivateChildRoutes(e,A,r.children)}else this.deactivateChildRoutes(e,A,i);else o&&this.deactivateRouteAndItsChildren(A,i)}deactivateRouteAndItsChildren(e,A){e.value.component&&this.routeReuseStrategy.shouldDetach(e.value.snapshot)?this.detachAndStoreRouteSubtree(e,A):this.deactivateRouteAndOutlet(e,A)}detachAndStoreRouteSubtree(e,A){let i=A.getContext(e.value.outlet),n=i&&e.value.component?i.children:A,o=Vd(e);for(let r of Object.values(o))this.deactivateRouteAndItsChildren(r,n);if(i&&i.outlet){let r=i.outlet.detach(),s=i.children.onOutletDeactivated();this.routeReuseStrategy.store(e.value.snapshot,{componentRef:r,route:e,contexts:s})}}deactivateRouteAndOutlet(e,A){let i=A.getContext(e.value.outlet),n=i&&e.value.component?i.children:A,o=Vd(e);for(let r of Object.values(o))this.deactivateRouteAndItsChildren(r,n);i&&(i.outlet&&(i.outlet.deactivate(),i.children.onOutletDeactivated()),i.attachRef=null,i.route=null)}activateChildRoutes(e,A,i){let n=Vd(A);e.children.forEach(o=>{this.activateRoutes(o,n[o.value.outlet],i),this.forwardEvent(new u6(o.value.snapshot))}),e.children.length&&this.forwardEvent(new h6(e.value.snapshot))}activateRoutes(e,A,i){let n=e.value,o=A?A.value:null;if(CM(n),n===o)if(n.component){let r=i.getOrCreateContext(n.outlet);this.activateChildRoutes(e,A,r.children)}else this.activateChildRoutes(e,A,i);else if(n.component){let r=i.getOrCreateContext(n.outlet);if(this.routeReuseStrategy.shouldAttach(n.snapshot)){let s=this.routeReuseStrategy.retrieve(n.snapshot);this.routeReuseStrategy.store(n.snapshot,null),r.children.onOutletReAttached(s.contexts),r.attachRef=s.componentRef,r.route=s.route.value,r.outlet&&r.outlet.attach(s.componentRef,s.route.value),CM(s.route.value),this.activateChildRoutes(e,null,r.children)}else r.attachRef=null,r.route=n,r.outlet&&r.outlet.activateWith(n,r.injector),this.activateChildRoutes(e,null,r.children)}else this.activateChildRoutes(e,null,i)}},D6=class{path;route;constructor(e){this.path=e,this.route=this.path[this.path.length-1]}},Wd=class{component;route;constructor(e,A){this.component=e,this.route=A}};function $EA(t,e,A){let i=t._root,n=e?e._root:null;return VQ(i,n,A,[i.value])}function AhA(t){let e=t.routeConfig?t.routeConfig.canActivateChild:null;return!e||e.length===0?null:{node:t,guards:e}}function oB(t,e){let A=Symbol(),i=e.get(t,A);return i===A?typeof t=="function"&&!sY(t)?t:e.get(t):i}function VQ(t,e,A,i,n={canDeactivateChecks:[],canActivateChecks:[]}){let o=Vd(e);return t.children.forEach(r=>{ehA(r,o[r.value.outlet],A,i.concat([r.value]),n),delete o[r.value.outlet]}),Object.entries(o).forEach(([r,s])=>WQ(s,A.getContext(r),n)),n}function ehA(t,e,A,i,n={canDeactivateChecks:[],canActivateChecks:[]}){let o=t.value,r=e?e.value:null,s=A?A.getContext(t.value.outlet):null;if(r&&o.routeConfig===r.routeConfig){let a=thA(r,o,o.routeConfig.runGuardsAndResolvers);a?n.canActivateChecks.push(new D6(i)):(o.data=r.data,o._resolvedData=r._resolvedData),o.component?VQ(t,e,s?s.children:null,i,n):VQ(t,e,A,i,n),a&&s&&s.outlet&&s.outlet.isActivated&&n.canDeactivateChecks.push(new Wd(s.outlet.component,r))}else r&&WQ(e,s,n),n.canActivateChecks.push(new D6(i)),o.component?VQ(t,null,s?s.children:null,i,n):VQ(t,null,A,i,n);return n}function thA(t,e,A){if(typeof A=="function")return A(t,e);switch(A){case"pathParamsChange":return!kI(t.url,e.url);case"pathParamsOrQueryParamsChange":return!kI(t.url,e.url)||!Ag(t.queryParams,e.queryParams);case"always":return!0;case"paramsOrQueryParamsChange":return!pM(t,e)||!Ag(t.queryParams,e.queryParams);case"paramsChange":default:return!pM(t,e)}}function WQ(t,e,A){let i=Vd(t),n=t.value;Object.entries(i).forEach(([o,r])=>{n.component?e?WQ(r,e.children.getContext(o),A):WQ(r,null,A):WQ(r,e,A)}),n.component?e&&e.outlet&&e.outlet.isActivated?A.canDeactivateChecks.push(new Wd(e.outlet.component,n)):A.canDeactivateChecks.push(new Wd(null,n)):A.canDeactivateChecks.push(new Wd(null,n))}function cu(t){return typeof t=="function"}function ihA(t){return typeof t=="boolean"}function nhA(t){return t&&cu(t.canLoad)}function ohA(t){return t&&cu(t.canActivate)}function rhA(t){return t&&cu(t.canActivateChild)}function shA(t){return t&&cu(t.canDeactivate)}function ahA(t){return t&&cu(t.canMatch)}function jH(t){return t instanceof Xg||t?.name==="EmptyError"}var i6=Symbol("INITIAL_VALUE");function nB(){return no(t=>Ls(t.map(e=>e.pipe(Pn(1),Qo(i6)))).pipe(Je(e=>{for(let A of e)if(A!==!0){if(A===i6)return i6;if(A===!1||chA(A))return A}return!0}),pt(e=>e!==i6),Pn(1)))}function chA(t){return Xd(t)||t instanceof iB}function lhA(t,e){return qo(A=>{let{targetSnapshot:i,currentSnapshot:n,guards:{canActivateChecks:o,canDeactivateChecks:r}}=A;return r.length===0&&o.length===0?ve(Ne(nA({},A),{guardsResult:!0})):ghA(r,i,n,t).pipe(qo(s=>s&&ihA(s)?IhA(i,o,t,e):ve(s)),Je(s=>Ne(nA({},A),{guardsResult:s})))})}function ghA(t,e,A,i){return On(t).pipe(qo(n=>hhA(n.component,n.route,A,e,i)),zl(n=>n!==!0,!0))}function IhA(t,e,A,i){return On(e).pipe(Jl(n=>l2(dhA(n.route.parent,i),ChA(n.route,i),EhA(t,n.path,A),BhA(t,n.route,A))),zl(n=>n!==!0,!0))}function ChA(t,e){return t!==null&&e&&e(new Q6(t)),ve(!0)}function dhA(t,e){return t!==null&&e&&e(new E6(t)),ve(!0)}function BhA(t,e,A){let i=e.routeConfig?e.routeConfig.canActivate:null;if(!i||i.length===0)return ve(!0);let n=i.map(o=>Yl(()=>{let r=su(e)??A,s=oB(o,r),a=ohA(s)?s.canActivate(e,t):$s(r,()=>s(e,t));return S2(a).pipe(zl())}));return ve(n).pipe(nB())}function EhA(t,e,A){let i=e[e.length-1],o=e.slice(0,e.length-1).reverse().map(r=>AhA(r)).filter(r=>r!==null).map(r=>Yl(()=>{let s=r.guards.map(a=>{let c=su(r.node)??A,l=oB(a,c),I=rhA(l)?l.canActivateChild(i,t):$s(c,()=>l(i,t));return S2(I).pipe(zl())});return ve(s).pipe(nB())}));return ve(o).pipe(nB())}function hhA(t,e,A,i,n){let o=e&&e.routeConfig?e.routeConfig.canDeactivate:null;if(!o||o.length===0)return ve(!0);let r=o.map(s=>{let a=su(e)??n,c=oB(s,a),l=shA(c)?c.canDeactivate(t,e,A,i):$s(a,()=>c(t,e,A,i));return S2(l).pipe(zl())});return ve(r).pipe(nB())}function QhA(t,e,A,i){let n=e.canLoad;if(n===void 0||n.length===0)return ve(!0);let o=n.map(r=>{let s=oB(r,t),a=nhA(s)?s.canLoad(e,A):$s(t,()=>s(e,A));return S2(a)});return ve(o).pipe(nB(),qH(i))}function qH(t){return O7(oo(e=>{if(typeof e!="boolean")throw w6(t,e)}),Je(e=>e===!0))}function uhA(t,e,A,i){let n=e.canMatch;if(!n||n.length===0)return ve(!0);let o=n.map(r=>{let s=oB(r,t),a=ahA(s)?s.canMatch(e,A):$s(t,()=>s(e,A));return S2(a)});return ve(o).pipe(nB(),qH(i))}var nu=class{segmentGroup;constructor(e){this.segmentGroup=e||null}},ou=class extends Error{urlTree;constructor(e){super(),this.urlTree=e}};function qd(t){return s2(new nu(t))}function fhA(t){return s2(new ZA(4e3,!1))}function mhA(t){return s2(OH(!1,oa.GuardRejected))}var yM=class{urlSerializer;urlTree;constructor(e,A){this.urlSerializer=e,this.urlTree=A}lineralizeSegments(e,A){let i=[],n=A.root;for(;;){if(i=i.concat(n.segments),n.numberOfChildren===0)return ve(i);if(n.numberOfChildren>1||!n.children[Bi])return fhA(`${e.redirectTo}`);n=n.children[Bi]}}applyRedirectCommands(e,A,i,n,o){if(typeof A!="string"){let s=A,{queryParams:a,fragment:c,routeConfig:l,url:I,outlet:C,params:d,data:B,title:E}=n,Q=$s(o,()=>s({params:d,data:B,queryParams:a,fragment:c,routeConfig:l,url:I,outlet:C,title:E}));if(Q instanceof tg)throw new ou(Q);A=Q}let r=this.applyRedirectCreateUrlTree(A,this.urlSerializer.parse(A),e,i);if(A[0]==="/")throw new ou(r);return r}applyRedirectCreateUrlTree(e,A,i,n){let o=this.createSegmentGroup(e,A.root,i,n);return new tg(o,this.createQueryParams(A.queryParams,this.urlTree.queryParams),A.fragment)}createQueryParams(e,A){let i={};return Object.entries(e).forEach(([n,o])=>{if(typeof o=="string"&&o[0]===":"){let s=o.substring(1);i[n]=A[s]}else i[n]=o}),i}createSegmentGroup(e,A,i,n){let o=this.createSegments(e,A.segments,i,n),r={};return Object.entries(A.children).forEach(([s,a])=>{r[s]=this.createSegmentGroup(e,a,i,n)}),new bn(o,r)}createSegments(e,A,i,n){return A.map(o=>o.path[0]===":"?this.findPosParam(e,o,n):this.findOrReturn(o,i))}findPosParam(e,A,i){let n=i[A.path.substring(1)];if(!n)throw new ZA(4001,!1);return n}findOrReturn(e,A){let i=0;for(let n of A){if(n.path===e.path)return A.splice(i),n;i++}return e}},vM={matched:!1,consumedSegments:[],remainingSegments:[],parameters:{},positionalParamSegments:{}};function phA(t,e,A,i,n){let o=VH(t,e,A);return o.matched?(i=OEA(e,i),uhA(i,e,A,n).pipe(Je(r=>r===!0?o:nA({},vM)))):ve(o)}function VH(t,e,A){if(e.path==="**")return whA(A);if(e.path==="")return e.pathMatch==="full"&&(t.hasChildren()||A.length>0)?nA({},vM):{matched:!0,consumedSegments:[],remainingSegments:A,parameters:{},positionalParamSegments:{}};let n=(e.matcher||DH)(A,t,e);if(!n)return nA({},vM);let o={};Object.entries(n.posParams??{}).forEach(([s,a])=>{o[s]=a.path});let r=n.consumed.length>0?nA(nA({},o),n.consumed[n.consumed.length-1].parameters):o;return{matched:!0,consumedSegments:n.consumed,remainingSegments:A.slice(n.consumed.length),parameters:r,positionalParamSegments:n.posParams??{}}}function whA(t){return{matched:!0,parameters:t.length>0?vH(t).parameters:{},consumedSegments:t,remainingSegments:[],positionalParamSegments:{}}}function mH(t,e,A,i){return A.length>0&&vhA(t,A,i)?{segmentGroup:new bn(e,yhA(i,new bn(A,t.children))),slicedSegments:[]}:A.length===0&&bhA(t,A,i)?{segmentGroup:new bn(t.segments,DhA(t,A,i,t.children)),slicedSegments:A}:{segmentGroup:new bn(t.segments,t.children),slicedSegments:A}}function DhA(t,e,A,i){let n={};for(let o of A)if(v6(t,e,o)&&!i[nl(o)]){let r=new bn([],{});n[nl(o)]=r}return nA(nA({},i),n)}function yhA(t,e){let A={};A[Bi]=e;for(let i of t)if(i.path===""&&nl(i)!==Bi){let n=new bn([],{});A[nl(i)]=n}return A}function vhA(t,e,A){return A.some(i=>v6(t,e,i)&&nl(i)!==Bi)}function bhA(t,e,A){return A.some(i=>v6(t,e,i))}function v6(t,e,A){return(t.hasChildren()||e.length>0)&&A.pathMatch==="full"?!1:A.path===""}function MhA(t,e,A){return e.length===0&&!t.children[A]}var bM=class{};function khA(t,e,A,i,n,o,r="emptyOnly"){return new MM(t,e,A,i,n,r,o).recognize()}var ShA=31,MM=class{injector;configLoader;rootComponentType;config;urlTree;paramsInheritanceStrategy;urlSerializer;applyRedirects;absoluteRedirectCount=0;allowRedirects=!0;constructor(e,A,i,n,o,r,s){this.injector=e,this.configLoader=A,this.rootComponentType=i,this.config=n,this.urlTree=o,this.paramsInheritanceStrategy=r,this.urlSerializer=s,this.applyRedirects=new yM(this.urlSerializer,this.urlTree)}noMatchError(e){return new ZA(4002,`'${e.segmentGroup}'`)}recognize(){let e=mH(this.urlTree.root,[],[],this.config).segmentGroup;return this.match(e).pipe(Je(({children:A,rootSnapshot:i})=>{let n=new qa(i,A),o=new tu("",n),r=NH(i,[],this.urlTree.queryParams,this.urlTree.fragment);return r.queryParams=this.urlTree.queryParams,o.url=this.urlSerializer.serialize(r),{state:o,tree:r}}))}match(e){let A=new SI([],Object.freeze({}),Object.freeze(nA({},this.urlTree.queryParams)),this.urlTree.fragment,Object.freeze({}),Bi,this.rootComponentType,null,{});return this.processSegmentGroup(this.injector,this.config,e,Bi,A).pipe(Je(i=>({children:i,rootSnapshot:A})),dr(i=>{if(i instanceof ou)return this.urlTree=i.urlTree,this.match(i.urlTree.root);throw i instanceof nu?this.noMatchError(i):i}))}processSegmentGroup(e,A,i,n,o){return i.segments.length===0&&i.hasChildren()?this.processChildren(e,A,i,o):this.processSegment(e,A,i,i.segments,n,!0,o).pipe(Je(r=>r instanceof qa?[r]:[]))}processChildren(e,A,i,n){let o=[];for(let r of Object.keys(i.children))r==="primary"?o.unshift(r):o.push(r);return On(o).pipe(Jl(r=>{let s=i.children[r],a=PEA(A,r);return this.processSegmentGroup(e,a,s,r,n)}),W7((r,s)=>(r.push(...s),r)),g2(null),Z7(),qo(r=>{if(r===null)return qd(i);let s=ZH(r);return RhA(s),ve(s)}))}processSegment(e,A,i,n,o,r,s){return On(A).pipe(Jl(a=>this.processSegmentAgainstRoute(a._injector??e,A,a,i,n,o,r,s).pipe(dr(c=>{if(c instanceof nu)return ve(null);throw c}))),zl(a=>!!a),dr(a=>{if(jH(a))return MhA(i,n,o)?ve(new bM):qd(i);throw a}))}processSegmentAgainstRoute(e,A,i,n,o,r,s,a){return nl(i)!==r&&(r===Bi||!v6(n,o,i))?qd(n):i.redirectTo===void 0?this.matchSegmentAgainstRoute(e,n,i,o,r,a):this.allowRedirects&&s?this.expandSegmentAgainstRouteUsingRedirect(e,n,A,i,o,r,a):qd(n)}expandSegmentAgainstRouteUsingRedirect(e,A,i,n,o,r,s){let{matched:a,parameters:c,consumedSegments:l,positionalParamSegments:I,remainingSegments:C}=VH(A,n,o);if(!a)return qd(A);typeof n.redirectTo=="string"&&n.redirectTo[0]==="/"&&(this.absoluteRedirectCount++,this.absoluteRedirectCount>ShA&&(this.allowRedirects=!1));let d=new SI(o,c,Object.freeze(nA({},this.urlTree.queryParams)),this.urlTree.fragment,pH(n),nl(n),n.component??n._loadedComponent??null,n,wH(n)),B=p6(d,s,this.paramsInheritanceStrategy);d.params=Object.freeze(B.params),d.data=Object.freeze(B.data);let E=this.applyRedirects.applyRedirectCommands(l,n.redirectTo,I,d,e);return this.applyRedirects.lineralizeSegments(n,E).pipe(qo(Q=>this.processSegment(e,i,A,Q.concat(C),r,!1,s)))}matchSegmentAgainstRoute(e,A,i,n,o,r){let s=phA(A,i,n,e,this.urlSerializer);return i.path==="**"&&(A.children={}),s.pipe(no(a=>a.matched?(e=i._injector??e,this.getChildConfig(e,i,n).pipe(no(({routes:c})=>{let l=i._loadedInjector??e,{parameters:I,consumedSegments:C,remainingSegments:d}=a,B=new SI(C,I,Object.freeze(nA({},this.urlTree.queryParams)),this.urlTree.fragment,pH(i),nl(i),i.component??i._loadedComponent??null,i,wH(i)),E=p6(B,r,this.paramsInheritanceStrategy);B.params=Object.freeze(E.params),B.data=Object.freeze(E.data);let{segmentGroup:Q,slicedSegments:u}=mH(A,C,d,c);if(u.length===0&&Q.hasChildren())return this.processChildren(l,c,Q,B).pipe(Je(L=>new qa(B,L)));if(c.length===0&&u.length===0)return ve(new qa(B,[]));let v=nl(i)===o;return this.processSegment(l,c,Q,u,v?Bi:o,!0,B).pipe(Je(L=>new qa(B,L instanceof qa?[L]:[])))}))):qd(A)))}getChildConfig(e,A,i){return A.children?ve({routes:A.children,injector:e}):A.loadChildren?A._loadedRoutes!==void 0?ve({routes:A._loadedRoutes,injector:A._loadedInjector}):QhA(e,A,i,this.urlSerializer).pipe(qo(n=>n?this.configLoader.loadChildren(e,A).pipe(oo(o=>{A._loadedRoutes=o.routes,A._loadedInjector=o.injector})):mhA(A))):ve({routes:[],injector:e})}};function RhA(t){t.sort((e,A)=>e.value.outlet===Bi?-1:A.value.outlet===Bi?1:e.value.outlet.localeCompare(A.value.outlet))}function LhA(t){let e=t.value.routeConfig;return e&&e.path===""}function ZH(t){let e=[],A=new Set;for(let i of t){if(!LhA(i)){e.push(i);continue}let n=e.find(o=>i.value.routeConfig===o.value.routeConfig);n!==void 0?(n.children.push(...i.children),A.add(n)):e.push(i)}for(let i of A){let n=ZH(i.children);e.push(new qa(i.value,n))}return e.filter(i=>!A.has(i))}function pH(t){return t.data||{}}function wH(t){return t.resolve||{}}function xhA(t,e,A,i,n,o){return qo(r=>khA(t,e,A,i,r.extractedUrl,n,o).pipe(Je(({state:s,tree:a})=>Ne(nA({},r),{targetSnapshot:s,urlAfterRedirects:a}))))}function FhA(t,e){return qo(A=>{let{targetSnapshot:i,guards:{canActivateChecks:n}}=A;if(!n.length)return ve(A);let o=new Set(n.map(a=>a.route)),r=new Set;for(let a of o)if(!r.has(a))for(let c of WH(a))r.add(c);let s=0;return On(r).pipe(Jl(a=>o.has(a)?NhA(a,i,t,e):(a.data=p6(a,a.parent,t).resolve,ve(void 0))),oo(()=>s++),Bd(1),qo(a=>s===r.size?ve(A):Ar))})}function WH(t){let e=t.children.map(A=>WH(A)).flat();return[t,...e]}function NhA(t,e,A,i){let n=t.routeConfig,o=t._resolve;return n?.title!==void 0&&!TH(n)&&(o[ru]=n.title),_hA(o,t,e,i).pipe(Je(r=>(t._resolvedData=r,t.data=p6(t,t.parent,A).resolve,null)))}function _hA(t,e,A,i){let n=EM(t);if(n.length===0)return ve({});let o={};return On(n).pipe(qo(r=>GhA(t[r],e,A,i).pipe(zl(),oo(s=>{if(s instanceof iB)throw w6(new M2,s);o[r]=s}))),Bd(1),Je(()=>o),dr(r=>jH(r)?Ar:s2(r)))}function GhA(t,e,A,i){let n=su(e)??i,o=oB(t,n),r=o.resolve?o.resolve(e,A):$s(n,()=>o(e,A));return S2(r)}function dM(t){return no(e=>{let A=t(e);return A?On(A).pipe(Je(()=>e)):ve(e)})}var LM=(()=>{class t{buildTitle(A){let i,n=A.root;for(;n!==void 0;)i=this.getResolvedTitleForRoute(n)??i,n=n.children.find(o=>o.outlet===Bi);return i}getResolvedTitleForRoute(A){return A.data[ru]}static \u0275fac=function(i){return new(i||t)};static \u0275prov=SA({token:t,factory:()=>m(XH),providedIn:"root"})}return t})(),XH=(()=>{class t extends LM{title;constructor(A){super(),this.title=A}updateTitle(A){let i=this.buildTitle(A);i!==void 0&&this.title.setTitle(i)}static \u0275fac=function(i){return new(i||t)(he(Jz))};static \u0275prov=SA({token:t,factory:t.\u0275fac,providedIn:"root"})}return t})(),FI=new BA("",{providedIn:"root",factory:()=>({})}),xM=(()=>{class t{static \u0275fac=function(i){return new(i||t)};static \u0275cmp=YA({type:t,selectors:[["ng-component"]],exportAs:["emptyRouterOutlet"],decls:1,vars:0,template:function(i,n){i&1&&UA(0,"router-outlet")},dependencies:[SM],encapsulation:2})}return t})();function FM(t){let e=t.children&&t.children.map(FM),A=e?Ne(nA({},t),{children:e}):nA({},t);return!A.component&&!A.loadComponent&&(e||A.loadChildren)&&A.outlet&&A.outlet!==Bi&&(A.component=xM),A}var rB=new BA(""),b6=(()=>{class t{componentLoaders=new WeakMap;childrenLoaders=new WeakMap;onLoadStartListener;onLoadEndListener;compiler=m(XT);loadComponent(A){if(this.componentLoaders.get(A))return this.componentLoaders.get(A);if(A._loadedComponent)return ve(A._loadedComponent);this.onLoadStartListener&&this.onLoadStartListener(A);let i=S2(A.loadComponent()).pipe(Je(AO),oo(o=>{this.onLoadEndListener&&this.onLoadEndListener(A),A._loadedComponent=o}),Tl(()=>{this.componentLoaders.delete(A)})),n=new r2(i,()=>new HA).pipe(ad());return this.componentLoaders.set(A,n),n}loadChildren(A,i){if(this.childrenLoaders.get(i))return this.childrenLoaders.get(i);if(i._loadedRoutes)return ve({routes:i._loadedRoutes,injector:i._loadedInjector});this.onLoadStartListener&&this.onLoadStartListener(i);let o=$H(i,this.compiler,A,this.onLoadEndListener).pipe(Tl(()=>{this.childrenLoaders.delete(i)})),r=new r2(o,()=>new HA).pipe(ad());return this.childrenLoaders.set(i,r),r}static \u0275fac=function(i){return new(i||t)};static \u0275prov=SA({token:t,factory:t.\u0275fac,providedIn:"root"})}return t})();function $H(t,e,A,i){return S2(t.loadChildren()).pipe(Je(AO),qo(n=>n instanceof Eb||Array.isArray(n)?ve(n):On(e.compileModuleAsync(n))),Je(n=>{i&&i(t);let o,r,s=!1;return Array.isArray(n)?(r=n,s=!0):(o=n.create(A).injector,r=o.get(rB,[],{optional:!0,self:!0}).flat()),{routes:r.map(FM),injector:o}}))}function UhA(t){return t&&typeof t=="object"&&"default"in t}function AO(t){return UhA(t)?t.default:t}var M6=(()=>{class t{static \u0275fac=function(i){return new(i||t)};static \u0275prov=SA({token:t,factory:()=>m(KhA),providedIn:"root"})}return t})(),KhA=(()=>{class t{shouldProcessUrl(A){return!0}extract(A){return A}merge(A,i){return A}static \u0275fac=function(i){return new(i||t)};static \u0275prov=SA({token:t,factory:t.\u0275fac,providedIn:"root"})}return t})(),NM=new BA(""),_M=new BA("");function eO(t,e,A){let i=t.get(_M),n=t.get(tt);return t.get(de).runOutsideAngular(()=>{if(!n.startViewTransition||i.skipNextTransition)return i.skipNextTransition=!1,new Promise(c=>setTimeout(c));let o,r=new Promise(c=>{o=c}),s=n.startViewTransition(()=>(o(),YhA(t))),{onViewTransitionCreated:a}=i;return a&&$s(t,()=>a({transition:s,from:e,to:A})),r})}function YhA(t){return new Promise(e=>{Vo({read:()=>setTimeout(e)},{injector:t})})}var GM=new BA(""),k6=(()=>{class t{currentNavigation=null;currentTransition=null;lastSuccessfulNavigation=null;events=new HA;transitionAbortSubject=new HA;configLoader=m(b6);environmentInjector=m(Br);destroyRef=m(Fd);urlSerializer=m(LI);rootContexts=m(xI);location=m(Qc);inputBindingEnabled=m(au,{optional:!0})!==null;titleStrategy=m(LM);options=m(FI,{optional:!0})||{};paramsInheritanceStrategy=this.options.paramsInheritanceStrategy||"emptyOnly";urlHandlingStrategy=m(M6);createViewTransition=m(NM,{optional:!0});navigationErrorHandler=m(GM,{optional:!0});navigationId=0;get hasRequestedNavigation(){return this.navigationId!==0}transitions;afterPreactivation=()=>ve(void 0);rootComponentType=null;destroyed=!1;constructor(){let A=n=>this.events.next(new d6(n)),i=n=>this.events.next(new B6(n));this.configLoader.onLoadEndListener=i,this.configLoader.onLoadStartListener=A,this.destroyRef.onDestroy(()=>{this.destroyed=!0})}complete(){this.transitions?.complete()}handleNavigationRequest(A){let i=++this.navigationId;this.transitions?.next(Ne(nA({},A),{extractedUrl:this.urlHandlingStrategy.extract(A.rawUrl),targetSnapshot:null,targetRouterState:null,guards:{canActivateChecks:[],canDeactivateChecks:[]},guardsResult:null,id:i}))}setupNavigations(A){return this.transitions=new li(null),this.transitions.pipe(pt(i=>i!==null),no(i=>{let n=!1,o=!1;return ve(i).pipe(no(r=>{if(this.navigationId>i.id)return this.cancelNavigationTransition(i,"",oa.SupersededByNewNavigation),Ar;this.currentTransition=i,this.currentNavigation={id:r.id,initialUrl:r.rawUrl,extractedUrl:r.extractedUrl,targetBrowserUrl:typeof r.extras.browserUrl=="string"?this.urlSerializer.parse(r.extras.browserUrl):r.extras.browserUrl,trigger:r.source,extras:r.extras,previousNavigation:this.lastSuccessfulNavigation?Ne(nA({},this.lastSuccessfulNavigation),{previousNavigation:null}):null};let s=!A.navigated||this.isUpdatingInternalState()||this.isUpdatedBrowserUrl(),a=r.extras.onSameUrlNavigation??A.onSameUrlNavigation;if(!s&&a!=="reload"){let c="";return this.events.next(new ig(r.id,this.urlSerializer.serialize(r.rawUrl),c,$d.IgnoredSameUrlNavigation)),r.resolve(!1),Ar}if(this.urlHandlingStrategy.shouldProcessUrl(r.rawUrl))return ve(r).pipe(no(c=>(this.events.next(new k2(c.id,this.urlSerializer.serialize(c.extractedUrl),c.source,c.restoredState)),c.id!==this.navigationId?Ar:Promise.resolve(c))),xhA(this.environmentInjector,this.configLoader,this.rootComponentType,A.config,this.urlSerializer,this.paramsInheritanceStrategy),oo(c=>{i.targetSnapshot=c.targetSnapshot,i.urlAfterRedirects=c.urlAfterRedirects,this.currentNavigation=Ne(nA({},this.currentNavigation),{finalUrl:c.urlAfterRedirects});let l=new $Q(c.id,this.urlSerializer.serialize(c.extractedUrl),this.urlSerializer.serialize(c.urlAfterRedirects),c.targetSnapshot);this.events.next(l)}));if(s&&this.urlHandlingStrategy.shouldProcessUrl(r.currentRawUrl)){let{id:c,extractedUrl:l,source:I,restoredState:C,extras:d}=r,B=new k2(c,this.urlSerializer.serialize(l),I,C);this.events.next(B);let E=YH(this.rootComponentType).snapshot;return this.currentTransition=i=Ne(nA({},r),{targetSnapshot:E,urlAfterRedirects:l,extras:Ne(nA({},d),{skipLocationChange:!1,replaceUrl:!1})}),this.currentNavigation.finalUrl=l,ve(i)}else{let c="";return this.events.next(new ig(r.id,this.urlSerializer.serialize(r.extractedUrl),c,$d.IgnoredByUrlHandlingStrategy)),r.resolve(!1),Ar}}),oo(r=>{let s=new l6(r.id,this.urlSerializer.serialize(r.extractedUrl),this.urlSerializer.serialize(r.urlAfterRedirects),r.targetSnapshot);this.events.next(s)}),Je(r=>(this.currentTransition=i=Ne(nA({},r),{guards:$EA(r.targetSnapshot,r.currentSnapshot,this.rootContexts)}),i)),lhA(this.environmentInjector,r=>this.events.next(r)),oo(r=>{if(i.guardsResult=r.guardsResult,r.guardsResult&&typeof r.guardsResult!="boolean")throw w6(this.urlSerializer,r.guardsResult);let s=new g6(r.id,this.urlSerializer.serialize(r.extractedUrl),this.urlSerializer.serialize(r.urlAfterRedirects),r.targetSnapshot,!!r.guardsResult);this.events.next(s)}),pt(r=>r.guardsResult?!0:(this.cancelNavigationTransition(r,"",oa.GuardRejected),!1)),dM(r=>{if(r.guards.canActivateChecks.length!==0)return ve(r).pipe(oo(s=>{let a=new I6(s.id,this.urlSerializer.serialize(s.extractedUrl),this.urlSerializer.serialize(s.urlAfterRedirects),s.targetSnapshot);this.events.next(a)}),no(s=>{let a=!1;return ve(s).pipe(FhA(this.paramsInheritanceStrategy,this.environmentInjector),oo({next:()=>a=!0,complete:()=>{a||this.cancelNavigationTransition(s,"",oa.NoDataFromResolver)}}))}),oo(s=>{let a=new C6(s.id,this.urlSerializer.serialize(s.extractedUrl),this.urlSerializer.serialize(s.urlAfterRedirects),s.targetSnapshot);this.events.next(a)}))}),dM(r=>{let s=a=>{let c=[];a.routeConfig?.loadComponent&&!a.routeConfig._loadedComponent&&c.push(this.configLoader.loadComponent(a.routeConfig).pipe(oo(l=>{a.component=l}),Je(()=>{})));for(let l of a.children)c.push(...s(l));return c};return Ls(s(r.targetSnapshot.root)).pipe(g2(null),Pn(1))}),dM(()=>this.afterPreactivation()),no(()=>{let{currentSnapshot:r,targetSnapshot:s}=i,a=this.createViewTransition?.(this.environmentInjector,r.root,s.root);return a?On(a).pipe(Je(()=>i)):ve(i)}),Je(r=>{let s=qEA(A.routeReuseStrategy,r.targetSnapshot,r.currentRouterState);return this.currentTransition=i=Ne(nA({},r),{targetRouterState:s}),this.currentNavigation.targetRouterState=s,i}),oo(()=>{this.events.next(new Au)}),XEA(this.rootContexts,A.routeReuseStrategy,r=>this.events.next(r),this.inputBindingEnabled),Pn(1),oo({next:r=>{n=!0,this.lastSuccessfulNavigation=this.currentNavigation,this.events.next(new Za(r.id,this.urlSerializer.serialize(r.extractedUrl),this.urlSerializer.serialize(r.urlAfterRedirects))),this.titleStrategy?.updateTitle(r.targetRouterState.snapshot),r.resolve(!0)},complete:()=>{n=!0}}),wt(this.transitionAbortSubject.pipe(oo(r=>{throw r}))),Tl(()=>{!n&&!o&&this.cancelNavigationTransition(i,"",oa.SupersededByNewNavigation),this.currentTransition?.id===i.id&&(this.currentNavigation=null,this.currentTransition=null)}),dr(r=>{if(this.destroyed)return i.resolve(!1),Ar;if(o=!0,PH(r))this.events.next(new eg(i.id,this.urlSerializer.serialize(i.extractedUrl),r.message,r.cancellationCode)),WEA(r)?this.events.next(new tB(r.url,r.navigationBehaviorOptions)):i.resolve(!1);else{let s=new AB(i.id,this.urlSerializer.serialize(i.extractedUrl),r,i.targetSnapshot??void 0);try{let a=$s(this.environmentInjector,()=>this.navigationErrorHandler?.(s));if(a instanceof iB){let{message:c,cancellationCode:l}=w6(this.urlSerializer,a);this.events.next(new eg(i.id,this.urlSerializer.serialize(i.extractedUrl),c,l)),this.events.next(new tB(a.redirectTo,a.navigationBehaviorOptions))}else throw this.events.next(s),r}catch(a){this.options.resolveNavigationPromiseOnError?i.resolve(!1):i.reject(a)}}return Ar}))}))}cancelNavigationTransition(A,i,n){let o=new eg(A.id,this.urlSerializer.serialize(A.extractedUrl),i,n);this.events.next(o),A.resolve(!1)}isUpdatingInternalState(){return this.currentTransition?.extractedUrl.toString()!==this.currentTransition?.currentUrlTree.toString()}isUpdatedBrowserUrl(){let A=this.urlHandlingStrategy.extract(this.urlSerializer.parse(this.location.path(!0))),i=this.currentNavigation?.targetBrowserUrl??this.currentNavigation?.extractedUrl;return A.toString()!==i?.toString()&&!this.currentNavigation?.extras.skipLocationChange}static \u0275fac=function(i){return new(i||t)};static \u0275prov=SA({token:t,factory:t.\u0275fac,providedIn:"root"})}return t})();function JhA(t){return t!==s6}var tO=(()=>{class t{static \u0275fac=function(i){return new(i||t)};static \u0275prov=SA({token:t,factory:()=>m(ThA),providedIn:"root"})}return t})(),y6=class{shouldDetach(e){return!1}store(e,A){}shouldAttach(e){return!1}retrieve(e){return null}shouldReuseRoute(e,A){return e.routeConfig===A.routeConfig}},ThA=(()=>{class t extends y6{static \u0275fac=(()=>{let A;return function(n){return(A||(A=bi(t)))(n||t)}})();static \u0275prov=SA({token:t,factory:t.\u0275fac,providedIn:"root"})}return t})(),iO=(()=>{class t{urlSerializer=m(LI);options=m(FI,{optional:!0})||{};canceledNavigationResolution=this.options.canceledNavigationResolution||"replace";location=m(Qc);urlHandlingStrategy=m(M6);urlUpdateStrategy=this.options.urlUpdateStrategy||"deferred";currentUrlTree=new tg;getCurrentUrlTree(){return this.currentUrlTree}rawUrlTree=this.currentUrlTree;getRawUrlTree(){return this.rawUrlTree}createBrowserPath({finalUrl:A,initialUrl:i,targetBrowserUrl:n}){let o=A!==void 0?this.urlHandlingStrategy.merge(A,i):i,r=n??o;return r instanceof tg?this.urlSerializer.serialize(r):r}commitTransition({targetRouterState:A,finalUrl:i,initialUrl:n}){i&&A?(this.currentUrlTree=i,this.rawUrlTree=this.urlHandlingStrategy.merge(i,n),this.routerState=A):this.rawUrlTree=n}routerState=YH(null);getRouterState(){return this.routerState}stateMemento=this.createStateMemento();updateStateMemento(){this.stateMemento=this.createStateMemento()}createStateMemento(){return{rawUrlTree:this.rawUrlTree,currentUrlTree:this.currentUrlTree,routerState:this.routerState}}resetInternalState({finalUrl:A}){this.routerState=this.stateMemento.routerState,this.currentUrlTree=this.stateMemento.currentUrlTree,this.rawUrlTree=this.urlHandlingStrategy.merge(this.currentUrlTree,A??this.rawUrlTree)}static \u0275fac=function(i){return new(i||t)};static \u0275prov=SA({token:t,factory:()=>m(zhA),providedIn:"root"})}return t})(),zhA=(()=>{class t extends iO{currentPageId=0;lastSuccessfulId=-1;restoredState(){return this.location.getState()}get browserPageId(){return this.canceledNavigationResolution!=="computed"?this.currentPageId:this.restoredState()?.\u0275routerPageId??this.currentPageId}registerNonRouterCurrentEntryChangeListener(A){return this.location.subscribe(i=>{i.type==="popstate"&&setTimeout(()=>{A(i.url,i.state,"popstate")})})}handleRouterEvent(A,i){A instanceof k2?this.updateStateMemento():A instanceof ig?this.commitTransition(i):A instanceof $Q?this.urlUpdateStrategy==="eager"&&(i.extras.skipLocationChange||this.setBrowserUrl(this.createBrowserPath(i),i)):A instanceof Au?(this.commitTransition(i),this.urlUpdateStrategy==="deferred"&&!i.extras.skipLocationChange&&this.setBrowserUrl(this.createBrowserPath(i),i)):A instanceof eg&&(A.code===oa.GuardRejected||A.code===oa.NoDataFromResolver)?this.restoreHistory(i):A instanceof AB?this.restoreHistory(i,!0):A instanceof Za&&(this.lastSuccessfulId=A.id,this.currentPageId=this.browserPageId)}setBrowserUrl(A,{extras:i,id:n}){let{replaceUrl:o,state:r}=i;if(this.location.isCurrentPathEqualTo(A)||o){let s=this.browserPageId,a=nA(nA({},r),this.generateNgRouterState(n,s));this.location.replaceState(A,"",a)}else{let s=nA(nA({},r),this.generateNgRouterState(n,this.browserPageId+1));this.location.go(A,"",s)}}restoreHistory(A,i=!1){if(this.canceledNavigationResolution==="computed"){let n=this.browserPageId,o=this.currentPageId-n;o!==0?this.location.historyGo(o):this.getCurrentUrlTree()===A.finalUrl&&o===0&&(this.resetInternalState(A),this.resetUrlToCurrentUrlTree())}else this.canceledNavigationResolution==="replace"&&(i&&this.resetInternalState(A),this.resetUrlToCurrentUrlTree())}resetUrlToCurrentUrlTree(){this.location.replaceState(this.urlSerializer.serialize(this.getRawUrlTree()),"",this.generateNgRouterState(this.lastSuccessfulId,this.currentPageId))}generateNgRouterState(A,i){return this.canceledNavigationResolution==="computed"?{navigationId:A,\u0275routerPageId:i}:{navigationId:A}}static \u0275fac=(()=>{let A;return function(n){return(A||(A=bi(t)))(n||t)}})();static \u0275prov=SA({token:t,factory:t.\u0275fac,providedIn:"root"})}return t})();function S6(t,e){t.events.pipe(pt(A=>A instanceof Za||A instanceof eg||A instanceof AB||A instanceof ig),Je(A=>A instanceof Za||A instanceof ig?0:(A instanceof eg?A.code===oa.Redirect||A.code===oa.SupersededByNewNavigation:!1)?2:1),pt(A=>A!==2),Pn(1)).subscribe(()=>{e()})}var HhA={paths:"exact",fragment:"ignored",matrixParams:"ignored",queryParams:"exact"},OhA={paths:"subset",fragment:"ignored",matrixParams:"ignored",queryParams:"subset"},ng=(()=>{class t{get currentUrlTree(){return this.stateManager.getCurrentUrlTree()}get rawUrlTree(){return this.stateManager.getRawUrlTree()}disposed=!1;nonRouterCurrentEntryChangeSubscription;console=m(ub);stateManager=m(iO);options=m(FI,{optional:!0})||{};pendingTasks=m(r0);urlUpdateStrategy=this.options.urlUpdateStrategy||"deferred";navigationTransitions=m(k6);urlSerializer=m(LI);location=m(Qc);urlHandlingStrategy=m(M6);_events=new HA;get events(){return this._events}get routerState(){return this.stateManager.getRouterState()}navigated=!1;routeReuseStrategy=m(tO);onSameUrlNavigation=this.options.onSameUrlNavigation||"ignore";config=m(rB,{optional:!0})?.flat()??[];componentInputBindingEnabled=!!m(au,{optional:!0});constructor(){this.resetConfig(this.config),this.navigationTransitions.setupNavigations(this).subscribe({error:A=>{this.console.warn(A)}}),this.subscribeToNavigationEvents()}eventsSubscription=new _t;subscribeToNavigationEvents(){let A=this.navigationTransitions.events.subscribe(i=>{try{let n=this.navigationTransitions.currentTransition,o=this.navigationTransitions.currentNavigation;if(n!==null&&o!==null){if(this.stateManager.handleRouterEvent(i,o),i instanceof eg&&i.code!==oa.Redirect&&i.code!==oa.SupersededByNewNavigation)this.navigated=!0;else if(i instanceof Za)this.navigated=!0;else if(i instanceof tB){let r=i.navigationBehaviorOptions,s=this.urlHandlingStrategy.merge(i.url,n.currentRawUrl),a=nA({browserUrl:n.extras.browserUrl,info:n.extras.info,skipLocationChange:n.extras.skipLocationChange,replaceUrl:n.extras.replaceUrl||this.urlUpdateStrategy==="eager"||JhA(n.source)},r);this.scheduleNavigation(s,s6,null,a,{resolve:n.resolve,reject:n.reject,promise:n.promise})}}jhA(i)&&this._events.next(i)}catch(n){this.navigationTransitions.transitionAbortSubject.next(n)}});this.eventsSubscription.add(A)}resetRootComponentType(A){this.routerState.root.component=A,this.navigationTransitions.rootComponentType=A}initialNavigation(){this.setUpLocationChangeListener(),this.navigationTransitions.hasRequestedNavigation||this.navigateToSyncWithBrowser(this.location.path(!0),s6,this.stateManager.restoredState())}setUpLocationChangeListener(){this.nonRouterCurrentEntryChangeSubscription??=this.stateManager.registerNonRouterCurrentEntryChangeListener((A,i,n)=>{this.navigateToSyncWithBrowser(A,n,i)})}navigateToSyncWithBrowser(A,i,n){let o={replaceUrl:!0},r=n?.navigationId?n:null;if(n){let a=nA({},n);delete a.navigationId,delete a.\u0275routerPageId,Object.keys(a).length!==0&&(o.state=a)}let s=this.parseUrl(A);this.scheduleNavigation(s,i,r,o)}get url(){return this.serializeUrl(this.currentUrlTree)}getCurrentNavigation(){return this.navigationTransitions.currentNavigation}get lastSuccessfulNavigation(){return this.navigationTransitions.lastSuccessfulNavigation}resetConfig(A){this.config=A.map(FM),this.navigated=!1}ngOnDestroy(){this.dispose()}dispose(){this._events.unsubscribe(),this.navigationTransitions.complete(),this.nonRouterCurrentEntryChangeSubscription&&(this.nonRouterCurrentEntryChangeSubscription.unsubscribe(),this.nonRouterCurrentEntryChangeSubscription=void 0),this.disposed=!0,this.eventsSubscription.unsubscribe()}createUrlTree(A,i={}){let{relativeTo:n,queryParams:o,fragment:r,queryParamsHandling:s,preserveFragment:a}=i,c=a?this.currentUrlTree.fragment:r,l=null;switch(s??this.options.defaultQueryParamsHandling){case"merge":l=nA(nA({},this.currentUrlTree.queryParams),o);break;case"preserve":l=this.currentUrlTree.queryParams;break;default:l=o||null}l!==null&&(l=this.removeEmptyProps(l));let I;try{let C=n?n.snapshot:this.routerState.snapshot.root;I=_H(C)}catch{(typeof A[0]!="string"||A[0][0]!=="/")&&(A=[]),I=this.currentUrlTree.root}return GH(I,A,l,c??null)}navigateByUrl(A,i={skipLocationChange:!1}){let n=Xd(A)?A:this.parseUrl(A),o=this.urlHandlingStrategy.merge(n,this.rawUrlTree);return this.scheduleNavigation(o,s6,null,i)}navigate(A,i={skipLocationChange:!1}){return PhA(A),this.navigateByUrl(this.createUrlTree(A,i),i)}serializeUrl(A){return this.urlSerializer.serialize(A)}parseUrl(A){try{return this.urlSerializer.parse(A)}catch{return this.urlSerializer.parse("/")}}isActive(A,i){let n;if(i===!0?n=nA({},HhA):i===!1?n=nA({},OhA):n=i,Xd(A))return hH(this.currentUrlTree,A,n);let o=this.parseUrl(A);return hH(this.currentUrlTree,o,n)}removeEmptyProps(A){return Object.entries(A).reduce((i,[n,o])=>(o!=null&&(i[n]=o),i),{})}scheduleNavigation(A,i,n,o,r){if(this.disposed)return Promise.resolve(!1);let s,a,c;r?(s=r.resolve,a=r.reject,c=r.promise):c=new Promise((I,C)=>{s=I,a=C});let l=this.pendingTasks.add();return S6(this,()=>{queueMicrotask(()=>this.pendingTasks.remove(l))}),this.navigationTransitions.handleNavigationRequest({source:i,restoredState:n,currentUrlTree:this.currentUrlTree,currentRawUrl:this.currentUrlTree,rawUrl:A,extras:o,resolve:s,reject:a,promise:c,currentSnapshot:this.routerState.snapshot,currentRouterState:this.routerState}),c.catch(I=>Promise.reject(I))}static \u0275fac=function(i){return new(i||t)};static \u0275prov=SA({token:t,factory:t.\u0275fac,providedIn:"root"})}return t})();function PhA(t){for(let e=0;e<t.length;e++)if(t[e]==null)throw new ZA(4008,!1)}function jhA(t){return!(t instanceof Au)&&!(t instanceof tB)}var lu=class{};var nO=(()=>{class t{router;injector;preloadingStrategy;loader;subscription;constructor(A,i,n,o){this.router=A,this.injector=i,this.preloadingStrategy=n,this.loader=o}setUpPreloading(){this.subscription=this.router.events.pipe(pt(A=>A instanceof Za),Jl(()=>this.preload())).subscribe(()=>{})}preload(){return this.processRoutes(this.injector,this.router.config)}ngOnDestroy(){this.subscription&&this.subscription.unsubscribe()}processRoutes(A,i){let n=[];for(let o of i){o.providers&&!o._injector&&(o._injector=hQ(o.providers,A,`Route: ${o.path}`));let r=o._injector??A,s=o._loadedInjector??r;(o.loadChildren&&!o._loadedRoutes&&o.canLoad===void 0||o.loadComponent&&!o._loadedComponent)&&n.push(this.preloadConfig(r,o)),(o.children||o._loadedRoutes)&&n.push(this.processRoutes(s,o.children??o._loadedRoutes))}return On(n).pipe(c2())}preloadConfig(A,i){return this.preloadingStrategy.preload(i,()=>{let n;i.loadChildren&&i.canLoad===void 0?n=this.loader.loadChildren(A,i):n=ve(null);let o=n.pipe(qo(r=>r===null?ve(void 0):(i._loadedRoutes=r.routes,i._loadedInjector=r.injector,this.processRoutes(r.injector??A,r.routes))));if(i.loadComponent&&!i._loadedComponent){let r=this.loader.loadComponent(i);return On([o,r]).pipe(c2())}else return o})}static \u0275fac=function(i){return new(i||t)(he(ng),he(Br),he(lu),he(b6))};static \u0275prov=SA({token:t,factory:t.\u0275fac,providedIn:"root"})}return t})(),oO=new BA(""),qhA=(()=>{class t{urlSerializer;transitions;viewportScroller;zone;options;routerEventsSubscription;scrollEventsSubscription;lastId=0;lastSource="imperative";restoredId=0;store={};constructor(A,i,n,o,r={}){this.urlSerializer=A,this.transitions=i,this.viewportScroller=n,this.zone=o,this.options=r,r.scrollPositionRestoration||="disabled",r.anchorScrolling||="disabled"}init(){this.options.scrollPositionRestoration!=="disabled"&&this.viewportScroller.setHistoryScrollRestoration("manual"),this.routerEventsSubscription=this.createScrollEvents(),this.scrollEventsSubscription=this.consumeScrollEvents()}createScrollEvents(){return this.transitions.events.subscribe(A=>{A instanceof k2?(this.store[this.lastId]=this.viewportScroller.getScrollPosition(),this.lastSource=A.navigationTrigger,this.restoredId=A.restoredState?A.restoredState.navigationId:0):A instanceof Za?(this.lastId=A.id,this.scheduleScrollEvent(A,this.urlSerializer.parse(A.urlAfterRedirects).fragment)):A instanceof ig&&A.code===$d.IgnoredSameUrlNavigation&&(this.lastSource=void 0,this.restoredId=0,this.scheduleScrollEvent(A,this.urlSerializer.parse(A.url).fragment))})}consumeScrollEvents(){return this.transitions.events.subscribe(A=>{A instanceof eB&&(A.position?this.options.scrollPositionRestoration==="top"?this.viewportScroller.scrollToPosition([0,0]):this.options.scrollPositionRestoration==="enabled"&&this.viewportScroller.scrollToPosition(A.position):A.anchor&&this.options.anchorScrolling==="enabled"?this.viewportScroller.scrollToAnchor(A.anchor):this.options.scrollPositionRestoration!=="disabled"&&this.viewportScroller.scrollToPosition([0,0]))})}scheduleScrollEvent(A,i){this.zone.runOutsideAngular(()=>{setTimeout(()=>{this.zone.run(()=>{this.transitions.events.next(new eB(A,this.lastSource==="popstate"?this.store[this.restoredId]:null,i))})},0)})}ngOnDestroy(){this.routerEventsSubscription?.unsubscribe(),this.scrollEventsSubscription?.unsubscribe()}static \u0275fac=function(i){cT()};static \u0275prov=SA({token:t,factory:t.\u0275fac})}return t})();function VhA(t){return t.routerState.root}function gu(t,e){return{\u0275kind:t,\u0275providers:e}}function ZhA(){let t=m(Dt);return e=>{let A=t.get(Ua);if(e!==A.components[0])return;let i=t.get(ng),n=t.get(rO);t.get(KM)===1&&i.initialNavigation(),t.get(cO,null,_i.Optional)?.setUpPreloading(),t.get(oO,null,_i.Optional)?.init(),i.resetRootComponentType(A.componentTypes[0]),n.closed||(n.next(),n.complete(),n.unsubscribe())}}var rO=new BA("",{factory:()=>new HA}),KM=new BA("",{providedIn:"root",factory:()=>1});function sO(){let t=[{provide:KM,useValue:0},wb(()=>{let e=m(Dt);return e.get(Lb,Promise.resolve()).then(()=>new Promise(i=>{let n=e.get(ng),o=e.get(rO);S6(n,()=>{i(!0)}),e.get(k6).afterPreactivation=()=>(i(!0),o.closed?ve(void 0):o),n.initialNavigation()}))})];return gu(2,t)}function aO(){let t=[wb(()=>{m(ng).setUpLocationChangeListener()}),{provide:KM,useValue:2}];return gu(3,t)}var cO=new BA("");function lO(t){return gu(0,[{provide:cO,useExisting:nO},{provide:lu,useExisting:t}])}function gO(){return gu(8,[RM,{provide:au,useExisting:RM}])}function IO(t){s0("NgRouterViewTransitions");let e=[{provide:NM,useValue:eO},{provide:_M,useValue:nA({skipNextTransition:!!t?.skipInitialTransition},t)}];return gu(9,e)}var CO=[Qc,{provide:LI,useClass:M2},ng,xI,{provide:ra,useFactory:VhA,deps:[ng]},b6,[]],R6=(()=>{class t{constructor(){}static forRoot(A,i){return{ngModule:t,providers:[CO,[],{provide:rB,multi:!0,useValue:A},[],i?.errorHandler?{provide:GM,useValue:i.errorHandler}:[],{provide:FI,useValue:i||{}},i?.useHash?XhA():$hA(),WhA(),i?.preloadingStrategy?lO(i.preloadingStrategy).\u0275providers:[],i?.initialNavigation?AQA(i):[],i?.bindToComponentInputs?gO().\u0275providers:[],i?.enableViewTransitions?IO().\u0275providers:[],eQA()]}}static forChild(A){return{ngModule:t,providers:[{provide:rB,multi:!0,useValue:A}]}}static \u0275fac=function(i){return new(i||t)};static \u0275mod=ge({type:t});static \u0275inj=le({})}return t})();function WhA(){return{provide:oO,useFactory:()=>{let t=m(Ez),e=m(de),A=m(FI),i=m(k6),n=m(LI);return A.scrollOffset&&t.setOffset(A.scrollOffset),new qhA(n,i,t,e,A)}}}function XhA(){return{provide:l0,useClass:_b}}function $hA(){return{provide:l0,useClass:vp}}function AQA(t){return[t.initialNavigation==="disabled"?aO().\u0275providers:[],t.initialNavigation==="enabledBlocking"?sO().\u0275providers:[]]}var UM=new BA("");function eQA(){return[{provide:UM,useFactory:ZhA},{provide:Db,multi:!0,useExisting:UM}]}var JM;try{JM=typeof Intl<"u"&&Intl.v8BreakIterator}catch{JM=!1}var Zt=(()=>{class t{_platformId=m(hc);isBrowser=this._platformId?$l(this._platformId):typeof document=="object"&&!!document;EDGE=this.isBrowser&&/(edge)/i.test(navigator.userAgent);TRIDENT=this.isBrowser&&/(msie|trident)/i.test(navigator.userAgent);BLINK=this.isBrowser&&!!(window.chrome||JM)&&typeof CSS<"u"&&!this.EDGE&&!this.TRIDENT;WEBKIT=this.isBrowser&&/AppleWebKit/i.test(navigator.userAgent)&&!this.BLINK&&!this.EDGE&&!this.TRIDENT;IOS=this.isBrowser&&/iPad|iPhone|iPod/.test(navigator.userAgent)&&!("MSStream"in window);FIREFOX=this.isBrowser&&/(firefox|minefield)/i.test(navigator.userAgent);ANDROID=this.isBrowser&&/android/i.test(navigator.userAgent)&&!this.TRIDENT;SAFARI=this.isBrowser&&/safari/i.test(navigator.userAgent)&&this.WEBKIT;constructor(){}static \u0275fac=function(i){return new(i||t)};static \u0275prov=SA({token:t,factory:t.\u0275fac,providedIn:"root"})}return t})();var sB,dO=["color","button","checkbox","date","datetime-local","email","file","hidden","image","month","number","password","radio","range","reset","search","submit","tel","text","time","url","week"];function TM(){if(sB)return sB;if(typeof document!="object"||!document)return sB=new Set(dO),sB;let t=document.createElement("input");return sB=new Set(dO.filter(e=>(t.setAttribute("type",e),t.type===e))),sB}var Iu;function nQA(){if(Iu==null&&typeof window<"u")try{window.addEventListener("test",null,Object.defineProperty({},"passive",{get:()=>Iu=!0}))}finally{Iu=Iu||!1}return Iu}function og(t){return nQA()?t:!!t.capture}var ol=function(t){return t[t.NORMAL=0]="NORMAL",t[t.NEGATED=1]="NEGATED",t[t.INVERTED=2]="INVERTED",t}(ol||{}),L6,NI;function x6(){if(NI==null){if(typeof document!="object"||!document||typeof Element!="function"||!Element)return NI=!1,NI;if("scrollBehavior"in document.documentElement.style)NI=!0;else{let t=Element.prototype.scrollTo;t?NI=!/\{\s*\[native code\]\s*\}/.test(t.toString()):NI=!1}}return NI}function aB(){if(typeof document!="object"||!document)return ol.NORMAL;if(L6==null){let t=document.createElement("div"),e=t.style;t.dir="rtl",e.width="1px",e.overflow="auto",e.visibility="hidden",e.pointerEvents="none",e.position="absolute";let A=document.createElement("div"),i=A.style;i.width="2px",i.height="1px",t.appendChild(A),document.body.appendChild(t),L6=ol.NORMAL,t.scrollLeft===0&&(t.scrollLeft=1,L6=t.scrollLeft===0?ol.NEGATED:ol.INVERTED),t.remove()}return L6}var YM;function oQA(){if(YM==null){let t=typeof document<"u"?document.head:null;YM=!!(t&&(t.createShadowRoot||t.attachShadow))}return YM}function BO(t){if(oQA()){let e=t.getRootNode?t.getRootNode():null;if(typeof ShadowRoot<"u"&&ShadowRoot&&e instanceof ShadowRoot)return e}return null}function cB(){let t=typeof document<"u"&&document?document.activeElement:null;for(;t&&t.shadowRoot;){let e=t.shadowRoot.activeElement;if(e===t)break;t=e}return t}function Wa(t){return t.composedPath?t.composedPath()[0]:t.target}function zM(){return typeof __karma__<"u"&&!!__karma__||typeof jasmine<"u"&&!!jasmine||typeof jest<"u"&&!!jest||typeof Mocha<"u"&&!!Mocha}function HM(t,e,A,i,n){let o=parseInt(kb.major),r=parseInt(kb.minor);return o>19||o===19&&r>0||o===0&&r===0?t.listen(e,A,i,n):(e.addEventListener(A,i,n),()=>{e.removeEventListener(A,i,n)})}var F6=new WeakMap,Ln=(()=>{class t{_appRef;_injector=m(Dt);_environmentInjector=m(Br);load(A){let i=this._appRef=this._appRef||this._injector.get(Ua),n=F6.get(i);n||(n={loaders:new Set,refs:[]},F6.set(i,n),i.onDestroy(()=>{F6.get(i)?.refs.forEach(o=>o.destroy()),F6.delete(i)})),n.loaders.has(A)||(n.loaders.add(A),n.refs.push(wp(A,{environmentInjector:this._environmentInjector})))}static \u0275fac=function(i){return new(i||t)};static \u0275prov=SA({token:t,factory:t.\u0275fac,providedIn:"root"})}return t})(),Cu=(()=>{class t{static \u0275fac=function(i){return new(i||t)};static \u0275cmp=YA({type:t,selectors:[["ng-component"]],exportAs:["cdkVisuallyHidden"],decls:0,vars:0,template:function(i,n){},styles:[".cdk-visually-hidden{border:0;clip:rect(0 0 0 0);height:1px;margin:-1px;overflow:hidden;padding:0;position:absolute;width:1px;white-space:nowrap;outline:0;-webkit-appearance:none;-moz-appearance:none;left:0}[dir=rtl] .cdk-visually-hidden{left:auto;right:0}"],encapsulation:2,changeDetection:0})}return t})();function rr(t,...e){return e.length?e.some(A=>t[A]):t.altKey||t.shiftKey||t.ctrlKey||t.metaKey}function Yo(t){return t!=null&&`${t}`!="false"}function Ns(t,e=0){return OM(t)?Number(t):arguments.length===2?e:0}function OM(t){return!isNaN(parseFloat(t))&&!isNaN(Number(t))}function lB(t){return Array.isArray(t)?t:[t]}function sr(t){return t==null?"":typeof t=="string"?t:`${t}px`}function sa(t){return t instanceof te?t.nativeElement:t}function rQA(t){if(t.type==="characterData"&&t.target instanceof Comment)return!0;if(t.type==="childList"){for(let e=0;e<t.addedNodes.length;e++)if(!(t.addedNodes[e]instanceof Comment))return!1;for(let e=0;e<t.removedNodes.length;e++)if(!(t.removedNodes[e]instanceof Comment))return!1;return!0}return!1}var EO=(()=>{class t{create(A){return typeof MutationObserver>"u"?null:new MutationObserver(A)}static \u0275fac=function(i){return new(i||t)};static \u0275prov=SA({token:t,factory:t.\u0275fac,providedIn:"root"})}return t})(),hO=(()=>{class t{_mutationObserverFactory=m(EO);_observedElements=new Map;_ngZone=m(de);constructor(){}ngOnDestroy(){this._observedElements.forEach((A,i)=>this._cleanupObserver(i))}observe(A){let i=sa(A);return new Ze(n=>{let r=this._observeElement(i).pipe(Je(s=>s.filter(a=>!rQA(a))),pt(s=>!!s.length)).subscribe(s=>{this._ngZone.run(()=>{n.next(s)})});return()=>{r.unsubscribe(),this._unobserveElement(i)}})}_observeElement(A){return this._ngZone.runOutsideAngular(()=>{if(this._observedElements.has(A))this._observedElements.get(A).count++;else{let i=new HA,n=this._mutationObserverFactory.create(o=>i.next(o));n&&n.observe(A,{characterData:!0,childList:!0,subtree:!0}),this._observedElements.set(A,{observer:n,stream:i,count:1})}return this._observedElements.get(A).stream})}_unobserveElement(A){this._observedElements.has(A)&&(this._observedElements.get(A).count--,this._observedElements.get(A).count||this._cleanupObserver(A))}_cleanupObserver(A){if(this._observedElements.has(A)){let{observer:i,stream:n}=this._observedElements.get(A);i&&i.disconnect(),n.complete(),this._observedElements.delete(A)}}static \u0275fac=function(i){return new(i||t)};static \u0275prov=SA({token:t,factory:t.\u0275fac,providedIn:"root"})}return t})(),N6=(()=>{class t{_contentObserver=m(hO);_elementRef=m(te);event=new XA;get disabled(){return this._disabled}set disabled(A){this._disabled=A,this._disabled?this._unsubscribe():this._subscribe()}_disabled=!1;get debounce(){return this._debounce}set debounce(A){this._debounce=Ns(A),this._subscribe()}_debounce;_currentSubscription=null;constructor(){}ngAfterContentInit(){!this._currentSubscription&&!this.disabled&&this._subscribe()}ngOnDestroy(){this._unsubscribe()}_subscribe(){this._unsubscribe();let A=this._contentObserver.observe(this._elementRef);this._currentSubscription=(this.debounce?A.pipe(Vc(this.debounce)):A).subscribe(this.event)}_unsubscribe(){this._currentSubscription?.unsubscribe()}static \u0275fac=function(i){return new(i||t)};static \u0275dir=OA({type:t,selectors:[["","cdkObserveContent",""]],inputs:{disabled:[2,"cdkObserveContentDisabled","disabled",ae],debounce:"debounce"},outputs:{event:"cdkObserveContent"},exportAs:["cdkObserveContent"]})}return t})(),gB=(()=>{class t{static \u0275fac=function(i){return new(i||t)};static \u0275mod=ge({type:t});static \u0275inj=le({providers:[EO]})}return t})();var QO=new Set,_I,sQA=(()=>{class t{_platform=m(Zt);_nonce=m(gQ,{optional:!0});_matchMedia;constructor(){this._matchMedia=this._platform.isBrowser&&window.matchMedia?window.matchMedia.bind(window):cQA}matchMedia(A){return(this._platform.WEBKIT||this._platform.BLINK)&&aQA(A,this._nonce),this._matchMedia(A)}static \u0275fac=function(i){return new(i||t)};static \u0275prov=SA({token:t,factory:t.\u0275fac,providedIn:"root"})}return t})();function aQA(t,e){if(!QO.has(t))try{_I||(_I=document.createElement("style"),e&&_I.setAttribute("nonce",e),_I.setAttribute("type","text/css"),document.head.appendChild(_I)),_I.sheet&&(_I.sheet.insertRule(`@media ${t} {body{ }}`,0),QO.add(t))}catch(A){console.error(A)}}function cQA(t){return{matches:t==="all"||t==="",media:t,addListener:()=>{},removeListener:()=>{}}}var _6=(()=>{class t{_mediaMatcher=m(sQA);_zone=m(de);_queries=new Map;_destroySubject=new HA;constructor(){}ngOnDestroy(){this._destroySubject.next(),this._destroySubject.complete()}isMatched(A){return uO(lB(A)).some(n=>this._registerQuery(n).mql.matches)}observe(A){let n=uO(lB(A)).map(r=>this._registerQuery(r).observable),o=Ls(n);return o=l2(o.pipe(Pn(1)),o.pipe(eI(1),Vc(0))),o.pipe(Je(r=>{let s={matches:!1,breakpoints:{}};return r.forEach(({matches:a,query:c})=>{s.matches=s.matches||a,s.breakpoints[c]=a}),s}))}_registerQuery(A){if(this._queries.has(A))return this._queries.get(A);let i=this._mediaMatcher.matchMedia(A),o={observable:new Ze(r=>{let s=a=>this._zone.run(()=>r.next(a));return i.addListener(s),()=>{i.removeListener(s)}}).pipe(Qo(i),Je(({matches:r})=>({query:A,matches:r})),wt(this._destroySubject)),mql:i};return this._queries.set(A,o),o}static \u0275fac=function(i){return new(i||t)};static \u0275prov=SA({token:t,factory:t.\u0275fac,providedIn:"root"})}return t})();function uO(t){return t.map(e=>e.split(",")).reduce((e,A)=>e.concat(A)).map(e=>e.trim())}var fO={XSmall:"(max-width: 599.98px)",Small:"(min-width: 600px) and (max-width: 959.98px)",Medium:"(min-width: 960px) and (max-width: 1279.98px)",Large:"(min-width: 1280px) and (max-width: 1919.98px)",XLarge:"(min-width: 1920px)",Handset:"(max-width: 599.98px) and (orientation: portrait), (max-width: 959.98px) and (orientation: landscape)",Tablet:"(min-width: 600px) and (max-width: 839.98px) and (orientation: portrait), (min-width: 960px) and (max-width: 1279.98px) and (orientation: landscape)",Web:"(min-width: 840px) and (orientation: portrait), (min-width: 1280px) and (orientation: landscape)",HandsetPortrait:"(max-width: 599.98px) and (orientation: portrait)",TabletPortrait:"(min-width: 600px) and (max-width: 839.98px) and (orientation: portrait)",WebPortrait:"(min-width: 840px) and (orientation: portrait)",HandsetLandscape:"(max-width: 959.98px) and (orientation: landscape)",TabletLandscape:"(min-width: 960px) and (max-width: 1279.98px) and (orientation: landscape)",WebLandscape:"(min-width: 1280px) and (orientation: landscape)"};var yO=" ";function $M(t,e,A){let i=Y6(t,e);A=A.trim(),!i.some(n=>n.trim()===A)&&(i.push(A),t.setAttribute(e,i.join(yO)))}function O6(t,e,A){let i=Y6(t,e);A=A.trim();let n=i.filter(o=>o!==A);n.length?t.setAttribute(e,n.join(yO)):t.removeAttribute(e)}function Y6(t,e){return t.getAttribute(e)?.match(/\S+/g)??[]}var vO="cdk-describedby-message",G6="cdk-describedby-host",VM=0,bO=(()=>{class t{_platform=m(Zt);_document=m(tt);_messageRegistry=new Map;_messagesContainer=null;_id=`${VM++}`;constructor(){m(Ln).load(Cu),this._id=m(fI)+"-"+VM++}describe(A,i,n){if(!this._canBeDescribed(A,i))return;let o=PM(i,n);typeof i!="string"?(mO(i,this._id),this._messageRegistry.set(o,{messageElement:i,referenceCount:0})):this._messageRegistry.has(o)||this._createMessageElement(i,n),this._isElementDescribedByMessage(A,o)||this._addMessageReference(A,o)}removeDescription(A,i,n){if(!i||!this._isElementNode(A))return;let o=PM(i,n);if(this._isElementDescribedByMessage(A,o)&&this._removeMessageReference(A,o),typeof i=="string"){let r=this._messageRegistry.get(o);r&&r.referenceCount===0&&this._deleteMessageElement(o)}this._messagesContainer?.childNodes.length===0&&(this._messagesContainer.remove(),this._messagesContainer=null)}ngOnDestroy(){let A=this._document.querySelectorAll(`[${G6}="${this._id}"]`);for(let i=0;i<A.length;i++)this._removeCdkDescribedByReferenceIds(A[i]),A[i].removeAttribute(G6);this._messagesContainer?.remove(),this._messagesContainer=null,this._messageRegistry.clear()}_createMessageElement(A,i){let n=this._document.createElement("div");mO(n,this._id),n.textContent=A,i&&n.setAttribute("role",i),this._createMessagesContainer(),this._messagesContainer.appendChild(n),this._messageRegistry.set(PM(A,i),{messageElement:n,referenceCount:0})}_deleteMessageElement(A){this._messageRegistry.get(A)?.messageElement?.remove(),this._messageRegistry.delete(A)}_createMessagesContainer(){if(this._messagesContainer)return;let A="cdk-describedby-message-container",i=this._document.querySelectorAll(`.${A}[platform="server"]`);for(let o=0;o<i.length;o++)i[o].remove();let n=this._document.createElement("div");n.style.visibility="hidden",n.classList.add(A),n.classList.add("cdk-visually-hidden"),this._platform.isBrowser||n.setAttribute("platform","server"),this._document.body.appendChild(n),this._messagesContainer=n}_removeCdkDescribedByReferenceIds(A){let i=Y6(A,"aria-describedby").filter(n=>n.indexOf(vO)!=0);A.setAttribute("aria-describedby",i.join(" "))}_addMessageReference(A,i){let n=this._messageRegistry.get(i);$M(A,"aria-describedby",n.messageElement.id),A.setAttribute(G6,this._id),n.referenceCount++}_removeMessageReference(A,i){let n=this._messageRegistry.get(i);n.referenceCount--,O6(A,"aria-describedby",n.messageElement.id),A.removeAttribute(G6)}_isElementDescribedByMessage(A,i){let n=Y6(A,"aria-describedby"),o=this._messageRegistry.get(i),r=o&&o.messageElement.id;return!!r&&n.indexOf(r)!=-1}_canBeDescribed(A,i){if(!this._isElementNode(A))return!1;if(i&&typeof i=="object")return!0;let n=i==null?"":`${i}`.trim(),o=A.getAttribute("aria-label");return n?!o||o.trim()!==n:!1}_isElementNode(A){return A.nodeType===this._document.ELEMENT_NODE}static \u0275fac=function(i){return new(i||t)};static \u0275prov=SA({token:t,factory:t.\u0275fac,providedIn:"root"})}return t})();function PM(t,e){return typeof t=="string"?`${e||""}/${t}`:t}function mO(t,e){t.id||(t.id=`${vO}-${e}-${VM++}`)}var wQA=200,ZM=class{_letterKeyStream=new HA;_items=[];_selectedItemIndex=-1;_pressedLetters=[];_skipPredicateFn;_selectedItem=new HA;selectedItem=this._selectedItem;constructor(e,A){let i=typeof A?.debounceInterval=="number"?A.debounceInterval:wQA;A?.skipPredicate&&(this._skipPredicateFn=A.skipPredicate),this.setItems(e),this._setupKeyHandler(i)}destroy(){this._pressedLetters=[],this._letterKeyStream.complete(),this._selectedItem.complete()}setCurrentSelectedItemIndex(e){this._selectedItemIndex=e}setItems(e){this._items=e}handleKey(e){let A=e.keyCode;e.key&&e.key.length===1?this._letterKeyStream.next(e.key.toLocaleUpperCase()):(A>=65&&A<=90||A>=48&&A<=57)&&this._letterKeyStream.next(String.fromCharCode(A))}isTyping(){return this._pressedLetters.length>0}reset(){this._pressedLetters=[]}_setupKeyHandler(e){this._letterKeyStream.pipe(oo(A=>this._pressedLetters.push(A)),Vc(e),pt(()=>this._pressedLetters.length>0),Je(()=>this._pressedLetters.join("").toLocaleUpperCase())).subscribe(A=>{for(let i=1;i<this._items.length+1;i++){let n=(this._selectedItemIndex+i)%this._items.length,o=this._items[n];if(!this._skipPredicateFn?.(o)&&o.getLabel?.().toLocaleUpperCase().trim().indexOf(A)===0){this._selectedItem.next(o);break}}this._pressedLetters=[]})}},J6=class{_items;_activeItemIndex=-1;_activeItem=Ko(null);_wrap=!1;_typeaheadSubscription=_t.EMPTY;_itemChangesSubscription;_vertical=!0;_horizontal;_allowedModifierKeys=[];_homeAndEnd=!1;_pageUpAndDown={enabled:!1,delta:10};_effectRef;_typeahead;_skipPredicateFn=e=>e.disabled;constructor(e,A){this._items=e,e instanceof Ec?this._itemChangesSubscription=e.changes.subscribe(i=>this._itemsChanged(i.toArray())):h2(e)&&(this._effectRef=mQ(()=>this._itemsChanged(e()),{injector:A}))}tabOut=new HA;change=new HA;skipPredicate(e){return this._skipPredicateFn=e,this}withWrap(e=!0){return this._wrap=e,this}withVerticalOrientation(e=!0){return this._vertical=e,this}withHorizontalOrientation(e){return this._horizontal=e,this}withAllowedModifierKeys(e){return this._allowedModifierKeys=e,this}withTypeAhead(e=200){this._typeaheadSubscription.unsubscribe();let A=this._getItemsArray();return this._typeahead=new ZM(A,{debounceInterval:typeof e=="number"?e:void 0,skipPredicate:i=>this._skipPredicateFn(i)}),this._typeaheadSubscription=this._typeahead.selectedItem.subscribe(i=>{this.setActiveItem(i)}),this}cancelTypeahead(){return this._typeahead?.reset(),this}withHomeAndEnd(e=!0){return this._homeAndEnd=e,this}withPageUpDown(e=!0,A=10){return this._pageUpAndDown={enabled:e,delta:A},this}setActiveItem(e){let A=this._activeItem();this.updateActiveItem(e),this._activeItem()!==A&&this.change.next(this._activeItemIndex)}onKeydown(e){let A=e.keyCode,n=["altKey","ctrlKey","metaKey","shiftKey"].every(o=>!e[o]||this._allowedModifierKeys.indexOf(o)>-1);switch(A){case 9:this.tabOut.next();return;case 40:if(this._vertical&&n){this.setNextItemActive();break}else return;case 38:if(this._vertical&&n){this.setPreviousItemActive();break}else return;case 39:if(this._horizontal&&n){this._horizontal==="rtl"?this.setPreviousItemActive():this.setNextItemActive();break}else return;case 37:if(this._horizontal&&n){this._horizontal==="rtl"?this.setNextItemActive():this.setPreviousItemActive();break}else return;case 36:if(this._homeAndEnd&&n){this.setFirstItemActive();break}else return;case 35:if(this._homeAndEnd&&n){this.setLastItemActive();break}else return;case 33:if(this._pageUpAndDown.enabled&&n){let o=this._activeItemIndex-this._pageUpAndDown.delta;this._setActiveItemByIndex(o>0?o:0,1);break}else return;case 34:if(this._pageUpAndDown.enabled&&n){let o=this._activeItemIndex+this._pageUpAndDown.delta,r=this._getItemsArray().length;this._setActiveItemByIndex(o<r?o:r-1,-1);break}else return;default:(n||rr(e,"shiftKey"))&&this._typeahead?.handleKey(e);return}this._typeahead?.reset(),e.preventDefault()}get activeItemIndex(){return this._activeItemIndex}get activeItem(){return this._activeItem()}isTyping(){return!!this._typeahead&&this._typeahead.isTyping()}setFirstItemActive(){this._setActiveItemByIndex(0,1)}setLastItemActive(){this._setActiveItemByIndex(this._getItemsArray().length-1,-1)}setNextItemActive(){this._activeItemIndex<0?this.setFirstItemActive():this._setActiveItemByDelta(1)}setPreviousItemActive(){this._activeItemIndex<0&&this._wrap?this.setLastItemActive():this._setActiveItemByDelta(-1)}updateActiveItem(e){let A=this._getItemsArray(),i=typeof e=="number"?e:A.indexOf(e),n=A[i];this._activeItem.set(n??null),this._activeItemIndex=i,this._typeahead?.setCurrentSelectedItemIndex(i)}destroy(){this._typeaheadSubscription.unsubscribe(),this._itemChangesSubscription?.unsubscribe(),this._effectRef?.destroy(),this._typeahead?.destroy(),this.tabOut.complete(),this.change.complete()}_setActiveItemByDelta(e){this._wrap?this._setActiveInWrapMode(e):this._setActiveInDefaultMode(e)}_setActiveInWrapMode(e){let A=this._getItemsArray();for(let i=1;i<=A.length;i++){let n=(this._activeItemIndex+e*i+A.length)%A.length,o=A[n];if(!this._skipPredicateFn(o)){this.setActiveItem(n);return}}}_setActiveInDefaultMode(e){this._setActiveItemByIndex(this._activeItemIndex+e,e)}_setActiveItemByIndex(e,A){let i=this._getItemsArray();if(i[e]){for(;this._skipPredicateFn(i[e]);)if(e+=A,!i[e])return;this.setActiveItem(e)}}_getItemsArray(){return h2(this._items)?this._items():this._items instanceof Ec?this._items.toArray():this._items}_itemsChanged(e){this._typeahead?.setItems(e);let A=this._activeItem();if(A){let i=e.indexOf(A);i>-1&&i!==this._activeItemIndex&&(this._activeItemIndex=i,this._typeahead?.setCurrentSelectedItemIndex(i))}}},T6=class extends J6{setActiveItem(e){this.activeItem&&this.activeItem.setInactiveStyles(),super.setActiveItem(e),this.activeItem&&this.activeItem.setActiveStyles()}},du=class extends J6{_origin="program";setFocusOrigin(e){return this._origin=e,this}setActiveItem(e){super.setActiveItem(e),this.activeItem&&this.activeItem.focus(this._origin)}};var hu=(()=>{class t{_platform=m(Zt);constructor(){}isDisabled(A){return A.hasAttribute("disabled")}isVisible(A){return yQA(A)&&getComputedStyle(A).visibility==="visible"}isTabbable(A){if(!this._platform.isBrowser)return!1;let i=DQA(xQA(A));if(i&&(pO(i)===-1||!this.isVisible(i)))return!1;let n=A.nodeName.toLowerCase(),o=pO(A);return A.hasAttribute("contenteditable")?o!==-1:n==="iframe"||n==="object"||this._platform.WEBKIT&&this._platform.IOS&&!RQA(A)?!1:n==="audio"?A.hasAttribute("controls")?o!==-1:!1:n==="video"?o===-1?!1:o!==null?!0:this._platform.FIREFOX||A.hasAttribute("controls"):A.tabIndex>=0}isFocusable(A,i){return LQA(A)&&!this.isDisabled(A)&&(i?.ignoreVisibility||this.isVisible(A))}static \u0275fac=function(i){return new(i||t)};static \u0275prov=SA({token:t,factory:t.\u0275fac,providedIn:"root"})}return t})();function DQA(t){try{return t.frameElement}catch{return null}}function yQA(t){return!!(t.offsetWidth||t.offsetHeight||typeof t.getClientRects=="function"&&t.getClientRects().length)}function vQA(t){let e=t.nodeName.toLowerCase();return e==="input"||e==="select"||e==="button"||e==="textarea"}function bQA(t){return kQA(t)&&t.type=="hidden"}function MQA(t){return SQA(t)&&t.hasAttribute("href")}function kQA(t){return t.nodeName.toLowerCase()=="input"}function SQA(t){return t.nodeName.toLowerCase()=="a"}function MO(t){if(!t.hasAttribute("tabindex")||t.tabIndex===void 0)return!1;let e=t.getAttribute("tabindex");return!!(e&&!isNaN(parseInt(e,10)))}function pO(t){if(!MO(t))return null;let e=parseInt(t.getAttribute("tabindex")||"",10);return isNaN(e)?-1:e}function RQA(t){let e=t.nodeName.toLowerCase(),A=e==="input"&&t.type;return A==="text"||A==="password"||e==="select"||e==="textarea"}function LQA(t){return bQA(t)?!1:vQA(t)||MQA(t)||t.hasAttribute("contenteditable")||MO(t)}function xQA(t){return t.ownerDocument&&t.ownerDocument.defaultView||window}var WM=class{_element;_checker;_ngZone;_document;_injector;_startAnchor;_endAnchor;_hasAttached=!1;startAnchorListener=()=>this.focusLastTabbableElement();endAnchorListener=()=>this.focusFirstTabbableElement();get enabled(){return this._enabled}set enabled(e){this._enabled=e,this._startAnchor&&this._endAnchor&&(this._toggleAnchorTabIndex(e,this._startAnchor),this._toggleAnchorTabIndex(e,this._endAnchor))}_enabled=!0;constructor(e,A,i,n,o=!1,r){this._element=e,this._checker=A,this._ngZone=i,this._document=n,this._injector=r,o||this.attachAnchors()}destroy(){let e=this._startAnchor,A=this._endAnchor;e&&(e.removeEventListener("focus",this.startAnchorListener),e.remove()),A&&(A.removeEventListener("focus",this.endAnchorListener),A.remove()),this._startAnchor=this._endAnchor=null,this._hasAttached=!1}attachAnchors(){return this._hasAttached?!0:(this._ngZone.runOutsideAngular(()=>{this._startAnchor||(this._startAnchor=this._createAnchor(),this._startAnchor.addEventListener("focus",this.startAnchorListener)),this._endAnchor||(this._endAnchor=this._createAnchor(),this._endAnchor.addEventListener("focus",this.endAnchorListener))}),this._element.parentNode&&(this._element.parentNode.insertBefore(this._startAnchor,this._element),this._element.parentNode.insertBefore(this._endAnchor,this._element.nextSibling),this._hasAttached=!0),this._hasAttached)}focusInitialElementWhenReady(e){return new Promise(A=>{this._executeOnStable(()=>A(this.focusInitialElement(e)))})}focusFirstTabbableElementWhenReady(e){return new Promise(A=>{this._executeOnStable(()=>A(this.focusFirstTabbableElement(e)))})}focusLastTabbableElementWhenReady(e){return new Promise(A=>{this._executeOnStable(()=>A(this.focusLastTabbableElement(e)))})}_getRegionBoundary(e){let A=this._element.querySelectorAll(`[cdk-focus-region-${e}], [cdkFocusRegion${e}], [cdk-focus-${e}]`);return e=="start"?A.length?A[0]:this._getFirstTabbableElement(this._element):A.length?A[A.length-1]:this._getLastTabbableElement(this._element)}focusInitialElement(e){let A=this._element.querySelector("[cdk-focus-initial], [cdkFocusInitial]");if(A){if(!this._checker.isFocusable(A)){let i=this._getFirstTabbableElement(A);return i?.focus(e),!!i}return A.focus(e),!0}return this.focusFirstTabbableElement(e)}focusFirstTabbableElement(e){let A=this._getRegionBoundary("start");return A&&A.focus(e),!!A}focusLastTabbableElement(e){let A=this._getRegionBoundary("end");return A&&A.focus(e),!!A}hasAttached(){return this._hasAttached}_getFirstTabbableElement(e){if(this._checker.isFocusable(e)&&this._checker.isTabbable(e))return e;let A=e.children;for(let i=0;i<A.length;i++){let n=A[i].nodeType===this._document.ELEMENT_NODE?this._getFirstTabbableElement(A[i]):null;if(n)return n}return null}_getLastTabbableElement(e){if(this._checker.isFocusable(e)&&this._checker.isTabbable(e))return e;let A=e.children;for(let i=A.length-1;i>=0;i--){let n=A[i].nodeType===this._document.ELEMENT_NODE?this._getLastTabbableElement(A[i]):null;if(n)return n}return null}_createAnchor(){let e=this._document.createElement("div");return this._toggleAnchorTabIndex(this._enabled,e),e.classList.add("cdk-visually-hidden"),e.classList.add("cdk-focus-trap-anchor"),e.setAttribute("aria-hidden","true"),e}_toggleAnchorTabIndex(e,A){e?A.setAttribute("tabindex","0"):A.removeAttribute("tabindex")}toggleAnchors(e){this._startAnchor&&this._endAnchor&&(this._toggleAnchorTabIndex(e,this._startAnchor),this._toggleAnchorTabIndex(e,this._endAnchor))}_executeOnStable(e){this._injector?Vo(e,{injector:this._injector}):setTimeout(e)}},P6=(()=>{class t{_checker=m(hu);_ngZone=m(de);_document=m(tt);_injector=m(Dt);constructor(){m(Ln).load(Cu)}create(A,i=!1){return new WM(A,this._checker,this._ngZone,this._document,i,this._injector)}static \u0275fac=function(i){return new(i||t)};static \u0275prov=SA({token:t,factory:t.\u0275fac,providedIn:"root"})}return t})();function Ak(t){return t.buttons===0||t.detail===0}function ek(t){let e=t.touches&&t.touches[0]||t.changedTouches&&t.changedTouches[0];return!!e&&e.identifier===-1&&(e.radiusX==null||e.radiusX===1)&&(e.radiusY==null||e.radiusY===1)}var FQA=new BA("cdk-input-modality-detector-options"),NQA={ignoreKeys:[18,17,224,91,16]},kO=650,IB=og({passive:!0,capture:!0}),_QA=(()=>{class t{_platform=m(Zt);modalityDetected;modalityChanged;get mostRecentModality(){return this._modality.value}_mostRecentTarget=null;_modality=new li(null);_options;_lastTouchMs=0;_onKeydown=A=>{this._options?.ignoreKeys?.some(i=>i===A.keyCode)||(this._modality.next("keyboard"),this._mostRecentTarget=Wa(A))};_onMousedown=A=>{Date.now()-this._lastTouchMs<kO||(this._modality.next(Ak(A)?"keyboard":"mouse"),this._mostRecentTarget=Wa(A))};_onTouchstart=A=>{if(ek(A)){this._modality.next("keyboard");return}this._lastTouchMs=Date.now(),this._modality.next("touch"),this._mostRecentTarget=Wa(A)};constructor(){let A=m(de),i=m(tt),n=m(FQA,{optional:!0});this._options=nA(nA({},NQA),n),this.modalityDetected=this._modality.pipe(eI(1)),this.modalityChanged=this.modalityDetected.pipe(Zc()),this._platform.isBrowser&&A.runOutsideAngular(()=>{i.addEventListener("keydown",this._onKeydown,IB),i.addEventListener("mousedown",this._onMousedown,IB),i.addEventListener("touchstart",this._onTouchstart,IB)})}ngOnDestroy(){this._modality.complete(),this._platform.isBrowser&&(document.removeEventListener("keydown",this._onKeydown,IB),document.removeEventListener("mousedown",this._onMousedown,IB),document.removeEventListener("touchstart",this._onTouchstart,IB))}static \u0275fac=function(i){return new(i||t)};static \u0275prov=SA({token:t,factory:t.\u0275fac,providedIn:"root"})}return t})(),GQA=new BA("liveAnnouncerElement",{providedIn:"root",factory:UQA});function UQA(){return null}var KQA=new BA("LIVE_ANNOUNCER_DEFAULT_OPTIONS"),YQA=0,j6=(()=>{class t{_ngZone=m(de);_defaultOptions=m(KQA,{optional:!0});_liveElement;_document=m(tt);_previousTimeout;_currentPromise;_currentResolve;constructor(){let A=m(GQA,{optional:!0});this._liveElement=A||this._createLiveElement()}announce(A,...i){let n=this._defaultOptions,o,r;return i.length===1&&typeof i[0]=="number"?r=i[0]:[o,r]=i,this.clear(),clearTimeout(this._previousTimeout),o||(o=n&&n.politeness?n.politeness:"polite"),r==null&&n&&(r=n.duration),this._liveElement.setAttribute("aria-live",o),this._liveElement.id&&this._exposeAnnouncerToModals(this._liveElement.id),this._ngZone.runOutsideAngular(()=>(this._currentPromise||(this._currentPromise=new Promise(s=>this._currentResolve=s)),clearTimeout(this._previousTimeout),this._previousTimeout=setTimeout(()=>{this._liveElement.textContent=A,typeof r=="number"&&(this._previousTimeout=setTimeout(()=>this.clear(),r)),this._currentResolve?.(),this._currentPromise=this._currentResolve=void 0},100),this._currentPromise))}clear(){this._liveElement&&(this._liveElement.textContent="")}ngOnDestroy(){clearTimeout(this._previousTimeout),this._liveElement?.remove(),this._liveElement=null,this._currentResolve?.(),this._currentPromise=this._currentResolve=void 0}_createLiveElement(){let A="cdk-live-announcer-element",i=this._document.getElementsByClassName(A),n=this._document.createElement("div");for(let o=0;o<i.length;o++)i[o].remove();return n.classList.add(A),n.classList.add("cdk-visually-hidden"),n.setAttribute("aria-atomic","true"),n.setAttribute("aria-live","polite"),n.id=`cdk-live-announcer-${YQA++}`,this._document.body.appendChild(n),n}_exposeAnnouncerToModals(A){let i=this._document.querySelectorAll('body > .cdk-overlay-container [aria-modal="true"]');for(let n=0;n<i.length;n++){let o=i[n],r=o.getAttribute("aria-owns");r?r.indexOf(A)===-1&&o.setAttribute("aria-owns",r+" "+A):o.setAttribute("aria-owns",A)}}static \u0275fac=function(i){return new(i||t)};static \u0275prov=SA({token:t,factory:t.\u0275fac,providedIn:"root"})}return t})();var K6=function(t){return t[t.IMMEDIATE=0]="IMMEDIATE",t[t.EVENTUAL=1]="EVENTUAL",t}(K6||{}),JQA=new BA("cdk-focus-monitor-default-options"),U6=og({passive:!0,capture:!0}),Jr=(()=>{class t{_ngZone=m(de);_platform=m(Zt);_inputModalityDetector=m(_QA);_origin=null;_lastFocusOrigin;_windowFocused=!1;_windowFocusTimeoutId;_originTimeoutId;_originFromTouchInteraction=!1;_elementInfo=new Map;_monitoredElementCount=0;_rootNodeFocusListenerCount=new Map;_detectionMode;_windowFocusListener=()=>{this._windowFocused=!0,this._windowFocusTimeoutId=setTimeout(()=>this._windowFocused=!1)};_document=m(tt,{optional:!0});_stopInputModalityDetector=new HA;constructor(){let A=m(JQA,{optional:!0});this._detectionMode=A?.detectionMode||K6.IMMEDIATE}_rootNodeFocusAndBlurListener=A=>{let i=Wa(A);for(let n=i;n;n=n.parentElement)A.type==="focus"?this._onFocus(A,n):this._onBlur(A,n)};monitor(A,i=!1){let n=sa(A);if(!this._platform.isBrowser||n.nodeType!==1)return ve();let o=BO(n)||this._getDocument(),r=this._elementInfo.get(n);if(r)return i&&(r.checkChildren=!0),r.subject;let s={checkChildren:i,subject:new HA,rootNode:o};return this._elementInfo.set(n,s),this._registerGlobalListeners(s),s.subject}stopMonitoring(A){let i=sa(A),n=this._elementInfo.get(i);n&&(n.subject.complete(),this._setClasses(i),this._elementInfo.delete(i),this._removeGlobalListeners(n))}focusVia(A,i,n){let o=sa(A),r=this._getDocument().activeElement;o===r?this._getClosestElementsInfo(o).forEach(([s,a])=>this._originChanged(s,i,a)):(this._setOrigin(i),typeof o.focus=="function"&&o.focus(n))}ngOnDestroy(){this._elementInfo.forEach((A,i)=>this.stopMonitoring(i))}_getDocument(){return this._document||document}_getWindow(){return this._getDocument().defaultView||window}_getFocusOrigin(A){return this._origin?this._originFromTouchInteraction?this._shouldBeAttributedToTouch(A)?"touch":"program":this._origin:this._windowFocused&&this._lastFocusOrigin?this._lastFocusOrigin:A&&this._isLastInteractionFromInputLabel(A)?"mouse":"program"}_shouldBeAttributedToTouch(A){return this._detectionMode===K6.EVENTUAL||!!A?.contains(this._inputModalityDetector._mostRecentTarget)}_setClasses(A,i){A.classList.toggle("cdk-focused",!!i),A.classList.toggle("cdk-touch-focused",i==="touch"),A.classList.toggle("cdk-keyboard-focused",i==="keyboard"),A.classList.toggle("cdk-mouse-focused",i==="mouse"),A.classList.toggle("cdk-program-focused",i==="program")}_setOrigin(A,i=!1){this._ngZone.runOutsideAngular(()=>{if(this._origin=A,this._originFromTouchInteraction=A==="touch"&&i,this._detectionMode===K6.IMMEDIATE){clearTimeout(this._originTimeoutId);let n=this._originFromTouchInteraction?kO:1;this._originTimeoutId=setTimeout(()=>this._origin=null,n)}})}_onFocus(A,i){let n=this._elementInfo.get(i),o=Wa(A);!n||!n.checkChildren&&i!==o||this._originChanged(i,this._getFocusOrigin(o),n)}_onBlur(A,i){let n=this._elementInfo.get(i);!n||n.checkChildren&&A.relatedTarget instanceof Node&&i.contains(A.relatedTarget)||(this._setClasses(i),this._emitOrigin(n,null))}_emitOrigin(A,i){A.subject.observers.length&&this._ngZone.run(()=>A.subject.next(i))}_registerGlobalListeners(A){if(!this._platform.isBrowser)return;let i=A.rootNode,n=this._rootNodeFocusListenerCount.get(i)||0;n||this._ngZone.runOutsideAngular(()=>{i.addEventListener("focus",this._rootNodeFocusAndBlurListener,U6),i.addEventListener("blur",this._rootNodeFocusAndBlurListener,U6)}),this._rootNodeFocusListenerCount.set(i,n+1),++this._monitoredElementCount===1&&(this._ngZone.runOutsideAngular(()=>{this._getWindow().addEventListener("focus",this._windowFocusListener)}),this._inputModalityDetector.modalityDetected.pipe(wt(this._stopInputModalityDetector)).subscribe(o=>{this._setOrigin(o,!0)}))}_removeGlobalListeners(A){let i=A.rootNode;if(this._rootNodeFocusListenerCount.has(i)){let n=this._rootNodeFocusListenerCount.get(i);n>1?this._rootNodeFocusListenerCount.set(i,n-1):(i.removeEventListener("focus",this._rootNodeFocusAndBlurListener,U6),i.removeEventListener("blur",this._rootNodeFocusAndBlurListener,U6),this._rootNodeFocusListenerCount.delete(i))}--this._monitoredElementCount||(this._getWindow().removeEventListener("focus",this._windowFocusListener),this._stopInputModalityDetector.next(),clearTimeout(this._windowFocusTimeoutId),clearTimeout(this._originTimeoutId))}_originChanged(A,i,n){this._setClasses(A,i),this._emitOrigin(n,i),this._lastFocusOrigin=i}_getClosestElementsInfo(A){let i=[];return this._elementInfo.forEach((n,o)=>{(o===A||n.checkChildren&&o.contains(A))&&i.push([o,n])}),i}_isLastInteractionFromInputLabel(A){let{_mostRecentTarget:i,mostRecentModality:n}=this._inputModalityDetector;if(n!=="mouse"||!i||i===A||A.nodeName!=="INPUT"&&A.nodeName!=="TEXTAREA"||A.disabled)return!1;let o=A.labels;if(o){for(let r=0;r<o.length;r++)if(o[r].contains(i))return!0}return!1}static \u0275fac=function(i){return new(i||t)};static \u0275prov=SA({token:t,factory:t.\u0275fac,providedIn:"root"})}return t})(),SO=(()=>{class t{_elementRef=m(te);_focusMonitor=m(Jr);_monitorSubscription;_focusOrigin=null;cdkFocusChange=new XA;constructor(){}get focusOrigin(){return this._focusOrigin}ngAfterViewInit(){let A=this._elementRef.nativeElement;this._monitorSubscription=this._focusMonitor.monitor(A,A.nodeType===1&&A.hasAttribute("cdkMonitorSubtreeFocus")).subscribe(i=>{this._focusOrigin=i,this.cdkFocusChange.emit(i)})}ngOnDestroy(){this._focusMonitor.stopMonitoring(this._elementRef),this._monitorSubscription&&this._monitorSubscription.unsubscribe()}static \u0275fac=function(i){return new(i||t)};static \u0275dir=OA({type:t,selectors:[["","cdkMonitorElementFocus",""],["","cdkMonitorSubtreeFocus",""]],outputs:{cdkFocusChange:"cdkFocusChange"},exportAs:["cdkMonitorFocus"]})}return t})(),GI=function(t){return t[t.NONE=0]="NONE",t[t.BLACK_ON_WHITE=1]="BLACK_ON_WHITE",t[t.WHITE_ON_BLACK=2]="WHITE_ON_BLACK",t}(GI||{}),wO="cdk-high-contrast-black-on-white",DO="cdk-high-contrast-white-on-black",jM="cdk-high-contrast-active",tk=(()=>{class t{_platform=m(Zt);_hasCheckedHighContrastMode;_document=m(tt);_breakpointSubscription;constructor(){this._breakpointSubscription=m(_6).observe("(forced-colors: active)").subscribe(()=>{this._hasCheckedHighContrastMode&&(this._hasCheckedHighContrastMode=!1,this._applyBodyHighContrastModeCssClasses())})}getHighContrastMode(){if(!this._platform.isBrowser)return GI.NONE;let A=this._document.createElement("div");A.style.backgroundColor="rgb(1,2,3)",A.style.position="absolute",this._document.body.appendChild(A);let i=this._document.defaultView||window,n=i&&i.getComputedStyle?i.getComputedStyle(A):null,o=(n&&n.backgroundColor||"").replace(/ /g,"");switch(A.remove(),o){case"rgb(0,0,0)":case"rgb(45,50,54)":case"rgb(32,32,32)":return GI.WHITE_ON_BLACK;case"rgb(255,255,255)":case"rgb(255,250,239)":return GI.BLACK_ON_WHITE}return GI.NONE}ngOnDestroy(){this._breakpointSubscription.unsubscribe()}_applyBodyHighContrastModeCssClasses(){if(!this._hasCheckedHighContrastMode&&this._platform.isBrowser&&this._document.body){let A=this._document.body.classList;A.remove(jM,wO,DO),this._hasCheckedHighContrastMode=!0;let i=this.getHighContrastMode();i===GI.BLACK_ON_WHITE?A.add(jM,wO):i===GI.WHITE_ON_BLACK&&A.add(jM,DO)}}static \u0275fac=function(i){return new(i||t)};static \u0275prov=SA({token:t,factory:t.\u0275fac,providedIn:"root"})}return t})(),q6=(()=>{class t{constructor(){m(tk)._applyBodyHighContrastModeCssClasses()}static \u0275fac=function(i){return new(i||t)};static \u0275mod=ge({type:t});static \u0275inj=le({imports:[gB]})}return t})(),qM={},$i=(()=>{class t{_appId=m(fI);getId(A){return this._appId!=="ng"&&(A+=this._appId),qM.hasOwnProperty(A)||(qM[A]=0),`${A}${qM[A]++}`}static \u0275fac=function(i){return new(i||t)};static \u0275prov=SA({token:t,factory:t.\u0275fac,providedIn:"root"})}return t})();var TQA=new BA("cdk-dir-doc",{providedIn:"root",factory:zQA});function zQA(){return m(tt)}var HQA=/^(ar|ckb|dv|he|iw|fa|nqo|ps|sd|ug|ur|yi|.*[-_](Adlm|Arab|Hebr|Nkoo|Rohg|Thaa))(?!.*[-_](Latn|Cyrl)($|-|_))($|-|_)/i;function OQA(t){let e=t?.toLowerCase()||"";return e==="auto"&&typeof navigator<"u"&&navigator?.language?HQA.test(navigator.language)?"rtl":"ltr":e==="rtl"?"rtl":"ltr"}var bo=(()=>{class t{value="ltr";change=new XA;constructor(){let A=m(TQA,{optional:!0});if(A){let i=A.body?A.body.dir:null,n=A.documentElement?A.documentElement.dir:null;this.value=OQA(i||n||"ltr")}}ngOnDestroy(){this.change.complete()}static \u0275fac=function(i){return new(i||t)};static \u0275prov=SA({token:t,factory:t.\u0275fac,providedIn:"root"})}return t})();var R2=(()=>{class t{static \u0275fac=function(i){return new(i||t)};static \u0275mod=ge({type:t});static \u0275inj=le({})}return t})();var PQA=["text"],jQA=[[["mat-icon"]],"*"],qQA=["mat-icon","*"];function VQA(t,e){if(t&1&&UA(0,"mat-pseudo-checkbox",1),t&2){let A=P();vA("disabled",A.disabled)("state",A.selected?"checked":"unchecked")}}function ZQA(t,e){if(t&1&&UA(0,"mat-pseudo-checkbox",3),t&2){let A=P();vA("disabled",A.disabled)}}function WQA(t,e){if(t&1&&(S(0,"span",4),tA(1),R()),t&2){let A=P();_(),ot("(",A.group.label,")")}}var XQA=["mat-internal-form-field",""],$QA=["*"];var Ve=(()=>{class t{constructor(){m(tk)._applyBodyHighContrastModeCssClasses()}static \u0275fac=function(i){return new(i||t)};static \u0275mod=ge({type:t});static \u0275inj=le({imports:[R2,R2]})}return t})(),UI=class{_defaultMatcher;ngControl;_parentFormGroup;_parentForm;_stateChanges;errorState=!1;matcher;constructor(e,A,i,n,o){this._defaultMatcher=e,this.ngControl=A,this._parentFormGroup=i,this._parentForm=n,this._stateChanges=o}updateErrorState(){let e=this.errorState,A=this._parentFormGroup||this._parentForm,i=this.matcher||this._defaultMatcher,n=this.ngControl?this.ngControl.control:null,o=i?.isErrorState(n,A)??!1;o!==e&&(this.errorState=o,this._stateChanges.next())}};var dB=(()=>{class t{isErrorState(A,i){return!!(A&&A.invalid&&(A.touched||i&&i.submitted))}static \u0275fac=function(i){return new(i||t)};static \u0275prov=SA({token:t,factory:t.\u0275fac,providedIn:"root"})}return t})(),Qr=(()=>{class t{static \u0275fac=function(i){return new(i||t)};static \u0275cmp=YA({type:t,selectors:[["structural-styles"]],decls:0,vars:0,template:function(i,n){},styles:['.mat-focus-indicator{position:relative}.mat-focus-indicator::before{top:0;left:0;right:0;bottom:0;position:absolute;box-sizing:border-box;pointer-events:none;display:var(--mat-focus-indicator-display, none);border-width:var(--mat-focus-indicator-border-width, 3px);border-style:var(--mat-focus-indicator-border-style, solid);border-color:var(--mat-focus-indicator-border-color, transparent);border-radius:var(--mat-focus-indicator-border-radius, 4px)}.mat-focus-indicator:focus::before{content:""}@media(forced-colors: active){html{--mat-focus-indicator-display: block}}'],encapsulation:2,changeDetection:0})}return t})();var _s=function(t){return t[t.FADING_IN=0]="FADING_IN",t[t.VISIBLE=1]="VISIBLE",t[t.FADING_OUT=2]="FADING_OUT",t[t.HIDDEN=3]="HIDDEN",t}(_s||{}),ok=class{_renderer;element;config;_animationForciblyDisabledThroughCss;state=_s.HIDDEN;constructor(e,A,i,n=!1){this._renderer=e,this.element=A,this.config=i,this._animationForciblyDisabledThroughCss=n}fadeOut(){this._renderer.fadeOutRipple(this)}},RO=og({passive:!0,capture:!0}),rk=class{_events=new Map;addHandler(e,A,i,n){let o=this._events.get(A);if(o){let r=o.get(i);r?r.add(n):o.set(i,new Set([n]))}else this._events.set(A,new Map([[i,new Set([n])]])),e.runOutsideAngular(()=>{document.addEventListener(A,this._delegateEventHandler,RO)})}removeHandler(e,A,i){let n=this._events.get(e);if(!n)return;let o=n.get(A);o&&(o.delete(i),o.size===0&&n.delete(A),n.size===0&&(this._events.delete(e),document.removeEventListener(e,this._delegateEventHandler,RO)))}_delegateEventHandler=e=>{let A=Wa(e);A&&this._events.get(e.type)?.forEach((i,n)=>{(n===A||n.contains(A))&&i.forEach(o=>o.handleEvent(e))})}},Z6={enterDuration:225,exitDuration:150},AuA=800,LO=og({passive:!0,capture:!0}),xO=["mousedown","touchstart"],FO=["mouseup","mouseleave","touchend","touchcancel"],euA=(()=>{class t{static \u0275fac=function(i){return new(i||t)};static \u0275cmp=YA({type:t,selectors:[["ng-component"]],hostAttrs:["mat-ripple-style-loader",""],decls:0,vars:0,template:function(i,n){},styles:[".mat-ripple{overflow:hidden;position:relative}.mat-ripple:not(:empty){transform:translateZ(0)}.mat-ripple.mat-ripple-unbounded{overflow:visible}.mat-ripple-element{position:absolute;border-radius:50%;pointer-events:none;transition:opacity,transform 0ms cubic-bezier(0, 0, 0.2, 1);transform:scale3d(0, 0, 0);background-color:var(--mat-ripple-color, color-mix(in srgb, var(--mat-sys-on-surface) 10%, transparent))}@media(forced-colors: active){.mat-ripple-element{display:none}}.cdk-drag-preview .mat-ripple-element,.cdk-drag-placeholder .mat-ripple-element{display:none}"],encapsulation:2,changeDetection:0})}return t})(),CB=class t{_target;_ngZone;_platform;_containerElement;_triggerElement;_isPointerDown=!1;_activeRipples=new Map;_mostRecentTransientRipple;_lastTouchStartEvent;_pointerUpEventsRegistered=!1;_containerRect;static _eventManager=new rk;constructor(e,A,i,n,o){this._target=e,this._ngZone=A,this._platform=n,n.isBrowser&&(this._containerElement=sa(i)),o&&o.get(Ln).load(euA)}fadeInRipple(e,A,i={}){let n=this._containerRect=this._containerRect||this._containerElement.getBoundingClientRect(),o=nA(nA({},Z6),i.animation);i.centered&&(e=n.left+n.width/2,A=n.top+n.height/2);let r=i.radius||tuA(e,A,n),s=e-n.left,a=A-n.top,c=o.enterDuration,l=document.createElement("div");l.classList.add("mat-ripple-element"),l.style.left=`${s-r}px`,l.style.top=`${a-r}px`,l.style.height=`${r*2}px`,l.style.width=`${r*2}px`,i.color!=null&&(l.style.backgroundColor=i.color),l.style.transitionDuration=`${c}ms`,this._containerElement.appendChild(l);let I=window.getComputedStyle(l),C=I.transitionProperty,d=I.transitionDuration,B=C==="none"||d==="0s"||d==="0s, 0s"||n.width===0&&n.height===0,E=new ok(this,l,i,B);l.style.transform="scale3d(1, 1, 1)",E.state=_s.FADING_IN,i.persistent||(this._mostRecentTransientRipple=E);let Q=null;return!B&&(c||o.exitDuration)&&this._ngZone.runOutsideAngular(()=>{let u=()=>{Q&&(Q.fallbackTimer=null),clearTimeout(L),this._finishRippleTransition(E)},v=()=>this._destroyRipple(E),L=setTimeout(v,c+100);l.addEventListener("transitionend",u),l.addEventListener("transitioncancel",v),Q={onTransitionEnd:u,onTransitionCancel:v,fallbackTimer:L}}),this._activeRipples.set(E,Q),(B||!c)&&this._finishRippleTransition(E),E}fadeOutRipple(e){if(e.state===_s.FADING_OUT||e.state===_s.HIDDEN)return;let A=e.element,i=nA(nA({},Z6),e.config.animation);A.style.transitionDuration=`${i.exitDuration}ms`,A.style.opacity="0",e.state=_s.FADING_OUT,(e._animationForciblyDisabledThroughCss||!i.exitDuration)&&this._finishRippleTransition(e)}fadeOutAll(){this._getActiveRipples().forEach(e=>e.fadeOut())}fadeOutAllNonPersistent(){this._getActiveRipples().forEach(e=>{e.config.persistent||e.fadeOut()})}setupTriggerEvents(e){let A=sa(e);!this._platform.isBrowser||!A||A===this._triggerElement||(this._removeTriggerEvents(),this._triggerElement=A,xO.forEach(i=>{t._eventManager.addHandler(this._ngZone,i,A,this)}))}handleEvent(e){e.type==="mousedown"?this._onMousedown(e):e.type==="touchstart"?this._onTouchStart(e):this._onPointerUp(),this._pointerUpEventsRegistered||(this._ngZone.runOutsideAngular(()=>{FO.forEach(A=>{this._triggerElement.addEventListener(A,this,LO)})}),this._pointerUpEventsRegistered=!0)}_finishRippleTransition(e){e.state===_s.FADING_IN?this._startFadeOutTransition(e):e.state===_s.FADING_OUT&&this._destroyRipple(e)}_startFadeOutTransition(e){let A=e===this._mostRecentTransientRipple,{persistent:i}=e.config;e.state=_s.VISIBLE,!i&&(!A||!this._isPointerDown)&&e.fadeOut()}_destroyRipple(e){let A=this._activeRipples.get(e)??null;this._activeRipples.delete(e),this._activeRipples.size||(this._containerRect=null),e===this._mostRecentTransientRipple&&(this._mostRecentTransientRipple=null),e.state=_s.HIDDEN,A!==null&&(e.element.removeEventListener("transitionend",A.onTransitionEnd),e.element.removeEventListener("transitioncancel",A.onTransitionCancel),A.fallbackTimer!==null&&clearTimeout(A.fallbackTimer)),e.element.remove()}_onMousedown(e){let A=Ak(e),i=this._lastTouchStartEvent&&Date.now()<this._lastTouchStartEvent+AuA;!this._target.rippleDisabled&&!A&&!i&&(this._isPointerDown=!0,this.fadeInRipple(e.clientX,e.clientY,this._target.rippleConfig))}_onTouchStart(e){if(!this._target.rippleDisabled&&!ek(e)){this._lastTouchStartEvent=Date.now(),this._isPointerDown=!0;let A=e.changedTouches;if(A)for(let i=0;i<A.length;i++)this.fadeInRipple(A[i].clientX,A[i].clientY,this._target.rippleConfig)}}_onPointerUp(){this._isPointerDown&&(this._isPointerDown=!1,this._getActiveRipples().forEach(e=>{let A=e.state===_s.VISIBLE||e.config.terminateOnPointerUp&&e.state===_s.FADING_IN;!e.config.persistent&&A&&e.fadeOut()}))}_getActiveRipples(){return Array.from(this._activeRipples.keys())}_removeTriggerEvents(){let e=this._triggerElement;e&&(xO.forEach(A=>t._eventManager.removeHandler(A,e,this)),this._pointerUpEventsRegistered&&(FO.forEach(A=>e.removeEventListener(A,this,LO)),this._pointerUpEventsRegistered=!1))}};function tuA(t,e,A){let i=Math.max(Math.abs(t-A.left),Math.abs(t-A.right)),n=Math.max(Math.abs(e-A.top),Math.abs(e-A.bottom));return Math.sqrt(i*i+n*n)}var L2=new BA("mat-ripple-global-options"),Gs=(()=>{class t{_elementRef=m(te);_animationMode=m(mi,{optional:!0});color;unbounded;centered;radius=0;animation;get disabled(){return this._disabled}set disabled(A){A&&this.fadeOutAllNonPersistent(),this._disabled=A,this._setupTriggerEventsIfEnabled()}_disabled=!1;get trigger(){return this._trigger||this._elementRef.nativeElement}set trigger(A){this._trigger=A,this._setupTriggerEventsIfEnabled()}_trigger;_rippleRenderer;_globalOptions;_isInitialized=!1;constructor(){let A=m(de),i=m(Zt),n=m(L2,{optional:!0}),o=m(Dt);this._globalOptions=n||{},this._rippleRenderer=new CB(this,A,this._elementRef,i,o)}ngOnInit(){this._isInitialized=!0,this._setupTriggerEventsIfEnabled()}ngOnDestroy(){this._rippleRenderer._removeTriggerEvents()}fadeOutAll(){this._rippleRenderer.fadeOutAll()}fadeOutAllNonPersistent(){this._rippleRenderer.fadeOutAllNonPersistent()}get rippleConfig(){return{centered:this.centered,radius:this.radius,color:this.color,animation:nA(nA(nA({},this._globalOptions.animation),this._animationMode==="NoopAnimations"?{enterDuration:0,exitDuration:0}:{}),this.animation),terminateOnPointerUp:this._globalOptions.terminateOnPointerUp}}get rippleDisabled(){return this.disabled||!!this._globalOptions.disabled}_setupTriggerEventsIfEnabled(){!this.disabled&&this._isInitialized&&this._rippleRenderer.setupTriggerEvents(this.trigger)}launch(A,i=0,n){return typeof A=="number"?this._rippleRenderer.fadeInRipple(A,i,nA(nA({},this.rippleConfig),n)):this._rippleRenderer.fadeInRipple(0,0,nA(nA({},this.rippleConfig),A))}static \u0275fac=function(i){return new(i||t)};static \u0275dir=OA({type:t,selectors:[["","mat-ripple",""],["","matRipple",""]],hostAttrs:[1,"mat-ripple"],hostVars:2,hostBindings:function(i,n){i&2&&ue("mat-ripple-unbounded",n.unbounded)},inputs:{color:[0,"matRippleColor","color"],unbounded:[0,"matRippleUnbounded","unbounded"],centered:[0,"matRippleCentered","centered"],radius:[0,"matRippleRadius","radius"],animation:[0,"matRippleAnimation","animation"],disabled:[0,"matRippleDisabled","disabled"],trigger:[0,"matRippleTrigger","trigger"]},exportAs:["matRipple"]})}return t})(),Xa=(()=>{class t{static \u0275fac=function(i){return new(i||t)};static \u0275mod=ge({type:t});static \u0275inj=le({imports:[Ve,Ve]})}return t})(),ak=(()=>{class t{_animationMode=m(mi,{optional:!0});state="unchecked";disabled=!1;appearance="full";constructor(){}static \u0275fac=function(i){return new(i||t)};static \u0275cmp=YA({type:t,selectors:[["mat-pseudo-checkbox"]],hostAttrs:[1,"mat-pseudo-checkbox"],hostVars:12,hostBindings:function(i,n){i&2&&ue("mat-pseudo-checkbox-indeterminate",n.state==="indeterminate")("mat-pseudo-checkbox-checked",n.state==="checked")("mat-pseudo-checkbox-disabled",n.disabled)("mat-pseudo-checkbox-minimal",n.appearance==="minimal")("mat-pseudo-checkbox-full",n.appearance==="full")("_mat-animation-noopable",n._animationMode==="NoopAnimations")},inputs:{state:"state",disabled:"disabled",appearance:"appearance"},decls:0,vars:0,template:function(i,n){},styles:['.mat-pseudo-checkbox{border-radius:2px;cursor:pointer;display:inline-block;vertical-align:middle;box-sizing:border-box;position:relative;flex-shrink:0;transition:border-color 90ms cubic-bezier(0, 0, 0.2, 0.1),background-color 90ms cubic-bezier(0, 0, 0.2, 0.1)}.mat-pseudo-checkbox::after{position:absolute;opacity:0;content:"";border-bottom:2px solid currentColor;transition:opacity 90ms cubic-bezier(0, 0, 0.2, 0.1)}.mat-pseudo-checkbox._mat-animation-noopable{transition:none !important;animation:none !important}.mat-pseudo-checkbox._mat-animation-noopable::after{transition:none}.mat-pseudo-checkbox-disabled{cursor:default}.mat-pseudo-checkbox-indeterminate::after{left:1px;opacity:1;border-radius:2px}.mat-pseudo-checkbox-checked::after{left:1px;border-left:2px solid currentColor;transform:rotate(-45deg);opacity:1;box-sizing:content-box}.mat-pseudo-checkbox-minimal.mat-pseudo-checkbox-checked::after,.mat-pseudo-checkbox-minimal.mat-pseudo-checkbox-indeterminate::after{color:var(--mat-minimal-pseudo-checkbox-selected-checkmark-color, var(--mat-sys-primary))}.mat-pseudo-checkbox-minimal.mat-pseudo-checkbox-checked.mat-pseudo-checkbox-disabled::after,.mat-pseudo-checkbox-minimal.mat-pseudo-checkbox-indeterminate.mat-pseudo-checkbox-disabled::after{color:var(--mat-minimal-pseudo-checkbox-disabled-selected-checkmark-color, color-mix(in srgb, var(--mat-sys-on-surface) 38%, transparent))}.mat-pseudo-checkbox-full{border-color:var(--mat-full-pseudo-checkbox-unselected-icon-color, var(--mat-sys-on-surface-variant));border-width:2px;border-style:solid}.mat-pseudo-checkbox-full.mat-pseudo-checkbox-disabled{border-color:var(--mat-full-pseudo-checkbox-disabled-unselected-icon-color, color-mix(in srgb, var(--mat-sys-on-surface) 38%, transparent))}.mat-pseudo-checkbox-full.mat-pseudo-checkbox-checked,.mat-pseudo-checkbox-full.mat-pseudo-checkbox-indeterminate{background-color:var(--mat-full-pseudo-checkbox-selected-icon-color, var(--mat-sys-primary));border-color:rgba(0,0,0,0)}.mat-pseudo-checkbox-full.mat-pseudo-checkbox-checked::after,.mat-pseudo-checkbox-full.mat-pseudo-checkbox-indeterminate::after{color:var(--mat-full-pseudo-checkbox-selected-checkmark-color, var(--mat-sys-on-primary))}.mat-pseudo-checkbox-full.mat-pseudo-checkbox-checked.mat-pseudo-checkbox-disabled,.mat-pseudo-checkbox-full.mat-pseudo-checkbox-indeterminate.mat-pseudo-checkbox-disabled{background-color:var(--mat-full-pseudo-checkbox-disabled-selected-icon-color, color-mix(in srgb, var(--mat-sys-on-surface) 38%, transparent))}.mat-pseudo-checkbox-full.mat-pseudo-checkbox-checked.mat-pseudo-checkbox-disabled::after,.mat-pseudo-checkbox-full.mat-pseudo-checkbox-indeterminate.mat-pseudo-checkbox-disabled::after{color:var(--mat-full-pseudo-checkbox-disabled-selected-checkmark-color, var(--mat-sys-surface))}.mat-pseudo-checkbox{width:18px;height:18px}.mat-pseudo-checkbox-minimal.mat-pseudo-checkbox-checked::after{width:14px;height:6px;transform-origin:center;top:-4.2426406871px;left:0;bottom:0;right:0;margin:auto}.mat-pseudo-checkbox-minimal.mat-pseudo-checkbox-indeterminate::after{top:8px;width:16px}.mat-pseudo-checkbox-full.mat-pseudo-checkbox-checked::after{width:10px;height:4px;transform-origin:center;top:-2.8284271247px;left:0;bottom:0;right:0;margin:auto}.mat-pseudo-checkbox-full.mat-pseudo-checkbox-indeterminate::after{top:6px;width:12px}'],encapsulation:2,changeDetection:0})}return t})(),ck=(()=>{class t{static \u0275fac=function(i){return new(i||t)};static \u0275mod=ge({type:t});static \u0275inj=le({imports:[Ve]})}return t})(),lk=new BA("MAT_OPTION_PARENT_COMPONENT"),gk=new BA("MatOptgroup");var sk=class{source;isUserInput;constructor(e,A=!1){this.source=e,this.isUserInput=A}},x2=(()=>{class t{_element=m(te);_changeDetectorRef=m(lt);_parent=m(lk,{optional:!0});group=m(gk,{optional:!0});_signalDisableRipple=!1;_selected=!1;_active=!1;_disabled=!1;_mostRecentViewValue="";get multiple(){return this._parent&&this._parent.multiple}get selected(){return this._selected}value;id=m($i).getId("mat-option-");get disabled(){return this.group&&this.group.disabled||this._disabled}set disabled(A){this._disabled=A}get disableRipple(){return this._signalDisableRipple?this._parent.disableRipple():!!this._parent?.disableRipple}get hideSingleSelectionIndicator(){return!!(this._parent&&this._parent.hideSingleSelectionIndicator)}onSelectionChange=new XA;_text;_stateChanges=new HA;constructor(){let A=m(Ln);A.load(Qr),A.load(Cu),this._signalDisableRipple=!!this._parent&&h2(this._parent.disableRipple)}get active(){return this._active}get viewValue(){return(this._text?.nativeElement.textContent||"").trim()}select(A=!0){this._selected||(this._selected=!0,this._changeDetectorRef.markForCheck(),A&&this._emitSelectionChangeEvent())}deselect(A=!0){this._selected&&(this._selected=!1,this._changeDetectorRef.markForCheck(),A&&this._emitSelectionChangeEvent())}focus(A,i){let n=this._getHostElement();typeof n.focus=="function"&&n.focus(i)}setActiveStyles(){this._active||(this._active=!0,this._changeDetectorRef.markForCheck())}setInactiveStyles(){this._active&&(this._active=!1,this._changeDetectorRef.markForCheck())}getLabel(){return this.viewValue}_handleKeydown(A){(A.keyCode===13||A.keyCode===32)&&!rr(A)&&(this._selectViaInteraction(),A.preventDefault())}_selectViaInteraction(){this.disabled||(this._selected=this.multiple?!this._selected:!0,this._changeDetectorRef.markForCheck(),this._emitSelectionChangeEvent(!0))}_getTabIndex(){return this.disabled?"-1":"0"}_getHostElement(){return this._element.nativeElement}ngAfterViewChecked(){if(this._selected){let A=this.viewValue;A!==this._mostRecentViewValue&&(this._mostRecentViewValue&&this._stateChanges.next(),this._mostRecentViewValue=A)}}ngOnDestroy(){this._stateChanges.complete()}_emitSelectionChangeEvent(A=!1){this.onSelectionChange.emit(new sk(this,A))}static \u0275fac=function(i){return new(i||t)};static \u0275cmp=YA({type:t,selectors:[["mat-option"]],viewQuery:function(i,n){if(i&1&&Ge(PQA,7),i&2){let o;$A(o=Ae())&&(n._text=o.first)}},hostAttrs:["role","option",1,"mat-mdc-option","mdc-list-item"],hostVars:11,hostBindings:function(i,n){i&1&&mA("click",function(){return n._selectViaInteraction()})("keydown",function(r){return n._handleKeydown(r)}),i&2&&(Fs("id",n.id),_e("aria-selected",n.selected)("aria-disabled",n.disabled.toString()),ue("mdc-list-item--selected",n.selected)("mat-mdc-option-multiple",n.multiple)("mat-mdc-option-active",n.active)("mdc-list-item--disabled",n.disabled))},inputs:{value:"value",id:"id",disabled:[2,"disabled","disabled",ae]},outputs:{onSelectionChange:"onSelectionChange"},exportAs:["matOption"],ngContentSelectors:qQA,decls:8,vars:5,consts:[["text",""],["aria-hidden","true",1,"mat-mdc-option-pseudo-checkbox",3,"disabled","state"],[1,"mdc-list-item__primary-text"],["state","checked","aria-hidden","true","appearance","minimal",1,"mat-mdc-option-pseudo-checkbox",3,"disabled"],[1,"cdk-visually-hidden"],["aria-hidden","true","mat-ripple","",1,"mat-mdc-option-ripple","mat-focus-indicator",3,"matRippleTrigger","matRippleDisabled"]],template:function(i,n){i&1&&(Yt(jQA),NA(0,VQA,1,2,"mat-pseudo-checkbox",1),xe(1),S(2,"span",2,0),xe(4,1),R(),NA(5,ZQA,1,1,"mat-pseudo-checkbox",3)(6,WQA,2,1,"span",4),UA(7,"div",5)),i&2&&(FA(n.multiple?0:-1),_(5),FA(!n.multiple&&n.selected&&!n.hideSingleSelectionIndicator?5:-1),_(),FA(n.group&&n.group._inert?6:-1),_(),vA("matRippleTrigger",n._getHostElement())("matRippleDisabled",n.disabled||n.disableRipple))},dependencies:[ak,Gs],styles:['.mat-mdc-option{-webkit-user-select:none;user-select:none;-moz-osx-font-smoothing:grayscale;-webkit-font-smoothing:antialiased;display:flex;position:relative;align-items:center;justify-content:flex-start;overflow:hidden;min-height:48px;padding:0 16px;cursor:pointer;-webkit-tap-highlight-color:rgba(0,0,0,0);color:var(--mat-option-label-text-color, var(--mat-sys-on-surface));font-family:var(--mat-option-label-text-font, var(--mat-sys-label-large-font));line-height:var(--mat-option-label-text-line-height, var(--mat-sys-label-large-line-height));font-size:var(--mat-option-label-text-size, var(--mat-sys-body-large-size));letter-spacing:var(--mat-option-label-text-tracking, var(--mat-sys-label-large-tracking));font-weight:var(--mat-option-label-text-weight, var(--mat-sys-body-large-weight))}.mat-mdc-option:hover:not(.mdc-list-item--disabled){background-color:var(--mat-option-hover-state-layer-color, color-mix(in srgb, var(--mat-sys-on-surface) calc(var(--mat-sys-hover-state-layer-opacity) * 100%), transparent))}.mat-mdc-option:focus.mdc-list-item,.mat-mdc-option.mat-mdc-option-active.mdc-list-item{background-color:var(--mat-option-focus-state-layer-color, color-mix(in srgb, var(--mat-sys-on-surface) calc(var(--mat-sys-focus-state-layer-opacity) * 100%), transparent));outline:0}.mat-mdc-option.mdc-list-item--selected:not(.mdc-list-item--disabled):not(.mat-mdc-option-multiple){background-color:var(--mat-option-selected-state-layer-color, var(--mat-sys-secondary-container))}.mat-mdc-option.mdc-list-item--selected:not(.mdc-list-item--disabled):not(.mat-mdc-option-multiple) .mdc-list-item__primary-text{color:var(--mat-option-selected-state-label-text-color, var(--mat-sys-on-secondary-container))}.mat-mdc-option .mat-pseudo-checkbox{--mat-minimal-pseudo-checkbox-selected-checkmark-color: var(--mat-option-selected-state-label-text-color, var(--mat-sys-on-secondary-container))}.mat-mdc-option.mdc-list-item{align-items:center;background:rgba(0,0,0,0)}.mat-mdc-option.mdc-list-item--disabled{cursor:default;pointer-events:none}.mat-mdc-option.mdc-list-item--disabled .mat-mdc-option-pseudo-checkbox,.mat-mdc-option.mdc-list-item--disabled .mdc-list-item__primary-text,.mat-mdc-option.mdc-list-item--disabled>mat-icon{opacity:.38}.mat-mdc-optgroup .mat-mdc-option:not(.mat-mdc-option-multiple){padding-left:32px}[dir=rtl] .mat-mdc-optgroup .mat-mdc-option:not(.mat-mdc-option-multiple){padding-left:16px;padding-right:32px}.mat-mdc-option .mat-icon,.mat-mdc-option .mat-pseudo-checkbox-full{margin-right:16px;flex-shrink:0}[dir=rtl] .mat-mdc-option .mat-icon,[dir=rtl] .mat-mdc-option .mat-pseudo-checkbox-full{margin-right:0;margin-left:16px}.mat-mdc-option .mat-pseudo-checkbox-minimal{margin-left:16px;flex-shrink:0}[dir=rtl] .mat-mdc-option .mat-pseudo-checkbox-minimal{margin-right:16px;margin-left:0}.mat-mdc-option .mat-mdc-option-ripple{top:0;left:0;right:0;bottom:0;position:absolute;pointer-events:none}.mat-mdc-option .mdc-list-item__primary-text{white-space:normal;font-size:inherit;font-weight:inherit;letter-spacing:inherit;line-height:inherit;font-family:inherit;text-decoration:inherit;text-transform:inherit;margin-right:auto}[dir=rtl] .mat-mdc-option .mdc-list-item__primary-text{margin-right:0;margin-left:auto}@media(forced-colors: active){.mat-mdc-option.mdc-list-item--selected:not(:has(.mat-mdc-option-pseudo-checkbox))::after{content:"";position:absolute;top:50%;right:16px;transform:translateY(-50%);width:10px;height:0;border-bottom:solid 10px;border-radius:10px}[dir=rtl] .mat-mdc-option.mdc-list-item--selected:not(:has(.mat-mdc-option-pseudo-checkbox))::after{right:auto;left:16px}}.mat-mdc-option-multiple{--mdc-list-list-item-selected-container-color:var(--mdc-list-list-item-container-color, transparent)}.mat-mdc-option-active .mat-focus-indicator::before{content:""}'],encapsulation:2,changeDetection:0})}return t})();function UO(t,e,A){if(A.length){let i=e.toArray(),n=A.toArray(),o=0;for(let r=0;r<t+1;r++)i[r].group&&i[r].group===n[o]&&o++;return o}return 0}function KO(t,e,A,i){return t<A?t:t+e>A+i?Math.max(0,t-i+e):A}var Ik=(()=>{class t{static \u0275fac=function(i){return new(i||t)};static \u0275mod=ge({type:t});static \u0275inj=le({imports:[Xa,Ve,ck]})}return t})(),NO={capture:!0},_O=["focus","mousedown","mouseenter","touchstart"],ik="mat-ripple-loader-uninitialized",nk="mat-ripple-loader-class-name",GO="mat-ripple-loader-centered",V6="mat-ripple-loader-disabled",Ck=(()=>{class t{_document=m(tt,{optional:!0});_animationMode=m(mi,{optional:!0});_globalRippleOptions=m(L2,{optional:!0});_platform=m(Zt);_ngZone=m(de);_injector=m(Dt);_hosts=new Map;constructor(){this._ngZone.runOutsideAngular(()=>{for(let A of _O)this._document?.addEventListener(A,this._onInteraction,NO)})}ngOnDestroy(){let A=this._hosts.keys();for(let i of A)this.destroyRipple(i);for(let i of _O)this._document?.removeEventListener(i,this._onInteraction,NO)}configureRipple(A,i){A.setAttribute(ik,this._globalRippleOptions?.namespace??""),(i.className||!A.hasAttribute(nk))&&A.setAttribute(nk,i.className||""),i.centered&&A.setAttribute(GO,""),i.disabled&&A.setAttribute(V6,"")}setDisabled(A,i){let n=this._hosts.get(A);n?(n.target.rippleDisabled=i,!i&&!n.hasSetUpEvents&&(n.hasSetUpEvents=!0,n.renderer.setupTriggerEvents(A))):i?A.setAttribute(V6,""):A.removeAttribute(V6)}_onInteraction=A=>{let i=Wa(A);if(i instanceof HTMLElement){let n=i.closest(`[${ik}="${this._globalRippleOptions?.namespace??""}"]`);n&&this._createRipple(n)}};_createRipple(A){if(!this._document||this._hosts.has(A))return;A.querySelector(".mat-ripple")?.remove();let i=this._document.createElement("span");i.classList.add("mat-ripple",A.getAttribute(nk)),A.append(i);let n=this._animationMode==="NoopAnimations",o=this._globalRippleOptions,r=n?0:o?.animation?.enterDuration??Z6.enterDuration,s=n?0:o?.animation?.exitDuration??Z6.exitDuration,a={rippleDisabled:n||o?.disabled||A.hasAttribute(V6),rippleConfig:{centered:A.hasAttribute(GO),terminateOnPointerUp:o?.terminateOnPointerUp,animation:{enterDuration:r,exitDuration:s}}},c=new CB(a,this._ngZone,i,this._platform,this._injector),l=!a.rippleDisabled;l&&c.setupTriggerEvents(A),this._hosts.set(A,{target:a,renderer:c,hasSetUpEvents:l}),A.removeAttribute(ik)}destroyRipple(A){let i=this._hosts.get(A);i&&(i.renderer._removeTriggerEvents(),this._hosts.delete(A))}static \u0275fac=function(i){return new(i||t)};static \u0275prov=SA({token:t,factory:t.\u0275fac,providedIn:"root"})}return t})(),BB=(()=>{class t{labelPosition;static \u0275fac=function(i){return new(i||t)};static \u0275cmp=YA({type:t,selectors:[["div","mat-internal-form-field",""]],hostAttrs:[1,"mdc-form-field","mat-internal-form-field"],hostVars:2,hostBindings:function(i,n){i&2&&ue("mdc-form-field--align-end",n.labelPosition==="before")},inputs:{labelPosition:"labelPosition"},attrs:XQA,ngContentSelectors:$QA,decls:1,vars:0,template:function(i,n){i&1&&(Yt(),xe(0))},styles:[".mat-internal-form-field{-moz-osx-font-smoothing:grayscale;-webkit-font-smoothing:antialiased;display:inline-flex;align-items:center;vertical-align:middle}.mat-internal-form-field>label{margin-left:0;margin-right:auto;padding-left:4px;padding-right:0;order:0}[dir=rtl] .mat-internal-form-field>label{margin-left:auto;margin-right:0;padding-left:0;padding-right:4px}.mdc-form-field--align-end>label{margin-left:auto;margin-right:0;padding-left:0;padding-right:4px;order:-1}[dir=rtl] .mdc-form-field--align-end .mdc-form-field--align-end label{margin-left:0;margin-right:auto;padding-left:4px;padding-right:0}"],encapsulation:2,changeDetection:0})}return t})();var iuA=["mat-button",""],dk=[[["",8,"material-icons",3,"iconPositionEnd",""],["mat-icon",3,"iconPositionEnd",""],["","matButtonIcon","",3,"iconPositionEnd",""]],"*",[["","iconPositionEnd","",8,"material-icons"],["mat-icon","iconPositionEnd",""],["","matButtonIcon","","iconPositionEnd",""]]],Bk=[".material-icons:not([iconPositionEnd]), mat-icon:not([iconPositionEnd]), [matButtonIcon]:not([iconPositionEnd])","*",".material-icons[iconPositionEnd], mat-icon[iconPositionEnd], [matButtonIcon][iconPositionEnd]"];var nuA="@media(forced-colors: active){.mat-mdc-button:not(.mdc-button--outlined),.mat-mdc-unelevated-button:not(.mdc-button--outlined),.mat-mdc-raised-button:not(.mdc-button--outlined),.mat-mdc-outlined-button:not(.mdc-button--outlined),.mat-mdc-icon-button.mat-mdc-icon-button{outline:solid 1px}}",ouA=["mat-fab",""],ruA=["mat-mini-fab",""],suA='.mat-mdc-fab-base{-webkit-user-select:none;user-select:none;position:relative;display:inline-flex;align-items:center;justify-content:center;box-sizing:border-box;width:56px;height:56px;padding:0;border:none;fill:currentColor;text-decoration:none;cursor:pointer;-moz-appearance:none;-webkit-appearance:none;overflow:visible;transition:box-shadow 280ms cubic-bezier(0.4, 0, 0.2, 1),opacity 15ms linear 30ms,transform 270ms 0ms cubic-bezier(0, 0, 0.2, 1);flex-shrink:0;-webkit-tap-highlight-color:rgba(0,0,0,0)}.mat-mdc-fab-base .mat-mdc-button-ripple,.mat-mdc-fab-base .mat-mdc-button-persistent-ripple,.mat-mdc-fab-base .mat-mdc-button-persistent-ripple::before{top:0;left:0;right:0;bottom:0;position:absolute;pointer-events:none;border-radius:inherit}.mat-mdc-fab-base .mat-mdc-button-ripple{overflow:hidden}.mat-mdc-fab-base .mat-mdc-button-persistent-ripple::before{content:"";opacity:0}.mat-mdc-fab-base .mdc-button__label,.mat-mdc-fab-base .mat-icon{z-index:1;position:relative}.mat-mdc-fab-base .mat-focus-indicator{top:0;left:0;right:0;bottom:0;position:absolute}.mat-mdc-fab-base:focus>.mat-focus-indicator::before{content:""}.mat-mdc-fab-base._mat-animation-noopable{transition:none !important;animation:none !important}.mat-mdc-fab-base::before{position:absolute;box-sizing:border-box;width:100%;height:100%;top:0;left:0;border:1px solid rgba(0,0,0,0);border-radius:inherit;content:"";pointer-events:none}.mat-mdc-fab-base[hidden]{display:none}.mat-mdc-fab-base::-moz-focus-inner{padding:0;border:0}.mat-mdc-fab-base:active,.mat-mdc-fab-base:focus{outline:none}.mat-mdc-fab-base:hover{cursor:pointer}.mat-mdc-fab-base>svg{width:100%}.mat-mdc-fab-base .mat-icon,.mat-mdc-fab-base .material-icons{transition:transform 180ms 90ms cubic-bezier(0, 0, 0.2, 1);fill:currentColor;will-change:transform}.mat-mdc-fab-base .mat-focus-indicator::before{margin:calc(calc(var(--mat-focus-indicator-border-width, 3px) + 2px)*-1)}.mat-mdc-fab-base[disabled],.mat-mdc-fab-base.mat-mdc-button-disabled{cursor:default;pointer-events:none}.mat-mdc-fab-base[disabled],.mat-mdc-fab-base[disabled]:focus,.mat-mdc-fab-base.mat-mdc-button-disabled,.mat-mdc-fab-base.mat-mdc-button-disabled:focus{box-shadow:none}.mat-mdc-fab-base.mat-mdc-button-disabled-interactive{pointer-events:auto}.mat-mdc-fab{background-color:var(--mdc-fab-container-color, var(--mat-sys-primary-container));border-radius:var(--mdc-fab-container-shape, var(--mat-sys-corner-large));color:var(--mat-fab-foreground-color, var(--mat-sys-on-primary-container, inherit));box-shadow:var(--mdc-fab-container-elevation-shadow, var(--mat-sys-level3))}.mat-mdc-fab:hover{box-shadow:var(--mdc-fab-hover-container-elevation-shadow, var(--mat-sys-level4))}.mat-mdc-fab:focus{box-shadow:var(--mdc-fab-focus-container-elevation-shadow, var(--mat-sys-level3))}.mat-mdc-fab:active,.mat-mdc-fab:focus:active{box-shadow:var(--mdc-fab-pressed-container-elevation-shadow, var(--mat-sys-level3))}.mat-mdc-fab[disabled],.mat-mdc-fab.mat-mdc-button-disabled{cursor:default;pointer-events:none;color:var(--mat-fab-disabled-state-foreground-color, color-mix(in srgb, var(--mat-sys-on-surface) 38%, transparent));background-color:var(--mat-fab-disabled-state-container-color, color-mix(in srgb, var(--mat-sys-on-surface) 12%, transparent))}.mat-mdc-fab.mat-mdc-button-disabled-interactive{pointer-events:auto}.mat-mdc-fab .mat-mdc-button-touch-target{position:absolute;top:50%;height:48px;left:50%;width:48px;transform:translate(-50%, -50%);display:var(--mat-fab-touch-target-display, block)}.mat-mdc-fab .mat-ripple-element{background-color:var(--mat-fab-ripple-color, color-mix(in srgb, var(--mat-sys-on-primary-container) calc(var(--mat-sys-pressed-state-layer-opacity) * 100%), transparent))}.mat-mdc-fab .mat-mdc-button-persistent-ripple::before{background-color:var(--mat-fab-state-layer-color, var(--mat-sys-on-primary-container))}.mat-mdc-fab.mat-mdc-button-disabled .mat-mdc-button-persistent-ripple::before{background-color:var(--mat-fab-disabled-state-layer-color)}.mat-mdc-fab:hover>.mat-mdc-button-persistent-ripple::before{opacity:var(--mat-fab-hover-state-layer-opacity, var(--mat-sys-hover-state-layer-opacity))}.mat-mdc-fab.cdk-program-focused>.mat-mdc-button-persistent-ripple::before,.mat-mdc-fab.cdk-keyboard-focused>.mat-mdc-button-persistent-ripple::before,.mat-mdc-fab.mat-mdc-button-disabled-interactive:focus>.mat-mdc-button-persistent-ripple::before{opacity:var(--mat-fab-focus-state-layer-opacity, var(--mat-sys-focus-state-layer-opacity))}.mat-mdc-fab:active>.mat-mdc-button-persistent-ripple::before{opacity:var(--mat-fab-pressed-state-layer-opacity, var(--mat-sys-pressed-state-layer-opacity))}.mat-mdc-mini-fab{width:40px;height:40px;background-color:var(--mdc-fab-small-container-color, var(--mat-sys-primary-container));border-radius:var(--mdc-fab-small-container-shape, var(--mat-sys-corner-medium));color:var(--mat-fab-small-foreground-color, var(--mat-sys-on-primary-container, inherit));box-shadow:var(--mdc-fab-small-container-elevation-shadow, var(--mat-sys-level3))}.mat-mdc-mini-fab:hover{box-shadow:var(--mdc-fab-small-hover-container-elevation-shadow, var(--mat-sys-level4))}.mat-mdc-mini-fab:focus{box-shadow:var(--mdc-fab-small-focus-container-elevation-shadow, var(--mat-sys-level3))}.mat-mdc-mini-fab:active,.mat-mdc-mini-fab:focus:active{box-shadow:var(--mdc-fab-small-pressed-container-elevation-shadow, var(--mat-sys-level3))}.mat-mdc-mini-fab[disabled],.mat-mdc-mini-fab.mat-mdc-button-disabled{cursor:default;pointer-events:none;color:var(--mat-fab-small-disabled-state-foreground-color, color-mix(in srgb, var(--mat-sys-on-surface) 38%, transparent));background-color:var(--mat-fab-small-disabled-state-container-color, color-mix(in srgb, var(--mat-sys-on-surface) 12%, transparent))}.mat-mdc-mini-fab.mat-mdc-button-disabled-interactive{pointer-events:auto}.mat-mdc-mini-fab .mat-mdc-button-touch-target{position:absolute;top:50%;height:48px;left:50%;width:48px;transform:translate(-50%, -50%);display:var(--mat-fab-small-touch-target-display)}.mat-mdc-mini-fab .mat-ripple-element{background-color:var(--mat-fab-small-ripple-color, color-mix(in srgb, var(--mat-sys-on-primary-container) calc(var(--mat-sys-pressed-state-layer-opacity) * 100%), transparent))}.mat-mdc-mini-fab .mat-mdc-button-persistent-ripple::before{background-color:var(--mat-fab-small-state-layer-color, var(--mat-sys-on-primary-container))}.mat-mdc-mini-fab.mat-mdc-button-disabled .mat-mdc-button-persistent-ripple::before{background-color:var(--mat-fab-small-disabled-state-layer-color)}.mat-mdc-mini-fab:hover>.mat-mdc-button-persistent-ripple::before{opacity:var(--mat-fab-small-hover-state-layer-opacity, var(--mat-sys-hover-state-layer-opacity))}.mat-mdc-mini-fab.cdk-program-focused>.mat-mdc-button-persistent-ripple::before,.mat-mdc-mini-fab.cdk-keyboard-focused>.mat-mdc-button-persistent-ripple::before,.mat-mdc-mini-fab.mat-mdc-button-disabled-interactive:focus>.mat-mdc-button-persistent-ripple::before{opacity:var(--mat-fab-small-focus-state-layer-opacity, var(--mat-sys-focus-state-layer-opacity))}.mat-mdc-mini-fab:active>.mat-mdc-button-persistent-ripple::before{opacity:var(--mat-fab-small-pressed-state-layer-opacity, var(--mat-sys-pressed-state-layer-opacity))}.mat-mdc-extended-fab{-moz-osx-font-smoothing:grayscale;-webkit-font-smoothing:antialiased;border-radius:24px;padding-left:20px;padding-right:20px;width:auto;max-width:100%;line-height:normal;height:var(--mdc-extended-fab-container-height, 56px);border-radius:var(--mdc-extended-fab-container-shape, var(--mat-sys-corner-large));font-family:var(--mdc-extended-fab-label-text-font, var(--mat-sys-label-large-font));font-size:var(--mdc-extended-fab-label-text-size, var(--mat-sys-label-large-size));font-weight:var(--mdc-extended-fab-label-text-weight, var(--mat-sys-label-large-weight));letter-spacing:var(--mdc-extended-fab-label-text-tracking, var(--mat-sys-label-large-tracking));box-shadow:var(--mdc-extended-fab-container-elevation-shadow, var(--mat-sys-level3))}.mat-mdc-extended-fab:hover{box-shadow:var(--mdc-extended-fab-hover-container-elevation-shadow, var(--mat-sys-level4))}.mat-mdc-extended-fab:focus{box-shadow:var(--mdc-extended-fab-focus-container-elevation-shadow, var(--mat-sys-level3))}.mat-mdc-extended-fab:active,.mat-mdc-extended-fab:focus:active{box-shadow:var(--mdc-extended-fab-pressed-container-elevation-shadow, var(--mat-sys-level3))}.mat-mdc-extended-fab[disabled],.mat-mdc-extended-fab.mat-mdc-button-disabled{cursor:default;pointer-events:none}.mat-mdc-extended-fab[disabled],.mat-mdc-extended-fab[disabled]:focus,.mat-mdc-extended-fab.mat-mdc-button-disabled,.mat-mdc-extended-fab.mat-mdc-button-disabled:focus{box-shadow:none}.mat-mdc-extended-fab.mat-mdc-button-disabled-interactive{pointer-events:auto}[dir=rtl] .mat-mdc-extended-fab .mdc-button__label+.mat-icon,[dir=rtl] .mat-mdc-extended-fab .mdc-button__label+.material-icons,.mat-mdc-extended-fab>.mat-icon,.mat-mdc-extended-fab>.material-icons{margin-left:-8px;margin-right:12px}.mat-mdc-extended-fab .mdc-button__label+.mat-icon,.mat-mdc-extended-fab .mdc-button__label+.material-icons,[dir=rtl] .mat-mdc-extended-fab>.mat-icon,[dir=rtl] .mat-mdc-extended-fab>.material-icons{margin-left:12px;margin-right:-8px}.mat-mdc-extended-fab .mat-mdc-button-touch-target{width:100%}',auA=["mat-icon-button",""],cuA=["*"];var luA=new BA("MAT_BUTTON_CONFIG");var guA=[{attribute:"mat-button",mdcClasses:["mdc-button","mat-mdc-button"]},{attribute:"mat-flat-button",mdcClasses:["mdc-button","mdc-button--unelevated","mat-mdc-unelevated-button"]},{attribute:"mat-raised-button",mdcClasses:["mdc-button","mdc-button--raised","mat-mdc-raised-button"]},{attribute:"mat-stroked-button",mdcClasses:["mdc-button","mdc-button--outlined","mat-mdc-outlined-button"]},{attribute:"mat-fab",mdcClasses:["mdc-fab","mat-mdc-fab-base","mat-mdc-fab"]},{attribute:"mat-mini-fab",mdcClasses:["mdc-fab","mat-mdc-fab-base","mdc-fab--mini","mat-mdc-mini-fab"]},{attribute:"mat-icon-button",mdcClasses:["mdc-icon-button","mat-mdc-icon-button"]}],X6=(()=>{class t{_elementRef=m(te);_ngZone=m(de);_animationMode=m(mi,{optional:!0});_focusMonitor=m(Jr);_rippleLoader=m(Ck);_isFab=!1;color;get disableRipple(){return this._disableRipple}set disableRipple(A){this._disableRipple=A,this._updateRippleDisabled()}_disableRipple=!1;get disabled(){return this._disabled}set disabled(A){this._disabled=A,this._updateRippleDisabled()}_disabled=!1;ariaDisabled;disabledInteractive;constructor(){m(Ln).load(Qr);let A=m(luA,{optional:!0}),i=this._elementRef.nativeElement,n=i.classList;this.disabledInteractive=A?.disabledInteractive??!1,this.color=A?.color??null,this._rippleLoader?.configureRipple(i,{className:"mat-mdc-button-ripple"});for(let{attribute:o,mdcClasses:r}of guA)i.hasAttribute(o)&&n.add(...r)}ngAfterViewInit(){this._focusMonitor.monitor(this._elementRef,!0)}ngOnDestroy(){this._focusMonitor.stopMonitoring(this._elementRef),this._rippleLoader?.destroyRipple(this._elementRef.nativeElement)}focus(A="program",i){A?this._focusMonitor.focusVia(this._elementRef.nativeElement,A,i):this._elementRef.nativeElement.focus(i)}_getAriaDisabled(){return this.ariaDisabled!=null?this.ariaDisabled:this.disabled&&this.disabledInteractive?!0:null}_getDisabledAttribute(){return this.disabledInteractive||!this.disabled?null:!0}_updateRippleDisabled(){this._rippleLoader?.setDisabled(this._elementRef.nativeElement,this.disableRipple||this.disabled)}static \u0275fac=function(i){return new(i||t)};static \u0275dir=OA({type:t,inputs:{color:"color",disableRipple:[2,"disableRipple","disableRipple",ae],disabled:[2,"disabled","disabled",ae],ariaDisabled:[2,"aria-disabled","ariaDisabled",ae],disabledInteractive:[2,"disabledInteractive","disabledInteractive",ae]}})}return t})();var ur=(()=>{class t extends X6{static \u0275fac=(()=>{let A;return function(n){return(A||(A=bi(t)))(n||t)}})();static \u0275cmp=YA({type:t,selectors:[["button","mat-button",""],["button","mat-raised-button",""],["button","mat-flat-button",""],["button","mat-stroked-button",""]],hostVars:14,hostBindings:function(i,n){i&2&&(_e("disabled",n._getDisabledAttribute())("aria-disabled",n._getAriaDisabled()),vo(n.color?"mat-"+n.color:""),ue("mat-mdc-button-disabled",n.disabled)("mat-mdc-button-disabled-interactive",n.disabledInteractive)("_mat-animation-noopable",n._animationMode==="NoopAnimations")("mat-unthemed",!n.color)("mat-mdc-button-base",!0))},exportAs:["matButton"],features:[et],attrs:iuA,ngContentSelectors:Bk,decls:7,vars:4,consts:[[1,"mat-mdc-button-persistent-ripple"],[1,"mdc-button__label"],[1,"mat-focus-indicator"],[1,"mat-mdc-button-touch-target"]],template:function(i,n){i&1&&(Yt(dk),UA(0,"span",0),xe(1),S(2,"span",1),xe(3,1),R(),xe(4,2),UA(5,"span",2)(6,"span",3)),i&2&&ue("mdc-button__ripple",!n._isFab)("mdc-fab__ripple",n._isFab)},styles:['.mat-mdc-button-base{text-decoration:none}.mdc-button{-webkit-user-select:none;user-select:none;position:relative;display:inline-flex;align-items:center;justify-content:center;box-sizing:border-box;min-width:64px;border:none;outline:none;line-height:inherit;-webkit-appearance:none;overflow:visible;vertical-align:middle;background:rgba(0,0,0,0);padding:0 8px}.mdc-button::-moz-focus-inner{padding:0;border:0}.mdc-button:active{outline:none}.mdc-button:hover{cursor:pointer}.mdc-button:disabled{cursor:default;pointer-events:none}.mdc-button[hidden]{display:none}.mdc-button .mdc-button__label{position:relative}.mat-mdc-button{padding:0 var(--mat-text-button-horizontal-padding, 12px);height:var(--mdc-text-button-container-height, 40px);font-family:var(--mdc-text-button-label-text-font, var(--mat-sys-label-large-font));font-size:var(--mdc-text-button-label-text-size, var(--mat-sys-label-large-size));letter-spacing:var(--mdc-text-button-label-text-tracking, var(--mat-sys-label-large-tracking));text-transform:var(--mdc-text-button-label-text-transform);font-weight:var(--mdc-text-button-label-text-weight, var(--mat-sys-label-large-weight))}.mat-mdc-button,.mat-mdc-button .mdc-button__ripple{border-radius:var(--mdc-text-button-container-shape, var(--mat-sys-corner-full))}.mat-mdc-button:not(:disabled){color:var(--mdc-text-button-label-text-color, var(--mat-sys-primary))}.mat-mdc-button[disabled],.mat-mdc-button.mat-mdc-button-disabled{cursor:default;pointer-events:none;color:var(--mdc-text-button-disabled-label-text-color, color-mix(in srgb, var(--mat-sys-on-surface) 38%, transparent))}.mat-mdc-button.mat-mdc-button-disabled-interactive{pointer-events:auto}.mat-mdc-button:has(.material-icons,mat-icon,[matButtonIcon]){padding:0 var(--mat-text-button-with-icon-horizontal-padding, 16px)}.mat-mdc-button>.mat-icon{margin-right:var(--mat-text-button-icon-spacing, 8px);margin-left:var(--mat-text-button-icon-offset, -4px)}[dir=rtl] .mat-mdc-button>.mat-icon{margin-right:var(--mat-text-button-icon-offset, -4px);margin-left:var(--mat-text-button-icon-spacing, 8px)}.mat-mdc-button .mdc-button__label+.mat-icon{margin-right:var(--mat-text-button-icon-offset, -4px);margin-left:var(--mat-text-button-icon-spacing, 8px)}[dir=rtl] .mat-mdc-button .mdc-button__label+.mat-icon{margin-right:var(--mat-text-button-icon-spacing, 8px);margin-left:var(--mat-text-button-icon-offset, -4px)}.mat-mdc-button .mat-ripple-element{background-color:var(--mat-text-button-ripple-color, color-mix(in srgb, var(--mat-sys-primary) calc(var(--mat-sys-pressed-state-layer-opacity) * 100%), transparent))}.mat-mdc-button .mat-mdc-button-persistent-ripple::before{background-color:var(--mat-text-button-state-layer-color, var(--mat-sys-primary))}.mat-mdc-button.mat-mdc-button-disabled .mat-mdc-button-persistent-ripple::before{background-color:var(--mat-text-button-disabled-state-layer-color, var(--mat-sys-on-surface-variant))}.mat-mdc-button:hover>.mat-mdc-button-persistent-ripple::before{opacity:var(--mat-text-button-hover-state-layer-opacity, var(--mat-sys-hover-state-layer-opacity))}.mat-mdc-button.cdk-program-focused>.mat-mdc-button-persistent-ripple::before,.mat-mdc-button.cdk-keyboard-focused>.mat-mdc-button-persistent-ripple::before,.mat-mdc-button.mat-mdc-button-disabled-interactive:focus>.mat-mdc-button-persistent-ripple::before{opacity:var(--mat-text-button-focus-state-layer-opacity, var(--mat-sys-focus-state-layer-opacity))}.mat-mdc-button:active>.mat-mdc-button-persistent-ripple::before{opacity:var(--mat-text-button-pressed-state-layer-opacity, var(--mat-sys-pressed-state-layer-opacity))}.mat-mdc-button .mat-mdc-button-touch-target{position:absolute;top:50%;height:48px;left:0;right:0;transform:translateY(-50%);display:var(--mat-text-button-touch-target-display, block)}.mat-mdc-unelevated-button{transition:box-shadow 280ms cubic-bezier(0.4, 0, 0.2, 1);height:var(--mdc-filled-button-container-height, 40px);font-family:var(--mdc-filled-button-label-text-font, var(--mat-sys-label-large-font));font-size:var(--mdc-filled-button-label-text-size, var(--mat-sys-label-large-size));letter-spacing:var(--mdc-filled-button-label-text-tracking, var(--mat-sys-label-large-tracking));text-transform:var(--mdc-filled-button-label-text-transform);font-weight:var(--mdc-filled-button-label-text-weight, var(--mat-sys-label-large-weight));padding:0 var(--mat-filled-button-horizontal-padding, 24px)}.mat-mdc-unelevated-button>.mat-icon{margin-right:var(--mat-filled-button-icon-spacing, 8px);margin-left:var(--mat-filled-button-icon-offset, -8px)}[dir=rtl] .mat-mdc-unelevated-button>.mat-icon{margin-right:var(--mat-filled-button-icon-offset, -8px);margin-left:var(--mat-filled-button-icon-spacing, 8px)}.mat-mdc-unelevated-button .mdc-button__label+.mat-icon{margin-right:var(--mat-filled-button-icon-offset, -8px);margin-left:var(--mat-filled-button-icon-spacing, 8px)}[dir=rtl] .mat-mdc-unelevated-button .mdc-button__label+.mat-icon{margin-right:var(--mat-filled-button-icon-spacing, 8px);margin-left:var(--mat-filled-button-icon-offset, -8px)}.mat-mdc-unelevated-button .mat-ripple-element{background-color:var(--mat-filled-button-ripple-color, color-mix(in srgb, var(--mat-sys-on-primary) calc(var(--mat-sys-pressed-state-layer-opacity) * 100%), transparent))}.mat-mdc-unelevated-button .mat-mdc-button-persistent-ripple::before{background-color:var(--mat-filled-button-state-layer-color, var(--mat-sys-on-primary))}.mat-mdc-unelevated-button.mat-mdc-button-disabled .mat-mdc-button-persistent-ripple::before{background-color:var(--mat-filled-button-disabled-state-layer-color, var(--mat-sys-on-surface-variant))}.mat-mdc-unelevated-button:hover>.mat-mdc-button-persistent-ripple::before{opacity:var(--mat-filled-button-hover-state-layer-opacity, var(--mat-sys-hover-state-layer-opacity))}.mat-mdc-unelevated-button.cdk-program-focused>.mat-mdc-button-persistent-ripple::before,.mat-mdc-unelevated-button.cdk-keyboard-focused>.mat-mdc-button-persistent-ripple::before,.mat-mdc-unelevated-button.mat-mdc-button-disabled-interactive:focus>.mat-mdc-button-persistent-ripple::before{opacity:var(--mat-filled-button-focus-state-layer-opacity, var(--mat-sys-focus-state-layer-opacity))}.mat-mdc-unelevated-button:active>.mat-mdc-button-persistent-ripple::before{opacity:var(--mat-filled-button-pressed-state-layer-opacity, var(--mat-sys-pressed-state-layer-opacity))}.mat-mdc-unelevated-button .mat-mdc-button-touch-target{position:absolute;top:50%;height:48px;left:0;right:0;transform:translateY(-50%);display:var(--mat-filled-button-touch-target-display, block)}.mat-mdc-unelevated-button:not(:disabled){color:var(--mdc-filled-button-label-text-color, var(--mat-sys-on-primary));background-color:var(--mdc-filled-button-container-color, var(--mat-sys-primary))}.mat-mdc-unelevated-button,.mat-mdc-unelevated-button .mdc-button__ripple{border-radius:var(--mdc-filled-button-container-shape, var(--mat-sys-corner-full))}.mat-mdc-unelevated-button[disabled],.mat-mdc-unelevated-button.mat-mdc-button-disabled{cursor:default;pointer-events:none;color:var(--mdc-filled-button-disabled-label-text-color, color-mix(in srgb, var(--mat-sys-on-surface) 38%, transparent));background-color:var(--mdc-filled-button-disabled-container-color, color-mix(in srgb, var(--mat-sys-on-surface) 12%, transparent))}.mat-mdc-unelevated-button.mat-mdc-button-disabled-interactive{pointer-events:auto}.mat-mdc-raised-button{transition:box-shadow 280ms cubic-bezier(0.4, 0, 0.2, 1);box-shadow:var(--mdc-protected-button-container-elevation-shadow, var(--mat-sys-level1));height:var(--mdc-protected-button-container-height, 40px);font-family:var(--mdc-protected-button-label-text-font, var(--mat-sys-label-large-font));font-size:var(--mdc-protected-button-label-text-size, var(--mat-sys-label-large-size));letter-spacing:var(--mdc-protected-button-label-text-tracking, var(--mat-sys-label-large-tracking));text-transform:var(--mdc-protected-button-label-text-transform);font-weight:var(--mdc-protected-button-label-text-weight, var(--mat-sys-label-large-weight));padding:0 var(--mat-protected-button-horizontal-padding, 24px)}.mat-mdc-raised-button>.mat-icon{margin-right:var(--mat-protected-button-icon-spacing, 8px);margin-left:var(--mat-protected-button-icon-offset, -8px)}[dir=rtl] .mat-mdc-raised-button>.mat-icon{margin-right:var(--mat-protected-button-icon-offset, -8px);margin-left:var(--mat-protected-button-icon-spacing, 8px)}.mat-mdc-raised-button .mdc-button__label+.mat-icon{margin-right:var(--mat-protected-button-icon-offset, -8px);margin-left:var(--mat-protected-button-icon-spacing, 8px)}[dir=rtl] .mat-mdc-raised-button .mdc-button__label+.mat-icon{margin-right:var(--mat-protected-button-icon-spacing, 8px);margin-left:var(--mat-protected-button-icon-offset, -8px)}.mat-mdc-raised-button .mat-ripple-element{background-color:var(--mat-protected-button-ripple-color, color-mix(in srgb, var(--mat-sys-primary) calc(var(--mat-sys-pressed-state-layer-opacity) * 100%), transparent))}.mat-mdc-raised-button .mat-mdc-button-persistent-ripple::before{background-color:var(--mat-protected-button-state-layer-color, var(--mat-sys-primary))}.mat-mdc-raised-button.mat-mdc-button-disabled .mat-mdc-button-persistent-ripple::before{background-color:var(--mat-protected-button-disabled-state-layer-color, var(--mat-sys-on-surface-variant))}.mat-mdc-raised-button:hover>.mat-mdc-button-persistent-ripple::before{opacity:var(--mat-protected-button-hover-state-layer-opacity, var(--mat-sys-hover-state-layer-opacity))}.mat-mdc-raised-button.cdk-program-focused>.mat-mdc-button-persistent-ripple::before,.mat-mdc-raised-button.cdk-keyboard-focused>.mat-mdc-button-persistent-ripple::before,.mat-mdc-raised-button.mat-mdc-button-disabled-interactive:focus>.mat-mdc-button-persistent-ripple::before{opacity:var(--mat-protected-button-focus-state-layer-opacity, var(--mat-sys-focus-state-layer-opacity))}.mat-mdc-raised-button:active>.mat-mdc-button-persistent-ripple::before{opacity:var(--mat-protected-button-pressed-state-layer-opacity, var(--mat-sys-pressed-state-layer-opacity))}.mat-mdc-raised-button .mat-mdc-button-touch-target{position:absolute;top:50%;height:48px;left:0;right:0;transform:translateY(-50%);display:var(--mat-protected-button-touch-target-display, block)}.mat-mdc-raised-button:not(:disabled){color:var(--mdc-protected-button-label-text-color, var(--mat-sys-primary));background-color:var(--mdc-protected-button-container-color, var(--mat-sys-surface))}.mat-mdc-raised-button,.mat-mdc-raised-button .mdc-button__ripple{border-radius:var(--mdc-protected-button-container-shape, var(--mat-sys-corner-full))}.mat-mdc-raised-button:hover{box-shadow:var(--mdc-protected-button-hover-container-elevation-shadow, var(--mat-sys-level2))}.mat-mdc-raised-button:focus{box-shadow:var(--mdc-protected-button-focus-container-elevation-shadow, var(--mat-sys-level1))}.mat-mdc-raised-button:active,.mat-mdc-raised-button:focus:active{box-shadow:var(--mdc-protected-button-pressed-container-elevation-shadow, var(--mat-sys-level1))}.mat-mdc-raised-button[disabled],.mat-mdc-raised-button.mat-mdc-button-disabled{cursor:default;pointer-events:none;color:var(--mdc-protected-button-disabled-label-text-color, color-mix(in srgb, var(--mat-sys-on-surface) 38%, transparent));background-color:var(--mdc-protected-button-disabled-container-color, color-mix(in srgb, var(--mat-sys-on-surface) 12%, transparent))}.mat-mdc-raised-button[disabled].mat-mdc-button-disabled,.mat-mdc-raised-button.mat-mdc-button-disabled.mat-mdc-button-disabled{box-shadow:var(--mdc-protected-button-disabled-container-elevation-shadow, var(--mat-sys-level0))}.mat-mdc-raised-button.mat-mdc-button-disabled-interactive{pointer-events:auto}.mat-mdc-outlined-button{border-style:solid;transition:border 280ms cubic-bezier(0.4, 0, 0.2, 1);height:var(--mdc-outlined-button-container-height, 40px);font-family:var(--mdc-outlined-button-label-text-font, var(--mat-sys-label-large-font));font-size:var(--mdc-outlined-button-label-text-size, var(--mat-sys-label-large-size));letter-spacing:var(--mdc-outlined-button-label-text-tracking, var(--mat-sys-label-large-tracking));text-transform:var(--mdc-outlined-button-label-text-transform);font-weight:var(--mdc-outlined-button-label-text-weight, var(--mat-sys-label-large-weight));border-radius:var(--mdc-outlined-button-container-shape, var(--mat-sys-corner-full));border-width:var(--mdc-outlined-button-outline-width, 1px);padding:0 var(--mat-outlined-button-horizontal-padding, 24px)}.mat-mdc-outlined-button>.mat-icon{margin-right:var(--mat-outlined-button-icon-spacing, 8px);margin-left:var(--mat-outlined-button-icon-offset, -8px)}[dir=rtl] .mat-mdc-outlined-button>.mat-icon{margin-right:var(--mat-outlined-button-icon-offset, -8px);margin-left:var(--mat-outlined-button-icon-spacing, 8px)}.mat-mdc-outlined-button .mdc-button__label+.mat-icon{margin-right:var(--mat-outlined-button-icon-offset, -8px);margin-left:var(--mat-outlined-button-icon-spacing, 8px)}[dir=rtl] .mat-mdc-outlined-button .mdc-button__label+.mat-icon{margin-right:var(--mat-outlined-button-icon-spacing, 8px);margin-left:var(--mat-outlined-button-icon-offset, -8px)}.mat-mdc-outlined-button .mat-ripple-element{background-color:var(--mat-outlined-button-ripple-color, color-mix(in srgb, var(--mat-sys-primary) calc(var(--mat-sys-pressed-state-layer-opacity) * 100%), transparent))}.mat-mdc-outlined-button .mat-mdc-button-persistent-ripple::before{background-color:var(--mat-outlined-button-state-layer-color, var(--mat-sys-primary))}.mat-mdc-outlined-button.mat-mdc-button-disabled .mat-mdc-button-persistent-ripple::before{background-color:var(--mat-outlined-button-disabled-state-layer-color, var(--mat-sys-on-surface-variant))}.mat-mdc-outlined-button:hover>.mat-mdc-button-persistent-ripple::before{opacity:var(--mat-outlined-button-hover-state-layer-opacity, var(--mat-sys-hover-state-layer-opacity))}.mat-mdc-outlined-button.cdk-program-focused>.mat-mdc-button-persistent-ripple::before,.mat-mdc-outlined-button.cdk-keyboard-focused>.mat-mdc-button-persistent-ripple::before,.mat-mdc-outlined-button.mat-mdc-button-disabled-interactive:focus>.mat-mdc-button-persistent-ripple::before{opacity:var(--mat-outlined-button-focus-state-layer-opacity, var(--mat-sys-focus-state-layer-opacity))}.mat-mdc-outlined-button:active>.mat-mdc-button-persistent-ripple::before{opacity:var(--mat-outlined-button-pressed-state-layer-opacity, var(--mat-sys-pressed-state-layer-opacity))}.mat-mdc-outlined-button .mat-mdc-button-touch-target{position:absolute;top:50%;height:48px;left:0;right:0;transform:translateY(-50%);display:var(--mat-outlined-button-touch-target-display, block)}.mat-mdc-outlined-button:not(:disabled){color:var(--mdc-outlined-button-label-text-color, var(--mat-sys-primary));border-color:var(--mdc-outlined-button-outline-color, var(--mat-sys-outline))}.mat-mdc-outlined-button[disabled],.mat-mdc-outlined-button.mat-mdc-button-disabled{cursor:default;pointer-events:none;color:var(--mdc-outlined-button-disabled-label-text-color, color-mix(in srgb, var(--mat-sys-on-surface) 38%, transparent));border-color:var(--mdc-outlined-button-disabled-outline-color, color-mix(in srgb, var(--mat-sys-on-surface) 12%, transparent))}.mat-mdc-outlined-button.mat-mdc-button-disabled-interactive{pointer-events:auto}.mat-mdc-outlined-button .mdc-button__ripple{border-width:var(--mdc-outlined-button-outline-width, 1px);border-style:solid;border-color:rgba(0,0,0,0)}.mat-mdc-button,.mat-mdc-unelevated-button,.mat-mdc-raised-button,.mat-mdc-outlined-button{-webkit-tap-highlight-color:rgba(0,0,0,0)}.mat-mdc-button .mat-mdc-button-ripple,.mat-mdc-button .mat-mdc-button-persistent-ripple,.mat-mdc-button .mat-mdc-button-persistent-ripple::before,.mat-mdc-unelevated-button .mat-mdc-button-ripple,.mat-mdc-unelevated-button .mat-mdc-button-persistent-ripple,.mat-mdc-unelevated-button .mat-mdc-button-persistent-ripple::before,.mat-mdc-raised-button .mat-mdc-button-ripple,.mat-mdc-raised-button .mat-mdc-button-persistent-ripple,.mat-mdc-raised-button .mat-mdc-button-persistent-ripple::before,.mat-mdc-outlined-button .mat-mdc-button-ripple,.mat-mdc-outlined-button .mat-mdc-button-persistent-ripple,.mat-mdc-outlined-button .mat-mdc-button-persistent-ripple::before{top:0;left:0;right:0;bottom:0;position:absolute;pointer-events:none;border-radius:inherit}.mat-mdc-button .mat-mdc-button-ripple,.mat-mdc-unelevated-button .mat-mdc-button-ripple,.mat-mdc-raised-button .mat-mdc-button-ripple,.mat-mdc-outlined-button .mat-mdc-button-ripple{overflow:hidden}.mat-mdc-button .mat-mdc-button-persistent-ripple::before,.mat-mdc-unelevated-button .mat-mdc-button-persistent-ripple::before,.mat-mdc-raised-button .mat-mdc-button-persistent-ripple::before,.mat-mdc-outlined-button .mat-mdc-button-persistent-ripple::before{content:"";opacity:0}.mat-mdc-button .mdc-button__label,.mat-mdc-button .mat-icon,.mat-mdc-unelevated-button .mdc-button__label,.mat-mdc-unelevated-button .mat-icon,.mat-mdc-raised-button .mdc-button__label,.mat-mdc-raised-button .mat-icon,.mat-mdc-outlined-button .mdc-button__label,.mat-mdc-outlined-button .mat-icon{z-index:1;position:relative}.mat-mdc-button .mat-focus-indicator,.mat-mdc-unelevated-button .mat-focus-indicator,.mat-mdc-raised-button .mat-focus-indicator,.mat-mdc-outlined-button .mat-focus-indicator{top:0;left:0;right:0;bottom:0;position:absolute}.mat-mdc-button:focus>.mat-focus-indicator::before,.mat-mdc-unelevated-button:focus>.mat-focus-indicator::before,.mat-mdc-raised-button:focus>.mat-focus-indicator::before,.mat-mdc-outlined-button:focus>.mat-focus-indicator::before{content:""}.mat-mdc-button._mat-animation-noopable,.mat-mdc-unelevated-button._mat-animation-noopable,.mat-mdc-raised-button._mat-animation-noopable,.mat-mdc-outlined-button._mat-animation-noopable{transition:none !important;animation:none !important}.mat-mdc-button>.mat-icon,.mat-mdc-unelevated-button>.mat-icon,.mat-mdc-raised-button>.mat-icon,.mat-mdc-outlined-button>.mat-icon{display:inline-block;position:relative;vertical-align:top;font-size:1.125rem;height:1.125rem;width:1.125rem}.mat-mdc-outlined-button .mat-mdc-button-ripple,.mat-mdc-outlined-button .mdc-button__ripple{top:-1px;left:-1px;bottom:-1px;right:-1px}.mat-mdc-unelevated-button .mat-focus-indicator::before,.mat-mdc-raised-button .mat-focus-indicator::before{margin:calc(calc(var(--mat-focus-indicator-border-width, 3px) + 2px)*-1)}.mat-mdc-outlined-button .mat-focus-indicator::before{margin:calc(calc(var(--mat-focus-indicator-border-width, 3px) + 3px)*-1)}',"@media(forced-colors: active){.mat-mdc-button:not(.mdc-button--outlined),.mat-mdc-unelevated-button:not(.mdc-button--outlined),.mat-mdc-raised-button:not(.mdc-button--outlined),.mat-mdc-outlined-button:not(.mdc-button--outlined),.mat-mdc-icon-button.mat-mdc-icon-button{outline:solid 1px}}"],encapsulation:2,changeDetection:0})}return t})();var JO=new BA("mat-mdc-fab-default-options",{providedIn:"root",factory:TO});function TO(){return{color:"accent"}}var W6=TO(),zO=(()=>{class t extends X6{_options=m(JO,{optional:!0});_isFab=!0;extended;constructor(){super(),this._options=this._options||W6,this.color=this._options.color||W6.color}static \u0275fac=function(i){return new(i||t)};static \u0275cmp=YA({type:t,selectors:[["button","mat-fab",""]],hostVars:18,hostBindings:function(i,n){i&2&&(_e("disabled",n._getDisabledAttribute())("aria-disabled",n._getAriaDisabled()),vo(n.color?"mat-"+n.color:""),ue("mat-mdc-button-disabled",n.disabled)("mat-mdc-button-disabled-interactive",n.disabledInteractive)("_mat-animation-noopable",n._animationMode==="NoopAnimations")("mat-unthemed",!n.color)("mat-mdc-button-base",!0)("mdc-fab--extended",n.extended)("mat-mdc-extended-fab",n.extended))},inputs:{extended:[2,"extended","extended",ae]},exportAs:["matButton"],features:[et],attrs:ouA,ngContentSelectors:Bk,decls:7,vars:4,consts:[[1,"mat-mdc-button-persistent-ripple"],[1,"mdc-button__label"],[1,"mat-focus-indicator"],[1,"mat-mdc-button-touch-target"]],template:function(i,n){i&1&&(Yt(dk),UA(0,"span",0),xe(1),S(2,"span",1),xe(3,1),R(),xe(4,2),UA(5,"span",2)(6,"span",3)),i&2&&ue("mdc-button__ripple",!n._isFab)("mdc-fab__ripple",n._isFab)},styles:['.mat-mdc-fab-base{-webkit-user-select:none;user-select:none;position:relative;display:inline-flex;align-items:center;justify-content:center;box-sizing:border-box;width:56px;height:56px;padding:0;border:none;fill:currentColor;text-decoration:none;cursor:pointer;-moz-appearance:none;-webkit-appearance:none;overflow:visible;transition:box-shadow 280ms cubic-bezier(0.4, 0, 0.2, 1),opacity 15ms linear 30ms,transform 270ms 0ms cubic-bezier(0, 0, 0.2, 1);flex-shrink:0;-webkit-tap-highlight-color:rgba(0,0,0,0)}.mat-mdc-fab-base .mat-mdc-button-ripple,.mat-mdc-fab-base .mat-mdc-button-persistent-ripple,.mat-mdc-fab-base .mat-mdc-button-persistent-ripple::before{top:0;left:0;right:0;bottom:0;position:absolute;pointer-events:none;border-radius:inherit}.mat-mdc-fab-base .mat-mdc-button-ripple{overflow:hidden}.mat-mdc-fab-base .mat-mdc-button-persistent-ripple::before{content:"";opacity:0}.mat-mdc-fab-base .mdc-button__label,.mat-mdc-fab-base .mat-icon{z-index:1;position:relative}.mat-mdc-fab-base .mat-focus-indicator{top:0;left:0;right:0;bottom:0;position:absolute}.mat-mdc-fab-base:focus>.mat-focus-indicator::before{content:""}.mat-mdc-fab-base._mat-animation-noopable{transition:none !important;animation:none !important}.mat-mdc-fab-base::before{position:absolute;box-sizing:border-box;width:100%;height:100%;top:0;left:0;border:1px solid rgba(0,0,0,0);border-radius:inherit;content:"";pointer-events:none}.mat-mdc-fab-base[hidden]{display:none}.mat-mdc-fab-base::-moz-focus-inner{padding:0;border:0}.mat-mdc-fab-base:active,.mat-mdc-fab-base:focus{outline:none}.mat-mdc-fab-base:hover{cursor:pointer}.mat-mdc-fab-base>svg{width:100%}.mat-mdc-fab-base .mat-icon,.mat-mdc-fab-base .material-icons{transition:transform 180ms 90ms cubic-bezier(0, 0, 0.2, 1);fill:currentColor;will-change:transform}.mat-mdc-fab-base .mat-focus-indicator::before{margin:calc(calc(var(--mat-focus-indicator-border-width, 3px) + 2px)*-1)}.mat-mdc-fab-base[disabled],.mat-mdc-fab-base.mat-mdc-button-disabled{cursor:default;pointer-events:none}.mat-mdc-fab-base[disabled],.mat-mdc-fab-base[disabled]:focus,.mat-mdc-fab-base.mat-mdc-button-disabled,.mat-mdc-fab-base.mat-mdc-button-disabled:focus{box-shadow:none}.mat-mdc-fab-base.mat-mdc-button-disabled-interactive{pointer-events:auto}.mat-mdc-fab{background-color:var(--mdc-fab-container-color, var(--mat-sys-primary-container));border-radius:var(--mdc-fab-container-shape, var(--mat-sys-corner-large));color:var(--mat-fab-foreground-color, var(--mat-sys-on-primary-container, inherit));box-shadow:var(--mdc-fab-container-elevation-shadow, var(--mat-sys-level3))}.mat-mdc-fab:hover{box-shadow:var(--mdc-fab-hover-container-elevation-shadow, var(--mat-sys-level4))}.mat-mdc-fab:focus{box-shadow:var(--mdc-fab-focus-container-elevation-shadow, var(--mat-sys-level3))}.mat-mdc-fab:active,.mat-mdc-fab:focus:active{box-shadow:var(--mdc-fab-pressed-container-elevation-shadow, var(--mat-sys-level3))}.mat-mdc-fab[disabled],.mat-mdc-fab.mat-mdc-button-disabled{cursor:default;pointer-events:none;color:var(--mat-fab-disabled-state-foreground-color, color-mix(in srgb, var(--mat-sys-on-surface) 38%, transparent));background-color:var(--mat-fab-disabled-state-container-color, color-mix(in srgb, var(--mat-sys-on-surface) 12%, transparent))}.mat-mdc-fab.mat-mdc-button-disabled-interactive{pointer-events:auto}.mat-mdc-fab .mat-mdc-button-touch-target{position:absolute;top:50%;height:48px;left:50%;width:48px;transform:translate(-50%, -50%);display:var(--mat-fab-touch-target-display, block)}.mat-mdc-fab .mat-ripple-element{background-color:var(--mat-fab-ripple-color, color-mix(in srgb, var(--mat-sys-on-primary-container) calc(var(--mat-sys-pressed-state-layer-opacity) * 100%), transparent))}.mat-mdc-fab .mat-mdc-button-persistent-ripple::before{background-color:var(--mat-fab-state-layer-color, var(--mat-sys-on-primary-container))}.mat-mdc-fab.mat-mdc-button-disabled .mat-mdc-button-persistent-ripple::before{background-color:var(--mat-fab-disabled-state-layer-color)}.mat-mdc-fab:hover>.mat-mdc-button-persistent-ripple::before{opacity:var(--mat-fab-hover-state-layer-opacity, var(--mat-sys-hover-state-layer-opacity))}.mat-mdc-fab.cdk-program-focused>.mat-mdc-button-persistent-ripple::before,.mat-mdc-fab.cdk-keyboard-focused>.mat-mdc-button-persistent-ripple::before,.mat-mdc-fab.mat-mdc-button-disabled-interactive:focus>.mat-mdc-button-persistent-ripple::before{opacity:var(--mat-fab-focus-state-layer-opacity, var(--mat-sys-focus-state-layer-opacity))}.mat-mdc-fab:active>.mat-mdc-button-persistent-ripple::before{opacity:var(--mat-fab-pressed-state-layer-opacity, var(--mat-sys-pressed-state-layer-opacity))}.mat-mdc-mini-fab{width:40px;height:40px;background-color:var(--mdc-fab-small-container-color, var(--mat-sys-primary-container));border-radius:var(--mdc-fab-small-container-shape, var(--mat-sys-corner-medium));color:var(--mat-fab-small-foreground-color, var(--mat-sys-on-primary-container, inherit));box-shadow:var(--mdc-fab-small-container-elevation-shadow, var(--mat-sys-level3))}.mat-mdc-mini-fab:hover{box-shadow:var(--mdc-fab-small-hover-container-elevation-shadow, var(--mat-sys-level4))}.mat-mdc-mini-fab:focus{box-shadow:var(--mdc-fab-small-focus-container-elevation-shadow, var(--mat-sys-level3))}.mat-mdc-mini-fab:active,.mat-mdc-mini-fab:focus:active{box-shadow:var(--mdc-fab-small-pressed-container-elevation-shadow, var(--mat-sys-level3))}.mat-mdc-mini-fab[disabled],.mat-mdc-mini-fab.mat-mdc-button-disabled{cursor:default;pointer-events:none;color:var(--mat-fab-small-disabled-state-foreground-color, color-mix(in srgb, var(--mat-sys-on-surface) 38%, transparent));background-color:var(--mat-fab-small-disabled-state-container-color, color-mix(in srgb, var(--mat-sys-on-surface) 12%, transparent))}.mat-mdc-mini-fab.mat-mdc-button-disabled-interactive{pointer-events:auto}.mat-mdc-mini-fab .mat-mdc-button-touch-target{position:absolute;top:50%;height:48px;left:50%;width:48px;transform:translate(-50%, -50%);display:var(--mat-fab-small-touch-target-display)}.mat-mdc-mini-fab .mat-ripple-element{background-color:var(--mat-fab-small-ripple-color, color-mix(in srgb, var(--mat-sys-on-primary-container) calc(var(--mat-sys-pressed-state-layer-opacity) * 100%), transparent))}.mat-mdc-mini-fab .mat-mdc-button-persistent-ripple::before{background-color:var(--mat-fab-small-state-layer-color, var(--mat-sys-on-primary-container))}.mat-mdc-mini-fab.mat-mdc-button-disabled .mat-mdc-button-persistent-ripple::before{background-color:var(--mat-fab-small-disabled-state-layer-color)}.mat-mdc-mini-fab:hover>.mat-mdc-button-persistent-ripple::before{opacity:var(--mat-fab-small-hover-state-layer-opacity, var(--mat-sys-hover-state-layer-opacity))}.mat-mdc-mini-fab.cdk-program-focused>.mat-mdc-button-persistent-ripple::before,.mat-mdc-mini-fab.cdk-keyboard-focused>.mat-mdc-button-persistent-ripple::before,.mat-mdc-mini-fab.mat-mdc-button-disabled-interactive:focus>.mat-mdc-button-persistent-ripple::before{opacity:var(--mat-fab-small-focus-state-layer-opacity, var(--mat-sys-focus-state-layer-opacity))}.mat-mdc-mini-fab:active>.mat-mdc-button-persistent-ripple::before{opacity:var(--mat-fab-small-pressed-state-layer-opacity, var(--mat-sys-pressed-state-layer-opacity))}.mat-mdc-extended-fab{-moz-osx-font-smoothing:grayscale;-webkit-font-smoothing:antialiased;border-radius:24px;padding-left:20px;padding-right:20px;width:auto;max-width:100%;line-height:normal;height:var(--mdc-extended-fab-container-height, 56px);border-radius:var(--mdc-extended-fab-container-shape, var(--mat-sys-corner-large));font-family:var(--mdc-extended-fab-label-text-font, var(--mat-sys-label-large-font));font-size:var(--mdc-extended-fab-label-text-size, var(--mat-sys-label-large-size));font-weight:var(--mdc-extended-fab-label-text-weight, var(--mat-sys-label-large-weight));letter-spacing:var(--mdc-extended-fab-label-text-tracking, var(--mat-sys-label-large-tracking));box-shadow:var(--mdc-extended-fab-container-elevation-shadow, var(--mat-sys-level3))}.mat-mdc-extended-fab:hover{box-shadow:var(--mdc-extended-fab-hover-container-elevation-shadow, var(--mat-sys-level4))}.mat-mdc-extended-fab:focus{box-shadow:var(--mdc-extended-fab-focus-container-elevation-shadow, var(--mat-sys-level3))}.mat-mdc-extended-fab:active,.mat-mdc-extended-fab:focus:active{box-shadow:var(--mdc-extended-fab-pressed-container-elevation-shadow, var(--mat-sys-level3))}.mat-mdc-extended-fab[disabled],.mat-mdc-extended-fab.mat-mdc-button-disabled{cursor:default;pointer-events:none}.mat-mdc-extended-fab[disabled],.mat-mdc-extended-fab[disabled]:focus,.mat-mdc-extended-fab.mat-mdc-button-disabled,.mat-mdc-extended-fab.mat-mdc-button-disabled:focus{box-shadow:none}.mat-mdc-extended-fab.mat-mdc-button-disabled-interactive{pointer-events:auto}[dir=rtl] .mat-mdc-extended-fab .mdc-button__label+.mat-icon,[dir=rtl] .mat-mdc-extended-fab .mdc-button__label+.material-icons,.mat-mdc-extended-fab>.mat-icon,.mat-mdc-extended-fab>.material-icons{margin-left:-8px;margin-right:12px}.mat-mdc-extended-fab .mdc-button__label+.mat-icon,.mat-mdc-extended-fab .mdc-button__label+.material-icons,[dir=rtl] .mat-mdc-extended-fab>.mat-icon,[dir=rtl] .mat-mdc-extended-fab>.material-icons{margin-left:12px;margin-right:-8px}.mat-mdc-extended-fab .mat-mdc-button-touch-target{width:100%}'],encapsulation:2,changeDetection:0})}return t})(),HO=(()=>{class t extends X6{_options=m(JO,{optional:!0});_isFab=!0;constructor(){super(),this._options=this._options||W6,this.color=this._options.color||W6.color}static \u0275fac=function(i){return new(i||t)};static \u0275cmp=YA({type:t,selectors:[["button","mat-mini-fab",""]],hostVars:14,hostBindings:function(i,n){i&2&&(_e("disabled",n._getDisabledAttribute())("aria-disabled",n._getAriaDisabled()),vo(n.color?"mat-"+n.color:""),ue("mat-mdc-button-disabled",n.disabled)("mat-mdc-button-disabled-interactive",n.disabledInteractive)("_mat-animation-noopable",n._animationMode==="NoopAnimations")("mat-unthemed",!n.color)("mat-mdc-button-base",!0))},exportAs:["matButton"],features:[et],attrs:ruA,ngContentSelectors:Bk,decls:7,vars:4,consts:[[1,"mat-mdc-button-persistent-ripple"],[1,"mdc-button__label"],[1,"mat-focus-indicator"],[1,"mat-mdc-button-touch-target"]],template:function(i,n){i&1&&(Yt(dk),UA(0,"span",0),xe(1),S(2,"span",1),xe(3,1),R(),xe(4,2),UA(5,"span",2)(6,"span",3)),i&2&&ue("mdc-button__ripple",!n._isFab)("mdc-fab__ripple",n._isFab)},styles:[suA],encapsulation:2,changeDetection:0})}return t})();var EB=(()=>{class t extends X6{constructor(){super(),this._rippleLoader.configureRipple(this._elementRef.nativeElement,{centered:!0})}static \u0275fac=function(i){return new(i||t)};static \u0275cmp=YA({type:t,selectors:[["button","mat-icon-button",""]],hostVars:14,hostBindings:function(i,n){i&2&&(_e("disabled",n._getDisabledAttribute())("aria-disabled",n._getAriaDisabled()),vo(n.color?"mat-"+n.color:""),ue("mat-mdc-button-disabled",n.disabled)("mat-mdc-button-disabled-interactive",n.disabledInteractive)("_mat-animation-noopable",n._animationMode==="NoopAnimations")("mat-unthemed",!n.color)("mat-mdc-button-base",!0))},exportAs:["matButton"],features:[et],attrs:auA,ngContentSelectors:cuA,decls:4,vars:0,consts:[[1,"mat-mdc-button-persistent-ripple","mdc-icon-button__ripple"],[1,"mat-focus-indicator"],[1,"mat-mdc-button-touch-target"]],template:function(i,n){i&1&&(Yt(),UA(0,"span",0),xe(1),UA(2,"span",1)(3,"span",2))},styles:['.mat-mdc-icon-button{-webkit-user-select:none;user-select:none;display:inline-block;position:relative;box-sizing:border-box;border:none;outline:none;background-color:rgba(0,0,0,0);fill:currentColor;color:inherit;text-decoration:none;cursor:pointer;z-index:0;overflow:visible;border-radius:50%;flex-shrink:0;text-align:center;width:var(--mdc-icon-button-state-layer-size, 40px);height:var(--mdc-icon-button-state-layer-size, 40px);padding:calc(calc(var(--mdc-icon-button-state-layer-size, 40px) - var(--mdc-icon-button-icon-size, 24px)) / 2);font-size:var(--mdc-icon-button-icon-size, 24px);color:var(--mdc-icon-button-icon-color, var(--mat-sys-on-surface-variant));-webkit-tap-highlight-color:rgba(0,0,0,0)}.mat-mdc-icon-button .mat-mdc-button-ripple,.mat-mdc-icon-button .mat-mdc-button-persistent-ripple,.mat-mdc-icon-button .mat-mdc-button-persistent-ripple::before{top:0;left:0;right:0;bottom:0;position:absolute;pointer-events:none;border-radius:inherit}.mat-mdc-icon-button .mat-mdc-button-ripple{overflow:hidden}.mat-mdc-icon-button .mat-mdc-button-persistent-ripple::before{content:"";opacity:0}.mat-mdc-icon-button .mdc-button__label,.mat-mdc-icon-button .mat-icon{z-index:1;position:relative}.mat-mdc-icon-button .mat-focus-indicator{top:0;left:0;right:0;bottom:0;position:absolute}.mat-mdc-icon-button:focus>.mat-focus-indicator::before{content:""}.mat-mdc-icon-button .mat-ripple-element{background-color:var(--mat-icon-button-ripple-color, color-mix(in srgb, var(--mat-sys-on-surface-variant) calc(var(--mat-sys-pressed-state-layer-opacity) * 100%), transparent))}.mat-mdc-icon-button .mat-mdc-button-persistent-ripple::before{background-color:var(--mat-icon-button-state-layer-color, var(--mat-sys-on-surface-variant))}.mat-mdc-icon-button.mat-mdc-button-disabled .mat-mdc-button-persistent-ripple::before{background-color:var(--mat-icon-button-disabled-state-layer-color, var(--mat-sys-on-surface-variant))}.mat-mdc-icon-button:hover>.mat-mdc-button-persistent-ripple::before{opacity:var(--mat-icon-button-hover-state-layer-opacity, var(--mat-sys-hover-state-layer-opacity))}.mat-mdc-icon-button.cdk-program-focused>.mat-mdc-button-persistent-ripple::before,.mat-mdc-icon-button.cdk-keyboard-focused>.mat-mdc-button-persistent-ripple::before,.mat-mdc-icon-button.mat-mdc-button-disabled-interactive:focus>.mat-mdc-button-persistent-ripple::before{opacity:var(--mat-icon-button-focus-state-layer-opacity, var(--mat-sys-focus-state-layer-opacity))}.mat-mdc-icon-button:active>.mat-mdc-button-persistent-ripple::before{opacity:var(--mat-icon-button-pressed-state-layer-opacity, var(--mat-sys-pressed-state-layer-opacity))}.mat-mdc-icon-button .mat-mdc-button-touch-target{position:absolute;top:50%;height:48px;left:50%;width:48px;transform:translate(-50%, -50%);display:var(--mat-icon-button-touch-target-display, block)}.mat-mdc-icon-button._mat-animation-noopable{transition:none !important;animation:none !important}.mat-mdc-icon-button[disabled],.mat-mdc-icon-button.mat-mdc-button-disabled{cursor:default;pointer-events:none;color:var(--mdc-icon-button-disabled-icon-color, color-mix(in srgb, var(--mat-sys-on-surface) 38%, transparent))}.mat-mdc-icon-button.mat-mdc-button-disabled-interactive{pointer-events:auto}.mat-mdc-icon-button img,.mat-mdc-icon-button svg{width:var(--mdc-icon-button-icon-size, 24px);height:var(--mdc-icon-button-icon-size, 24px);vertical-align:baseline}.mat-mdc-icon-button .mat-mdc-button-persistent-ripple{border-radius:50%}.mat-mdc-icon-button[hidden]{display:none}.mat-mdc-icon-button.mat-unthemed:not(.mdc-ripple-upgraded):focus::before,.mat-mdc-icon-button.mat-primary:not(.mdc-ripple-upgraded):focus::before,.mat-mdc-icon-button.mat-accent:not(.mdc-ripple-upgraded):focus::before,.mat-mdc-icon-button.mat-warn:not(.mdc-ripple-upgraded):focus::before{background:rgba(0,0,0,0);opacity:1}',nuA],encapsulation:2,changeDetection:0})}return t})();var KI=(()=>{class t{static \u0275fac=function(i){return new(i||t)};static \u0275mod=ge({type:t});static \u0275inj=le({imports:[Ve,Xa,Ve]})}return t})();var $6=class{};function A8(t){return t&&typeof t.connect=="function"&&!(t instanceof r2)}var hB=function(t){return t[t.REPLACED=0]="REPLACED",t[t.INSERTED=1]="INSERTED",t[t.MOVED=2]="MOVED",t[t.REMOVED=3]="REMOVED",t}(hB||{}),Qu=new BA("_ViewRepeater"),QB=class{applyChanges(e,A,i,n,o){e.forEachOperation((r,s,a)=>{let c,l;if(r.previousIndex==null){let I=i(r,s,a);c=A.createEmbeddedView(I.templateRef,I.context,I.index),l=hB.INSERTED}else a==null?(A.remove(s),l=hB.REMOVED):(c=A.get(s),A.move(c,a),l=hB.MOVED);o&&o({context:c?.context,operation:l,record:r})})}detach(){}};var F2=class{_multiple;_emitChanges;compareWith;_selection=new Set;_deselectedToEmit=[];_selectedToEmit=[];_selected;get selected(){return this._selected||(this._selected=Array.from(this._selection.values())),this._selected}changed=new HA;constructor(e=!1,A,i=!0,n){this._multiple=e,this._emitChanges=i,this.compareWith=n,A&&A.length&&(e?A.forEach(o=>this._markSelected(o)):this._markSelected(A[0]),this._selectedToEmit.length=0)}select(...e){this._verifyValueAssignment(e),e.forEach(i=>this._markSelected(i));let A=this._hasQueuedChanges();return this._emitChangeEvent(),A}deselect(...e){this._verifyValueAssignment(e),e.forEach(i=>this._unmarkSelected(i));let A=this._hasQueuedChanges();return this._emitChangeEvent(),A}setSelection(...e){this._verifyValueAssignment(e);let A=this.selected,i=new Set(e);e.forEach(o=>this._markSelected(o)),A.filter(o=>!i.has(this._getConcreteValue(o,i))).forEach(o=>this._unmarkSelected(o));let n=this._hasQueuedChanges();return this._emitChangeEvent(),n}toggle(e){return this.isSelected(e)?this.deselect(e):this.select(e)}clear(e=!0){this._unmarkAll();let A=this._hasQueuedChanges();return e&&this._emitChangeEvent(),A}isSelected(e){return this._selection.has(this._getConcreteValue(e))}isEmpty(){return this._selection.size===0}hasValue(){return!this.isEmpty()}sort(e){this._multiple&&this.selected&&this._selected.sort(e)}isMultipleSelection(){return this._multiple}_emitChangeEvent(){this._selected=null,(this._selectedToEmit.length||this._deselectedToEmit.length)&&(this.changed.next({source:this,added:this._selectedToEmit,removed:this._deselectedToEmit}),this._deselectedToEmit=[],this._selectedToEmit=[])}_markSelected(e){e=this._getConcreteValue(e),this.isSelected(e)||(this._multiple||this._unmarkAll(),this.isSelected(e)||this._selection.add(e),this._emitChanges&&this._selectedToEmit.push(e))}_unmarkSelected(e){e=this._getConcreteValue(e),this.isSelected(e)&&(this._selection.delete(e),this._emitChanges&&this._deselectedToEmit.push(e))}_unmarkAll(){this.isEmpty()||this._selection.forEach(e=>this._unmarkSelected(e))}_verifyValueAssignment(e){e.length>1&&this._multiple}_hasQueuedChanges(){return!!(this._deselectedToEmit.length||this._selectedToEmit.length)}_getConcreteValue(e,A){if(this.compareWith){A=A??this._selection;for(let i of A)if(this.compareWith(e,i))return i;return e}else return e}};var uB=(()=>{class t{_listeners=[];notify(A,i){for(let n of this._listeners)n(A,i)}listen(A){return this._listeners.push(A),()=>{this._listeners=this._listeners.filter(i=>A!==i)}}ngOnDestroy(){this._listeners=[]}static \u0275fac=function(i){return new(i||t)};static \u0275prov=SA({token:t,factory:t.\u0275fac,providedIn:"root"})}return t})();var IuA=20,N2=(()=>{class t{_ngZone=m(de);_platform=m(Zt);_renderer=m(ds).createRenderer(null,null);_cleanupGlobalListener;constructor(){}_scrolled=new HA;_scrolledCount=0;scrollContainers=new Map;register(A){this.scrollContainers.has(A)||this.scrollContainers.set(A,A.elementScrolled().subscribe(()=>this._scrolled.next(A)))}deregister(A){let i=this.scrollContainers.get(A);i&&(i.unsubscribe(),this.scrollContainers.delete(A))}scrolled(A=IuA){return this._platform.isBrowser?new Ze(i=>{this._cleanupGlobalListener||(this._cleanupGlobalListener=this._ngZone.runOutsideAngular(()=>this._renderer.listen("document","scroll",()=>this._scrolled.next())));let n=A>0?this._scrolled.pipe(Cd(A)).subscribe(i):this._scrolled.subscribe(i);return this._scrolledCount++,()=>{n.unsubscribe(),this._scrolledCount--,this._scrolledCount||(this._cleanupGlobalListener?.(),this._cleanupGlobalListener=void 0)}}):ve()}ngOnDestroy(){this._cleanupGlobalListener?.(),this._cleanupGlobalListener=void 0,this.scrollContainers.forEach((A,i)=>this.deregister(i)),this._scrolled.complete()}ancestorScrolled(A,i){let n=this.getAncestorScrollContainers(A);return this.scrolled(i).pipe(pt(o=>!o||n.indexOf(o)>-1))}getAncestorScrollContainers(A){let i=[];return this.scrollContainers.forEach((n,o)=>{this._scrollableContainsElement(o,A)&&i.push(o)}),i}_scrollableContainsElement(A,i){let n=sa(i),o=A.getElementRef().nativeElement;do if(n==o)return!0;while(n=n.parentElement);return!1}static \u0275fac=function(i){return new(i||t)};static \u0275prov=SA({token:t,factory:t.\u0275fac,providedIn:"root"})}return t})(),h0=(()=>{class t{elementRef=m(te);scrollDispatcher=m(N2);ngZone=m(de);dir=m(bo,{optional:!0});_scrollElement=this.elementRef.nativeElement;_destroyed=new HA;_renderer=m(Gi);_cleanupScroll;_elementScrolled=new HA;constructor(){}ngOnInit(){this._cleanupScroll=this.ngZone.runOutsideAngular(()=>this._renderer.listen(this._scrollElement,"scroll",A=>this._elementScrolled.next(A))),this.scrollDispatcher.register(this)}ngOnDestroy(){this._cleanupScroll?.(),this._elementScrolled.complete(),this.scrollDispatcher.deregister(this),this._destroyed.next(),this._destroyed.complete()}elementScrolled(){return this._elementScrolled}getElementRef(){return this.elementRef}scrollTo(A){let i=this.elementRef.nativeElement,n=this.dir&&this.dir.value=="rtl";A.left==null&&(A.left=n?A.end:A.start),A.right==null&&(A.right=n?A.start:A.end),A.bottom!=null&&(A.top=i.scrollHeight-i.clientHeight-A.bottom),n&&aB()!=ol.NORMAL?(A.left!=null&&(A.right=i.scrollWidth-i.clientWidth-A.left),aB()==ol.INVERTED?A.left=A.right:aB()==ol.NEGATED&&(A.left=A.right?-A.right:A.right)):A.right!=null&&(A.left=i.scrollWidth-i.clientWidth-A.right),this._applyScrollToOptions(A)}_applyScrollToOptions(A){let i=this.elementRef.nativeElement;x6()?i.scrollTo(A):(A.top!=null&&(i.scrollTop=A.top),A.left!=null&&(i.scrollLeft=A.left))}measureScrollOffset(A){let i="left",n="right",o=this.elementRef.nativeElement;if(A=="top")return o.scrollTop;if(A=="bottom")return o.scrollHeight-o.clientHeight-o.scrollTop;let r=this.dir&&this.dir.value=="rtl";return A=="start"?A=r?n:i:A=="end"&&(A=r?i:n),r&&aB()==ol.INVERTED?A==i?o.scrollWidth-o.clientWidth-o.scrollLeft:o.scrollLeft:r&&aB()==ol.NEGATED?A==i?o.scrollLeft+o.scrollWidth-o.clientWidth:-o.scrollLeft:A==i?o.scrollLeft:o.scrollWidth-o.clientWidth-o.scrollLeft}static \u0275fac=function(i){return new(i||t)};static \u0275dir=OA({type:t,selectors:[["","cdk-scrollable",""],["","cdkScrollable",""]]})}return t})(),CuA=20,mc=(()=>{class t{_platform=m(Zt);_listeners;_viewportSize;_change=new HA;_document=m(tt,{optional:!0});constructor(){let A=m(de),i=m(ds).createRenderer(null,null);A.runOutsideAngular(()=>{if(this._platform.isBrowser){let n=o=>this._change.next(o);this._listeners=[i.listen("window","resize",n),i.listen("window","orientationchange",n)]}this.change().subscribe(()=>this._viewportSize=null)})}ngOnDestroy(){this._listeners?.forEach(A=>A()),this._change.complete()}getViewportSize(){this._viewportSize||this._updateViewportSize();let A={width:this._viewportSize.width,height:this._viewportSize.height};return this._platform.isBrowser||(this._viewportSize=null),A}getViewportRect(){let A=this.getViewportScrollPosition(),{width:i,height:n}=this.getViewportSize();return{top:A.top,left:A.left,bottom:A.top+n,right:A.left+i,height:n,width:i}}getViewportScrollPosition(){if(!this._platform.isBrowser)return{top:0,left:0};let A=this._document,i=this._getWindow(),n=A.documentElement,o=n.getBoundingClientRect(),r=-o.top||A.body.scrollTop||i.scrollY||n.scrollTop||0,s=-o.left||A.body.scrollLeft||i.scrollX||n.scrollLeft||0;return{top:r,left:s}}change(A=CuA){return A>0?this._change.pipe(Cd(A)):this._change}_getWindow(){return this._document.defaultView||window}_updateViewportSize(){let A=this._getWindow();this._viewportSize=this._platform.isBrowser?{width:A.innerWidth,height:A.innerHeight}:{width:0,height:0}}static \u0275fac=function(i){return new(i||t)};static \u0275prov=SA({token:t,factory:t.\u0275fac,providedIn:"root"})}return t})();var E0=(()=>{class t{static \u0275fac=function(i){return new(i||t)};static \u0275mod=ge({type:t});static \u0275inj=le({})}return t})(),uu=(()=>{class t{static \u0275fac=function(i){return new(i||t)};static \u0275mod=ge({type:t});static \u0275inj=le({imports:[R2,E0,R2,E0]})}return t})();var fu=class{_attachedHost;attach(e){return this._attachedHost=e,e.attach(this)}detach(){let e=this._attachedHost;e!=null&&(this._attachedHost=null,e.detach())}get isAttached(){return this._attachedHost!=null}setAttachedHost(e){this._attachedHost=e}},sl=class extends fu{component;viewContainerRef;injector;componentFactoryResolver;projectableNodes;constructor(e,A,i,n,o){super(),this.component=e,this.viewContainerRef=A,this.injector=i,this.projectableNodes=o}},aa=class extends fu{templateRef;viewContainerRef;context;injector;constructor(e,A,i,n){super(),this.templateRef=e,this.viewContainerRef=A,this.context=i,this.injector=n}get origin(){return this.templateRef.elementRef}attach(e,A=this.context){return this.context=A,super.attach(e)}detach(){return this.context=void 0,super.detach()}},Ek=class extends fu{element;constructor(e){super(),this.element=e instanceof te?e.nativeElement:e}},_2=class{_attachedPortal;_disposeFn;_isDisposed=!1;hasAttached(){return!!this._attachedPortal}attach(e){if(e instanceof sl)return this._attachedPortal=e,this.attachComponentPortal(e);if(e instanceof aa)return this._attachedPortal=e,this.attachTemplatePortal(e);if(this.attachDomPortal&&e instanceof Ek)return this._attachedPortal=e,this.attachDomPortal(e)}attachDomPortal=null;detach(){this._attachedPortal&&(this._attachedPortal.setAttachedHost(null),this._attachedPortal=null),this._invokeDisposeFn()}dispose(){this.hasAttached()&&this.detach(),this._invokeDisposeFn(),this._isDisposed=!0}setDisposeFn(e){this._disposeFn=e}_invokeDisposeFn(){this._disposeFn&&(this._disposeFn(),this._disposeFn=null)}};var e8=class extends _2{outletElement;_appRef;_defaultInjector;_document;constructor(e,A,i,n,o){super(),this.outletElement=e,this._appRef=i,this._defaultInjector=n,this._document=o}attachComponentPortal(e){let A;if(e.viewContainerRef){let i=e.injector||e.viewContainerRef.injector,n=i.get(i0,null,{optional:!0})||void 0;A=e.viewContainerRef.createComponent(e.component,{index:e.viewContainerRef.length,injector:i,ngModuleRef:n,projectableNodes:e.projectableNodes||void 0}),this.setDisposeFn(()=>A.destroy())}else A=wp(e.component,{elementInjector:e.injector||this._defaultInjector||Dt.NULL,environmentInjector:this._appRef.injector,projectableNodes:e.projectableNodes||void 0}),this._appRef.attachView(A.hostView),this.setDisposeFn(()=>{this._appRef.viewCount>0&&this._appRef.detachView(A.hostView),A.destroy()});return this.outletElement.appendChild(this._getComponentRootNode(A)),this._attachedPortal=e,A}attachTemplatePortal(e){let A=e.viewContainerRef,i=A.createEmbeddedView(e.templateRef,e.context,{injector:e.injector});return i.rootNodes.forEach(n=>this.outletElement.appendChild(n)),i.detectChanges(),this.setDisposeFn(()=>{let n=A.indexOf(i);n!==-1&&A.remove(n)}),this._attachedPortal=e,i}attachDomPortal=e=>{let A=e.element;A.parentNode;let i=this._document.createComment("dom-portal");A.parentNode.insertBefore(i,A),this.outletElement.appendChild(A),this._attachedPortal=e,super.setDisposeFn(()=>{i.parentNode&&i.parentNode.replaceChild(A,i)})};dispose(){super.dispose(),this.outletElement.remove()}_getComponentRootNode(e){return e.hostView.rootNodes[0]}};var OO=(()=>{class t extends aa{constructor(){let A=m(vn),i=m(Un);super(A,i)}static \u0275fac=function(i){return new(i||t)};static \u0275dir=OA({type:t,selectors:[["","cdkPortal",""]],exportAs:["cdkPortal"],features:[et]})}return t})();var ca=(()=>{class t extends _2{_moduleRef=m(i0,{optional:!0});_document=m(tt);_viewContainerRef=m(Un);_isInitialized=!1;_attachedRef;constructor(){super()}get portal(){return this._attachedPortal}set portal(A){this.hasAttached()&&!A&&!this._isInitialized||(this.hasAttached()&&super.detach(),A&&super.attach(A),this._attachedPortal=A||null)}attached=new XA;get attachedRef(){return this._attachedRef}ngOnInit(){this._isInitialized=!0}ngOnDestroy(){super.dispose(),this._attachedRef=this._attachedPortal=null}attachComponentPortal(A){A.setAttachedHost(this);let i=A.viewContainerRef!=null?A.viewContainerRef:this._viewContainerRef,n=i.createComponent(A.component,{index:i.length,injector:A.injector||i.injector,projectableNodes:A.projectableNodes||void 0,ngModuleRef:this._moduleRef||void 0});return i!==this._viewContainerRef&&this._getRootNode().appendChild(n.hostView.rootNodes[0]),super.setDisposeFn(()=>n.destroy()),this._attachedPortal=A,this._attachedRef=n,this.attached.emit(n),n}attachTemplatePortal(A){A.setAttachedHost(this);let i=this._viewContainerRef.createEmbeddedView(A.templateRef,A.context,{injector:A.injector});return super.setDisposeFn(()=>this._viewContainerRef.clear()),this._attachedPortal=A,this._attachedRef=i,this.attached.emit(i),i}attachDomPortal=A=>{let i=A.element;i.parentNode;let n=this._document.createComment("dom-portal");A.setAttachedHost(this),i.parentNode.insertBefore(n,i),this._getRootNode().appendChild(i),this._attachedPortal=A,super.setDisposeFn(()=>{n.parentNode&&n.parentNode.replaceChild(i,n)})};_getRootNode(){let A=this._viewContainerRef.element.nativeElement;return A.nodeType===A.ELEMENT_NODE?A:A.parentNode}static \u0275fac=function(i){return new(i||t)};static \u0275dir=OA({type:t,selectors:[["","cdkPortalOutlet",""]],inputs:{portal:[0,"cdkPortalOutlet","portal"]},outputs:{attached:"attached"},exportAs:["cdkPortalOutlet"],features:[et]})}return t})();var sg=(()=>{class t{static \u0275fac=function(i){return new(i||t)};static \u0275mod=ge({type:t});static \u0275inj=le({})}return t})();var PO=x6(),hk=class{_viewportRuler;_previousHTMLStyles={top:"",left:""};_previousScrollPosition;_isEnabled=!1;_document;constructor(e,A){this._viewportRuler=e,this._document=A}attach(){}enable(){if(this._canBeEnabled()){let e=this._document.documentElement;this._previousScrollPosition=this._viewportRuler.getViewportScrollPosition(),this._previousHTMLStyles.left=e.style.left||"",this._previousHTMLStyles.top=e.style.top||"",e.style.left=sr(-this._previousScrollPosition.left),e.style.top=sr(-this._previousScrollPosition.top),e.classList.add("cdk-global-scrollblock"),this._isEnabled=!0}}disable(){if(this._isEnabled){let e=this._document.documentElement,A=this._document.body,i=e.style,n=A.style,o=i.scrollBehavior||"",r=n.scrollBehavior||"";this._isEnabled=!1,i.left=this._previousHTMLStyles.left,i.top=this._previousHTMLStyles.top,e.classList.remove("cdk-global-scrollblock"),PO&&(i.scrollBehavior=n.scrollBehavior="auto"),window.scroll(this._previousScrollPosition.left,this._previousScrollPosition.top),PO&&(i.scrollBehavior=o,n.scrollBehavior=r)}}_canBeEnabled(){if(this._document.documentElement.classList.contains("cdk-global-scrollblock")||this._isEnabled)return!1;let A=this._document.body,i=this._viewportRuler.getViewportSize();return A.scrollHeight>i.height||A.scrollWidth>i.width}};var Qk=class{_scrollDispatcher;_ngZone;_viewportRuler;_config;_scrollSubscription=null;_overlayRef;_initialScrollPosition;constructor(e,A,i,n){this._scrollDispatcher=e,this._ngZone=A,this._viewportRuler=i,this._config=n}attach(e){this._overlayRef,this._overlayRef=e}enable(){if(this._scrollSubscription)return;let e=this._scrollDispatcher.scrolled(0).pipe(pt(A=>!A||!this._overlayRef.overlayElement.contains(A.getElementRef().nativeElement)));this._config&&this._config.threshold&&this._config.threshold>1?(this._initialScrollPosition=this._viewportRuler.getViewportScrollPosition().top,this._scrollSubscription=e.subscribe(()=>{let A=this._viewportRuler.getViewportScrollPosition().top;Math.abs(A-this._initialScrollPosition)>this._config.threshold?this._detach():this._overlayRef.updatePosition()})):this._scrollSubscription=e.subscribe(this._detach)}disable(){this._scrollSubscription&&(this._scrollSubscription.unsubscribe(),this._scrollSubscription=null)}detach(){this.disable(),this._overlayRef=null}_detach=()=>{this.disable(),this._overlayRef.hasAttached()&&this._ngZone.run(()=>this._overlayRef.detach())}},t8=class{enable(){}disable(){}attach(){}};function uk(t,e){return e.some(A=>{let i=t.bottom<A.top,n=t.top>A.bottom,o=t.right<A.left,r=t.left>A.right;return i||n||o||r})}function jO(t,e){return e.some(A=>{let i=t.top<A.top,n=t.bottom>A.bottom,o=t.left<A.left,r=t.right>A.right;return i||n||o||r})}var fk=class{_scrollDispatcher;_viewportRuler;_ngZone;_config;_scrollSubscription=null;_overlayRef;constructor(e,A,i,n){this._scrollDispatcher=e,this._viewportRuler=A,this._ngZone=i,this._config=n}attach(e){this._overlayRef,this._overlayRef=e}enable(){if(!this._scrollSubscription){let e=this._config?this._config.scrollThrottle:0;this._scrollSubscription=this._scrollDispatcher.scrolled(e).subscribe(()=>{if(this._overlayRef.updatePosition(),this._config&&this._config.autoClose){let A=this._overlayRef.overlayElement.getBoundingClientRect(),{width:i,height:n}=this._viewportRuler.getViewportSize();uk(A,[{width:i,height:n,bottom:n,right:i,top:0,left:0}])&&(this.disable(),this._ngZone.run(()=>this._overlayRef.detach()))}})}}disable(){this._scrollSubscription&&(this._scrollSubscription.unsubscribe(),this._scrollSubscription=null)}detach(){this.disable(),this._overlayRef=null}},BuA=(()=>{class t{_scrollDispatcher=m(N2);_viewportRuler=m(mc);_ngZone=m(de);_document=m(tt);constructor(){}noop=()=>new t8;close=A=>new Qk(this._scrollDispatcher,this._ngZone,this._viewportRuler,A);block=()=>new hk(this._viewportRuler,this._document);reposition=A=>new fk(this._scrollDispatcher,this._viewportRuler,this._ngZone,A);static \u0275fac=function(i){return new(i||t)};static \u0275prov=SA({token:t,factory:t.\u0275fac,providedIn:"root"})}return t})(),G2=class{positionStrategy;scrollStrategy=new t8;panelClass="";hasBackdrop=!1;backdropClass="cdk-overlay-dark-backdrop";width;height;minWidth;minHeight;maxWidth;maxHeight;direction;disposeOnNavigation=!1;constructor(e){if(e){let A=Object.keys(e);for(let i of A)e[i]!==void 0&&(this[i]=e[i])}}};var mk=class{connectionPair;scrollableViewProperties;constructor(e,A){this.connectionPair=e,this.scrollableViewProperties=A}};var $O=(()=>{class t{_attachedOverlays=[];_document=m(tt);_isAttached;constructor(){}ngOnDestroy(){this.detach()}add(A){this.remove(A),this._attachedOverlays.push(A)}remove(A){let i=this._attachedOverlays.indexOf(A);i>-1&&this._attachedOverlays.splice(i,1),this._attachedOverlays.length===0&&this.detach()}static \u0275fac=function(i){return new(i||t)};static \u0275prov=SA({token:t,factory:t.\u0275fac,providedIn:"root"})}return t})(),EuA=(()=>{class t extends $O{_ngZone=m(de);_renderer=m(ds).createRenderer(null,null);_cleanupKeydown;add(A){super.add(A),this._isAttached||(this._ngZone.runOutsideAngular(()=>{this._cleanupKeydown=this._renderer.listen("body","keydown",this._keydownListener)}),this._isAttached=!0)}detach(){this._isAttached&&(this._cleanupKeydown?.(),this._isAttached=!1)}_keydownListener=A=>{let i=this._attachedOverlays;for(let n=i.length-1;n>-1;n--)if(i[n]._keydownEvents.observers.length>0){this._ngZone.run(()=>i[n]._keydownEvents.next(A));break}};static \u0275fac=(()=>{let A;return function(n){return(A||(A=bi(t)))(n||t)}})();static \u0275prov=SA({token:t,factory:t.\u0275fac,providedIn:"root"})}return t})(),huA=(()=>{class t extends $O{_platform=m(Zt);_ngZone=m(de,{optional:!0});_cursorOriginalValue;_cursorStyleIsSet=!1;_pointerDownEventTarget;add(A){if(super.add(A),!this._isAttached){let i=this._document.body;this._ngZone?this._ngZone.runOutsideAngular(()=>this._addEventListeners(i)):this._addEventListeners(i),this._platform.IOS&&!this._cursorStyleIsSet&&(this._cursorOriginalValue=i.style.cursor,i.style.cursor="pointer",this._cursorStyleIsSet=!0),this._isAttached=!0}}detach(){if(this._isAttached){let A=this._document.body;A.removeEventListener("pointerdown",this._pointerDownListener,!0),A.removeEventListener("click",this._clickListener,!0),A.removeEventListener("auxclick",this._clickListener,!0),A.removeEventListener("contextmenu",this._clickListener,!0),this._platform.IOS&&this._cursorStyleIsSet&&(A.style.cursor=this._cursorOriginalValue,this._cursorStyleIsSet=!1),this._isAttached=!1}}_addEventListeners(A){A.addEventListener("pointerdown",this._pointerDownListener,!0),A.addEventListener("click",this._clickListener,!0),A.addEventListener("auxclick",this._clickListener,!0),A.addEventListener("contextmenu",this._clickListener,!0)}_pointerDownListener=A=>{this._pointerDownEventTarget=Wa(A)};_clickListener=A=>{let i=Wa(A),n=A.type==="click"&&this._pointerDownEventTarget?this._pointerDownEventTarget:i;this._pointerDownEventTarget=null;let o=this._attachedOverlays.slice();for(let r=o.length-1;r>-1;r--){let s=o[r];if(s._outsidePointerEvents.observers.length<1||!s.hasAttached())continue;if(qO(s.overlayElement,i)||qO(s.overlayElement,n))break;let a=s._outsidePointerEvents;this._ngZone?this._ngZone.run(()=>a.next(A)):a.next(A)}};static \u0275fac=(()=>{let A;return function(n){return(A||(A=bi(t)))(n||t)}})();static \u0275prov=SA({token:t,factory:t.\u0275fac,providedIn:"root"})}return t})();function qO(t,e){let A=typeof ShadowRoot<"u"&&ShadowRoot,i=e;for(;i;){if(i===t)return!0;i=A&&i instanceof ShadowRoot?i.host:i.parentNode}return!1}var AP=(()=>{class t{static \u0275fac=function(i){return new(i||t)};static \u0275cmp=YA({type:t,selectors:[["ng-component"]],hostAttrs:["cdk-overlay-style-loader",""],decls:0,vars:0,template:function(i,n){},styles:[".cdk-overlay-container,.cdk-global-overlay-wrapper{pointer-events:none;top:0;left:0;height:100%;width:100%}.cdk-overlay-container{position:fixed}@layer cdk-overlay{.cdk-overlay-container{z-index:1000}}.cdk-overlay-container:empty{display:none}.cdk-global-overlay-wrapper{display:flex;position:absolute}@layer cdk-overlay{.cdk-global-overlay-wrapper{z-index:1000}}.cdk-overlay-pane{position:absolute;pointer-events:auto;box-sizing:border-box;display:flex;max-width:100%;max-height:100%}@layer cdk-overlay{.cdk-overlay-pane{z-index:1000}}.cdk-overlay-backdrop{position:absolute;top:0;bottom:0;left:0;right:0;pointer-events:auto;-webkit-tap-highlight-color:rgba(0,0,0,0);opacity:0}@layer cdk-overlay{.cdk-overlay-backdrop{z-index:1000;transition:opacity 400ms cubic-bezier(0.25, 0.8, 0.25, 1)}}.cdk-overlay-backdrop-showing{opacity:1}@media(forced-colors: active){.cdk-overlay-backdrop-showing{opacity:.6}}@layer cdk-overlay{.cdk-overlay-dark-backdrop{background:rgba(0,0,0,.32)}}.cdk-overlay-transparent-backdrop{transition:visibility 1ms linear,opacity 1ms linear;visibility:hidden;opacity:1}.cdk-overlay-transparent-backdrop.cdk-overlay-backdrop-showing,.cdk-high-contrast-active .cdk-overlay-transparent-backdrop{opacity:0;visibility:visible}.cdk-overlay-backdrop-noop-animation{transition:none}.cdk-overlay-connected-position-bounding-box{position:absolute;display:flex;flex-direction:column;min-width:1px;min-height:1px}@layer cdk-overlay{.cdk-overlay-connected-position-bounding-box{z-index:1000}}.cdk-global-scrollblock{position:fixed;width:100%;overflow-y:scroll}"],encapsulation:2,changeDetection:0})}return t})(),i8=(()=>{class t{_platform=m(Zt);_containerElement;_document=m(tt);_styleLoader=m(Ln);constructor(){}ngOnDestroy(){this._containerElement?.remove()}getContainerElement(){return this._loadStyles(),this._containerElement||this._createContainer(),this._containerElement}_createContainer(){let A="cdk-overlay-container";if(this._platform.isBrowser||zM()){let n=this._document.querySelectorAll(`.${A}[platform="server"], .${A}[platform="test"]`);for(let o=0;o<n.length;o++)n[o].remove()}let i=this._document.createElement("div");i.classList.add(A),zM()?i.setAttribute("platform","test"):this._platform.isBrowser||i.setAttribute("platform","server"),this._document.body.appendChild(i),this._containerElement=i}_loadStyles(){this._styleLoader.load(AP)}static \u0275fac=function(i){return new(i||t)};static \u0275prov=SA({token:t,factory:t.\u0275fac,providedIn:"root"})}return t})(),pk=class{_renderer;_ngZone;element;_cleanupClick;_cleanupTransitionEnd;_fallbackTimeout;constructor(e,A,i,n){this._renderer=A,this._ngZone=i,this.element=e.createElement("div"),this.element.classList.add("cdk-overlay-backdrop"),this._cleanupClick=A.listen(this.element,"click",n)}detach(){this._ngZone.runOutsideAngular(()=>{let e=this.element;clearTimeout(this._fallbackTimeout),this._cleanupTransitionEnd?.(),this._cleanupTransitionEnd=this._renderer.listen(e,"transitionend",this.dispose),this._fallbackTimeout=setTimeout(this.dispose,500),e.style.pointerEvents="none",e.classList.remove("cdk-overlay-backdrop-showing")})}dispose=()=>{clearTimeout(this._fallbackTimeout),this._cleanupClick?.(),this._cleanupTransitionEnd?.(),this._cleanupClick=this._cleanupTransitionEnd=this._fallbackTimeout=void 0,this.element.remove()}},fB=class{_portalOutlet;_host;_pane;_config;_ngZone;_keyboardDispatcher;_document;_location;_outsideClickDispatcher;_animationsDisabled;_injector;_renderer;_backdropClick=new HA;_attachments=new HA;_detachments=new HA;_positionStrategy;_scrollStrategy;_locationChanges=_t.EMPTY;_backdropRef=null;_previousHostParent;_keydownEvents=new HA;_outsidePointerEvents=new HA;_renders=new HA;_afterRenderRef;_afterNextRenderRef;constructor(e,A,i,n,o,r,s,a,c,l=!1,I,C){this._portalOutlet=e,this._host=A,this._pane=i,this._config=n,this._ngZone=o,this._keyboardDispatcher=r,this._document=s,this._location=a,this._outsideClickDispatcher=c,this._animationsDisabled=l,this._injector=I,this._renderer=C,n.scrollStrategy&&(this._scrollStrategy=n.scrollStrategy,this._scrollStrategy.attach(this)),this._positionStrategy=n.positionStrategy,this._afterRenderRef=ia(()=>IQ(()=>{this._renders.next()},{injector:this._injector}))}get overlayElement(){return this._pane}get backdropElement(){return this._backdropRef?.element||null}get hostElement(){return this._host}attach(e){!this._host.parentElement&&this._previousHostParent&&this._previousHostParent.appendChild(this._host);let A=this._portalOutlet.attach(e);return this._positionStrategy&&this._positionStrategy.attach(this),this._updateStackingOrder(),this._updateElementSize(),this._updateElementDirection(),this._scrollStrategy&&this._scrollStrategy.enable(),this._afterNextRenderRef?.destroy(),this._afterNextRenderRef=Vo(()=>{this.hasAttached()&&this.updatePosition()},{injector:this._injector}),this._togglePointerEvents(!0),this._config.hasBackdrop&&this._attachBackdrop(),this._config.panelClass&&this._toggleClasses(this._pane,this._config.panelClass,!0),this._attachments.next(),this._keyboardDispatcher.add(this),this._config.disposeOnNavigation&&(this._locationChanges=this._location.subscribe(()=>this.dispose())),this._outsideClickDispatcher.add(this),typeof A?.onDestroy=="function"&&A.onDestroy(()=>{this.hasAttached()&&this._ngZone.runOutsideAngular(()=>Promise.resolve().then(()=>this.detach()))}),A}detach(){if(!this.hasAttached())return;this.detachBackdrop(),this._togglePointerEvents(!1),this._positionStrategy&&this._positionStrategy.detach&&this._positionStrategy.detach(),this._scrollStrategy&&this._scrollStrategy.disable();let e=this._portalOutlet.detach();return this._detachments.next(),this._keyboardDispatcher.remove(this),this._detachContentWhenEmpty(),this._locationChanges.unsubscribe(),this._outsideClickDispatcher.remove(this),e}dispose(){let e=this.hasAttached();this._positionStrategy&&this._positionStrategy.dispose(),this._disposeScrollStrategy(),this._backdropRef?.dispose(),this._locationChanges.unsubscribe(),this._keyboardDispatcher.remove(this),this._portalOutlet.dispose(),this._attachments.complete(),this._backdropClick.complete(),this._keydownEvents.complete(),this._outsidePointerEvents.complete(),this._outsideClickDispatcher.remove(this),this._host?.remove(),this._afterNextRenderRef?.destroy(),this._previousHostParent=this._pane=this._host=this._backdropRef=null,e&&this._detachments.next(),this._detachments.complete(),this._afterRenderRef.destroy(),this._renders.complete()}hasAttached(){return this._portalOutlet.hasAttached()}backdropClick(){return this._backdropClick}attachments(){return this._attachments}detachments(){return this._detachments}keydownEvents(){return this._keydownEvents}outsidePointerEvents(){return this._outsidePointerEvents}getConfig(){return this._config}updatePosition(){this._positionStrategy&&this._positionStrategy.apply()}updatePositionStrategy(e){e!==this._positionStrategy&&(this._positionStrategy&&this._positionStrategy.dispose(),this._positionStrategy=e,this.hasAttached()&&(e.attach(this),this.updatePosition()))}updateSize(e){this._config=nA(nA({},this._config),e),this._updateElementSize()}setDirection(e){this._config=Ne(nA({},this._config),{direction:e}),this._updateElementDirection()}addPanelClass(e){this._pane&&this._toggleClasses(this._pane,e,!0)}removePanelClass(e){this._pane&&this._toggleClasses(this._pane,e,!1)}getDirection(){let e=this._config.direction;return e?typeof e=="string"?e:e.value:"ltr"}updateScrollStrategy(e){e!==this._scrollStrategy&&(this._disposeScrollStrategy(),this._scrollStrategy=e,this.hasAttached()&&(e.attach(this),e.enable()))}_updateElementDirection(){this._host.setAttribute("dir",this.getDirection())}_updateElementSize(){if(!this._pane)return;let e=this._pane.style;e.width=sr(this._config.width),e.height=sr(this._config.height),e.minWidth=sr(this._config.minWidth),e.minHeight=sr(this._config.minHeight),e.maxWidth=sr(this._config.maxWidth),e.maxHeight=sr(this._config.maxHeight)}_togglePointerEvents(e){this._pane.style.pointerEvents=e?"":"none"}_attachBackdrop(){let e="cdk-overlay-backdrop-showing";this._backdropRef?.dispose(),this._backdropRef=new pk(this._document,this._renderer,this._ngZone,A=>{this._backdropClick.next(A)}),this._animationsDisabled&&this._backdropRef.element.classList.add("cdk-overlay-backdrop-noop-animation"),this._config.backdropClass&&this._toggleClasses(this._backdropRef.element,this._config.backdropClass,!0),this._host.parentElement.insertBefore(this._backdropRef.element,this._host),!this._animationsDisabled&&typeof requestAnimationFrame<"u"?this._ngZone.runOutsideAngular(()=>{requestAnimationFrame(()=>this._backdropRef?.element.classList.add(e))}):this._backdropRef.element.classList.add(e)}_updateStackingOrder(){this._host.nextSibling&&this._host.parentNode.appendChild(this._host)}detachBackdrop(){this._animationsDisabled?(this._backdropRef?.dispose(),this._backdropRef=null):this._backdropRef?.detach()}_toggleClasses(e,A,i){let n=lB(A||[]).filter(o=>!!o);n.length&&(i?e.classList.add(...n):e.classList.remove(...n))}_detachContentWhenEmpty(){this._ngZone.runOutsideAngular(()=>{let e=this._renders.pipe(wt(ho(this._attachments,this._detachments))).subscribe(()=>{(!this._pane||!this._host||this._pane.children.length===0)&&(this._pane&&this._config.panelClass&&this._toggleClasses(this._pane,this._config.panelClass,!1),this._host&&this._host.parentElement&&(this._previousHostParent=this._host.parentElement,this._host.remove()),e.unsubscribe())})})}_disposeScrollStrategy(){let e=this._scrollStrategy;e?.disable(),e?.detach?.()}},VO="cdk-overlay-connected-position-bounding-box",QuA=/([A-Za-z%]+)$/,wk=class{_viewportRuler;_document;_platform;_overlayContainer;_overlayRef;_isInitialRender;_lastBoundingBoxSize={width:0,height:0};_isPushed=!1;_canPush=!0;_growAfterOpen=!1;_hasFlexibleDimensions=!0;_positionLocked=!1;_originRect;_overlayRect;_viewportRect;_containerRect;_viewportMargin=0;_scrollables=[];_preferredPositions=[];_origin;_pane;_isDisposed;_boundingBox;_lastPosition;_lastScrollVisibility;_positionChanges=new HA;_resizeSubscription=_t.EMPTY;_offsetX=0;_offsetY=0;_transformOriginSelector;_appliedPanelClasses=[];_previousPushAmount;positionChanges=this._positionChanges;get positions(){return this._preferredPositions}constructor(e,A,i,n,o){this._viewportRuler=A,this._document=i,this._platform=n,this._overlayContainer=o,this.setOrigin(e)}attach(e){this._overlayRef&&this._overlayRef,this._validatePositions(),e.hostElement.classList.add(VO),this._overlayRef=e,this._boundingBox=e.hostElement,this._pane=e.overlayElement,this._isDisposed=!1,this._isInitialRender=!0,this._lastPosition=null,this._resizeSubscription.unsubscribe(),this._resizeSubscription=this._viewportRuler.change().subscribe(()=>{this._isInitialRender=!0,this.apply()})}apply(){if(this._isDisposed||!this._platform.isBrowser)return;if(!this._isInitialRender&&this._positionLocked&&this._lastPosition){this.reapplyLastPosition();return}this._clearPanelClasses(),this._resetOverlayElementStyles(),this._resetBoundingBoxStyles(),this._viewportRect=this._getNarrowedViewportRect(),this._originRect=this._getOriginRect(),this._overlayRect=this._pane.getBoundingClientRect(),this._containerRect=this._overlayContainer.getContainerElement().getBoundingClientRect();let e=this._originRect,A=this._overlayRect,i=this._viewportRect,n=this._containerRect,o=[],r;for(let s of this._preferredPositions){let a=this._getOriginPoint(e,n,s),c=this._getOverlayPoint(a,A,s),l=this._getOverlayFit(c,A,i,s);if(l.isCompletelyWithinViewport){this._isPushed=!1,this._applyPosition(s,a);return}if(this._canFitWithFlexibleDimensions(l,c,i)){o.push({position:s,origin:a,overlayRect:A,boundingBoxRect:this._calculateBoundingBoxRect(a,s)});continue}(!r||r.overlayFit.visibleArea<l.visibleArea)&&(r={overlayFit:l,overlayPoint:c,originPoint:a,position:s,overlayRect:A})}if(o.length){let s=null,a=-1;for(let c of o){let l=c.boundingBoxRect.width*c.boundingBoxRect.height*(c.position.weight||1);l>a&&(a=l,s=c)}this._isPushed=!1,this._applyPosition(s.position,s.origin);return}if(this._canPush){this._isPushed=!0,this._applyPosition(r.position,r.originPoint);return}this._applyPosition(r.position,r.originPoint)}detach(){this._clearPanelClasses(),this._lastPosition=null,this._previousPushAmount=null,this._resizeSubscription.unsubscribe()}dispose(){this._isDisposed||(this._boundingBox&&YI(this._boundingBox.style,{top:"",left:"",right:"",bottom:"",height:"",width:"",alignItems:"",justifyContent:""}),this._pane&&this._resetOverlayElementStyles(),this._overlayRef&&this._overlayRef.hostElement.classList.remove(VO),this.detach(),this._positionChanges.complete(),this._overlayRef=this._boundingBox=null,this._isDisposed=!0)}reapplyLastPosition(){if(this._isDisposed||!this._platform.isBrowser)return;let e=this._lastPosition;if(e){this._originRect=this._getOriginRect(),this._overlayRect=this._pane.getBoundingClientRect(),this._viewportRect=this._getNarrowedViewportRect(),this._containerRect=this._overlayContainer.getContainerElement().getBoundingClientRect();let A=this._getOriginPoint(this._originRect,this._containerRect,e);this._applyPosition(e,A)}else this.apply()}withScrollableContainers(e){return this._scrollables=e,this}withPositions(e){return this._preferredPositions=e,e.indexOf(this._lastPosition)===-1&&(this._lastPosition=null),this._validatePositions(),this}withViewportMargin(e){return this._viewportMargin=e,this}withFlexibleDimensions(e=!0){return this._hasFlexibleDimensions=e,this}withGrowAfterOpen(e=!0){return this._growAfterOpen=e,this}withPush(e=!0){return this._canPush=e,this}withLockedPosition(e=!0){return this._positionLocked=e,this}setOrigin(e){return this._origin=e,this}withDefaultOffsetX(e){return this._offsetX=e,this}withDefaultOffsetY(e){return this._offsetY=e,this}withTransformOriginOn(e){return this._transformOriginSelector=e,this}_getOriginPoint(e,A,i){let n;if(i.originX=="center")n=e.left+e.width/2;else{let r=this._isRtl()?e.right:e.left,s=this._isRtl()?e.left:e.right;n=i.originX=="start"?r:s}A.left<0&&(n-=A.left);let o;return i.originY=="center"?o=e.top+e.height/2:o=i.originY=="top"?e.top:e.bottom,A.top<0&&(o-=A.top),{x:n,y:o}}_getOverlayPoint(e,A,i){let n;i.overlayX=="center"?n=-A.width/2:i.overlayX==="start"?n=this._isRtl()?-A.width:0:n=this._isRtl()?0:-A.width;let o;return i.overlayY=="center"?o=-A.height/2:o=i.overlayY=="top"?0:-A.height,{x:e.x+n,y:e.y+o}}_getOverlayFit(e,A,i,n){let o=WO(A),{x:r,y:s}=e,a=this._getOffset(n,"x"),c=this._getOffset(n,"y");a&&(r+=a),c&&(s+=c);let l=0-r,I=r+o.width-i.width,C=0-s,d=s+o.height-i.height,B=this._subtractOverflows(o.width,l,I),E=this._subtractOverflows(o.height,C,d),Q=B*E;return{visibleArea:Q,isCompletelyWithinViewport:o.width*o.height===Q,fitsInViewportVertically:E===o.height,fitsInViewportHorizontally:B==o.width}}_canFitWithFlexibleDimensions(e,A,i){if(this._hasFlexibleDimensions){let n=i.bottom-A.y,o=i.right-A.x,r=ZO(this._overlayRef.getConfig().minHeight),s=ZO(this._overlayRef.getConfig().minWidth),a=e.fitsInViewportVertically||r!=null&&r<=n,c=e.fitsInViewportHorizontally||s!=null&&s<=o;return a&&c}return!1}_pushOverlayOnScreen(e,A,i){if(this._previousPushAmount&&this._positionLocked)return{x:e.x+this._previousPushAmount.x,y:e.y+this._previousPushAmount.y};let n=WO(A),o=this._viewportRect,r=Math.max(e.x+n.width-o.width,0),s=Math.max(e.y+n.height-o.height,0),a=Math.max(o.top-i.top-e.y,0),c=Math.max(o.left-i.left-e.x,0),l=0,I=0;return n.width<=o.width?l=c||-r:l=e.x<this._viewportMargin?o.left-i.left-e.x:0,n.height<=o.height?I=a||-s:I=e.y<this._viewportMargin?o.top-i.top-e.y:0,this._previousPushAmount={x:l,y:I},{x:e.x+l,y:e.y+I}}_applyPosition(e,A){if(this._setTransformOrigin(e),this._setOverlayElementStyles(A,e),this._setBoundingBoxStyles(A,e),e.panelClass&&this._addPanelClasses(e.panelClass),this._positionChanges.observers.length){let i=this._getScrollVisibility();if(e!==this._lastPosition||!this._lastScrollVisibility||!uuA(this._lastScrollVisibility,i)){let n=new mk(e,i);this._positionChanges.next(n)}this._lastScrollVisibility=i}this._lastPosition=e,this._isInitialRender=!1}_setTransformOrigin(e){if(!this._transformOriginSelector)return;let A=this._boundingBox.querySelectorAll(this._transformOriginSelector),i,n=e.overlayY;e.overlayX==="center"?i="center":this._isRtl()?i=e.overlayX==="start"?"right":"left":i=e.overlayX==="start"?"left":"right";for(let o=0;o<A.length;o++)A[o].style.transformOrigin=`${i} ${n}`}_calculateBoundingBoxRect(e,A){let i=this._viewportRect,n=this._isRtl(),o,r,s;if(A.overlayY==="top")r=e.y,o=i.height-r+this._viewportMargin;else if(A.overlayY==="bottom")s=i.height-e.y+this._viewportMargin*2,o=i.height-s+this._viewportMargin;else{let d=Math.min(i.bottom-e.y+i.top,e.y),B=this._lastBoundingBoxSize.height;o=d*2,r=e.y-d,o>B&&!this._isInitialRender&&!this._growAfterOpen&&(r=e.y-B/2)}let a=A.overlayX==="start"&&!n||A.overlayX==="end"&&n,c=A.overlayX==="end"&&!n||A.overlayX==="start"&&n,l,I,C;if(c)C=i.width-e.x+this._viewportMargin*2,l=e.x-this._viewportMargin;else if(a)I=e.x,l=i.right-e.x;else{let d=Math.min(i.right-e.x+i.left,e.x),B=this._lastBoundingBoxSize.width;l=d*2,I=e.x-d,l>B&&!this._isInitialRender&&!this._growAfterOpen&&(I=e.x-B/2)}return{top:r,left:I,bottom:s,right:C,width:l,height:o}}_setBoundingBoxStyles(e,A){let i=this._calculateBoundingBoxRect(e,A);!this._isInitialRender&&!this._growAfterOpen&&(i.height=Math.min(i.height,this._lastBoundingBoxSize.height),i.width=Math.min(i.width,this._lastBoundingBoxSize.width));let n={};if(this._hasExactPosition())n.top=n.left="0",n.bottom=n.right=n.maxHeight=n.maxWidth="",n.width=n.height="100%";else{let o=this._overlayRef.getConfig().maxHeight,r=this._overlayRef.getConfig().maxWidth;n.height=sr(i.height),n.top=sr(i.top),n.bottom=sr(i.bottom),n.width=sr(i.width),n.left=sr(i.left),n.right=sr(i.right),A.overlayX==="center"?n.alignItems="center":n.alignItems=A.overlayX==="end"?"flex-end":"flex-start",A.overlayY==="center"?n.justifyContent="center":n.justifyContent=A.overlayY==="bottom"?"flex-end":"flex-start",o&&(n.maxHeight=sr(o)),r&&(n.maxWidth=sr(r))}this._lastBoundingBoxSize=i,YI(this._boundingBox.style,n)}_resetBoundingBoxStyles(){YI(this._boundingBox.style,{top:"0",left:"0",right:"0",bottom:"0",height:"",width:"",alignItems:"",justifyContent:""})}_resetOverlayElementStyles(){YI(this._pane.style,{top:"",left:"",bottom:"",right:"",position:"",transform:""})}_setOverlayElementStyles(e,A){let i={},n=this._hasExactPosition(),o=this._hasFlexibleDimensions,r=this._overlayRef.getConfig();if(n){let l=this._viewportRuler.getViewportScrollPosition();YI(i,this._getExactOverlayY(A,e,l)),YI(i,this._getExactOverlayX(A,e,l))}else i.position="static";let s="",a=this._getOffset(A,"x"),c=this._getOffset(A,"y");a&&(s+=`translateX(${a}px) `),c&&(s+=`translateY(${c}px)`),i.transform=s.trim(),r.maxHeight&&(n?i.maxHeight=sr(r.maxHeight):o&&(i.maxHeight="")),r.maxWidth&&(n?i.maxWidth=sr(r.maxWidth):o&&(i.maxWidth="")),YI(this._pane.style,i)}_getExactOverlayY(e,A,i){let n={top:"",bottom:""},o=this._getOverlayPoint(A,this._overlayRect,e);if(this._isPushed&&(o=this._pushOverlayOnScreen(o,this._overlayRect,i)),e.overlayY==="bottom"){let r=this._document.documentElement.clientHeight;n.bottom=`${r-(o.y+this._overlayRect.height)}px`}else n.top=sr(o.y);return n}_getExactOverlayX(e,A,i){let n={left:"",right:""},o=this._getOverlayPoint(A,this._overlayRect,e);this._isPushed&&(o=this._pushOverlayOnScreen(o,this._overlayRect,i));let r;if(this._isRtl()?r=e.overlayX==="end"?"left":"right":r=e.overlayX==="end"?"right":"left",r==="right"){let s=this._document.documentElement.clientWidth;n.right=`${s-(o.x+this._overlayRect.width)}px`}else n.left=sr(o.x);return n}_getScrollVisibility(){let e=this._getOriginRect(),A=this._pane.getBoundingClientRect(),i=this._scrollables.map(n=>n.getElementRef().nativeElement.getBoundingClientRect());return{isOriginClipped:jO(e,i),isOriginOutsideView:uk(e,i),isOverlayClipped:jO(A,i),isOverlayOutsideView:uk(A,i)}}_subtractOverflows(e,...A){return A.reduce((i,n)=>i-Math.max(n,0),e)}_getNarrowedViewportRect(){let e=this._document.documentElement.clientWidth,A=this._document.documentElement.clientHeight,i=this._viewportRuler.getViewportScrollPosition();return{top:i.top+this._viewportMargin,left:i.left+this._viewportMargin,right:i.left+e-this._viewportMargin,bottom:i.top+A-this._viewportMargin,width:e-2*this._viewportMargin,height:A-2*this._viewportMargin}}_isRtl(){return this._overlayRef.getDirection()==="rtl"}_hasExactPosition(){return!this._hasFlexibleDimensions||this._isPushed}_getOffset(e,A){return A==="x"?e.offsetX==null?this._offsetX:e.offsetX:e.offsetY==null?this._offsetY:e.offsetY}_validatePositions(){}_addPanelClasses(e){this._pane&&lB(e).forEach(A=>{A!==""&&this._appliedPanelClasses.indexOf(A)===-1&&(this._appliedPanelClasses.push(A),this._pane.classList.add(A))})}_clearPanelClasses(){this._pane&&(this._appliedPanelClasses.forEach(e=>{this._pane.classList.remove(e)}),this._appliedPanelClasses=[])}_getOriginRect(){let e=this._origin;if(e instanceof te)return e.nativeElement.getBoundingClientRect();if(e instanceof Element)return e.getBoundingClientRect();let A=e.width||0,i=e.height||0;return{top:e.y,bottom:e.y+i,left:e.x,right:e.x+A,height:i,width:A}}};function YI(t,e){for(let A in e)e.hasOwnProperty(A)&&(t[A]=e[A]);return t}function ZO(t){if(typeof t!="number"&&t!=null){let[e,A]=t.split(QuA);return!A||A==="px"?parseFloat(e):null}return t||null}function WO(t){return{top:Math.floor(t.top),right:Math.floor(t.right),bottom:Math.floor(t.bottom),left:Math.floor(t.left),width:Math.floor(t.width),height:Math.floor(t.height)}}function uuA(t,e){return t===e?!0:t.isOriginClipped===e.isOriginClipped&&t.isOriginOutsideView===e.isOriginOutsideView&&t.isOverlayClipped===e.isOverlayClipped&&t.isOverlayOutsideView===e.isOverlayOutsideView}var XO="cdk-global-overlay-wrapper",Dk=class{_overlayRef;_cssPosition="static";_topOffset="";_bottomOffset="";_alignItems="";_xPosition="";_xOffset="";_width="";_height="";_isDisposed=!1;attach(e){let A=e.getConfig();this._overlayRef=e,this._width&&!A.width&&e.updateSize({width:this._width}),this._height&&!A.height&&e.updateSize({height:this._height}),e.hostElement.classList.add(XO),this._isDisposed=!1}top(e=""){return this._bottomOffset="",this._topOffset=e,this._alignItems="flex-start",this}left(e=""){return this._xOffset=e,this._xPosition="left",this}bottom(e=""){return this._topOffset="",this._bottomOffset=e,this._alignItems="flex-end",this}right(e=""){return this._xOffset=e,this._xPosition="right",this}start(e=""){return this._xOffset=e,this._xPosition="start",this}end(e=""){return this._xOffset=e,this._xPosition="end",this}width(e=""){return this._overlayRef?this._overlayRef.updateSize({width:e}):this._width=e,this}height(e=""){return this._overlayRef?this._overlayRef.updateSize({height:e}):this._height=e,this}centerHorizontally(e=""){return this.left(e),this._xPosition="center",this}centerVertically(e=""){return this.top(e),this._alignItems="center",this}apply(){if(!this._overlayRef||!this._overlayRef.hasAttached())return;let e=this._overlayRef.overlayElement.style,A=this._overlayRef.hostElement.style,i=this._overlayRef.getConfig(),{width:n,height:o,maxWidth:r,maxHeight:s}=i,a=(n==="100%"||n==="100vw")&&(!r||r==="100%"||r==="100vw"),c=(o==="100%"||o==="100vh")&&(!s||s==="100%"||s==="100vh"),l=this._xPosition,I=this._xOffset,C=this._overlayRef.getConfig().direction==="rtl",d="",B="",E="";a?E="flex-start":l==="center"?(E="center",C?B=I:d=I):C?l==="left"||l==="end"?(E="flex-end",d=I):(l==="right"||l==="start")&&(E="flex-start",B=I):l==="left"||l==="start"?(E="flex-start",d=I):(l==="right"||l==="end")&&(E="flex-end",B=I),e.position=this._cssPosition,e.marginLeft=a?"0":d,e.marginTop=c?"0":this._topOffset,e.marginBottom=this._bottomOffset,e.marginRight=a?"0":B,A.justifyContent=E,A.alignItems=c?"flex-start":this._alignItems}dispose(){if(this._isDisposed||!this._overlayRef)return;let e=this._overlayRef.overlayElement.style,A=this._overlayRef.hostElement,i=A.style;A.classList.remove(XO),i.justifyContent=i.alignItems=e.marginTop=e.marginBottom=e.marginLeft=e.marginRight=e.position="",this._overlayRef=null,this._isDisposed=!0}},fuA=(()=>{class t{_viewportRuler=m(mc);_document=m(tt);_platform=m(Zt);_overlayContainer=m(i8);constructor(){}global(){return new Dk}flexibleConnectedTo(A){return new wk(A,this._viewportRuler,this._document,this._platform,this._overlayContainer)}static \u0275fac=function(i){return new(i||t)};static \u0275prov=SA({token:t,factory:t.\u0275fac,providedIn:"root"})}return t})(),Sr=(()=>{class t{scrollStrategies=m(BuA);_overlayContainer=m(i8);_positionBuilder=m(fuA);_keyboardDispatcher=m(EuA);_injector=m(Dt);_ngZone=m(de);_document=m(tt);_directionality=m(bo);_location=m(Qc);_outsideClickDispatcher=m(huA);_animationsModuleType=m(mi,{optional:!0});_idGenerator=m($i);_renderer=m(ds).createRenderer(null,null);_appRef;_styleLoader=m(Ln);constructor(){}create(A){this._styleLoader.load(AP);let i=this._createHostElement(),n=this._createPaneElement(i),o=this._createPortalOutlet(n),r=new G2(A);return r.direction=r.direction||this._directionality.value,new fB(o,i,n,r,this._ngZone,this._keyboardDispatcher,this._document,this._location,this._outsideClickDispatcher,this._animationsModuleType==="NoopAnimations",this._injector.get(Br),this._renderer)}position(){return this._positionBuilder}_createPaneElement(A){let i=this._document.createElement("div");return i.id=this._idGenerator.getId("cdk-overlay-"),i.classList.add("cdk-overlay-pane"),A.appendChild(i),i}_createHostElement(){let A=this._document.createElement("div");return this._overlayContainer.getContainerElement().appendChild(A),A}_createPortalOutlet(A){return this._appRef||(this._appRef=this._injector.get(Ua)),new e8(A,null,this._appRef,this._injector,this._document)}static \u0275fac=function(i){return new(i||t)};static \u0275prov=SA({token:t,factory:t.\u0275fac,providedIn:"root"})}return t})(),muA=[{originX:"start",originY:"bottom",overlayX:"start",overlayY:"top"},{originX:"start",originY:"top",overlayX:"start",overlayY:"bottom"},{originX:"end",originY:"top",overlayX:"end",overlayY:"bottom"},{originX:"end",originY:"bottom",overlayX:"end",overlayY:"top"}],eP=new BA("cdk-connected-overlay-scroll-strategy",{providedIn:"root",factory:()=>{let t=m(Sr);return()=>t.scrollStrategies.reposition()}}),mu=(()=>{class t{elementRef=m(te);constructor(){}static \u0275fac=function(i){return new(i||t)};static \u0275dir=OA({type:t,selectors:[["","cdk-overlay-origin",""],["","overlay-origin",""],["","cdkOverlayOrigin",""]],exportAs:["cdkOverlayOrigin"]})}return t})(),yk=(()=>{class t{_overlay=m(Sr);_dir=m(bo,{optional:!0});_overlayRef;_templatePortal;_backdropSubscription=_t.EMPTY;_attachSubscription=_t.EMPTY;_detachSubscription=_t.EMPTY;_positionSubscription=_t.EMPTY;_offsetX;_offsetY;_position;_scrollStrategyFactory=m(eP);_disposeOnNavigation=!1;_ngZone=m(de);origin;positions;positionStrategy;get offsetX(){return this._offsetX}set offsetX(A){this._offsetX=A,this._position&&this._updatePositionStrategy(this._position)}get offsetY(){return this._offsetY}set offsetY(A){this._offsetY=A,this._position&&this._updatePositionStrategy(this._position)}width;height;minWidth;minHeight;backdropClass;panelClass;viewportMargin=0;scrollStrategy;open=!1;disableClose=!1;transformOriginSelector;hasBackdrop=!1;lockPosition=!1;flexibleDimensions=!1;growAfterOpen=!1;push=!1;get disposeOnNavigation(){return this._disposeOnNavigation}set disposeOnNavigation(A){this._disposeOnNavigation=A}backdropClick=new XA;positionChange=new XA;attach=new XA;detach=new XA;overlayKeydown=new XA;overlayOutsideClick=new XA;constructor(){let A=m(vn),i=m(Un);this._templatePortal=new aa(A,i),this.scrollStrategy=this._scrollStrategyFactory()}get overlayRef(){return this._overlayRef}get dir(){return this._dir?this._dir.value:"ltr"}ngOnDestroy(){this._attachSubscription.unsubscribe(),this._detachSubscription.unsubscribe(),this._backdropSubscription.unsubscribe(),this._positionSubscription.unsubscribe(),this._overlayRef&&this._overlayRef.dispose()}ngOnChanges(A){this._position&&(this._updatePositionStrategy(this._position),this._overlayRef.updateSize({width:this.width,minWidth:this.minWidth,height:this.height,minHeight:this.minHeight}),A.origin&&this.open&&this._position.apply()),A.open&&(this.open?this._attachOverlay():this._detachOverlay())}_createOverlay(){(!this.positions||!this.positions.length)&&(this.positions=muA);let A=this._overlayRef=this._overlay.create(this._buildConfig());this._attachSubscription=A.attachments().subscribe(()=>this.attach.emit()),this._detachSubscription=A.detachments().subscribe(()=>this.detach.emit()),A.keydownEvents().subscribe(i=>{this.overlayKeydown.next(i),i.keyCode===27&&!this.disableClose&&!rr(i)&&(i.preventDefault(),this._detachOverlay())}),this._overlayRef.outsidePointerEvents().subscribe(i=>{let n=this._getOriginElement(),o=Wa(i);(!n||n!==o&&!n.contains(o))&&this.overlayOutsideClick.next(i)})}_buildConfig(){let A=this._position=this.positionStrategy||this._createPositionStrategy(),i=new G2({direction:this._dir||"ltr",positionStrategy:A,scrollStrategy:this.scrollStrategy,hasBackdrop:this.hasBackdrop,disposeOnNavigation:this.disposeOnNavigation});return(this.width||this.width===0)&&(i.width=this.width),(this.height||this.height===0)&&(i.height=this.height),(this.minWidth||this.minWidth===0)&&(i.minWidth=this.minWidth),(this.minHeight||this.minHeight===0)&&(i.minHeight=this.minHeight),this.backdropClass&&(i.backdropClass=this.backdropClass),this.panelClass&&(i.panelClass=this.panelClass),i}_updatePositionStrategy(A){let i=this.positions.map(n=>({originX:n.originX,originY:n.originY,overlayX:n.overlayX,overlayY:n.overlayY,offsetX:n.offsetX||this.offsetX,offsetY:n.offsetY||this.offsetY,panelClass:n.panelClass||void 0}));return A.setOrigin(this._getOrigin()).withPositions(i).withFlexibleDimensions(this.flexibleDimensions).withPush(this.push).withGrowAfterOpen(this.growAfterOpen).withViewportMargin(this.viewportMargin).withLockedPosition(this.lockPosition).withTransformOriginOn(this.transformOriginSelector)}_createPositionStrategy(){let A=this._overlay.position().flexibleConnectedTo(this._getOrigin());return this._updatePositionStrategy(A),A}_getOrigin(){return this.origin instanceof mu?this.origin.elementRef:this.origin}_getOriginElement(){return this.origin instanceof mu?this.origin.elementRef.nativeElement:this.origin instanceof te?this.origin.nativeElement:typeof Element<"u"&&this.origin instanceof Element?this.origin:null}_attachOverlay(){this._overlayRef?this._overlayRef.getConfig().hasBackdrop=this.hasBackdrop:this._createOverlay(),this._overlayRef.hasAttached()||this._overlayRef.attach(this._templatePortal),this.hasBackdrop?this._backdropSubscription=this._overlayRef.backdropClick().subscribe(A=>{this.backdropClick.emit(A)}):this._backdropSubscription.unsubscribe(),this._positionSubscription.unsubscribe(),this.positionChange.observers.length>0&&(this._positionSubscription=this._position.positionChanges.pipe($7(()=>this.positionChange.observers.length>0)).subscribe(A=>{this._ngZone.run(()=>this.positionChange.emit(A)),this.positionChange.observers.length===0&&this._positionSubscription.unsubscribe()}))}_detachOverlay(){this._overlayRef&&this._overlayRef.detach(),this._backdropSubscription.unsubscribe(),this._positionSubscription.unsubscribe()}static \u0275fac=function(i){return new(i||t)};static \u0275dir=OA({type:t,selectors:[["","cdk-connected-overlay",""],["","connected-overlay",""],["","cdkConnectedOverlay",""]],inputs:{origin:[0,"cdkConnectedOverlayOrigin","origin"],positions:[0,"cdkConnectedOverlayPositions","positions"],positionStrategy:[0,"cdkConnectedOverlayPositionStrategy","positionStrategy"],offsetX:[0,"cdkConnectedOverlayOffsetX","offsetX"],offsetY:[0,"cdkConnectedOverlayOffsetY","offsetY"],width:[0,"cdkConnectedOverlayWidth","width"],height:[0,"cdkConnectedOverlayHeight","height"],minWidth:[0,"cdkConnectedOverlayMinWidth","minWidth"],minHeight:[0,"cdkConnectedOverlayMinHeight","minHeight"],backdropClass:[0,"cdkConnectedOverlayBackdropClass","backdropClass"],panelClass:[0,"cdkConnectedOverlayPanelClass","panelClass"],viewportMargin:[0,"cdkConnectedOverlayViewportMargin","viewportMargin"],scrollStrategy:[0,"cdkConnectedOverlayScrollStrategy","scrollStrategy"],open:[0,"cdkConnectedOverlayOpen","open"],disableClose:[0,"cdkConnectedOverlayDisableClose","disableClose"],transformOriginSelector:[0,"cdkConnectedOverlayTransformOriginOn","transformOriginSelector"],hasBackdrop:[2,"cdkConnectedOverlayHasBackdrop","hasBackdrop",ae],lockPosition:[2,"cdkConnectedOverlayLockPosition","lockPosition",ae],flexibleDimensions:[2,"cdkConnectedOverlayFlexibleDimensions","flexibleDimensions",ae],growAfterOpen:[2,"cdkConnectedOverlayGrowAfterOpen","growAfterOpen",ae],push:[2,"cdkConnectedOverlayPush","push",ae],disposeOnNavigation:[2,"cdkConnectedOverlayDisposeOnNavigation","disposeOnNavigation",ae]},outputs:{backdropClick:"backdropClick",positionChange:"positionChange",attach:"attach",detach:"detach",overlayKeydown:"overlayKeydown",overlayOutsideClick:"overlayOutsideClick"},exportAs:["cdkConnectedOverlay"],features:[Kt]})}return t})();function puA(t){return()=>t.scrollStrategies.reposition()}var wuA={provide:eP,deps:[Sr],useFactory:puA},u0=(()=>{class t{static \u0275fac=function(i){return new(i||t)};static \u0275mod=ge({type:t});static \u0275inj=le({providers:[Sr,wuA],imports:[R2,sg,uu,uu]})}return t})();var vk=class{_box;_destroyed=new HA;_resizeSubject=new HA;_resizeObserver;_elementObservables=new Map;constructor(e){this._box=e,typeof ResizeObserver<"u"&&(this._resizeObserver=new ResizeObserver(A=>this._resizeSubject.next(A)))}observe(e){return this._elementObservables.has(e)||this._elementObservables.set(e,new Ze(A=>{let i=this._resizeSubject.subscribe(A);return this._resizeObserver?.observe(e,{box:this._box}),()=>{this._resizeObserver?.unobserve(e),i.unsubscribe(),this._elementObservables.delete(e)}}).pipe(pt(A=>A.some(i=>i.target===e)),$g({bufferSize:1,refCount:!0}),wt(this._destroyed))),this._elementObservables.get(e)}destroy(){this._destroyed.next(),this._destroyed.complete(),this._resizeSubject.complete(),this._elementObservables.clear()}},n8=(()=>{class t{_cleanupErrorListener;_observers=new Map;_ngZone=m(de);constructor(){typeof ResizeObserver<"u"}ngOnDestroy(){for(let[,A]of this._observers)A.destroy();this._observers.clear(),this._cleanupErrorListener?.()}observe(A,i){let n=i?.box||"content-box";return this._observers.has(n)||this._observers.set(n,new vk(n)),this._observers.get(n).observe(A)}static \u0275fac=function(i){return new(i||t)};static \u0275prov=SA({token:t,factory:t.\u0275fac,providedIn:"root"})}return t})();var Wt=function(t){return t[t.State=0]="State",t[t.Transition=1]="Transition",t[t.Sequence=2]="Sequence",t[t.Group=3]="Group",t[t.Animate=4]="Animate",t[t.Keyframes=5]="Keyframes",t[t.Style=6]="Style",t[t.Trigger=7]="Trigger",t[t.Reference=8]="Reference",t[t.AnimateChild=9]="AnimateChild",t[t.AnimateRef=10]="AnimateRef",t[t.Query=11]="Query",t[t.Stagger=12]="Stagger",t}(Wt||{}),pc="*";function cg(t,e){return{type:Wt.Trigger,name:t,definitions:e,options:{}}}function $a(t,e=null){return{type:Wt.Animate,styles:e,timings:t}}function tP(t,e=null){return{type:Wt.Sequence,steps:t,options:e}}function ar(t){return{type:Wt.Style,styles:t,offset:null}}function wc(t,e,A){return{type:Wt.State,name:t,styles:e,options:A}}function la(t,e,A=null){return{type:Wt.Transition,expr:t,animation:e,options:A}}function bk(t=null){return{type:Wt.AnimateChild,options:t}}function Mk(t,e,A=null){return{type:Wt.Query,selector:t,animation:e,options:A}}var ag=class{_onDoneFns=[];_onStartFns=[];_onDestroyFns=[];_originalOnDoneFns=[];_originalOnStartFns=[];_started=!1;_destroyed=!1;_finished=!1;_position=0;parentPlayer=null;totalTime;constructor(e=0,A=0){this.totalTime=e+A}_onFinish(){this._finished||(this._finished=!0,this._onDoneFns.forEach(e=>e()),this._onDoneFns=[])}onStart(e){this._originalOnStartFns.push(e),this._onStartFns.push(e)}onDone(e){this._originalOnDoneFns.push(e),this._onDoneFns.push(e)}onDestroy(e){this._onDestroyFns.push(e)}hasStarted(){return this._started}init(){}play(){this.hasStarted()||(this._onStart(),this.triggerMicrotask()),this._started=!0}triggerMicrotask(){queueMicrotask(()=>this._onFinish())}_onStart(){this._onStartFns.forEach(e=>e()),this._onStartFns=[]}pause(){}restart(){}finish(){this._onFinish()}destroy(){this._destroyed||(this._destroyed=!0,this.hasStarted()||this._onStart(),this.finish(),this._onDestroyFns.forEach(e=>e()),this._onDestroyFns=[])}reset(){this._started=!1,this._finished=!1,this._onStartFns=this._originalOnStartFns,this._onDoneFns=this._originalOnDoneFns}setPosition(e){this._position=this.totalTime?e*this.totalTime:1}getPosition(){return this.totalTime?this._position/this.totalTime:1}triggerCallback(e){let A=e=="start"?this._onStartFns:this._onDoneFns;A.forEach(i=>i()),A.length=0}},JI=class{_onDoneFns=[];_onStartFns=[];_finished=!1;_started=!1;_destroyed=!1;_onDestroyFns=[];parentPlayer=null;totalTime=0;players;constructor(e){this.players=e;let A=0,i=0,n=0,o=this.players.length;o==0?queueMicrotask(()=>this._onFinish()):this.players.forEach(r=>{r.onDone(()=>{++A==o&&this._onFinish()}),r.onDestroy(()=>{++i==o&&this._onDestroy()}),r.onStart(()=>{++n==o&&this._onStart()})}),this.totalTime=this.players.reduce((r,s)=>Math.max(r,s.totalTime),0)}_onFinish(){this._finished||(this._finished=!0,this._onDoneFns.forEach(e=>e()),this._onDoneFns=[])}init(){this.players.forEach(e=>e.init())}onStart(e){this._onStartFns.push(e)}_onStart(){this.hasStarted()||(this._started=!0,this._onStartFns.forEach(e=>e()),this._onStartFns=[])}onDone(e){this._onDoneFns.push(e)}onDestroy(e){this._onDestroyFns.push(e)}hasStarted(){return this._started}play(){this.parentPlayer||this.init(),this._onStart(),this.players.forEach(e=>e.play())}pause(){this.players.forEach(e=>e.pause())}restart(){this.players.forEach(e=>e.restart())}finish(){this._onFinish(),this.players.forEach(e=>e.finish())}destroy(){this._onDestroy()}_onDestroy(){this._destroyed||(this._destroyed=!0,this._onFinish(),this.players.forEach(e=>e.destroy()),this._onDestroyFns.forEach(e=>e()),this._onDestroyFns=[])}reset(){this.players.forEach(e=>e.reset()),this._destroyed=!1,this._finished=!1,this._started=!1}setPosition(e){let A=e*this.totalTime;this.players.forEach(i=>{let n=i.totalTime?Math.min(1,A/i.totalTime):1;i.setPosition(n)})}getPosition(){let e=this.players.reduce((A,i)=>A===null||i.totalTime>A.totalTime?i:A,null);return e!=null?e.getPosition():0}beforeDestroy(){this.players.forEach(e=>{e.beforeDestroy&&e.beforeDestroy()})}triggerCallback(e){let A=e=="start"?this._onStartFns:this._onDoneFns;A.forEach(i=>i()),A.length=0}},mB="!";var DuA=["notch"],yuA=["matFormFieldNotchedOutline",""],vuA=["*"],buA=["textField"],MuA=["iconPrefixContainer"],kuA=["textPrefixContainer"],SuA=["iconSuffixContainer"],RuA=["textSuffixContainer"],LuA=["*",[["mat-label"]],[["","matPrefix",""],["","matIconPrefix",""]],[["","matTextPrefix",""]],[["","matTextSuffix",""]],[["","matSuffix",""],["","matIconSuffix",""]],[["mat-error"],["","matError",""]],[["mat-hint",3,"align","end"]],[["mat-hint","align","end"]]],xuA=["*","mat-label","[matPrefix], [matIconPrefix]","[matTextPrefix]","[matTextSuffix]","[matSuffix], [matIconSuffix]","mat-error, [matError]","mat-hint:not([align='end'])","mat-hint[align='end']"];function FuA(t,e){t&1&&UA(0,"span",21)}function NuA(t,e){if(t&1&&(S(0,"label",20),xe(1,1),NA(2,FuA,1,0,"span",21),R()),t&2){let A=P(2);vA("floating",A._shouldLabelFloat())("monitorResize",A._hasOutline())("id",A._labelId),_e("for",A._control.disableAutomaticLabeling?null:A._control.id),_(2),FA(!A.hideRequiredMarker&&A._control.required?2:-1)}}function _uA(t,e){if(t&1&&NA(0,NuA,3,5,"label",20),t&2){let A=P();FA(A._hasFloatingLabel()?0:-1)}}function GuA(t,e){t&1&&UA(0,"div",7)}function UuA(t,e){}function KuA(t,e){if(t&1&&NA(0,UuA,0,0,"ng-template",13),t&2){P(2);let A=or(1);vA("ngTemplateOutlet",A)}}function YuA(t,e){if(t&1&&(S(0,"div",9),NA(1,KuA,1,1,null,13),R()),t&2){let A=P();vA("matFormFieldNotchedOutlineOpen",A._shouldLabelFloat()),_(),FA(A._forceDisplayInfixLabel()?-1:1)}}function JuA(t,e){t&1&&(S(0,"div",10,2),xe(2,2),R())}function TuA(t,e){t&1&&(S(0,"div",11,3),xe(2,3),R())}function zuA(t,e){}function HuA(t,e){if(t&1&&NA(0,zuA,0,0,"ng-template",13),t&2){P();let A=or(1);vA("ngTemplateOutlet",A)}}function OuA(t,e){t&1&&(S(0,"div",14,4),xe(2,4),R())}function PuA(t,e){t&1&&(S(0,"div",15,5),xe(2,5),R())}function juA(t,e){t&1&&UA(0,"div",16)}function quA(t,e){if(t&1&&(S(0,"div",18),xe(1,6),R()),t&2){let A=P();vA("@transitionMessages",A._subscriptAnimationState)}}function VuA(t,e){if(t&1&&(S(0,"mat-hint",22),tA(1),R()),t&2){let A=P(2);vA("id",A._hintLabelId),_(),Mt(A.hintLabel)}}function ZuA(t,e){if(t&1&&(S(0,"div",19),NA(1,VuA,2,2,"mat-hint",22),xe(2,7),UA(3,"div",23),xe(4,8),R()),t&2){let A=P();vA("@transitionMessages",A._subscriptAnimationState),_(),FA(A.hintLabel?1:-1)}}var r8=(()=>{class t{static \u0275fac=function(i){return new(i||t)};static \u0275dir=OA({type:t,selectors:[["mat-label"]]})}return t})(),WuA=new BA("MatError");var iP=(()=>{class t{align="start";id=m($i).getId("mat-mdc-hint-");static \u0275fac=function(i){return new(i||t)};static \u0275dir=OA({type:t,selectors:[["mat-hint"]],hostAttrs:[1,"mat-mdc-form-field-hint","mat-mdc-form-field-bottom-align"],hostVars:4,hostBindings:function(i,n){i&2&&(Fs("id",n.id),_e("align",null),ue("mat-mdc-form-field-hint-end",n.align==="end"))},inputs:{align:"align",id:"id"}})}return t})(),XuA=new BA("MatPrefix");var lP=new BA("MatSuffix"),gP=(()=>{class t{set _isTextSelector(A){this._isText=!0}_isText=!1;static \u0275fac=function(i){return new(i||t)};static \u0275dir=OA({type:t,selectors:[["","matSuffix",""],["","matIconSuffix",""],["","matTextSuffix",""]],inputs:{_isTextSelector:[0,"matTextSuffix","_isTextSelector"]},features:[ct([{provide:lP,useExisting:t}])]})}return t})(),IP=new BA("FloatingLabelParent"),nP=(()=>{class t{_elementRef=m(te);get floating(){return this._floating}set floating(A){this._floating=A,this.monitorResize&&this._handleResize()}_floating=!1;get monitorResize(){return this._monitorResize}set monitorResize(A){this._monitorResize=A,this._monitorResize?this._subscribeToResize():this._resizeSubscription.unsubscribe()}_monitorResize=!1;_resizeObserver=m(n8);_ngZone=m(de);_parent=m(IP);_resizeSubscription=new _t;constructor(){}ngOnDestroy(){this._resizeSubscription.unsubscribe()}getWidth(){return $uA(this._elementRef.nativeElement)}get element(){return this._elementRef.nativeElement}_handleResize(){setTimeout(()=>this._parent._handleLabelResized())}_subscribeToResize(){this._resizeSubscription.unsubscribe(),this._ngZone.runOutsideAngular(()=>{this._resizeSubscription=this._resizeObserver.observe(this._elementRef.nativeElement,{box:"border-box"}).subscribe(()=>this._handleResize())})}static \u0275fac=function(i){return new(i||t)};static \u0275dir=OA({type:t,selectors:[["label","matFormFieldFloatingLabel",""]],hostAttrs:[1,"mdc-floating-label","mat-mdc-floating-label"],hostVars:2,hostBindings:function(i,n){i&2&&ue("mdc-floating-label--float-above",n.floating)},inputs:{floating:"floating",monitorResize:"monitorResize"}})}return t})();function $uA(t){let e=t;if(e.offsetParent!==null)return e.scrollWidth;let A=e.cloneNode(!0);A.style.setProperty("position","absolute"),A.style.setProperty("transform","translate(-9999px, -9999px)"),document.documentElement.appendChild(A);let i=A.scrollWidth;return A.remove(),i}var oP="mdc-line-ripple--active",o8="mdc-line-ripple--deactivating",rP=(()=>{class t{_elementRef=m(te);_cleanupTransitionEnd;constructor(){let A=m(de),i=m(Gi);A.runOutsideAngular(()=>{this._cleanupTransitionEnd=i.listen(this._elementRef.nativeElement,"transitionend",this._handleTransitionEnd)})}activate(){let A=this._elementRef.nativeElement.classList;A.remove(o8),A.add(oP)}deactivate(){this._elementRef.nativeElement.classList.add(o8)}_handleTransitionEnd=A=>{let i=this._elementRef.nativeElement.classList,n=i.contains(o8);A.propertyName==="opacity"&&n&&i.remove(oP,o8)};ngOnDestroy(){this._cleanupTransitionEnd()}static \u0275fac=function(i){return new(i||t)};static \u0275dir=OA({type:t,selectors:[["div","matFormFieldLineRipple",""]],hostAttrs:[1,"mdc-line-ripple"]})}return t})(),sP=(()=>{class t{_elementRef=m(te);_ngZone=m(de);open=!1;_notch;constructor(){}ngAfterViewInit(){let A=this._elementRef.nativeElement.querySelector(".mdc-floating-label");A?(this._elementRef.nativeElement.classList.add("mdc-notched-outline--upgraded"),typeof requestAnimationFrame=="function"&&(A.style.transitionDuration="0s",this._ngZone.runOutsideAngular(()=>{requestAnimationFrame(()=>A.style.transitionDuration="")}))):this._elementRef.nativeElement.classList.add("mdc-notched-outline--no-label")}_setNotchWidth(A){!this.open||!A?this._notch.nativeElement.style.width="":this._notch.nativeElement.style.width=`calc(${A}px * var(--mat-mdc-form-field-floating-label-scale, 0.75) + 9px)`}static \u0275fac=function(i){return new(i||t)};static \u0275cmp=YA({type:t,selectors:[["div","matFormFieldNotchedOutline",""]],viewQuery:function(i,n){if(i&1&&Ge(DuA,5),i&2){let o;$A(o=Ae())&&(n._notch=o.first)}},hostAttrs:[1,"mdc-notched-outline"],hostVars:2,hostBindings:function(i,n){i&2&&ue("mdc-notched-outline--notched",n.open)},inputs:{open:[0,"matFormFieldNotchedOutlineOpen","open"]},attrs:yuA,ngContentSelectors:vuA,decls:5,vars:0,consts:[["notch",""],[1,"mat-mdc-notch-piece","mdc-notched-outline__leading"],[1,"mat-mdc-notch-piece","mdc-notched-outline__notch"],[1,"mat-mdc-notch-piece","mdc-notched-outline__trailing"]],template:function(i,n){i&1&&(Yt(),UA(0,"div",1),S(1,"div",2,0),xe(3),R(),UA(4,"div",3))},encapsulation:2,changeDetection:0})}return t})(),A4A={transitionMessages:cg("transitionMessages",[wc("enter",ar({opacity:1,transform:"translateY(0%)"})),la("void => enter",[ar({opacity:0,transform:"translateY(-5px)"}),$a("300ms cubic-bezier(0.55, 0, 0.55, 0.2)")])])},pu=(()=>{class t{value;stateChanges;id;placeholder;ngControl;focused;empty;shouldLabelFloat;required;disabled;errorState;controlType;autofilled;userAriaDescribedBy;disableAutomaticLabeling;static \u0275fac=function(i){return new(i||t)};static \u0275dir=OA({type:t})}return t})();var wu=new BA("MatFormField"),e4A=new BA("MAT_FORM_FIELD_DEFAULT_OPTIONS"),aP="fill",t4A="auto",cP="fixed",i4A="translateY(-50%)",lg=(()=>{class t{_elementRef=m(te);_changeDetectorRef=m(lt);_dir=m(bo);_platform=m(Zt);_idGenerator=m($i);_defaults=m(e4A,{optional:!0});_animationMode=m(mi,{optional:!0});_textField;_iconPrefixContainer;_textPrefixContainer;_iconSuffixContainer;_textSuffixContainer;_floatingLabel;_notchedOutline;_lineRipple;_formFieldControl;_prefixChildren;_suffixChildren;_errorChildren;_hintChildren;_labelChild=mT(r8);get hideRequiredMarker(){return this._hideRequiredMarker}set hideRequiredMarker(A){this._hideRequiredMarker=Yo(A)}_hideRequiredMarker=!1;color="primary";get floatLabel(){return this._floatLabel||this._defaults?.floatLabel||t4A}set floatLabel(A){A!==this._floatLabel&&(this._floatLabel=A,this._changeDetectorRef.markForCheck())}_floatLabel;get appearance(){return this._appearance}set appearance(A){let i=this._appearance,n=A||this._defaults?.appearance||aP;this._appearance=n,this._appearance==="outline"&&this._appearance!==i&&(this._needsOutlineLabelOffsetUpdate=!0)}_appearance=aP;get subscriptSizing(){return this._subscriptSizing||this._defaults?.subscriptSizing||cP}set subscriptSizing(A){this._subscriptSizing=A||this._defaults?.subscriptSizing||cP}_subscriptSizing=null;get hintLabel(){return this._hintLabel}set hintLabel(A){this._hintLabel=A,this._processHints()}_hintLabel="";_hasIconPrefix=!1;_hasTextPrefix=!1;_hasIconSuffix=!1;_hasTextSuffix=!1;_labelId=this._idGenerator.getId("mat-mdc-form-field-label-");_hintLabelId=this._idGenerator.getId("mat-mdc-hint-");_subscriptAnimationState="";get _control(){return this._explicitFormFieldControl||this._formFieldControl}set _control(A){this._explicitFormFieldControl=A}_destroyed=new HA;_isFocused=null;_explicitFormFieldControl;_needsOutlineLabelOffsetUpdate=!1;_previousControl=null;_stateChanges;_valueChanges;_describedByChanges;_injector=m(Dt);constructor(){let A=this._defaults;A&&(A.appearance&&(this.appearance=A.appearance),this._hideRequiredMarker=!!A?.hideRequiredMarker,A.color&&(this.color=A.color))}ngAfterViewInit(){this._updateFocusState(),this._subscriptAnimationState="enter",this._changeDetectorRef.detectChanges()}ngAfterContentInit(){this._assertFormFieldControl(),this._initializeSubscript(),this._initializePrefixAndSuffix(),this._initializeOutlineLabelOffsetSubscriptions()}ngAfterContentChecked(){this._assertFormFieldControl(),this._control!==this._previousControl&&(this._initializeControl(this._previousControl),this._previousControl=this._control)}ngOnDestroy(){this._stateChanges?.unsubscribe(),this._valueChanges?.unsubscribe(),this._describedByChanges?.unsubscribe(),this._destroyed.next(),this._destroyed.complete()}getLabelId=c0(()=>this._hasFloatingLabel()?this._labelId:null);getConnectedOverlayOrigin(){return this._textField||this._elementRef}_animateAndLockLabel(){this._hasFloatingLabel()&&(this.floatLabel="always")}_initializeControl(A){let i=this._control,n="mat-mdc-form-field-type-";A&&this._elementRef.nativeElement.classList.remove(n+A.controlType),i.controlType&&this._elementRef.nativeElement.classList.add(n+i.controlType),this._stateChanges?.unsubscribe(),this._stateChanges=i.stateChanges.subscribe(()=>{this._updateFocusState(),this._changeDetectorRef.markForCheck()}),this._describedByChanges?.unsubscribe(),this._describedByChanges=i.stateChanges.pipe(Qo([void 0,void 0]),Je(()=>[i.errorState,i.userAriaDescribedBy]),am(),pt(([[o,r],[s,a]])=>o!==s||r!==a)).subscribe(()=>this._syncDescribedByIds()),this._valueChanges?.unsubscribe(),i.ngControl&&i.ngControl.valueChanges&&(this._valueChanges=i.ngControl.valueChanges.pipe(wt(this._destroyed)).subscribe(()=>this._changeDetectorRef.markForCheck()))}_checkPrefixAndSuffixTypes(){this._hasIconPrefix=!!this._prefixChildren.find(A=>!A._isText),this._hasTextPrefix=!!this._prefixChildren.find(A=>A._isText),this._hasIconSuffix=!!this._suffixChildren.find(A=>!A._isText),this._hasTextSuffix=!!this._suffixChildren.find(A=>A._isText)}_initializePrefixAndSuffix(){this._checkPrefixAndSuffixTypes(),ho(this._prefixChildren.changes,this._suffixChildren.changes).subscribe(()=>{this._checkPrefixAndSuffixTypes(),this._changeDetectorRef.markForCheck()})}_initializeSubscript(){this._hintChildren.changes.subscribe(()=>{this._processHints(),this._changeDetectorRef.markForCheck()}),this._errorChildren.changes.subscribe(()=>{this._syncDescribedByIds(),this._changeDetectorRef.markForCheck()}),this._validateHints(),this._syncDescribedByIds()}_assertFormFieldControl(){this._control}_updateFocusState(){this._control.focused&&!this._isFocused?(this._isFocused=!0,this._lineRipple?.activate()):!this._control.focused&&(this._isFocused||this._isFocused===null)&&(this._isFocused=!1,this._lineRipple?.deactivate()),this._textField?.nativeElement.classList.toggle("mdc-text-field--focused",this._control.focused)}_initializeOutlineLabelOffsetSubscriptions(){this._prefixChildren.changes.subscribe(()=>this._needsOutlineLabelOffsetUpdate=!0),IQ(()=>{this._needsOutlineLabelOffsetUpdate&&(this._needsOutlineLabelOffsetUpdate=!1,this._updateOutlineLabelOffset())},{injector:this._injector}),this._dir.change.pipe(wt(this._destroyed)).subscribe(()=>this._needsOutlineLabelOffsetUpdate=!0)}_shouldAlwaysFloat(){return this.floatLabel==="always"}_hasOutline(){return this.appearance==="outline"}_forceDisplayInfixLabel(){return!this._platform.isBrowser&&this._prefixChildren.length&&!this._shouldLabelFloat()}_hasFloatingLabel=c0(()=>!!this._labelChild());_shouldLabelFloat(){return this._hasFloatingLabel()?this._control.shouldLabelFloat||this._shouldAlwaysFloat():!1}_shouldForward(A){let i=this._control?this._control.ngControl:null;return i&&i[A]}_getDisplayedMessages(){return this._errorChildren&&this._errorChildren.length>0&&this._control.errorState?"error":"hint"}_handleLabelResized(){this._refreshOutlineNotchWidth()}_refreshOutlineNotchWidth(){!this._hasOutline()||!this._floatingLabel||!this._shouldLabelFloat()?this._notchedOutline?._setNotchWidth(0):this._notchedOutline?._setNotchWidth(this._floatingLabel.getWidth())}_processHints(){this._validateHints(),this._syncDescribedByIds()}_validateHints(){this._hintChildren}_syncDescribedByIds(){if(this._control){let A=[];if(this._control.userAriaDescribedBy&&typeof this._control.userAriaDescribedBy=="string"&&A.push(...this._control.userAriaDescribedBy.split(" ")),this._getDisplayedMessages()==="hint"){let i=this._hintChildren?this._hintChildren.find(o=>o.align==="start"):null,n=this._hintChildren?this._hintChildren.find(o=>o.align==="end"):null;i?A.push(i.id):this._hintLabel&&A.push(this._hintLabelId),n&&A.push(n.id)}else this._errorChildren&&A.push(...this._errorChildren.map(i=>i.id));this._control.setDescribedByIds(A)}}_updateOutlineLabelOffset(){if(!this._hasOutline()||!this._floatingLabel)return;let A=this._floatingLabel.element;if(!(this._iconPrefixContainer||this._textPrefixContainer)){A.style.transform="";return}if(!this._isAttachedToDom()){this._needsOutlineLabelOffsetUpdate=!0;return}let i=this._iconPrefixContainer?.nativeElement,n=this._textPrefixContainer?.nativeElement,o=this._iconSuffixContainer?.nativeElement,r=this._textSuffixContainer?.nativeElement,s=i?.getBoundingClientRect().width??0,a=n?.getBoundingClientRect().width??0,c=o?.getBoundingClientRect().width??0,l=r?.getBoundingClientRect().width??0,I=this._dir.value==="rtl"?"-1":"1",C=`${s+a}px`,B=`calc(${I} * (${C} + var(--mat-mdc-form-field-label-offset-x, 0px)))`;A.style.transform=`var(
        --mat-mdc-form-field-label-transform,
        ${i4A} translateX(${B})
    )`;let E=s+a+c+l;this._elementRef.nativeElement.style.setProperty("--mat-form-field-notch-max-width",`calc(100% - ${E}px)`)}_isAttachedToDom(){let A=this._elementRef.nativeElement;if(A.getRootNode){let i=A.getRootNode();return i&&i!==A}return document.documentElement.contains(A)}static \u0275fac=function(i){return new(i||t)};static \u0275cmp=YA({type:t,selectors:[["mat-form-field"]],contentQueries:function(i,n,o){if(i&1&&(zT(o,n._labelChild,r8,5),Ii(o,pu,5),Ii(o,XuA,5),Ii(o,lP,5),Ii(o,WuA,5),Ii(o,iP,5)),i&2){HT();let r;$A(r=Ae())&&(n._formFieldControl=r.first),$A(r=Ae())&&(n._prefixChildren=r),$A(r=Ae())&&(n._suffixChildren=r),$A(r=Ae())&&(n._errorChildren=r),$A(r=Ae())&&(n._hintChildren=r)}},viewQuery:function(i,n){if(i&1&&(Ge(buA,5),Ge(MuA,5),Ge(kuA,5),Ge(SuA,5),Ge(RuA,5),Ge(nP,5),Ge(sP,5),Ge(rP,5)),i&2){let o;$A(o=Ae())&&(n._textField=o.first),$A(o=Ae())&&(n._iconPrefixContainer=o.first),$A(o=Ae())&&(n._textPrefixContainer=o.first),$A(o=Ae())&&(n._iconSuffixContainer=o.first),$A(o=Ae())&&(n._textSuffixContainer=o.first),$A(o=Ae())&&(n._floatingLabel=o.first),$A(o=Ae())&&(n._notchedOutline=o.first),$A(o=Ae())&&(n._lineRipple=o.first)}},hostAttrs:[1,"mat-mdc-form-field"],hostVars:42,hostBindings:function(i,n){i&2&&ue("mat-mdc-form-field-label-always-float",n._shouldAlwaysFloat())("mat-mdc-form-field-has-icon-prefix",n._hasIconPrefix)("mat-mdc-form-field-has-icon-suffix",n._hasIconSuffix)("mat-form-field-invalid",n._control.errorState)("mat-form-field-disabled",n._control.disabled)("mat-form-field-autofilled",n._control.autofilled)("mat-form-field-no-animations",n._animationMode==="NoopAnimations")("mat-form-field-appearance-fill",n.appearance=="fill")("mat-form-field-appearance-outline",n.appearance=="outline")("mat-form-field-hide-placeholder",n._hasFloatingLabel()&&!n._shouldLabelFloat())("mat-focused",n._control.focused)("mat-primary",n.color!=="accent"&&n.color!=="warn")("mat-accent",n.color==="accent")("mat-warn",n.color==="warn")("ng-untouched",n._shouldForward("untouched"))("ng-touched",n._shouldForward("touched"))("ng-pristine",n._shouldForward("pristine"))("ng-dirty",n._shouldForward("dirty"))("ng-valid",n._shouldForward("valid"))("ng-invalid",n._shouldForward("invalid"))("ng-pending",n._shouldForward("pending"))},inputs:{hideRequiredMarker:"hideRequiredMarker",color:"color",floatLabel:"floatLabel",appearance:"appearance",subscriptSizing:"subscriptSizing",hintLabel:"hintLabel"},exportAs:["matFormField"],features:[ct([{provide:wu,useExisting:t},{provide:IP,useExisting:t}])],ngContentSelectors:xuA,decls:18,vars:21,consts:[["labelTemplate",""],["textField",""],["iconPrefixContainer",""],["textPrefixContainer",""],["textSuffixContainer",""],["iconSuffixContainer",""],[1,"mat-mdc-text-field-wrapper","mdc-text-field",3,"click"],[1,"mat-mdc-form-field-focus-overlay"],[1,"mat-mdc-form-field-flex"],["matFormFieldNotchedOutline","",3,"matFormFieldNotchedOutlineOpen"],[1,"mat-mdc-form-field-icon-prefix"],[1,"mat-mdc-form-field-text-prefix"],[1,"mat-mdc-form-field-infix"],[3,"ngTemplateOutlet"],[1,"mat-mdc-form-field-text-suffix"],[1,"mat-mdc-form-field-icon-suffix"],["matFormFieldLineRipple",""],[1,"mat-mdc-form-field-subscript-wrapper","mat-mdc-form-field-bottom-align"],[1,"mat-mdc-form-field-error-wrapper"],[1,"mat-mdc-form-field-hint-wrapper"],["matFormFieldFloatingLabel","",3,"floating","monitorResize","id"],["aria-hidden","true",1,"mat-mdc-form-field-required-marker","mdc-floating-label--required"],[3,"id"],[1,"mat-mdc-form-field-hint-spacer"]],template:function(i,n){if(i&1){let o=De();Yt(LuA),NA(0,_uA,1,1,"ng-template",null,0,fQ),S(2,"div",6,1),mA("click",function(s){return LA(o),xA(n._control.onContainerClick(s))}),NA(4,GuA,1,0,"div",7),S(5,"div",8),NA(6,YuA,2,2,"div",9)(7,JuA,3,0,"div",10)(8,TuA,3,0,"div",11),S(9,"div",12),NA(10,HuA,1,1,null,13),xe(11),R(),NA(12,OuA,3,0,"div",14)(13,PuA,3,0,"div",15),R(),NA(14,juA,1,0,"div",16),R(),S(15,"div",17),NA(16,quA,2,1,"div",18)(17,ZuA,5,2,"div",19),R()}if(i&2){let o;_(2),ue("mdc-text-field--filled",!n._hasOutline())("mdc-text-field--outlined",n._hasOutline())("mdc-text-field--no-label",!n._hasFloatingLabel())("mdc-text-field--disabled",n._control.disabled)("mdc-text-field--invalid",n._control.errorState),_(2),FA(!n._hasOutline()&&!n._control.disabled?4:-1),_(2),FA(n._hasOutline()?6:-1),_(),FA(n._hasIconPrefix?7:-1),_(),FA(n._hasTextPrefix?8:-1),_(2),FA(!n._hasOutline()||n._forceDisplayInfixLabel()?10:-1),_(2),FA(n._hasTextSuffix?12:-1),_(),FA(n._hasIconSuffix?13:-1),_(),FA(n._hasOutline()?-1:14),_(),ue("mat-mdc-form-field-subscript-dynamic-size",n.subscriptSizing==="dynamic"),_(),FA((o=n._getDisplayedMessages())==="error"?16:o==="hint"?17:-1)}},dependencies:[nP,sP,vQ,rP,iP],styles:['.mdc-text-field{display:inline-flex;align-items:baseline;padding:0 16px;position:relative;box-sizing:border-box;overflow:hidden;will-change:opacity,transform,color;border-top-left-radius:4px;border-top-right-radius:4px;border-bottom-right-radius:0;border-bottom-left-radius:0}.mdc-text-field__input{width:100%;min-width:0;border:none;border-radius:0;background:none;padding:0;-moz-appearance:none;-webkit-appearance:none;height:28px}.mdc-text-field__input::-webkit-calendar-picker-indicator{display:none}.mdc-text-field__input::-ms-clear{display:none}.mdc-text-field__input:focus{outline:none}.mdc-text-field__input:invalid{box-shadow:none}.mdc-text-field__input::placeholder{opacity:0}.mdc-text-field__input::-moz-placeholder{opacity:0}.mdc-text-field__input::-webkit-input-placeholder{opacity:0}.mdc-text-field__input:-ms-input-placeholder{opacity:0}.mdc-text-field--no-label .mdc-text-field__input::placeholder,.mdc-text-field--focused .mdc-text-field__input::placeholder{opacity:1}.mdc-text-field--no-label .mdc-text-field__input::-moz-placeholder,.mdc-text-field--focused .mdc-text-field__input::-moz-placeholder{opacity:1}.mdc-text-field--no-label .mdc-text-field__input::-webkit-input-placeholder,.mdc-text-field--focused .mdc-text-field__input::-webkit-input-placeholder{opacity:1}.mdc-text-field--no-label .mdc-text-field__input:-ms-input-placeholder,.mdc-text-field--focused .mdc-text-field__input:-ms-input-placeholder{opacity:1}.mdc-text-field--disabled:not(.mdc-text-field--no-label) .mdc-text-field__input.mat-mdc-input-disabled-interactive::placeholder{opacity:0}.mdc-text-field--disabled:not(.mdc-text-field--no-label) .mdc-text-field__input.mat-mdc-input-disabled-interactive::-moz-placeholder{opacity:0}.mdc-text-field--disabled:not(.mdc-text-field--no-label) .mdc-text-field__input.mat-mdc-input-disabled-interactive::-webkit-input-placeholder{opacity:0}.mdc-text-field--disabled:not(.mdc-text-field--no-label) .mdc-text-field__input.mat-mdc-input-disabled-interactive:-ms-input-placeholder{opacity:0}.mdc-text-field--outlined .mdc-text-field__input,.mdc-text-field--filled.mdc-text-field--no-label .mdc-text-field__input{height:100%}.mdc-text-field--outlined .mdc-text-field__input{display:flex;border:none !important;background-color:rgba(0,0,0,0)}.mdc-text-field--disabled .mdc-text-field__input{pointer-events:auto}.mdc-text-field--filled:not(.mdc-text-field--disabled) .mdc-text-field__input{color:var(--mdc-filled-text-field-input-text-color, var(--mat-sys-on-surface));caret-color:var(--mdc-filled-text-field-caret-color, var(--mat-sys-primary))}.mdc-text-field--filled:not(.mdc-text-field--disabled) .mdc-text-field__input::placeholder{color:var(--mdc-filled-text-field-input-text-placeholder-color, var(--mat-sys-on-surface-variant))}.mdc-text-field--filled:not(.mdc-text-field--disabled) .mdc-text-field__input::-moz-placeholder{color:var(--mdc-filled-text-field-input-text-placeholder-color, var(--mat-sys-on-surface-variant))}.mdc-text-field--filled:not(.mdc-text-field--disabled) .mdc-text-field__input::-webkit-input-placeholder{color:var(--mdc-filled-text-field-input-text-placeholder-color, var(--mat-sys-on-surface-variant))}.mdc-text-field--filled:not(.mdc-text-field--disabled) .mdc-text-field__input:-ms-input-placeholder{color:var(--mdc-filled-text-field-input-text-placeholder-color, var(--mat-sys-on-surface-variant))}.mdc-text-field--filled.mdc-text-field--invalid:not(.mdc-text-field--disabled) .mdc-text-field__input{caret-color:var(--mdc-filled-text-field-error-caret-color)}.mdc-text-field--filled.mdc-text-field--disabled .mdc-text-field__input{color:var(--mdc-filled-text-field-disabled-input-text-color, color-mix(in srgb, var(--mat-sys-on-surface) 38%, transparent))}.mdc-text-field--outlined:not(.mdc-text-field--disabled) .mdc-text-field__input{color:var(--mdc-outlined-text-field-input-text-color, var(--mat-sys-on-surface));caret-color:var(--mdc-outlined-text-field-caret-color, var(--mat-sys-primary))}.mdc-text-field--outlined:not(.mdc-text-field--disabled) .mdc-text-field__input::placeholder{color:var(--mdc-outlined-text-field-input-text-placeholder-color, var(--mat-sys-on-surface-variant))}.mdc-text-field--outlined:not(.mdc-text-field--disabled) .mdc-text-field__input::-moz-placeholder{color:var(--mdc-outlined-text-field-input-text-placeholder-color, var(--mat-sys-on-surface-variant))}.mdc-text-field--outlined:not(.mdc-text-field--disabled) .mdc-text-field__input::-webkit-input-placeholder{color:var(--mdc-outlined-text-field-input-text-placeholder-color, var(--mat-sys-on-surface-variant))}.mdc-text-field--outlined:not(.mdc-text-field--disabled) .mdc-text-field__input:-ms-input-placeholder{color:var(--mdc-outlined-text-field-input-text-placeholder-color, var(--mat-sys-on-surface-variant))}.mdc-text-field--outlined.mdc-text-field--invalid:not(.mdc-text-field--disabled) .mdc-text-field__input{caret-color:var(--mdc-outlined-text-field-error-caret-color)}.mdc-text-field--outlined.mdc-text-field--disabled .mdc-text-field__input{color:var(--mdc-outlined-text-field-disabled-input-text-color, color-mix(in srgb, var(--mat-sys-on-surface) 38%, transparent))}@media(forced-colors: active){.mdc-text-field--disabled .mdc-text-field__input{background-color:Window}}.mdc-text-field--filled{height:56px;border-bottom-right-radius:0;border-bottom-left-radius:0;border-top-left-radius:var(--mdc-filled-text-field-container-shape, var(--mat-sys-corner-extra-small));border-top-right-radius:var(--mdc-filled-text-field-container-shape, var(--mat-sys-corner-extra-small))}.mdc-text-field--filled:not(.mdc-text-field--disabled){background-color:var(--mdc-filled-text-field-container-color, var(--mat-sys-surface-variant))}.mdc-text-field--filled.mdc-text-field--disabled{background-color:var(--mdc-filled-text-field-disabled-container-color, color-mix(in srgb, var(--mat-sys-on-surface) 4%, transparent))}.mdc-text-field--outlined{height:56px;overflow:visible;padding-right:max(16px,var(--mdc-outlined-text-field-container-shape, var(--mat-sys-corner-extra-small)));padding-left:max(16px,var(--mdc-outlined-text-field-container-shape, var(--mat-sys-corner-extra-small)) + 4px)}[dir=rtl] .mdc-text-field--outlined{padding-right:max(16px,var(--mdc-outlined-text-field-container-shape, var(--mat-sys-corner-extra-small)) + 4px);padding-left:max(16px,var(--mdc-outlined-text-field-container-shape, var(--mat-sys-corner-extra-small)))}.mdc-floating-label{position:absolute;left:0;transform-origin:left top;line-height:1.15rem;text-align:left;text-overflow:ellipsis;white-space:nowrap;cursor:text;overflow:hidden;will-change:transform}[dir=rtl] .mdc-floating-label{right:0;left:auto;transform-origin:right top;text-align:right}.mdc-text-field .mdc-floating-label{top:50%;transform:translateY(-50%);pointer-events:none}.mdc-notched-outline .mdc-floating-label{display:inline-block;position:relative;max-width:100%}.mdc-text-field--outlined .mdc-floating-label{left:4px;right:auto}[dir=rtl] .mdc-text-field--outlined .mdc-floating-label{left:auto;right:4px}.mdc-text-field--filled .mdc-floating-label{left:16px;right:auto}[dir=rtl] .mdc-text-field--filled .mdc-floating-label{left:auto;right:16px}.mdc-text-field--disabled .mdc-floating-label{cursor:default}@media(forced-colors: active){.mdc-text-field--disabled .mdc-floating-label{z-index:1}}.mdc-text-field--filled.mdc-text-field--no-label .mdc-floating-label{display:none}.mdc-text-field--filled:not(.mdc-text-field--disabled) .mdc-floating-label{color:var(--mdc-filled-text-field-label-text-color, var(--mat-sys-on-surface-variant))}.mdc-text-field--filled:not(.mdc-text-field--disabled).mdc-text-field--focused .mdc-floating-label{color:var(--mdc-filled-text-field-focus-label-text-color, var(--mat-sys-primary))}.mdc-text-field--filled:not(.mdc-text-field--disabled):not(.mdc-text-field--focused):hover .mdc-floating-label{color:var(--mdc-filled-text-field-hover-label-text-color, var(--mat-sys-on-surface-variant))}.mdc-text-field--filled.mdc-text-field--disabled .mdc-floating-label{color:var(--mdc-filled-text-field-disabled-label-text-color, color-mix(in srgb, var(--mat-sys-on-surface) 38%, transparent))}.mdc-text-field--filled:not(.mdc-text-field--disabled).mdc-text-field--invalid .mdc-floating-label{color:var(--mdc-filled-text-field-error-label-text-color, var(--mat-sys-error))}.mdc-text-field--filled:not(.mdc-text-field--disabled).mdc-text-field--invalid.mdc-text-field--focused .mdc-floating-label{color:var(--mdc-filled-text-field-error-focus-label-text-color, var(--mat-sys-error))}.mdc-text-field--filled:not(.mdc-text-field--disabled).mdc-text-field--invalid:not(.mdc-text-field--disabled):hover .mdc-floating-label{color:var(--mdc-filled-text-field-error-hover-label-text-color, var(--mat-sys-on-error-container))}.mdc-text-field--filled .mdc-floating-label{font-family:var(--mdc-filled-text-field-label-text-font, var(--mat-sys-body-large-font));font-size:var(--mdc-filled-text-field-label-text-size, var(--mat-sys-body-large-size));font-weight:var(--mdc-filled-text-field-label-text-weight, var(--mat-sys-body-large-weight));letter-spacing:var(--mdc-filled-text-field-label-text-tracking, var(--mat-sys-body-large-tracking))}.mdc-text-field--outlined:not(.mdc-text-field--disabled) .mdc-floating-label{color:var(--mdc-outlined-text-field-label-text-color, var(--mat-sys-on-surface-variant))}.mdc-text-field--outlined:not(.mdc-text-field--disabled).mdc-text-field--focused .mdc-floating-label{color:var(--mdc-outlined-text-field-focus-label-text-color, var(--mat-sys-primary))}.mdc-text-field--outlined:not(.mdc-text-field--disabled):not(.mdc-text-field--focused):hover .mdc-floating-label{color:var(--mdc-outlined-text-field-hover-label-text-color, var(--mat-sys-on-surface))}.mdc-text-field--outlined.mdc-text-field--disabled .mdc-floating-label{color:var(--mdc-outlined-text-field-disabled-label-text-color, color-mix(in srgb, var(--mat-sys-on-surface) 38%, transparent))}.mdc-text-field--outlined:not(.mdc-text-field--disabled).mdc-text-field--invalid .mdc-floating-label{color:var(--mdc-outlined-text-field-error-label-text-color, var(--mat-sys-error))}.mdc-text-field--outlined:not(.mdc-text-field--disabled).mdc-text-field--invalid.mdc-text-field--focused .mdc-floating-label{color:var(--mdc-outlined-text-field-error-focus-label-text-color, var(--mat-sys-error))}.mdc-text-field--outlined:not(.mdc-text-field--disabled).mdc-text-field--invalid:not(.mdc-text-field--disabled):hover .mdc-floating-label{color:var(--mdc-outlined-text-field-error-hover-label-text-color, var(--mat-sys-on-error-container))}.mdc-text-field--outlined .mdc-floating-label{font-family:var(--mdc-outlined-text-field-label-text-font, var(--mat-sys-body-large-font));font-size:var(--mdc-outlined-text-field-label-text-size, var(--mat-sys-body-large-size));font-weight:var(--mdc-outlined-text-field-label-text-weight, var(--mat-sys-body-large-weight));letter-spacing:var(--mdc-outlined-text-field-label-text-tracking, var(--mat-sys-body-large-tracking))}.mdc-floating-label--float-above{cursor:auto;transform:translateY(-106%) scale(0.75)}.mdc-text-field--filled .mdc-floating-label--float-above{transform:translateY(-106%) scale(0.75)}.mdc-text-field--outlined .mdc-floating-label--float-above{transform:translateY(-37.25px) scale(1);font-size:.75rem}.mdc-notched-outline .mdc-floating-label--float-above{text-overflow:clip}.mdc-notched-outline--upgraded .mdc-floating-label--float-above{max-width:133.3333333333%}.mdc-text-field--outlined.mdc-notched-outline--upgraded .mdc-floating-label--float-above,.mdc-text-field--outlined .mdc-notched-outline--upgraded .mdc-floating-label--float-above{transform:translateY(-34.75px) scale(0.75)}.mdc-text-field--outlined.mdc-notched-outline--upgraded .mdc-floating-label--float-above,.mdc-text-field--outlined .mdc-notched-outline--upgraded .mdc-floating-label--float-above{font-size:1rem}.mdc-floating-label--required:not(.mdc-floating-label--hide-required-marker)::after{margin-left:1px;margin-right:0;content:"*"}[dir=rtl] .mdc-floating-label--required:not(.mdc-floating-label--hide-required-marker)::after{margin-left:0;margin-right:1px}.mdc-notched-outline{display:flex;position:absolute;top:0;right:0;left:0;box-sizing:border-box;width:100%;max-width:100%;height:100%;text-align:left;pointer-events:none}[dir=rtl] .mdc-notched-outline{text-align:right}.mdc-text-field--outlined .mdc-notched-outline{z-index:1}.mat-mdc-notch-piece{box-sizing:border-box;height:100%;pointer-events:none;border-top:1px solid;border-bottom:1px solid}.mdc-text-field--focused .mat-mdc-notch-piece{border-width:2px}.mdc-text-field--outlined:not(.mdc-text-field--disabled) .mat-mdc-notch-piece{border-color:var(--mdc-outlined-text-field-outline-color, var(--mat-sys-outline));border-width:var(--mdc-outlined-text-field-outline-width, 1px)}.mdc-text-field--outlined:not(.mdc-text-field--disabled):not(.mdc-text-field--focused):hover .mat-mdc-notch-piece{border-color:var(--mdc-outlined-text-field-hover-outline-color, var(--mat-sys-on-surface))}.mdc-text-field--outlined:not(.mdc-text-field--disabled).mdc-text-field--focused .mat-mdc-notch-piece{border-color:var(--mdc-outlined-text-field-focus-outline-color, var(--mat-sys-primary))}.mdc-text-field--outlined.mdc-text-field--disabled .mat-mdc-notch-piece{border-color:var(--mdc-outlined-text-field-disabled-outline-color, color-mix(in srgb, var(--mat-sys-on-surface) 12%, transparent))}.mdc-text-field--outlined:not(.mdc-text-field--disabled).mdc-text-field--invalid .mat-mdc-notch-piece{border-color:var(--mdc-outlined-text-field-error-outline-color, var(--mat-sys-error))}.mdc-text-field--outlined:not(.mdc-text-field--disabled).mdc-text-field--invalid:not(.mdc-text-field--focused):hover .mdc-notched-outline .mat-mdc-notch-piece{border-color:var(--mdc-outlined-text-field-error-hover-outline-color, var(--mat-sys-on-error-container))}.mdc-text-field--outlined:not(.mdc-text-field--disabled).mdc-text-field--invalid.mdc-text-field--focused .mat-mdc-notch-piece{border-color:var(--mdc-outlined-text-field-error-focus-outline-color, var(--mat-sys-error))}.mdc-text-field--outlined:not(.mdc-text-field--disabled).mdc-text-field--focused .mdc-notched-outline .mat-mdc-notch-piece{border-width:var(--mdc-outlined-text-field-focus-outline-width, 2px)}.mdc-notched-outline__leading{border-left:1px solid;border-right:none;border-top-right-radius:0;border-bottom-right-radius:0;border-top-left-radius:var(--mdc-outlined-text-field-container-shape, var(--mat-sys-corner-extra-small));border-bottom-left-radius:var(--mdc-outlined-text-field-container-shape, var(--mat-sys-corner-extra-small))}.mdc-text-field--outlined .mdc-notched-outline .mdc-notched-outline__leading{width:max(12px,var(--mdc-outlined-text-field-container-shape, var(--mat-sys-corner-extra-small)))}[dir=rtl] .mdc-notched-outline__leading{border-left:none;border-right:1px solid;border-bottom-left-radius:0;border-top-left-radius:0;border-top-right-radius:var(--mdc-outlined-text-field-container-shape, var(--mat-sys-corner-extra-small));border-bottom-right-radius:var(--mdc-outlined-text-field-container-shape, var(--mat-sys-corner-extra-small))}.mdc-notched-outline__trailing{flex-grow:1;border-left:none;border-right:1px solid;border-top-left-radius:0;border-bottom-left-radius:0;border-top-right-radius:var(--mdc-outlined-text-field-container-shape, var(--mat-sys-corner-extra-small));border-bottom-right-radius:var(--mdc-outlined-text-field-container-shape, var(--mat-sys-corner-extra-small))}[dir=rtl] .mdc-notched-outline__trailing{border-left:1px solid;border-right:none;border-top-right-radius:0;border-bottom-right-radius:0;border-top-left-radius:var(--mdc-outlined-text-field-container-shape, var(--mat-sys-corner-extra-small));border-bottom-left-radius:var(--mdc-outlined-text-field-container-shape, var(--mat-sys-corner-extra-small))}.mdc-notched-outline__notch{flex:0 0 auto;width:auto}.mdc-text-field--outlined .mdc-notched-outline .mdc-notched-outline__notch{max-width:min(var(--mat-form-field-notch-max-width, 100%),100% - max(12px,var(--mdc-outlined-text-field-container-shape, var(--mat-sys-corner-extra-small)))*2)}.mdc-text-field--outlined .mdc-notched-outline--notched .mdc-notched-outline__notch{padding-top:1px}.mdc-text-field--focused.mdc-text-field--outlined .mdc-notched-outline--notched .mdc-notched-outline__notch{padding-top:2px}.mdc-notched-outline--notched .mdc-notched-outline__notch{padding-left:0;padding-right:8px;border-top:none;--mat-form-field-notch-max-width: 100%}[dir=rtl] .mdc-notched-outline--notched .mdc-notched-outline__notch{padding-left:8px;padding-right:0}.mdc-notched-outline--no-label .mdc-notched-outline__notch{display:none}.mdc-line-ripple::before,.mdc-line-ripple::after{position:absolute;bottom:0;left:0;width:100%;border-bottom-style:solid;content:""}.mdc-line-ripple::before{z-index:1;border-bottom-width:var(--mdc-filled-text-field-active-indicator-height, 1px)}.mdc-text-field--filled:not(.mdc-text-field--disabled) .mdc-line-ripple::before{border-bottom-color:var(--mdc-filled-text-field-active-indicator-color, var(--mat-sys-on-surface-variant))}.mdc-text-field--filled:not(.mdc-text-field--disabled):not(.mdc-text-field--focused):hover .mdc-line-ripple::before{border-bottom-color:var(--mdc-filled-text-field-hover-active-indicator-color, var(--mat-sys-on-surface))}.mdc-text-field--filled.mdc-text-field--disabled .mdc-line-ripple::before{border-bottom-color:var(--mdc-filled-text-field-disabled-active-indicator-color, color-mix(in srgb, var(--mat-sys-on-surface) 38%, transparent))}.mdc-text-field--filled:not(.mdc-text-field--disabled).mdc-text-field--invalid .mdc-line-ripple::before{border-bottom-color:var(--mdc-filled-text-field-error-active-indicator-color, var(--mat-sys-error))}.mdc-text-field--filled:not(.mdc-text-field--disabled).mdc-text-field--invalid:not(.mdc-text-field--focused):hover .mdc-line-ripple::before{border-bottom-color:var(--mdc-filled-text-field-error-hover-active-indicator-color, var(--mat-sys-on-error-container))}.mdc-line-ripple::after{transform:scaleX(0);opacity:0;z-index:2}.mdc-text-field--filled .mdc-line-ripple::after{border-bottom-width:var(--mdc-filled-text-field-focus-active-indicator-height, 2px)}.mdc-text-field--filled:not(.mdc-text-field--disabled) .mdc-line-ripple::after{border-bottom-color:var(--mdc-filled-text-field-focus-active-indicator-color, var(--mat-sys-primary))}.mdc-text-field--filled.mdc-text-field--invalid:not(.mdc-text-field--disabled) .mdc-line-ripple::after{border-bottom-color:var(--mdc-filled-text-field-error-focus-active-indicator-color, var(--mat-sys-error))}.mdc-line-ripple--active::after{transform:scaleX(1);opacity:1}.mdc-line-ripple--deactivating::after{opacity:0}.mdc-text-field--disabled{pointer-events:none}.mat-mdc-form-field-textarea-control{vertical-align:middle;resize:vertical;box-sizing:border-box;height:auto;margin:0;padding:0;border:none;overflow:auto}.mat-mdc-form-field-input-control.mat-mdc-form-field-input-control{-moz-osx-font-smoothing:grayscale;-webkit-font-smoothing:antialiased;font:inherit;letter-spacing:inherit;text-decoration:inherit;text-transform:inherit;border:none}.mat-mdc-form-field .mat-mdc-floating-label.mdc-floating-label{-moz-osx-font-smoothing:grayscale;-webkit-font-smoothing:antialiased;line-height:normal;pointer-events:all;will-change:auto}.mat-mdc-form-field:not(.mat-form-field-disabled) .mat-mdc-floating-label.mdc-floating-label{cursor:inherit}.mdc-text-field--no-label:not(.mdc-text-field--textarea) .mat-mdc-form-field-input-control.mdc-text-field__input,.mat-mdc-text-field-wrapper .mat-mdc-form-field-input-control{height:auto}.mat-mdc-text-field-wrapper .mat-mdc-form-field-input-control.mdc-text-field__input[type=color]{height:23px}.mat-mdc-text-field-wrapper{height:auto;flex:auto;will-change:auto}.mat-mdc-form-field-has-icon-prefix .mat-mdc-text-field-wrapper{padding-left:0;--mat-mdc-form-field-label-offset-x: -16px}.mat-mdc-form-field-has-icon-suffix .mat-mdc-text-field-wrapper{padding-right:0}[dir=rtl] .mat-mdc-text-field-wrapper{padding-left:16px;padding-right:16px}[dir=rtl] .mat-mdc-form-field-has-icon-suffix .mat-mdc-text-field-wrapper{padding-left:0}[dir=rtl] .mat-mdc-form-field-has-icon-prefix .mat-mdc-text-field-wrapper{padding-right:0}.mat-form-field-disabled .mdc-text-field__input::placeholder{color:var(--mat-form-field-disabled-input-text-placeholder-color, color-mix(in srgb, var(--mat-sys-on-surface) 38%, transparent))}.mat-form-field-disabled .mdc-text-field__input::-moz-placeholder{color:var(--mat-form-field-disabled-input-text-placeholder-color, color-mix(in srgb, var(--mat-sys-on-surface) 38%, transparent))}.mat-form-field-disabled .mdc-text-field__input::-webkit-input-placeholder{color:var(--mat-form-field-disabled-input-text-placeholder-color, color-mix(in srgb, var(--mat-sys-on-surface) 38%, transparent))}.mat-form-field-disabled .mdc-text-field__input:-ms-input-placeholder{color:var(--mat-form-field-disabled-input-text-placeholder-color, color-mix(in srgb, var(--mat-sys-on-surface) 38%, transparent))}.mat-mdc-form-field-label-always-float .mdc-text-field__input::placeholder{transition-delay:40ms;transition-duration:110ms;opacity:1}.mat-mdc-text-field-wrapper .mat-mdc-form-field-infix .mat-mdc-floating-label{left:auto;right:auto}.mat-mdc-text-field-wrapper.mdc-text-field--outlined .mdc-text-field__input{display:inline-block}.mat-mdc-form-field .mat-mdc-text-field-wrapper.mdc-text-field .mdc-notched-outline__notch{padding-top:0}.mat-mdc-form-field.mat-mdc-form-field.mat-mdc-form-field.mat-mdc-form-field.mat-mdc-form-field.mat-mdc-form-field .mdc-notched-outline__notch{border-left:1px solid rgba(0,0,0,0)}[dir=rtl] .mat-mdc-form-field.mat-mdc-form-field.mat-mdc-form-field.mat-mdc-form-field.mat-mdc-form-field.mat-mdc-form-field .mdc-notched-outline__notch{border-left:none;border-right:1px solid rgba(0,0,0,0)}.mat-mdc-form-field-infix{min-height:var(--mat-form-field-container-height, 56px);padding-top:var(--mat-form-field-filled-with-label-container-padding-top, 24px);padding-bottom:var(--mat-form-field-filled-with-label-container-padding-bottom, 8px)}.mdc-text-field--outlined .mat-mdc-form-field-infix,.mdc-text-field--no-label .mat-mdc-form-field-infix{padding-top:var(--mat-form-field-container-vertical-padding, 16px);padding-bottom:var(--mat-form-field-container-vertical-padding, 16px)}.mat-mdc-text-field-wrapper .mat-mdc-form-field-flex .mat-mdc-floating-label{top:calc(var(--mat-form-field-container-height, 56px)/2)}.mdc-text-field--filled .mat-mdc-floating-label{display:var(--mat-form-field-filled-label-display, block)}.mat-mdc-text-field-wrapper.mdc-text-field--outlined .mdc-notched-outline--upgraded .mdc-floating-label--float-above{--mat-mdc-form-field-label-transform: translateY(calc(calc(6.75px + var(--mat-form-field-container-height, 56px) / 2) * -1)) scale(var(--mat-mdc-form-field-floating-label-scale, 0.75));transform:var(--mat-mdc-form-field-label-transform)}.mat-mdc-form-field-subscript-wrapper{box-sizing:border-box;width:100%;position:relative}.mat-mdc-form-field-hint-wrapper,.mat-mdc-form-field-error-wrapper{position:absolute;top:0;left:0;right:0;padding:0 16px}.mat-mdc-form-field-subscript-dynamic-size .mat-mdc-form-field-hint-wrapper,.mat-mdc-form-field-subscript-dynamic-size .mat-mdc-form-field-error-wrapper{position:static}.mat-mdc-form-field-bottom-align::before{content:"";display:inline-block;height:16px}.mat-mdc-form-field-bottom-align.mat-mdc-form-field-subscript-dynamic-size::before{content:unset}.mat-mdc-form-field-hint-end{order:1}.mat-mdc-form-field-hint-wrapper{display:flex}.mat-mdc-form-field-hint-spacer{flex:1 0 1em}.mat-mdc-form-field-error{display:block;color:var(--mat-form-field-error-text-color, var(--mat-sys-error))}.mat-mdc-form-field-subscript-wrapper,.mat-mdc-form-field-bottom-align::before{-moz-osx-font-smoothing:grayscale;-webkit-font-smoothing:antialiased;font-family:var(--mat-form-field-subscript-text-font, var(--mat-sys-body-small-font));line-height:var(--mat-form-field-subscript-text-line-height, var(--mat-sys-body-small-line-height));font-size:var(--mat-form-field-subscript-text-size, var(--mat-sys-body-small-size));letter-spacing:var(--mat-form-field-subscript-text-tracking, var(--mat-sys-body-small-tracking));font-weight:var(--mat-form-field-subscript-text-weight, var(--mat-sys-body-small-weight))}.mat-mdc-form-field-focus-overlay{top:0;left:0;right:0;bottom:0;position:absolute;opacity:0;pointer-events:none;background-color:var(--mat-form-field-state-layer-color, var(--mat-sys-on-surface))}.mat-mdc-text-field-wrapper:hover .mat-mdc-form-field-focus-overlay{opacity:var(--mat-form-field-hover-state-layer-opacity, var(--mat-sys-hover-state-layer-opacity))}.mat-mdc-form-field.mat-focused .mat-mdc-form-field-focus-overlay{opacity:var(--mat-form-field-focus-state-layer-opacity, 0)}select.mat-mdc-form-field-input-control{-moz-appearance:none;-webkit-appearance:none;background-color:rgba(0,0,0,0);display:inline-flex;box-sizing:border-box}select.mat-mdc-form-field-input-control:not(:disabled){cursor:pointer}select.mat-mdc-form-field-input-control:not(.mat-mdc-native-select-inline) option{color:var(--mat-form-field-select-option-text-color, var(--mat-sys-neutral10))}select.mat-mdc-form-field-input-control:not(.mat-mdc-native-select-inline) option:disabled{color:var(--mat-form-field-select-disabled-option-text-color, color-mix(in srgb, var(--mat-sys-neutral10) 38%, transparent))}.mat-mdc-form-field-type-mat-native-select .mat-mdc-form-field-infix::after{content:"";width:0;height:0;border-left:5px solid rgba(0,0,0,0);border-right:5px solid rgba(0,0,0,0);border-top:5px solid;position:absolute;right:0;top:50%;margin-top:-2.5px;pointer-events:none;color:var(--mat-form-field-enabled-select-arrow-color, var(--mat-sys-on-surface-variant))}[dir=rtl] .mat-mdc-form-field-type-mat-native-select .mat-mdc-form-field-infix::after{right:auto;left:0}.mat-mdc-form-field-type-mat-native-select.mat-focused .mat-mdc-form-field-infix::after{color:var(--mat-form-field-focus-select-arrow-color, var(--mat-sys-primary))}.mat-mdc-form-field-type-mat-native-select.mat-form-field-disabled .mat-mdc-form-field-infix::after{color:var(--mat-form-field-disabled-select-arrow-color, color-mix(in srgb, var(--mat-sys-on-surface) 38%, transparent))}.mat-mdc-form-field-type-mat-native-select .mat-mdc-form-field-input-control{padding-right:15px}[dir=rtl] .mat-mdc-form-field-type-mat-native-select .mat-mdc-form-field-input-control{padding-right:0;padding-left:15px}@media(forced-colors: active){.mat-form-field-appearance-fill .mat-mdc-text-field-wrapper{outline:solid 1px}}@media(forced-colors: active){.mat-form-field-appearance-fill.mat-form-field-disabled .mat-mdc-text-field-wrapper{outline-color:GrayText}}@media(forced-colors: active){.mat-form-field-appearance-fill.mat-focused .mat-mdc-text-field-wrapper{outline:dashed 3px}}@media(forced-colors: active){.mat-mdc-form-field.mat-focused .mdc-notched-outline{border:dashed 3px}}.mat-mdc-form-field-input-control[type=date],.mat-mdc-form-field-input-control[type=datetime],.mat-mdc-form-field-input-control[type=datetime-local],.mat-mdc-form-field-input-control[type=month],.mat-mdc-form-field-input-control[type=week],.mat-mdc-form-field-input-control[type=time]{line-height:1}.mat-mdc-form-field-input-control::-webkit-datetime-edit{line-height:1;padding:0;margin-bottom:-2px}.mat-mdc-form-field{--mat-mdc-form-field-floating-label-scale: 0.75;display:inline-flex;flex-direction:column;min-width:0;text-align:left;-moz-osx-font-smoothing:grayscale;-webkit-font-smoothing:antialiased;font-family:var(--mat-form-field-container-text-font, var(--mat-sys-body-large-font));line-height:var(--mat-form-field-container-text-line-height, var(--mat-sys-body-large-line-height));font-size:var(--mat-form-field-container-text-size, var(--mat-sys-body-large-size));letter-spacing:var(--mat-form-field-container-text-tracking, var(--mat-sys-body-large-tracking));font-weight:var(--mat-form-field-container-text-weight, var(--mat-sys-body-large-weight))}.mat-mdc-form-field .mdc-text-field--outlined .mdc-floating-label--float-above{font-size:calc(var(--mat-form-field-outlined-label-text-populated-size)*var(--mat-mdc-form-field-floating-label-scale))}.mat-mdc-form-field .mdc-text-field--outlined .mdc-notched-outline--upgraded .mdc-floating-label--float-above{font-size:var(--mat-form-field-outlined-label-text-populated-size)}[dir=rtl] .mat-mdc-form-field{text-align:right}.mat-mdc-form-field-flex{display:inline-flex;align-items:baseline;box-sizing:border-box;width:100%}.mat-mdc-text-field-wrapper{width:100%;z-index:0}.mat-mdc-form-field-icon-prefix,.mat-mdc-form-field-icon-suffix{align-self:center;line-height:0;pointer-events:auto;position:relative;z-index:1}.mat-mdc-form-field-icon-prefix>.mat-icon,.mat-mdc-form-field-icon-suffix>.mat-icon{padding:0 12px;box-sizing:content-box}.mat-mdc-form-field-icon-prefix{color:var(--mat-form-field-leading-icon-color, var(--mat-sys-on-surface-variant))}.mat-form-field-disabled .mat-mdc-form-field-icon-prefix{color:var(--mat-form-field-disabled-leading-icon-color, color-mix(in srgb, var(--mat-sys-on-surface) 38%, transparent))}.mat-mdc-form-field-icon-suffix{color:var(--mat-form-field-trailing-icon-color, var(--mat-sys-on-surface-variant))}.mat-form-field-disabled .mat-mdc-form-field-icon-suffix{color:var(--mat-form-field-disabled-trailing-icon-color, color-mix(in srgb, var(--mat-sys-on-surface) 38%, transparent))}.mat-form-field-invalid .mat-mdc-form-field-icon-suffix{color:var(--mat-form-field-error-trailing-icon-color, var(--mat-sys-error))}.mat-form-field-invalid:not(.mat-focused):not(.mat-form-field-disabled) .mat-mdc-text-field-wrapper:hover .mat-mdc-form-field-icon-suffix{color:var(--mat-form-field-error-hover-trailing-icon-color, var(--mat-sys-on-error-container))}.mat-form-field-invalid.mat-focused .mat-mdc-text-field-wrapper .mat-mdc-form-field-icon-suffix{color:var(--mat-form-field-error-focus-trailing-icon-color, var(--mat-sys-error))}.mat-mdc-form-field-icon-prefix,[dir=rtl] .mat-mdc-form-field-icon-suffix{padding:0 4px 0 0}.mat-mdc-form-field-icon-suffix,[dir=rtl] .mat-mdc-form-field-icon-prefix{padding:0 0 0 4px}.mat-mdc-form-field-subscript-wrapper .mat-icon,.mat-mdc-form-field label .mat-icon{width:1em;height:1em;font-size:inherit}.mat-mdc-form-field-infix{flex:auto;min-width:0;width:180px;position:relative;box-sizing:border-box}.mat-mdc-form-field-infix:has(textarea[cols]){width:auto}.mat-mdc-form-field .mdc-notched-outline__notch{margin-left:-1px;-webkit-clip-path:inset(-9em -999em -9em 1px);clip-path:inset(-9em -999em -9em 1px)}[dir=rtl] .mat-mdc-form-field .mdc-notched-outline__notch{margin-left:0;margin-right:-1px;-webkit-clip-path:inset(-9em 1px -9em -999em);clip-path:inset(-9em 1px -9em -999em)}.mat-mdc-form-field:not(.mat-form-field-no-animations) .mdc-floating-label{transition:transform 150ms cubic-bezier(0.4, 0, 0.2, 1),color 150ms cubic-bezier(0.4, 0, 0.2, 1)}.mat-mdc-form-field:not(.mat-form-field-no-animations) .mdc-text-field__input{transition:opacity 150ms cubic-bezier(0.4, 0, 0.2, 1)}.mat-mdc-form-field:not(.mat-form-field-no-animations) .mdc-text-field__input::placeholder{transition:opacity 67ms cubic-bezier(0.4, 0, 0.2, 1)}.mat-mdc-form-field:not(.mat-form-field-no-animations) .mdc-text-field__input::-moz-placeholder{transition:opacity 67ms cubic-bezier(0.4, 0, 0.2, 1)}.mat-mdc-form-field:not(.mat-form-field-no-animations) .mdc-text-field__input::-webkit-input-placeholder{transition:opacity 67ms cubic-bezier(0.4, 0, 0.2, 1)}.mat-mdc-form-field:not(.mat-form-field-no-animations) .mdc-text-field__input:-ms-input-placeholder{transition:opacity 67ms cubic-bezier(0.4, 0, 0.2, 1)}.mat-mdc-form-field:not(.mat-form-field-no-animations).mdc-text-field--no-label .mdc-text-field__input::placeholder,.mat-mdc-form-field:not(.mat-form-field-no-animations).mdc-text-field--focused .mdc-text-field__input::placeholder{transition-delay:40ms;transition-duration:110ms}.mat-mdc-form-field:not(.mat-form-field-no-animations).mdc-text-field--no-label .mdc-text-field__input::-moz-placeholder,.mat-mdc-form-field:not(.mat-form-field-no-animations).mdc-text-field--focused .mdc-text-field__input::-moz-placeholder{transition-delay:40ms;transition-duration:110ms}.mat-mdc-form-field:not(.mat-form-field-no-animations).mdc-text-field--no-label .mdc-text-field__input::-webkit-input-placeholder,.mat-mdc-form-field:not(.mat-form-field-no-animations).mdc-text-field--focused .mdc-text-field__input::-webkit-input-placeholder{transition-delay:40ms;transition-duration:110ms}.mat-mdc-form-field:not(.mat-form-field-no-animations).mdc-text-field--no-label .mdc-text-field__input:-ms-input-placeholder,.mat-mdc-form-field:not(.mat-form-field-no-animations).mdc-text-field--focused .mdc-text-field__input:-ms-input-placeholder{transition-delay:40ms;transition-duration:110ms}.mat-mdc-form-field:not(.mat-form-field-no-animations) .mdc-text-field--filled:not(.mdc-ripple-upgraded):focus .mdc-text-field__ripple::before{transition-duration:75ms}.mat-mdc-form-field:not(.mat-form-field-no-animations) .mdc-line-ripple::after{transition:transform 180ms cubic-bezier(0.4, 0, 0.2, 1),opacity 180ms cubic-bezier(0.4, 0, 0.2, 1)}.mdc-notched-outline .mdc-floating-label{max-width:calc(100% + 1px)}.mdc-notched-outline--upgraded .mdc-floating-label--float-above{max-width:calc(133.3333333333% + 1px)}'],encapsulation:2,data:{animation:[A4A.transitionMessages]},changeDetection:0})}return t})(),f0=(()=>{class t{static \u0275fac=function(i){return new(i||t)};static \u0275mod=ge({type:t});static \u0275inj=le({imports:[Ve,gB,Ve]})}return t})();var n4A=["trigger"],o4A=["panel"],r4A=[[["mat-select-trigger"]],"*"],s4A=["mat-select-trigger","*"];function a4A(t,e){if(t&1&&(S(0,"span",4),tA(1),R()),t&2){let A=P();_(),Mt(A.placeholder)}}function c4A(t,e){t&1&&xe(0)}function l4A(t,e){if(t&1&&(S(0,"span",11),tA(1),R()),t&2){let A=P(2);_(),Mt(A.triggerValue)}}function g4A(t,e){if(t&1&&(S(0,"span",5),NA(1,c4A,1,0)(2,l4A,2,1,"span",11),R()),t&2){let A=P();_(),FA(A.customTrigger?1:2)}}function I4A(t,e){if(t&1){let A=De();S(0,"div",12,1),mA("@transformPanel.done",function(n){LA(A);let o=P();return xA(o._panelDoneAnimatingStream.next(n.toState))})("keydown",function(n){LA(A);let o=P();return xA(o._handleKeydown(n))}),xe(2,1),R()}if(t&2){let A=P();TT("mat-mdc-select-panel mdc-menu-surface mdc-menu-surface--open ",A._getPanelTheme(),""),vA("ngClass",A.panelClass)("@transformPanel","showing"),_e("id",A.id+"-panel")("aria-multiselectable",A.multiple)("aria-label",A.ariaLabel||null)("aria-labelledby",A._getPanelAriaLabelledby())}}var C4A={transformPanelWrap:cg("transformPanelWrap",[la("* => void",Mk("@transformPanel",[bk()],{optional:!0}))]),transformPanel:cg("transformPanel",[wc("void",ar({opacity:0,transform:"scale(1, 0.8)"})),la("void => showing",$a("120ms cubic-bezier(0, 0, 0.2, 1)",ar({opacity:1,transform:"scale(1, 1)"}))),la("* => void",$a("100ms linear",ar({opacity:0})))])};var CP=new BA("mat-select-scroll-strategy",{providedIn:"root",factory:()=>{let t=m(Sr);return()=>t.scrollStrategies.reposition()}});function d4A(t){return()=>t.scrollStrategies.reposition()}var B4A=new BA("MAT_SELECT_CONFIG"),E4A={provide:CP,deps:[Sr],useFactory:d4A},h4A=new BA("MatSelectTrigger"),kk=class{source;value;constructor(e,A){this.source=e,this.value=A}},pB=(()=>{class t{_viewportRuler=m(mc);_changeDetectorRef=m(lt);_elementRef=m(te);_dir=m(bo,{optional:!0});_idGenerator=m($i);_parentFormField=m(wu,{optional:!0});ngControl=m(Pa,{self:!0,optional:!0});_liveAnnouncer=m(j6);_defaultOptions=m(B4A,{optional:!0});_initialized=new HA;options;optionGroups;customTrigger;_positions=[{originX:"start",originY:"bottom",overlayX:"start",overlayY:"top"},{originX:"end",originY:"bottom",overlayX:"end",overlayY:"top"},{originX:"start",originY:"top",overlayX:"start",overlayY:"bottom",panelClass:"mat-mdc-select-panel-above"},{originX:"end",originY:"top",overlayX:"end",overlayY:"bottom",panelClass:"mat-mdc-select-panel-above"}];_scrollOptionIntoView(A){let i=this.options.toArray()[A];if(i){let n=this.panel.nativeElement,o=UO(A,this.options,this.optionGroups),r=i._getHostElement();A===0&&o===1?n.scrollTop=0:n.scrollTop=KO(r.offsetTop,r.offsetHeight,n.scrollTop,n.offsetHeight)}}_positioningSettled(){this._scrollOptionIntoView(this._keyManager.activeItemIndex||0)}_getChangeEvent(A){return new kk(this,A)}_scrollStrategyFactory=m(CP);_panelOpen=!1;_compareWith=(A,i)=>A===i;_uid=this._idGenerator.getId("mat-select-");_triggerAriaLabelledBy=null;_previousControl;_destroy=new HA;_errorStateTracker;stateChanges=new HA;disableAutomaticLabeling=!0;userAriaDescribedBy;_selectionModel;_keyManager;_preferredOverlayOrigin;_overlayWidth;_onChange=()=>{};_onTouched=()=>{};_valueId=this._idGenerator.getId("mat-select-value-");_panelDoneAnimatingStream=new HA;_scrollStrategy;_overlayPanelClass=this._defaultOptions?.overlayPanelClass||"";get focused(){return this._focused||this._panelOpen}_focused=!1;controlType="mat-select";trigger;panel;_overlayDir;panelClass;disabled=!1;disableRipple=!1;tabIndex=0;get hideSingleSelectionIndicator(){return this._hideSingleSelectionIndicator}set hideSingleSelectionIndicator(A){this._hideSingleSelectionIndicator=A,this._syncParentProperties()}_hideSingleSelectionIndicator=this._defaultOptions?.hideSingleSelectionIndicator??!1;get placeholder(){return this._placeholder}set placeholder(A){this._placeholder=A,this.stateChanges.next()}_placeholder;get required(){return this._required??this.ngControl?.control?.hasValidator(Oa.required)??!1}set required(A){this._required=A,this.stateChanges.next()}_required;get multiple(){return this._multiple}set multiple(A){this._selectionModel,this._multiple=A}_multiple=!1;disableOptionCentering=this._defaultOptions?.disableOptionCentering??!1;get compareWith(){return this._compareWith}set compareWith(A){this._compareWith=A,this._selectionModel&&this._initializeSelection()}get value(){return this._value}set value(A){this._assignValue(A)&&this._onChange(A)}_value;ariaLabel="";ariaLabelledby;get errorStateMatcher(){return this._errorStateTracker.matcher}set errorStateMatcher(A){this._errorStateTracker.matcher=A}typeaheadDebounceInterval;sortComparator;get id(){return this._id}set id(A){this._id=A||this._uid,this.stateChanges.next()}_id;get errorState(){return this._errorStateTracker.errorState}set errorState(A){this._errorStateTracker.errorState=A}panelWidth=this._defaultOptions&&typeof this._defaultOptions.panelWidth<"u"?this._defaultOptions.panelWidth:"auto";canSelectNullableOptions=this._defaultOptions?.canSelectNullableOptions??!1;optionSelectionChanges=Yl(()=>{let A=this.options;return A?A.changes.pipe(Qo(A),no(()=>ho(...A.map(i=>i.onSelectionChange)))):this._initialized.pipe(no(()=>this.optionSelectionChanges))});openedChange=new XA;_openedStream=this.openedChange.pipe(pt(A=>A),Je(()=>{}));_closedStream=this.openedChange.pipe(pt(A=>!A),Je(()=>{}));selectionChange=new XA;valueChange=new XA;constructor(){let A=m(dB),i=m(jQ,{optional:!0}),n=m(bI,{optional:!0}),o=m(new Er("tabindex"),{optional:!0});this.ngControl&&(this.ngControl.valueAccessor=this),this._defaultOptions?.typeaheadDebounceInterval!=null&&(this.typeaheadDebounceInterval=this._defaultOptions.typeaheadDebounceInterval),this._errorStateTracker=new UI(A,this.ngControl,n,i,this.stateChanges),this._scrollStrategy=this._scrollStrategyFactory(),this.tabIndex=o==null?0:parseInt(o)||0,this.id=this.id}ngOnInit(){this._selectionModel=new F2(this.multiple),this.stateChanges.next(),this._panelDoneAnimatingStream.pipe(Zc(),wt(this._destroy)).subscribe(()=>this._panelDoneAnimating(this.panelOpen)),this._viewportRuler.change().pipe(wt(this._destroy)).subscribe(()=>{this.panelOpen&&(this._overlayWidth=this._getOverlayWidth(this._preferredOverlayOrigin),this._changeDetectorRef.detectChanges())})}ngAfterContentInit(){this._initialized.next(),this._initialized.complete(),this._initKeyManager(),this._selectionModel.changed.pipe(wt(this._destroy)).subscribe(A=>{A.added.forEach(i=>i.select()),A.removed.forEach(i=>i.deselect())}),this.options.changes.pipe(Qo(null),wt(this._destroy)).subscribe(()=>{this._resetOptions(),this._initializeSelection()})}ngDoCheck(){let A=this._getTriggerAriaLabelledby(),i=this.ngControl;if(A!==this._triggerAriaLabelledBy){let n=this._elementRef.nativeElement;this._triggerAriaLabelledBy=A,A?n.setAttribute("aria-labelledby",A):n.removeAttribute("aria-labelledby")}i&&(this._previousControl!==i.control&&(this._previousControl!==void 0&&i.disabled!==null&&i.disabled!==this.disabled&&(this.disabled=i.disabled),this._previousControl=i.control),this.updateErrorState())}ngOnChanges(A){(A.disabled||A.userAriaDescribedBy)&&this.stateChanges.next(),A.typeaheadDebounceInterval&&this._keyManager&&this._keyManager.withTypeAhead(this.typeaheadDebounceInterval)}ngOnDestroy(){this._keyManager?.destroy(),this._destroy.next(),this._destroy.complete(),this.stateChanges.complete(),this._clearFromModal()}toggle(){this.panelOpen?this.close():this.open()}open(){this._canOpen()&&(this._parentFormField&&(this._preferredOverlayOrigin=this._parentFormField.getConnectedOverlayOrigin()),this._overlayWidth=this._getOverlayWidth(this._preferredOverlayOrigin),this._applyModalPanelOwnership(),this._panelOpen=!0,this._keyManager.withHorizontalOrientation(null),this._highlightCorrectOption(),this._changeDetectorRef.markForCheck(),this.stateChanges.next())}_trackedModal=null;_applyModalPanelOwnership(){let A=this._elementRef.nativeElement.closest('body > .cdk-overlay-container [aria-modal="true"]');if(!A)return;let i=`${this.id}-panel`;this._trackedModal&&O6(this._trackedModal,"aria-owns",i),$M(A,"aria-owns",i),this._trackedModal=A}_clearFromModal(){if(!this._trackedModal)return;let A=`${this.id}-panel`;O6(this._trackedModal,"aria-owns",A),this._trackedModal=null}close(){this._panelOpen&&(this._panelOpen=!1,this._keyManager.withHorizontalOrientation(this._isRtl()?"rtl":"ltr"),this._changeDetectorRef.markForCheck(),this._onTouched(),this.stateChanges.next())}writeValue(A){this._assignValue(A)}registerOnChange(A){this._onChange=A}registerOnTouched(A){this._onTouched=A}setDisabledState(A){this.disabled=A,this._changeDetectorRef.markForCheck(),this.stateChanges.next()}get panelOpen(){return this._panelOpen}get selected(){return this.multiple?this._selectionModel?.selected||[]:this._selectionModel?.selected[0]}get triggerValue(){if(this.empty)return"";if(this._multiple){let A=this._selectionModel.selected.map(i=>i.viewValue);return this._isRtl()&&A.reverse(),A.join(", ")}return this._selectionModel.selected[0].viewValue}updateErrorState(){this._errorStateTracker.updateErrorState()}_isRtl(){return this._dir?this._dir.value==="rtl":!1}_handleKeydown(A){this.disabled||(this.panelOpen?this._handleOpenKeydown(A):this._handleClosedKeydown(A))}_handleClosedKeydown(A){let i=A.keyCode,n=i===40||i===38||i===37||i===39,o=i===13||i===32,r=this._keyManager;if(!r.isTyping()&&o&&!rr(A)||(this.multiple||A.altKey)&&n)A.preventDefault(),this.open();else if(!this.multiple){let s=this.selected;r.onKeydown(A);let a=this.selected;a&&s!==a&&this._liveAnnouncer.announce(a.viewValue,1e4)}}_handleOpenKeydown(A){let i=this._keyManager,n=A.keyCode,o=n===40||n===38,r=i.isTyping();if(o&&A.altKey)A.preventDefault(),this.close();else if(!r&&(n===13||n===32)&&i.activeItem&&!rr(A))A.preventDefault(),i.activeItem._selectViaInteraction();else if(!r&&this._multiple&&n===65&&A.ctrlKey){A.preventDefault();let s=this.options.some(a=>!a.disabled&&!a.selected);this.options.forEach(a=>{a.disabled||(s?a.select():a.deselect())})}else{let s=i.activeItemIndex;i.onKeydown(A),this._multiple&&o&&A.shiftKey&&i.activeItem&&i.activeItemIndex!==s&&i.activeItem._selectViaInteraction()}}_onFocus(){this.disabled||(this._focused=!0,this.stateChanges.next())}_onBlur(){this._focused=!1,this._keyManager?.cancelTypeahead(),!this.disabled&&!this.panelOpen&&(this._onTouched(),this._changeDetectorRef.markForCheck(),this.stateChanges.next())}_onAttached(){this._overlayDir.positionChange.pipe(Pn(1)).subscribe(()=>{this._changeDetectorRef.detectChanges(),this._positioningSettled()})}_getPanelTheme(){return this._parentFormField?`mat-${this._parentFormField.color}`:""}get empty(){return!this._selectionModel||this._selectionModel.isEmpty()}_initializeSelection(){Promise.resolve().then(()=>{this.ngControl&&(this._value=this.ngControl.value),this._setSelectionByValue(this._value),this.stateChanges.next()})}_setSelectionByValue(A){if(this.options.forEach(i=>i.setInactiveStyles()),this._selectionModel.clear(),this.multiple&&A)Array.isArray(A),A.forEach(i=>this._selectOptionByValue(i)),this._sortValues();else{let i=this._selectOptionByValue(A);i?this._keyManager.updateActiveItem(i):this.panelOpen||this._keyManager.updateActiveItem(-1)}this._changeDetectorRef.markForCheck()}_selectOptionByValue(A){let i=this.options.find(n=>{if(this._selectionModel.isSelected(n))return!1;try{return(n.value!=null||this.canSelectNullableOptions)&&this._compareWith(n.value,A)}catch{return!1}});return i&&this._selectionModel.select(i),i}_assignValue(A){return A!==this._value||this._multiple&&Array.isArray(A)?(this.options&&this._setSelectionByValue(A),this._value=A,!0):!1}_skipPredicate=A=>this.panelOpen?!1:A.disabled;_getOverlayWidth(A){return this.panelWidth==="auto"?(A instanceof mu?A.elementRef:A||this._elementRef).nativeElement.getBoundingClientRect().width:this.panelWidth===null?"":this.panelWidth}_syncParentProperties(){if(this.options)for(let A of this.options)A._changeDetectorRef.markForCheck()}_initKeyManager(){this._keyManager=new T6(this.options).withTypeAhead(this.typeaheadDebounceInterval).withVerticalOrientation().withHorizontalOrientation(this._isRtl()?"rtl":"ltr").withHomeAndEnd().withPageUpDown().withAllowedModifierKeys(["shiftKey"]).skipPredicate(this._skipPredicate),this._keyManager.tabOut.subscribe(()=>{this.panelOpen&&(!this.multiple&&this._keyManager.activeItem&&this._keyManager.activeItem._selectViaInteraction(),this.focus(),this.close())}),this._keyManager.change.subscribe(()=>{this._panelOpen&&this.panel?this._scrollOptionIntoView(this._keyManager.activeItemIndex||0):!this._panelOpen&&!this.multiple&&this._keyManager.activeItem&&this._keyManager.activeItem._selectViaInteraction()})}_resetOptions(){let A=ho(this.options.changes,this._destroy);this.optionSelectionChanges.pipe(wt(A)).subscribe(i=>{this._onSelect(i.source,i.isUserInput),i.isUserInput&&!this.multiple&&this._panelOpen&&(this.close(),this.focus())}),ho(...this.options.map(i=>i._stateChanges)).pipe(wt(A)).subscribe(()=>{this._changeDetectorRef.detectChanges(),this.stateChanges.next()})}_onSelect(A,i){let n=this._selectionModel.isSelected(A);!this.canSelectNullableOptions&&A.value==null&&!this._multiple?(A.deselect(),this._selectionModel.clear(),this.value!=null&&this._propagateChanges(A.value)):(n!==A.selected&&(A.selected?this._selectionModel.select(A):this._selectionModel.deselect(A)),i&&this._keyManager.setActiveItem(A),this.multiple&&(this._sortValues(),i&&this.focus())),n!==this._selectionModel.isSelected(A)&&this._propagateChanges(),this.stateChanges.next()}_sortValues(){if(this.multiple){let A=this.options.toArray();this._selectionModel.sort((i,n)=>this.sortComparator?this.sortComparator(i,n,A):A.indexOf(i)-A.indexOf(n)),this.stateChanges.next()}}_propagateChanges(A){let i;this.multiple?i=this.selected.map(n=>n.value):i=this.selected?this.selected.value:A,this._value=i,this.valueChange.emit(i),this._onChange(i),this.selectionChange.emit(this._getChangeEvent(i)),this._changeDetectorRef.markForCheck()}_highlightCorrectOption(){if(this._keyManager)if(this.empty){let A=-1;for(let i=0;i<this.options.length;i++)if(!this.options.get(i).disabled){A=i;break}this._keyManager.setActiveItem(A)}else this._keyManager.setActiveItem(this._selectionModel.selected[0])}_canOpen(){return!this._panelOpen&&!this.disabled&&this.options?.length>0}focus(A){this._elementRef.nativeElement.focus(A)}_getPanelAriaLabelledby(){if(this.ariaLabel)return null;let A=this._parentFormField?.getLabelId()||null,i=A?A+" ":"";return this.ariaLabelledby?i+this.ariaLabelledby:A}_getAriaActiveDescendant(){return this.panelOpen&&this._keyManager&&this._keyManager.activeItem?this._keyManager.activeItem.id:null}_getTriggerAriaLabelledby(){if(this.ariaLabel)return null;let A=this._parentFormField?.getLabelId(),i=(A?A+" ":"")+this._valueId;return this.ariaLabelledby&&(i+=" "+this.ariaLabelledby),i}_panelDoneAnimating(A){this.openedChange.emit(A)}setDescribedByIds(A){A.length?this._elementRef.nativeElement.setAttribute("aria-describedby",A.join(" ")):this._elementRef.nativeElement.removeAttribute("aria-describedby")}onContainerClick(){this.focus(),this.open()}get shouldLabelFloat(){return this.panelOpen||!this.empty||this.focused&&!!this.placeholder}static \u0275fac=function(i){return new(i||t)};static \u0275cmp=YA({type:t,selectors:[["mat-select"]],contentQueries:function(i,n,o){if(i&1&&(Ii(o,h4A,5),Ii(o,x2,5),Ii(o,gk,5)),i&2){let r;$A(r=Ae())&&(n.customTrigger=r.first),$A(r=Ae())&&(n.options=r),$A(r=Ae())&&(n.optionGroups=r)}},viewQuery:function(i,n){if(i&1&&(Ge(n4A,5),Ge(o4A,5),Ge(yk,5)),i&2){let o;$A(o=Ae())&&(n.trigger=o.first),$A(o=Ae())&&(n.panel=o.first),$A(o=Ae())&&(n._overlayDir=o.first)}},hostAttrs:["role","combobox","aria-haspopup","listbox",1,"mat-mdc-select"],hostVars:19,hostBindings:function(i,n){i&1&&mA("keydown",function(r){return n._handleKeydown(r)})("focus",function(){return n._onFocus()})("blur",function(){return n._onBlur()}),i&2&&(_e("id",n.id)("tabindex",n.disabled?-1:n.tabIndex)("aria-controls",n.panelOpen?n.id+"-panel":null)("aria-expanded",n.panelOpen)("aria-label",n.ariaLabel||null)("aria-required",n.required.toString())("aria-disabled",n.disabled.toString())("aria-invalid",n.errorState)("aria-activedescendant",n._getAriaActiveDescendant()),ue("mat-mdc-select-disabled",n.disabled)("mat-mdc-select-invalid",n.errorState)("mat-mdc-select-required",n.required)("mat-mdc-select-empty",n.empty)("mat-mdc-select-multiple",n.multiple))},inputs:{userAriaDescribedBy:[0,"aria-describedby","userAriaDescribedBy"],panelClass:"panelClass",disabled:[2,"disabled","disabled",ae],disableRipple:[2,"disableRipple","disableRipple",ae],tabIndex:[2,"tabIndex","tabIndex",A=>A==null?0:Mi(A)],hideSingleSelectionIndicator:[2,"hideSingleSelectionIndicator","hideSingleSelectionIndicator",ae],placeholder:"placeholder",required:[2,"required","required",ae],multiple:[2,"multiple","multiple",ae],disableOptionCentering:[2,"disableOptionCentering","disableOptionCentering",ae],compareWith:"compareWith",value:"value",ariaLabel:[0,"aria-label","ariaLabel"],ariaLabelledby:[0,"aria-labelledby","ariaLabelledby"],errorStateMatcher:"errorStateMatcher",typeaheadDebounceInterval:[2,"typeaheadDebounceInterval","typeaheadDebounceInterval",Mi],sortComparator:"sortComparator",id:"id",panelWidth:"panelWidth",canSelectNullableOptions:[2,"canSelectNullableOptions","canSelectNullableOptions",ae]},outputs:{openedChange:"openedChange",_openedStream:"opened",_closedStream:"closed",selectionChange:"selectionChange",valueChange:"valueChange"},exportAs:["matSelect"],features:[ct([{provide:pu,useExisting:t},{provide:lk,useExisting:t}]),Kt],ngContentSelectors:s4A,decls:11,vars:8,consts:[["fallbackOverlayOrigin","cdkOverlayOrigin","trigger",""],["panel",""],["cdk-overlay-origin","",1,"mat-mdc-select-trigger",3,"click"],[1,"mat-mdc-select-value"],[1,"mat-mdc-select-placeholder","mat-mdc-select-min-line"],[1,"mat-mdc-select-value-text"],[1,"mat-mdc-select-arrow-wrapper"],[1,"mat-mdc-select-arrow"],["viewBox","0 0 24 24","width","24px","height","24px","focusable","false","aria-hidden","true"],["d","M7 10l5 5 5-5z"],["cdk-connected-overlay","","cdkConnectedOverlayLockPosition","","cdkConnectedOverlayHasBackdrop","","cdkConnectedOverlayBackdropClass","cdk-overlay-transparent-backdrop",3,"backdropClick","attach","detach","cdkConnectedOverlayPanelClass","cdkConnectedOverlayScrollStrategy","cdkConnectedOverlayOrigin","cdkConnectedOverlayOpen","cdkConnectedOverlayPositions","cdkConnectedOverlayWidth"],[1,"mat-mdc-select-min-line"],["role","listbox","tabindex","-1",3,"keydown","ngClass"]],template:function(i,n){if(i&1){let o=De();Yt(r4A),S(0,"div",2,0),mA("click",function(){return LA(o),xA(n.open())}),S(3,"div",3),NA(4,a4A,2,1,"span",4)(5,g4A,3,1,"span",5),R(),S(6,"div",6)(7,"div",7),hr(),S(8,"svg",8),UA(9,"path",9),R()()()(),NA(10,I4A,3,9,"ng-template",10),mA("backdropClick",function(){return LA(o),xA(n.close())})("attach",function(){return LA(o),xA(n._onAttached())})("detach",function(){return LA(o),xA(n.close())})}if(i&2){let o=or(1);_(3),_e("id",n._valueId),_(),FA(n.empty?4:5),_(6),vA("cdkConnectedOverlayPanelClass",n._overlayPanelClass)("cdkConnectedOverlayScrollStrategy",n._scrollStrategy)("cdkConnectedOverlayOrigin",n._preferredOverlayOrigin||o)("cdkConnectedOverlayOpen",n.panelOpen)("cdkConnectedOverlayPositions",n._positions)("cdkConnectedOverlayWidth",n._overlayWidth)}},dependencies:[mu,yk,Ha],styles:['.mat-mdc-select{display:inline-block;width:100%;outline:none;-moz-osx-font-smoothing:grayscale;-webkit-font-smoothing:antialiased;color:var(--mat-select-enabled-trigger-text-color, var(--mat-sys-on-surface));font-family:var(--mat-select-trigger-text-font, var(--mat-sys-body-large-font));line-height:var(--mat-select-trigger-text-line-height, var(--mat-sys-body-large-line-height));font-size:var(--mat-select-trigger-text-size, var(--mat-sys-body-large-size));font-weight:var(--mat-select-trigger-text-weight, var(--mat-sys-body-large-weight));letter-spacing:var(--mat-select-trigger-text-tracking, var(--mat-sys-body-large-tracking))}div.mat-mdc-select-panel{box-shadow:var(--mat-select-container-elevation-shadow, 0px 3px 1px -2px rgba(0, 0, 0, 0.2), 0px 2px 2px 0px rgba(0, 0, 0, 0.14), 0px 1px 5px 0px rgba(0, 0, 0, 0.12))}.mat-mdc-select-disabled{color:var(--mat-select-disabled-trigger-text-color, color-mix(in srgb, var(--mat-sys-on-surface) 38%, transparent))}.mat-mdc-select-disabled .mat-mdc-select-placeholder{color:var(--mat-select-disabled-trigger-text-color, color-mix(in srgb, var(--mat-sys-on-surface) 38%, transparent))}.mat-mdc-select-trigger{display:inline-flex;align-items:center;cursor:pointer;position:relative;box-sizing:border-box;width:100%}.mat-mdc-select-disabled .mat-mdc-select-trigger{-webkit-user-select:none;user-select:none;cursor:default}.mat-mdc-select-value{width:100%;overflow:hidden;text-overflow:ellipsis;white-space:nowrap}.mat-mdc-select-value-text{white-space:nowrap;overflow:hidden;text-overflow:ellipsis}.mat-mdc-select-arrow-wrapper{height:24px;flex-shrink:0;display:inline-flex;align-items:center}.mat-form-field-appearance-fill .mdc-text-field--no-label .mat-mdc-select-arrow-wrapper{transform:none}.mat-mdc-form-field .mat-mdc-select.mat-mdc-select-invalid .mat-mdc-select-arrow,.mat-form-field-invalid:not(.mat-form-field-disabled) .mat-mdc-form-field-infix::after{color:var(--mat-select-invalid-arrow-color, var(--mat-sys-error))}.mat-mdc-select-arrow{width:10px;height:5px;position:relative;color:var(--mat-select-enabled-arrow-color, var(--mat-sys-on-surface-variant))}.mat-mdc-form-field.mat-focused .mat-mdc-select-arrow{color:var(--mat-select-focused-arrow-color, var(--mat-sys-primary))}.mat-mdc-form-field .mat-mdc-select.mat-mdc-select-disabled .mat-mdc-select-arrow{color:var(--mat-select-disabled-arrow-color, color-mix(in srgb, var(--mat-sys-on-surface) 38%, transparent))}.mat-mdc-select-arrow svg{fill:currentColor;position:absolute;top:50%;left:50%;transform:translate(-50%, -50%)}@media(forced-colors: active){.mat-mdc-select-arrow svg{fill:CanvasText}.mat-mdc-select-disabled .mat-mdc-select-arrow svg{fill:GrayText}}div.mat-mdc-select-panel{width:100%;max-height:275px;outline:0;overflow:auto;padding:8px 0;border-radius:4px;box-sizing:border-box;position:static;background-color:var(--mat-select-panel-background-color, var(--mat-sys-surface-container))}@media(forced-colors: active){div.mat-mdc-select-panel{outline:solid 1px}}.cdk-overlay-pane:not(.mat-mdc-select-panel-above) div.mat-mdc-select-panel{border-top-left-radius:0;border-top-right-radius:0;transform-origin:top center}.mat-mdc-select-panel-above div.mat-mdc-select-panel{border-bottom-left-radius:0;border-bottom-right-radius:0;transform-origin:bottom center}div.mat-mdc-select-panel .mat-mdc-option{--mdc-list-list-item-container-color: var(--mat-select-panel-background-color)}.mat-mdc-select-placeholder{transition:color 400ms 133.3333333333ms cubic-bezier(0.25, 0.8, 0.25, 1);color:var(--mat-select-placeholder-text-color, var(--mat-sys-on-surface-variant))}.mat-form-field-no-animations .mat-mdc-select-placeholder,._mat-animation-noopable .mat-mdc-select-placeholder{transition:none}.mat-form-field-hide-placeholder .mat-mdc-select-placeholder{color:rgba(0,0,0,0);-webkit-text-fill-color:rgba(0,0,0,0);transition:none;display:block}.mat-mdc-form-field-type-mat-select:not(.mat-form-field-disabled) .mat-mdc-text-field-wrapper{cursor:pointer}.mat-mdc-form-field-type-mat-select.mat-form-field-appearance-fill .mat-mdc-floating-label{max-width:calc(100% - 18px)}.mat-mdc-form-field-type-mat-select.mat-form-field-appearance-fill .mdc-floating-label--float-above{max-width:calc(100%/0.75 - 24px)}.mat-mdc-form-field-type-mat-select.mat-form-field-appearance-outline .mdc-notched-outline__notch{max-width:calc(100% - 60px)}.mat-mdc-form-field-type-mat-select.mat-form-field-appearance-outline .mdc-text-field--label-floating .mdc-notched-outline__notch{max-width:calc(100% - 24px)}.mat-mdc-select-min-line:empty::before{content:" ";white-space:pre;width:1px;display:inline-block;visibility:hidden}.mat-form-field-appearance-fill .mat-mdc-select-arrow-wrapper{transform:var(--mat-select-arrow-transform, translateY(-8px))}'],encapsulation:2,data:{animation:[C4A.transformPanel]},changeDetection:0})}return t})();var a8=(()=>{class t{static \u0275fac=function(i){return new(i||t)};static \u0275mod=ge({type:t});static \u0275inj=le({providers:[E4A],imports:[u0,Ik,Ve,E0,f0,Ik,Ve]})}return t})();var Q4A=["tooltip"],hP=20;var QP=new BA("mat-tooltip-scroll-strategy",{providedIn:"root",factory:()=>{let t=m(Sr);return()=>t.scrollStrategies.reposition({scrollThrottle:hP})}});function u4A(t){return()=>t.scrollStrategies.reposition({scrollThrottle:hP})}var f4A={provide:QP,deps:[Sr],useFactory:u4A};function m4A(){return{showDelay:0,hideDelay:0,touchendHideDelay:1500}}var p4A=new BA("mat-tooltip-default-options",{providedIn:"root",factory:m4A});var BP="tooltip-panel",EP=og({passive:!0}),w4A=8,D4A=8,y4A=24,v4A=200,wB=(()=>{class t{_elementRef=m(te);_ngZone=m(de);_platform=m(Zt);_ariaDescriber=m(bO);_focusMonitor=m(Jr);_dir=m(bo);_injector=m(Dt);_defaultOptions=m(p4A,{optional:!0});_overlayRef;_tooltipInstance;_portal;_position="below";_positionAtOrigin=!1;_disabled=!1;_tooltipClass;_viewInitialized=!1;_pointerExitEventsInitialized=!1;_tooltipComponent=b4A;_viewportMargin=8;_currentPosition;_cssClassPrefix="mat-mdc";_ariaDescriptionPending;_dirSubscribed=!1;get position(){return this._position}set position(A){A!==this._position&&(this._position=A,this._overlayRef&&(this._updatePosition(this._overlayRef),this._tooltipInstance?.show(0),this._overlayRef.updatePosition()))}get positionAtOrigin(){return this._positionAtOrigin}set positionAtOrigin(A){this._positionAtOrigin=Yo(A),this._detach(),this._overlayRef=null}get disabled(){return this._disabled}set disabled(A){let i=Yo(A);this._disabled!==i&&(this._disabled=i,i?this.hide(0):this._setupPointerEnterEventsIfNeeded(),this._syncAriaDescription(this.message))}get showDelay(){return this._showDelay}set showDelay(A){this._showDelay=Ns(A)}_showDelay;get hideDelay(){return this._hideDelay}set hideDelay(A){this._hideDelay=Ns(A),this._tooltipInstance&&(this._tooltipInstance._mouseLeaveHideDelay=this._hideDelay)}_hideDelay;touchGestures="auto";get message(){return this._message}set message(A){let i=this._message;this._message=A!=null?String(A).trim():"",!this._message&&this._isTooltipVisible()?this.hide(0):(this._setupPointerEnterEventsIfNeeded(),this._updateTooltipMessage()),this._syncAriaDescription(i)}_message="";get tooltipClass(){return this._tooltipClass}set tooltipClass(A){this._tooltipClass=A,this._tooltipInstance&&this._setTooltipClass(this._tooltipClass)}_passiveListeners=[];_touchstartTimeout=null;_destroyed=new HA;_isDestroyed=!1;constructor(){let A=this._defaultOptions;A&&(this._showDelay=A.showDelay,this._hideDelay=A.hideDelay,A.position&&(this.position=A.position),A.positionAtOrigin&&(this.positionAtOrigin=A.positionAtOrigin),A.touchGestures&&(this.touchGestures=A.touchGestures),A.tooltipClass&&(this.tooltipClass=A.tooltipClass)),this._viewportMargin=w4A}ngAfterViewInit(){this._viewInitialized=!0,this._setupPointerEnterEventsIfNeeded(),this._focusMonitor.monitor(this._elementRef).pipe(wt(this._destroyed)).subscribe(A=>{A?A==="keyboard"&&this._ngZone.run(()=>this.show()):this._ngZone.run(()=>this.hide(0))})}ngOnDestroy(){let A=this._elementRef.nativeElement;this._touchstartTimeout&&clearTimeout(this._touchstartTimeout),this._overlayRef&&(this._overlayRef.dispose(),this._tooltipInstance=null),this._passiveListeners.forEach(([i,n])=>{A.removeEventListener(i,n,EP)}),this._passiveListeners.length=0,this._destroyed.next(),this._destroyed.complete(),this._isDestroyed=!0,this._ariaDescriber.removeDescription(A,this.message,"tooltip"),this._focusMonitor.stopMonitoring(A)}show(A=this.showDelay,i){if(this.disabled||!this.message||this._isTooltipVisible()){this._tooltipInstance?._cancelPendingAnimations();return}let n=this._createOverlay(i);this._detach(),this._portal=this._portal||new sl(this._tooltipComponent,this._injector.get(Un));let o=this._tooltipInstance=n.attach(this._portal).instance;o._triggerElement=this._elementRef.nativeElement,o._mouseLeaveHideDelay=this._hideDelay,o.afterHidden().pipe(wt(this._destroyed)).subscribe(()=>this._detach()),this._setTooltipClass(this._tooltipClass),this._updateTooltipMessage(),o.show(A)}hide(A=this.hideDelay){let i=this._tooltipInstance;i&&(i.isVisible()?i.hide(A):(i._cancelPendingAnimations(),this._detach()))}toggle(A){this._isTooltipVisible()?this.hide():this.show(void 0,A)}_isTooltipVisible(){return!!this._tooltipInstance&&this._tooltipInstance.isVisible()}_createOverlay(A){if(this._overlayRef){let r=this._overlayRef.getConfig().positionStrategy;if((!this.positionAtOrigin||!A)&&r._origin instanceof te)return this._overlayRef;this._detach()}let i=this._injector.get(N2).getAncestorScrollContainers(this._elementRef),n=this._injector.get(Sr),o=n.position().flexibleConnectedTo(this.positionAtOrigin?A||this._elementRef:this._elementRef).withTransformOriginOn(`.${this._cssClassPrefix}-tooltip`).withFlexibleDimensions(!1).withViewportMargin(this._viewportMargin).withScrollableContainers(i);return o.positionChanges.pipe(wt(this._destroyed)).subscribe(r=>{this._updateCurrentPositionClass(r.connectionPair),this._tooltipInstance&&r.scrollableViewProperties.isOverlayClipped&&this._tooltipInstance.isVisible()&&this._ngZone.run(()=>this.hide(0))}),this._overlayRef=n.create({direction:this._dir,positionStrategy:o,panelClass:`${this._cssClassPrefix}-${BP}`,scrollStrategy:this._injector.get(QP)()}),this._updatePosition(this._overlayRef),this._overlayRef.detachments().pipe(wt(this._destroyed)).subscribe(()=>this._detach()),this._overlayRef.outsidePointerEvents().pipe(wt(this._destroyed)).subscribe(()=>this._tooltipInstance?._handleBodyInteraction()),this._overlayRef.keydownEvents().pipe(wt(this._destroyed)).subscribe(r=>{this._isTooltipVisible()&&r.keyCode===27&&!rr(r)&&(r.preventDefault(),r.stopPropagation(),this._ngZone.run(()=>this.hide(0)))}),this._defaultOptions?.disableTooltipInteractivity&&this._overlayRef.addPanelClass(`${this._cssClassPrefix}-tooltip-panel-non-interactive`),this._dirSubscribed||(this._dirSubscribed=!0,this._dir.change.pipe(wt(this._destroyed)).subscribe(()=>{this._overlayRef&&this._updatePosition(this._overlayRef)})),this._overlayRef}_detach(){this._overlayRef&&this._overlayRef.hasAttached()&&this._overlayRef.detach(),this._tooltipInstance=null}_updatePosition(A){let i=A.getConfig().positionStrategy,n=this._getOrigin(),o=this._getOverlayPosition();i.withPositions([this._addOffset(nA(nA({},n.main),o.main)),this._addOffset(nA(nA({},n.fallback),o.fallback))])}_addOffset(A){let i=D4A,n=!this._dir||this._dir.value=="ltr";return A.originY==="top"?A.offsetY=-i:A.originY==="bottom"?A.offsetY=i:A.originX==="start"?A.offsetX=n?-i:i:A.originX==="end"&&(A.offsetX=n?i:-i),A}_getOrigin(){let A=!this._dir||this._dir.value=="ltr",i=this.position,n;i=="above"||i=="below"?n={originX:"center",originY:i=="above"?"top":"bottom"}:i=="before"||i=="left"&&A||i=="right"&&!A?n={originX:"start",originY:"center"}:(i=="after"||i=="right"&&A||i=="left"&&!A)&&(n={originX:"end",originY:"center"});let{x:o,y:r}=this._invertPosition(n.originX,n.originY);return{main:n,fallback:{originX:o,originY:r}}}_getOverlayPosition(){let A=!this._dir||this._dir.value=="ltr",i=this.position,n;i=="above"?n={overlayX:"center",overlayY:"bottom"}:i=="below"?n={overlayX:"center",overlayY:"top"}:i=="before"||i=="left"&&A||i=="right"&&!A?n={overlayX:"end",overlayY:"center"}:(i=="after"||i=="right"&&A||i=="left"&&!A)&&(n={overlayX:"start",overlayY:"center"});let{x:o,y:r}=this._invertPosition(n.overlayX,n.overlayY);return{main:n,fallback:{overlayX:o,overlayY:r}}}_updateTooltipMessage(){this._tooltipInstance&&(this._tooltipInstance.message=this.message,this._tooltipInstance._markForCheck(),Vo(()=>{this._tooltipInstance&&this._overlayRef.updatePosition()},{injector:this._injector}))}_setTooltipClass(A){this._tooltipInstance&&(this._tooltipInstance.tooltipClass=A,this._tooltipInstance._markForCheck())}_invertPosition(A,i){return this.position==="above"||this.position==="below"?i==="top"?i="bottom":i==="bottom"&&(i="top"):A==="end"?A="start":A==="start"&&(A="end"),{x:A,y:i}}_updateCurrentPositionClass(A){let{overlayY:i,originX:n,originY:o}=A,r;if(i==="center"?this._dir&&this._dir.value==="rtl"?r=n==="end"?"left":"right":r=n==="start"?"left":"right":r=i==="bottom"&&o==="top"?"above":"below",r!==this._currentPosition){let s=this._overlayRef;if(s){let a=`${this._cssClassPrefix}-${BP}-`;s.removePanelClass(a+this._currentPosition),s.addPanelClass(a+r)}this._currentPosition=r}}_setupPointerEnterEventsIfNeeded(){this._disabled||!this.message||!this._viewInitialized||this._passiveListeners.length||(this._platformSupportsMouseEvents()?this._passiveListeners.push(["mouseenter",A=>{this._setupPointerExitEventsIfNeeded();let i;A.x!==void 0&&A.y!==void 0&&(i=A),this.show(void 0,i)}]):this.touchGestures!=="off"&&(this._disableNativeGesturesIfNecessary(),this._passiveListeners.push(["touchstart",A=>{let i=A.targetTouches?.[0],n=i?{x:i.clientX,y:i.clientY}:void 0;this._setupPointerExitEventsIfNeeded(),this._touchstartTimeout&&clearTimeout(this._touchstartTimeout);let o=500;this._touchstartTimeout=setTimeout(()=>{this._touchstartTimeout=null,this.show(void 0,n)},this._defaultOptions?.touchLongPressShowDelay??o)}])),this._addListeners(this._passiveListeners))}_setupPointerExitEventsIfNeeded(){if(this._pointerExitEventsInitialized)return;this._pointerExitEventsInitialized=!0;let A=[];if(this._platformSupportsMouseEvents())A.push(["mouseleave",i=>{let n=i.relatedTarget;(!n||!this._overlayRef?.overlayElement.contains(n))&&this.hide()}],["wheel",i=>this._wheelListener(i)]);else if(this.touchGestures!=="off"){this._disableNativeGesturesIfNecessary();let i=()=>{this._touchstartTimeout&&clearTimeout(this._touchstartTimeout),this.hide(this._defaultOptions?.touchendHideDelay)};A.push(["touchend",i],["touchcancel",i])}this._addListeners(A),this._passiveListeners.push(...A)}_addListeners(A){A.forEach(([i,n])=>{this._elementRef.nativeElement.addEventListener(i,n,EP)})}_platformSupportsMouseEvents(){return!this._platform.IOS&&!this._platform.ANDROID}_wheelListener(A){if(this._isTooltipVisible()){let i=this._injector.get(tt).elementFromPoint(A.clientX,A.clientY),n=this._elementRef.nativeElement;i!==n&&!n.contains(i)&&this.hide()}}_disableNativeGesturesIfNecessary(){let A=this.touchGestures;if(A!=="off"){let i=this._elementRef.nativeElement,n=i.style;(A==="on"||i.nodeName!=="INPUT"&&i.nodeName!=="TEXTAREA")&&(n.userSelect=n.msUserSelect=n.webkitUserSelect=n.MozUserSelect="none"),(A==="on"||!i.draggable)&&(n.webkitUserDrag="none"),n.touchAction="none",n.webkitTapHighlightColor="transparent"}}_syncAriaDescription(A){this._ariaDescriptionPending||(this._ariaDescriptionPending=!0,this._ariaDescriber.removeDescription(this._elementRef.nativeElement,A,"tooltip"),this._isDestroyed||Vo({write:()=>{this._ariaDescriptionPending=!1,this.message&&!this.disabled&&this._ariaDescriber.describe(this._elementRef.nativeElement,this.message,"tooltip")}},{injector:this._injector}))}static \u0275fac=function(i){return new(i||t)};static \u0275dir=OA({type:t,selectors:[["","matTooltip",""]],hostAttrs:[1,"mat-mdc-tooltip-trigger"],hostVars:2,hostBindings:function(i,n){i&2&&ue("mat-mdc-tooltip-disabled",n.disabled)},inputs:{position:[0,"matTooltipPosition","position"],positionAtOrigin:[0,"matTooltipPositionAtOrigin","positionAtOrigin"],disabled:[0,"matTooltipDisabled","disabled"],showDelay:[0,"matTooltipShowDelay","showDelay"],hideDelay:[0,"matTooltipHideDelay","hideDelay"],touchGestures:[0,"matTooltipTouchGestures","touchGestures"],message:[0,"matTooltip","message"],tooltipClass:[0,"matTooltipClass","tooltipClass"]},exportAs:["matTooltip"]})}return t})(),b4A=(()=>{class t{_changeDetectorRef=m(lt);_elementRef=m(te);_isMultiline=!1;message;tooltipClass;_showTimeoutId;_hideTimeoutId;_triggerElement;_mouseLeaveHideDelay;_animationsDisabled;_tooltip;_closeOnInteraction=!1;_isVisible=!1;_onHide=new HA;_showAnimation="mat-mdc-tooltip-show";_hideAnimation="mat-mdc-tooltip-hide";constructor(){let A=m(mi,{optional:!0});this._animationsDisabled=A==="NoopAnimations"}show(A){this._hideTimeoutId!=null&&clearTimeout(this._hideTimeoutId),this._showTimeoutId=setTimeout(()=>{this._toggleVisibility(!0),this._showTimeoutId=void 0},A)}hide(A){this._showTimeoutId!=null&&clearTimeout(this._showTimeoutId),this._hideTimeoutId=setTimeout(()=>{this._toggleVisibility(!1),this._hideTimeoutId=void 0},A)}afterHidden(){return this._onHide}isVisible(){return this._isVisible}ngOnDestroy(){this._cancelPendingAnimations(),this._onHide.complete(),this._triggerElement=null}_handleBodyInteraction(){this._closeOnInteraction&&this.hide(0)}_markForCheck(){this._changeDetectorRef.markForCheck()}_handleMouseLeave({relatedTarget:A}){(!A||!this._triggerElement.contains(A))&&(this.isVisible()?this.hide(this._mouseLeaveHideDelay):this._finalizeAnimation(!1))}_onShow(){this._isMultiline=this._isTooltipMultiline(),this._markForCheck()}_isTooltipMultiline(){let A=this._elementRef.nativeElement.getBoundingClientRect();return A.height>y4A&&A.width>=v4A}_handleAnimationEnd({animationName:A}){(A===this._showAnimation||A===this._hideAnimation)&&this._finalizeAnimation(A===this._showAnimation)}_cancelPendingAnimations(){this._showTimeoutId!=null&&clearTimeout(this._showTimeoutId),this._hideTimeoutId!=null&&clearTimeout(this._hideTimeoutId),this._showTimeoutId=this._hideTimeoutId=void 0}_finalizeAnimation(A){A?this._closeOnInteraction=!0:this.isVisible()||this._onHide.next()}_toggleVisibility(A){let i=this._tooltip.nativeElement,n=this._showAnimation,o=this._hideAnimation;if(i.classList.remove(A?o:n),i.classList.add(A?n:o),this._isVisible!==A&&(this._isVisible=A,this._changeDetectorRef.markForCheck()),A&&!this._animationsDisabled&&typeof getComputedStyle=="function"){let r=getComputedStyle(i);(r.getPropertyValue("animation-duration")==="0s"||r.getPropertyValue("animation-name")==="none")&&(this._animationsDisabled=!0)}A&&this._onShow(),this._animationsDisabled&&(i.classList.add("_mat-animation-noopable"),this._finalizeAnimation(A))}static \u0275fac=function(i){return new(i||t)};static \u0275cmp=YA({type:t,selectors:[["mat-tooltip-component"]],viewQuery:function(i,n){if(i&1&&Ge(Q4A,7),i&2){let o;$A(o=Ae())&&(n._tooltip=o.first)}},hostAttrs:["aria-hidden","true"],hostBindings:function(i,n){i&1&&mA("mouseleave",function(r){return n._handleMouseLeave(r)})},decls:4,vars:4,consts:[["tooltip",""],[1,"mdc-tooltip","mat-mdc-tooltip",3,"animationend","ngClass"],[1,"mat-mdc-tooltip-surface","mdc-tooltip__surface"]],template:function(i,n){if(i&1){let o=De();S(0,"div",1,0),mA("animationend",function(s){return LA(o),xA(n._handleAnimationEnd(s))}),S(2,"div",2),tA(3),R()()}i&2&&(ue("mdc-tooltip--multiline",n._isMultiline),vA("ngClass",n.tooltipClass),_(3),Mt(n.message))},dependencies:[Ha],styles:['.mat-mdc-tooltip{position:relative;transform:scale(0);display:inline-flex}.mat-mdc-tooltip::before{content:"";top:0;right:0;bottom:0;left:0;z-index:-1;position:absolute}.mat-mdc-tooltip-panel-below .mat-mdc-tooltip::before{top:-8px}.mat-mdc-tooltip-panel-above .mat-mdc-tooltip::before{bottom:-8px}.mat-mdc-tooltip-panel-right .mat-mdc-tooltip::before{left:-8px}.mat-mdc-tooltip-panel-left .mat-mdc-tooltip::before{right:-8px}.mat-mdc-tooltip._mat-animation-noopable{animation:none;transform:scale(1)}.mat-mdc-tooltip-surface{word-break:normal;overflow-wrap:anywhere;padding:4px 8px;min-width:40px;max-width:200px;min-height:24px;max-height:40vh;box-sizing:border-box;overflow:hidden;text-align:center;will-change:transform,opacity;background-color:var(--mdc-plain-tooltip-container-color, var(--mat-sys-inverse-surface));color:var(--mdc-plain-tooltip-supporting-text-color, var(--mat-sys-inverse-on-surface));border-radius:var(--mdc-plain-tooltip-container-shape, var(--mat-sys-corner-extra-small));font-family:var(--mdc-plain-tooltip-supporting-text-font, var(--mat-sys-body-small-font));font-size:var(--mdc-plain-tooltip-supporting-text-size, var(--mat-sys-body-small-size));font-weight:var(--mdc-plain-tooltip-supporting-text-weight, var(--mat-sys-body-small-weight));line-height:var(--mdc-plain-tooltip-supporting-text-line-height, var(--mat-sys-body-small-line-height));letter-spacing:var(--mdc-plain-tooltip-supporting-text-tracking, var(--mat-sys-body-small-tracking))}.mat-mdc-tooltip-surface::before{position:absolute;box-sizing:border-box;width:100%;height:100%;top:0;left:0;border:1px solid rgba(0,0,0,0);border-radius:inherit;content:"";pointer-events:none}.mdc-tooltip--multiline .mat-mdc-tooltip-surface{text-align:left}[dir=rtl] .mdc-tooltip--multiline .mat-mdc-tooltip-surface{text-align:right}.mat-mdc-tooltip-panel{line-height:normal}.mat-mdc-tooltip-panel.mat-mdc-tooltip-panel-non-interactive{pointer-events:none}@keyframes mat-mdc-tooltip-show{0%{opacity:0;transform:scale(0.8)}100%{opacity:1;transform:scale(1)}}@keyframes mat-mdc-tooltip-hide{0%{opacity:1;transform:scale(1)}100%{opacity:0;transform:scale(0.8)}}.mat-mdc-tooltip-show{animation:mat-mdc-tooltip-show 150ms cubic-bezier(0, 0, 0.2, 1) forwards}.mat-mdc-tooltip-hide{animation:mat-mdc-tooltip-hide 75ms cubic-bezier(0.4, 0, 1, 1) forwards}'],encapsulation:2,changeDetection:0})}return t})();var c8=(()=>{class t{static \u0275fac=function(i){return new(i||t)};static \u0275mod=ge({type:t});static \u0275inj=le({providers:[f4A],imports:[q6,u0,Ve,Ve,E0]})}return t})();function M4A(t,e){if(t&1&&(S(0,"mat-option",17),tA(1),R()),t&2){let A=e.$implicit;vA("value",A),_(),ot(" ",A," ")}}function k4A(t,e){if(t&1){let A=De();S(0,"mat-form-field",14)(1,"mat-select",16,0),mA("selectionChange",function(n){LA(A);let o=P(2);return xA(o._changePageSize(n.value))}),ln(3,M4A,2,2,"mat-option",17,Kn),R(),S(5,"div",18),mA("click",function(){LA(A);let n=or(2);return xA(n.open())}),R()()}if(t&2){let A=P(2);vA("appearance",A._formFieldAppearance)("color",A.color),_(),vA("value",A.pageSize)("disabled",A.disabled)("aria-labelledby",A._pageSizeLabelId)("panelClass",A.selectConfig.panelClass||"")("disableOptionCentering",A.selectConfig.disableOptionCentering),_(2),gn(A._displayedPageSizeOptions)}}function S4A(t,e){if(t&1&&(S(0,"div",15),tA(1),R()),t&2){let A=P(2);_(),Mt(A.pageSize)}}function R4A(t,e){if(t&1&&(S(0,"div",3)(1,"div",13),tA(2),R(),NA(3,k4A,6,7,"mat-form-field",14)(4,S4A,2,1,"div",15),R()),t&2){let A=P();_(),_e("id",A._pageSizeLabelId),_(),ot(" ",A._intl.itemsPerPageLabel," "),_(),FA(A._displayedPageSizeOptions.length>1?3:-1),_(),FA(A._displayedPageSizeOptions.length<=1?4:-1)}}function L4A(t,e){if(t&1){let A=De();S(0,"button",19),mA("click",function(){LA(A);let n=P();return xA(n._buttonClicked(0,n._previousButtonsDisabled()))}),hr(),S(1,"svg",8),UA(2,"path",20),R()()}if(t&2){let A=P();vA("matTooltip",A._intl.firstPageLabel)("matTooltipDisabled",A._previousButtonsDisabled())("disabled",A._previousButtonsDisabled()),_e("aria-label",A._intl.firstPageLabel)}}function x4A(t,e){if(t&1){let A=De();S(0,"button",21),mA("click",function(){LA(A);let n=P();return xA(n._buttonClicked(n.getNumberOfPages()-1,n._nextButtonsDisabled()))}),hr(),S(1,"svg",8),UA(2,"path",22),R()()}if(t&2){let A=P();vA("matTooltip",A._intl.lastPageLabel)("matTooltipDisabled",A._nextButtonsDisabled())("disabled",A._nextButtonsDisabled()),_e("aria-label",A._intl.lastPageLabel)}}var TI=(()=>{class t{changes=new HA;itemsPerPageLabel="Items per page:";nextPageLabel="Next page";previousPageLabel="Previous page";firstPageLabel="First page";lastPageLabel="Last page";getRangeLabel=(A,i,n)=>{if(n==0||i==0)return`0 of ${n}`;n=Math.max(n,0);let o=A*i,r=o<n?Math.min(o+i,n):o+i;return`${o+1} \u2013 ${r} of ${n}`};static \u0275fac=function(i){return new(i||t)};static \u0275prov=SA({token:t,factory:t.\u0275fac,providedIn:"root"})}return t})();function F4A(t){return t||new TI}var N4A={provide:TI,deps:[[new hI,new rQ,TI]],useFactory:F4A},_4A=50;var G4A=new BA("MAT_PAGINATOR_DEFAULT_OPTIONS"),Sk=(()=>{class t{_intl=m(TI);_changeDetectorRef=m(lt);_formFieldAppearance;_pageSizeLabelId=m($i).getId("mat-paginator-page-size-label-");_intlChanges;_isInitialized=!1;_initializedStream=new qc(1);color;get pageIndex(){return this._pageIndex}set pageIndex(A){this._pageIndex=Math.max(A||0,0),this._changeDetectorRef.markForCheck()}_pageIndex=0;get length(){return this._length}set length(A){this._length=A||0,this._changeDetectorRef.markForCheck()}_length=0;get pageSize(){return this._pageSize}set pageSize(A){this._pageSize=Math.max(A||0,0),this._updateDisplayedPageSizeOptions()}_pageSize;get pageSizeOptions(){return this._pageSizeOptions}set pageSizeOptions(A){this._pageSizeOptions=(A||[]).map(i=>Mi(i,0)),this._updateDisplayedPageSizeOptions()}_pageSizeOptions=[];hidePageSize=!1;showFirstLastButtons=!1;selectConfig={};disabled=!1;page=new XA;_displayedPageSizeOptions;initialized=this._initializedStream;constructor(){let A=this._intl,i=m(G4A,{optional:!0});if(this._intlChanges=A.changes.subscribe(()=>this._changeDetectorRef.markForCheck()),i){let{pageSize:n,pageSizeOptions:o,hidePageSize:r,showFirstLastButtons:s}=i;n!=null&&(this._pageSize=n),o!=null&&(this._pageSizeOptions=o),r!=null&&(this.hidePageSize=r),s!=null&&(this.showFirstLastButtons=s)}this._formFieldAppearance=i?.formFieldAppearance||"outline"}ngOnInit(){this._isInitialized=!0,this._updateDisplayedPageSizeOptions(),this._initializedStream.next()}ngOnDestroy(){this._initializedStream.complete(),this._intlChanges.unsubscribe()}nextPage(){this.hasNextPage()&&this._navigate(this.pageIndex+1)}previousPage(){this.hasPreviousPage()&&this._navigate(this.pageIndex-1)}firstPage(){this.hasPreviousPage()&&this._navigate(0)}lastPage(){this.hasNextPage()&&this._navigate(this.getNumberOfPages()-1)}hasPreviousPage(){return this.pageIndex>=1&&this.pageSize!=0}hasNextPage(){let A=this.getNumberOfPages()-1;return this.pageIndex<A&&this.pageSize!=0}getNumberOfPages(){return this.pageSize?Math.ceil(this.length/this.pageSize):0}_changePageSize(A){let i=this.pageIndex*this.pageSize,n=this.pageIndex;this.pageIndex=Math.floor(i/A)||0,this.pageSize=A,this._emitPageEvent(n)}_nextButtonsDisabled(){return this.disabled||!this.hasNextPage()}_previousButtonsDisabled(){return this.disabled||!this.hasPreviousPage()}_updateDisplayedPageSizeOptions(){this._isInitialized&&(this.pageSize||(this._pageSize=this.pageSizeOptions.length!=0?this.pageSizeOptions[0]:_4A),this._displayedPageSizeOptions=this.pageSizeOptions.slice(),this._displayedPageSizeOptions.indexOf(this.pageSize)===-1&&this._displayedPageSizeOptions.push(this.pageSize),this._displayedPageSizeOptions.sort((A,i)=>A-i),this._changeDetectorRef.markForCheck())}_emitPageEvent(A){this.page.emit({previousPageIndex:A,pageIndex:this.pageIndex,pageSize:this.pageSize,length:this.length})}_navigate(A){let i=this.pageIndex;A!==i&&(this.pageIndex=A,this._emitPageEvent(i))}_buttonClicked(A,i){i||this._navigate(A)}static \u0275fac=function(i){return new(i||t)};static \u0275cmp=YA({type:t,selectors:[["mat-paginator"]],hostAttrs:["role","group",1,"mat-mdc-paginator"],inputs:{color:"color",pageIndex:[2,"pageIndex","pageIndex",Mi],length:[2,"length","length",Mi],pageSize:[2,"pageSize","pageSize",Mi],pageSizeOptions:"pageSizeOptions",hidePageSize:[2,"hidePageSize","hidePageSize",ae],showFirstLastButtons:[2,"showFirstLastButtons","showFirstLastButtons",ae],selectConfig:"selectConfig",disabled:[2,"disabled","disabled",ae]},outputs:{page:"page"},exportAs:["matPaginator"],decls:14,vars:12,consts:[["selectRef",""],[1,"mat-mdc-paginator-outer-container"],[1,"mat-mdc-paginator-container"],[1,"mat-mdc-paginator-page-size"],[1,"mat-mdc-paginator-range-actions"],["aria-live","polite",1,"mat-mdc-paginator-range-label"],["mat-icon-button","","type","button","matTooltipPosition","above","disabledInteractive","",1,"mat-mdc-paginator-navigation-first",3,"matTooltip","matTooltipDisabled","disabled"],["mat-icon-button","","type","button","matTooltipPosition","above","disabledInteractive","",1,"mat-mdc-paginator-navigation-previous",3,"click","matTooltip","matTooltipDisabled","disabled"],["viewBox","0 0 24 24","focusable","false","aria-hidden","true",1,"mat-mdc-paginator-icon"],["d","M15.41 7.41L14 6l-6 6 6 6 1.41-1.41L10.83 12z"],["mat-icon-button","","type","button","matTooltipPosition","above","disabledInteractive","",1,"mat-mdc-paginator-navigation-next",3,"click","matTooltip","matTooltipDisabled","disabled"],["d","M10 6L8.59 7.41 13.17 12l-4.58 4.59L10 18l6-6z"],["mat-icon-button","","type","button","matTooltipPosition","above","disabledInteractive","",1,"mat-mdc-paginator-navigation-last",3,"matTooltip","matTooltipDisabled","disabled"],[1,"mat-mdc-paginator-page-size-label"],[1,"mat-mdc-paginator-page-size-select",3,"appearance","color"],[1,"mat-mdc-paginator-page-size-value"],["hideSingleSelectionIndicator","",3,"selectionChange","value","disabled","aria-labelledby","panelClass","disableOptionCentering"],[3,"value"],[1,"mat-mdc-paginator-touch-target",3,"click"],["mat-icon-button","","type","button","matTooltipPosition","above","disabledInteractive","",1,"mat-mdc-paginator-navigation-first",3,"click","matTooltip","matTooltipDisabled","disabled"],["d","M18.41 16.59L13.82 12l4.59-4.59L17 6l-6 6 6 6zM6 6h2v12H6z"],["mat-icon-button","","type","button","matTooltipPosition","above","disabledInteractive","",1,"mat-mdc-paginator-navigation-last",3,"click","matTooltip","matTooltipDisabled","disabled"],["d","M5.59 7.41L10.18 12l-4.59 4.59L7 18l6-6-6-6zM16 6h2v12h-2z"]],template:function(i,n){i&1&&(S(0,"div",1)(1,"div",2),NA(2,R4A,5,4,"div",3),S(3,"div",4)(4,"div",5),tA(5),R(),NA(6,L4A,3,4,"button",6),S(7,"button",7),mA("click",function(){return n._buttonClicked(n.pageIndex-1,n._previousButtonsDisabled())}),hr(),S(8,"svg",8),UA(9,"path",9),R()(),uI(),S(10,"button",10),mA("click",function(){return n._buttonClicked(n.pageIndex+1,n._nextButtonsDisabled())}),hr(),S(11,"svg",8),UA(12,"path",11),R()(),NA(13,x4A,3,4,"button",12),R()()()),i&2&&(_(2),FA(n.hidePageSize?-1:2),_(3),ot(" ",n._intl.getRangeLabel(n.pageIndex,n.pageSize,n.length)," "),_(),FA(n.showFirstLastButtons?6:-1),_(),vA("matTooltip",n._intl.previousPageLabel)("matTooltipDisabled",n._previousButtonsDisabled())("disabled",n._previousButtonsDisabled()),_e("aria-label",n._intl.previousPageLabel),_(3),vA("matTooltip",n._intl.nextPageLabel)("matTooltipDisabled",n._nextButtonsDisabled())("disabled",n._nextButtonsDisabled()),_e("aria-label",n._intl.nextPageLabel),_(3),FA(n.showFirstLastButtons?13:-1))},dependencies:[lg,pB,x2,EB,wB],styles:[".mat-mdc-paginator{display:block;-moz-osx-font-smoothing:grayscale;-webkit-font-smoothing:antialiased;color:var(--mat-paginator-container-text-color, var(--mat-sys-on-surface));background-color:var(--mat-paginator-container-background-color, var(--mat-sys-surface));font-family:var(--mat-paginator-container-text-font, var(--mat-sys-body-small-font));line-height:var(--mat-paginator-container-text-line-height, var(--mat-sys-body-small-line-height));font-size:var(--mat-paginator-container-text-size, var(--mat-sys-body-small-size));font-weight:var(--mat-paginator-container-text-weight, var(--mat-sys-body-small-weight));letter-spacing:var(--mat-paginator-container-text-tracking, var(--mat-sys-body-small-tracking));--mat-form-field-container-height:var(--mat-paginator-form-field-container-height, 40px);--mat-form-field-container-vertical-padding:var(--mat-paginator-form-field-container-vertical-padding, 8px)}.mat-mdc-paginator .mat-mdc-select-value{font-size:var(--mat-paginator-select-trigger-text-size, var(--mat-sys-body-small-size))}.mat-mdc-paginator .mat-mdc-form-field-subscript-wrapper{display:none}.mat-mdc-paginator .mat-mdc-select{line-height:1.5}.mat-mdc-paginator-outer-container{display:flex}.mat-mdc-paginator-container{display:flex;align-items:center;justify-content:flex-end;padding:0 8px;flex-wrap:wrap;width:100%;min-height:var(--mat-paginator-container-size, 56px)}.mat-mdc-paginator-page-size{display:flex;align-items:baseline;margin-right:8px}[dir=rtl] .mat-mdc-paginator-page-size{margin-right:0;margin-left:8px}.mat-mdc-paginator-page-size-label{margin:0 4px}.mat-mdc-paginator-page-size-select{margin:0 4px;width:84px}.mat-mdc-paginator-range-label{margin:0 32px 0 24px}.mat-mdc-paginator-range-actions{display:flex;align-items:center}.mat-mdc-paginator-icon{display:inline-block;width:28px;fill:var(--mat-paginator-enabled-icon-color, var(--mat-sys-on-surface-variant))}.mat-mdc-icon-button[aria-disabled] .mat-mdc-paginator-icon{fill:var(--mat-paginator-disabled-icon-color, color-mix(in srgb, var(--mat-sys-on-surface) 38%, transparent))}[dir=rtl] .mat-mdc-paginator-icon{transform:rotate(180deg)}@media(forced-colors: active){.mat-mdc-icon-button[disabled] .mat-mdc-paginator-icon,.mat-mdc-paginator-icon{fill:currentColor;fill:CanvasText}.mat-mdc-paginator-range-actions .mat-mdc-icon-button{outline:solid 1px}}.mat-mdc-paginator-touch-target{display:var(--mat-paginator-touch-target-display, block);position:absolute;top:50%;left:50%;width:84px;height:48px;background-color:rgba(0,0,0,0);transform:translate(-50%, -50%);cursor:pointer}"],encapsulation:2,changeDetection:0})}return t})(),fP=(()=>{class t{static \u0275fac=function(i){return new(i||t)};static \u0275mod=ge({type:t});static \u0275inj=le({providers:[N4A],imports:[KI,a8,c8,Sk]})}return t})();function K4A(t,e){if(t&1){let A=De();S(0,"div",1)(1,"button",2),mA("click",function(){LA(A);let n=P();return xA(n.action())}),tA(2),R()()}if(t&2){let A=P();_(2),ot(" ",A.data.action," ")}}var Y4A=["label"];function J4A(t,e){}var T4A=Math.pow(2,31)-1,Du=class{_overlayRef;instance;containerInstance;_afterDismissed=new HA;_afterOpened=new HA;_onAction=new HA;_durationTimeoutId;_dismissedByAction=!1;constructor(e,A){this._overlayRef=A,this.containerInstance=e,e._onExit.subscribe(()=>this._finishDismiss())}dismiss(){this._afterDismissed.closed||this.containerInstance.exit(),clearTimeout(this._durationTimeoutId)}dismissWithAction(){this._onAction.closed||(this._dismissedByAction=!0,this._onAction.next(),this._onAction.complete(),this.dismiss()),clearTimeout(this._durationTimeoutId)}closeWithAction(){this.dismissWithAction()}_dismissAfter(e){this._durationTimeoutId=setTimeout(()=>this.dismiss(),Math.min(e,T4A))}_open(){this._afterOpened.closed||(this._afterOpened.next(),this._afterOpened.complete())}_finishDismiss(){this._overlayRef.dispose(),this._onAction.closed||this._onAction.complete(),this._afterDismissed.next({dismissedByAction:this._dismissedByAction}),this._afterDismissed.complete(),this._dismissedByAction=!1}afterDismissed(){return this._afterDismissed}afterOpened(){return this.containerInstance._onEnter}onAction(){return this._onAction}},mP=new BA("MatSnackBarData"),DB=class{politeness="assertive";announcementMessage="";viewContainerRef;duration=0;panelClass;direction;data=null;horizontalPosition="center";verticalPosition="bottom"},z4A=(()=>{class t{static \u0275fac=function(i){return new(i||t)};static \u0275dir=OA({type:t,selectors:[["","matSnackBarLabel",""]],hostAttrs:[1,"mat-mdc-snack-bar-label","mdc-snackbar__label"]})}return t})(),H4A=(()=>{class t{static \u0275fac=function(i){return new(i||t)};static \u0275dir=OA({type:t,selectors:[["","matSnackBarActions",""]],hostAttrs:[1,"mat-mdc-snack-bar-actions","mdc-snackbar__actions"]})}return t})(),O4A=(()=>{class t{static \u0275fac=function(i){return new(i||t)};static \u0275dir=OA({type:t,selectors:[["","matSnackBarAction",""]],hostAttrs:[1,"mat-mdc-snack-bar-action","mdc-snackbar__action"]})}return t})(),P4A=(()=>{class t{snackBarRef=m(Du);data=m(mP);constructor(){}action(){this.snackBarRef.dismissWithAction()}get hasAction(){return!!this.data.action}static \u0275fac=function(i){return new(i||t)};static \u0275cmp=YA({type:t,selectors:[["simple-snack-bar"]],hostAttrs:[1,"mat-mdc-simple-snack-bar"],exportAs:["matSnackBar"],decls:3,vars:2,consts:[["matSnackBarLabel",""],["matSnackBarActions",""],["mat-button","","matSnackBarAction","",3,"click"]],template:function(i,n){i&1&&(S(0,"div",0),tA(1),R(),NA(2,K4A,3,1,"div",1)),i&2&&(_(),ot(" ",n.data.message,`
`),_(),FA(n.hasAction?2:-1))},dependencies:[ur,z4A,H4A,O4A],styles:[".mat-mdc-simple-snack-bar{display:flex}"],encapsulation:2,changeDetection:0})}return t})(),j4A={snackBarState:cg("state",[wc("void, hidden",ar({transform:"scale(0.8)",opacity:0})),wc("visible",ar({transform:"scale(1)",opacity:1})),la("* => visible",$a("150ms cubic-bezier(0, 0, 0.2, 1)")),la("* => void, * => hidden",$a("75ms cubic-bezier(0.4, 0.0, 1, 1)",ar({opacity:0})))])},q4A=(()=>{class t extends _2{_ngZone=m(de);_elementRef=m(te);_changeDetectorRef=m(lt);_platform=m(Zt);snackBarConfig=m(DB);_document=m(tt);_trackedModals=new Set;_announceDelay=150;_announceTimeoutId;_destroyed=!1;_portalOutlet;_onAnnounce=new HA;_onExit=new HA;_onEnter=new HA;_animationState="void";_live;_label;_role;_liveElementId=m($i).getId("mat-snack-bar-container-live-");constructor(){super();let A=this.snackBarConfig;A.politeness==="assertive"&&!A.announcementMessage?this._live="assertive":A.politeness==="off"?this._live="off":this._live="polite",this._platform.FIREFOX&&(this._live==="polite"&&(this._role="status"),this._live==="assertive"&&(this._role="alert"))}attachComponentPortal(A){this._assertNotAttached();let i=this._portalOutlet.attachComponentPortal(A);return this._afterPortalAttached(),i}attachTemplatePortal(A){this._assertNotAttached();let i=this._portalOutlet.attachTemplatePortal(A);return this._afterPortalAttached(),i}attachDomPortal=A=>{this._assertNotAttached();let i=this._portalOutlet.attachDomPortal(A);return this._afterPortalAttached(),i};onAnimationEnd(A){let{fromState:i,toState:n}=A;if((n==="void"&&i!=="void"||n==="hidden")&&this._completeExit(),n==="visible"){let o=this._onEnter;this._ngZone.run(()=>{o.next(),o.complete()})}}enter(){this._destroyed||(this._animationState="visible",this._changeDetectorRef.markForCheck(),this._changeDetectorRef.detectChanges(),this._screenReaderAnnounce())}exit(){return this._ngZone.run(()=>{this._animationState="hidden",this._changeDetectorRef.markForCheck(),this._elementRef.nativeElement.setAttribute("mat-exit",""),clearTimeout(this._announceTimeoutId)}),this._onExit}ngOnDestroy(){this._destroyed=!0,this._clearFromModals(),this._completeExit()}_completeExit(){queueMicrotask(()=>{this._onExit.next(),this._onExit.complete()})}_afterPortalAttached(){let A=this._elementRef.nativeElement,i=this.snackBarConfig.panelClass;i&&(Array.isArray(i)?i.forEach(r=>A.classList.add(r)):A.classList.add(i)),this._exposeToModals();let n=this._label.nativeElement,o="mdc-snackbar__label";n.classList.toggle(o,!n.querySelector(`.${o}`))}_exposeToModals(){let A=this._liveElementId,i=this._document.querySelectorAll('body > .cdk-overlay-container [aria-modal="true"]');for(let n=0;n<i.length;n++){let o=i[n],r=o.getAttribute("aria-owns");this._trackedModals.add(o),r?r.indexOf(A)===-1&&o.setAttribute("aria-owns",r+" "+A):o.setAttribute("aria-owns",A)}}_clearFromModals(){this._trackedModals.forEach(A=>{let i=A.getAttribute("aria-owns");if(i){let n=i.replace(this._liveElementId,"").trim();n.length>0?A.setAttribute("aria-owns",n):A.removeAttribute("aria-owns")}}),this._trackedModals.clear()}_assertNotAttached(){this._portalOutlet.hasAttached()}_screenReaderAnnounce(){this._announceTimeoutId||this._ngZone.runOutsideAngular(()=>{this._announceTimeoutId=setTimeout(()=>{let A=this._elementRef.nativeElement.querySelector("[aria-hidden]"),i=this._elementRef.nativeElement.querySelector("[aria-live]");if(A&&i){let n=null;this._platform.isBrowser&&document.activeElement instanceof HTMLElement&&A.contains(document.activeElement)&&(n=document.activeElement),A.removeAttribute("aria-hidden"),i.appendChild(A),n?.focus(),this._onAnnounce.next(),this._onAnnounce.complete()}},this._announceDelay)})}static \u0275fac=function(i){return new(i||t)};static \u0275cmp=YA({type:t,selectors:[["mat-snack-bar-container"]],viewQuery:function(i,n){if(i&1&&(Ge(ca,7),Ge(Y4A,7)),i&2){let o;$A(o=Ae())&&(n._portalOutlet=o.first),$A(o=Ae())&&(n._label=o.first)}},hostAttrs:[1,"mdc-snackbar","mat-mdc-snack-bar-container"],hostVars:1,hostBindings:function(i,n){i&1&&vb("@state.done",function(r){return n.onAnimationEnd(r)}),i&2&&yb("@state",n._animationState)},features:[et],decls:6,vars:3,consts:[["label",""],[1,"mdc-snackbar__surface","mat-mdc-snackbar-surface"],[1,"mat-mdc-snack-bar-label"],["aria-hidden","true"],["cdkPortalOutlet",""]],template:function(i,n){i&1&&(S(0,"div",1)(1,"div",2,0)(3,"div",3),NA(4,J4A,0,0,"ng-template",4),R(),UA(5,"div"),R()()),i&2&&(_(5),_e("aria-live",n._live)("role",n._role)("id",n._liveElementId))},dependencies:[ca],styles:[".mat-mdc-snack-bar-container{display:flex;align-items:center;justify-content:center;box-sizing:border-box;-webkit-tap-highlight-color:rgba(0,0,0,0);margin:8px}.mat-mdc-snack-bar-handset .mat-mdc-snack-bar-container{width:100vw}.mat-mdc-snackbar-surface{box-shadow:0px 3px 5px -1px rgba(0, 0, 0, 0.2), 0px 6px 10px 0px rgba(0, 0, 0, 0.14), 0px 1px 18px 0px rgba(0, 0, 0, 0.12);display:flex;align-items:center;justify-content:flex-start;box-sizing:border-box;padding-left:0;padding-right:8px}[dir=rtl] .mat-mdc-snackbar-surface{padding-right:0;padding-left:8px}.mat-mdc-snack-bar-container .mat-mdc-snackbar-surface{min-width:344px;max-width:672px}.mat-mdc-snack-bar-handset .mat-mdc-snackbar-surface{width:100%;min-width:0}@media(forced-colors: active){.mat-mdc-snackbar-surface{outline:solid 1px}}.mat-mdc-snack-bar-container .mat-mdc-snackbar-surface{color:var(--mdc-snackbar-supporting-text-color, var(--mat-sys-inverse-on-surface));border-radius:var(--mdc-snackbar-container-shape, var(--mat-sys-corner-extra-small));background-color:var(--mdc-snackbar-container-color, var(--mat-sys-inverse-surface))}.mdc-snackbar__label{width:100%;flex-grow:1;box-sizing:border-box;margin:0;padding:14px 8px 14px 16px}[dir=rtl] .mdc-snackbar__label{padding-left:8px;padding-right:16px}.mat-mdc-snack-bar-container .mdc-snackbar__label{font-family:var(--mdc-snackbar-supporting-text-font, var(--mat-sys-body-medium-font));font-size:var(--mdc-snackbar-supporting-text-size, var(--mat-sys-body-medium-size));font-weight:var(--mdc-snackbar-supporting-text-weight, var(--mat-sys-body-medium-weight));line-height:var(--mdc-snackbar-supporting-text-line-height, var(--mat-sys-body-medium-line-height))}.mat-mdc-snack-bar-actions{display:flex;flex-shrink:0;align-items:center;box-sizing:border-box}.mat-mdc-snack-bar-handset,.mat-mdc-snack-bar-container,.mat-mdc-snack-bar-label{flex:1 1 auto}.mat-mdc-snack-bar-container .mat-mdc-button.mat-mdc-snack-bar-action:not(:disabled).mat-unthemed{color:var(--mat-snack-bar-button-color, var(--mat-sys-inverse-primary))}.mat-mdc-snack-bar-container .mat-mdc-button.mat-mdc-snack-bar-action:not(:disabled){--mat-text-button-state-layer-color:currentColor;--mat-text-button-ripple-color:currentColor}.mat-mdc-snack-bar-container .mat-mdc-button.mat-mdc-snack-bar-action:not(:disabled) .mat-ripple-element{opacity:.1}"],encapsulation:2,data:{animation:[j4A.snackBarState]}})}return t})();function V4A(){return new DB}var Z4A=new BA("mat-snack-bar-default-options",{providedIn:"root",factory:V4A}),pP=(()=>{class t{_overlay=m(Sr);_live=m(j6);_injector=m(Dt);_breakpointObserver=m(_6);_parentSnackBar=m(t,{optional:!0,skipSelf:!0});_defaultConfig=m(Z4A);_snackBarRefAtThisLevel=null;simpleSnackBarComponent=P4A;snackBarContainerComponent=q4A;handsetCssClass="mat-mdc-snack-bar-handset";get _openedSnackBarRef(){let A=this._parentSnackBar;return A?A._openedSnackBarRef:this._snackBarRefAtThisLevel}set _openedSnackBarRef(A){this._parentSnackBar?this._parentSnackBar._openedSnackBarRef=A:this._snackBarRefAtThisLevel=A}constructor(){}openFromComponent(A,i){return this._attach(A,i)}openFromTemplate(A,i){return this._attach(A,i)}open(A,i="",n){let o=nA(nA({},this._defaultConfig),n);return o.data={message:A,action:i},o.announcementMessage===A&&(o.announcementMessage=void 0),this.openFromComponent(this.simpleSnackBarComponent,o)}dismiss(){this._openedSnackBarRef&&this._openedSnackBarRef.dismiss()}ngOnDestroy(){this._snackBarRefAtThisLevel&&this._snackBarRefAtThisLevel.dismiss()}_attachSnackBarContainer(A,i){let n=i&&i.viewContainerRef&&i.viewContainerRef.injector,o=Dt.create({parent:n||this._injector,providers:[{provide:DB,useValue:i}]}),r=new sl(this.snackBarContainerComponent,i.viewContainerRef,o),s=A.attach(r);return s.instance.snackBarConfig=i,s.instance}_attach(A,i){let n=nA(nA(nA({},new DB),this._defaultConfig),i),o=this._createOverlay(n),r=this._attachSnackBarContainer(o,n),s=new Du(r,o);if(A instanceof vn){let a=new aa(A,null,{$implicit:n.data,snackBarRef:s});s.instance=r.attachTemplatePortal(a)}else{let a=this._createInjector(n,s),c=new sl(A,void 0,a),l=r.attachComponentPortal(c);s.instance=l.instance}return this._breakpointObserver.observe(fO.HandsetPortrait).pipe(wt(o.detachments())).subscribe(a=>{o.overlayElement.classList.toggle(this.handsetCssClass,a.matches)}),n.announcementMessage&&r._onAnnounce.subscribe(()=>{this._live.announce(n.announcementMessage,n.politeness)}),this._animateSnackBar(s,n),this._openedSnackBarRef=s,this._openedSnackBarRef}_animateSnackBar(A,i){A.afterDismissed().subscribe(()=>{this._openedSnackBarRef==A&&(this._openedSnackBarRef=null),i.announcementMessage&&this._live.clear()}),this._openedSnackBarRef?(this._openedSnackBarRef.afterDismissed().subscribe(()=>{A.containerInstance.enter()}),this._openedSnackBarRef.dismiss()):A.containerInstance.enter(),i.duration&&i.duration>0&&A.afterOpened().subscribe(()=>A._dismissAfter(i.duration))}_createOverlay(A){let i=new G2;i.direction=A.direction;let n=this._overlay.position().global(),o=A.direction==="rtl",r=A.horizontalPosition==="left"||A.horizontalPosition==="start"&&!o||A.horizontalPosition==="end"&&o,s=!r&&A.horizontalPosition!=="center";return r?n.left("0"):s?n.right("0"):n.centerHorizontally(),A.verticalPosition==="top"?n.top("0"):n.bottom("0"),i.positionStrategy=n,this._overlay.create(i)}_createInjector(A,i){let n=A&&A.viewContainerRef&&A.viewContainerRef.injector;return Dt.create({parent:n||this._injector,providers:[{provide:Du,useValue:i},{provide:mP,useValue:A.data}]})}static \u0275fac=function(i){return new(i||t)};static \u0275prov=SA({token:t,factory:t.\u0275fac,providedIn:"root"})}return t})();var W4A=function(){var t,e,A,i,n,o,r,s,a,c,l,I=arguments.length>0&&arguments[0]!==void 0?arguments[0]:{},C=new Promise((h,f)=>{t=h}),d=h=>console.log(h);function B(h){throw h}function E(){var h=l.buffer;A=new Int8Array(h),i=new Int16Array(h),o=new Uint8Array(h),n=new Int32Array(h),r=new Uint32Array(h),s=new Float32Array(h),a=new Float64Array(h),c=new BigInt64Array(h),new BigUint64Array(h)}I.agerrMessages=[],I.stderrMessages=[],e=h=>I.stderrMessages.push(h);var Q=typeof TextDecoder<"u"?new TextDecoder:void 0,u=function(h){let f=arguments.length>1&&arguments[1]!==void 0?arguments[1]:0;for(var w=f+(arguments.length>2&&arguments[2]!==void 0?arguments[2]:NaN),D=f;h[D]&&!(D>=w);)++D;if(D-f>16&&h.buffer&&Q)return Q.decode(h.subarray(f,D));for(var O="";f<D;){var Z=h[f++];if(128&Z){var q=63&h[f++];if((224&Z)!=192){var CA=63&h[f++];if((Z=(240&Z)==224?(15&Z)<<12|q<<6|CA:(7&Z)<<18|q<<12|CA<<6|63&h[f++])<65536)O+=String.fromCharCode(Z);else{var kA=Z-65536;O+=String.fromCharCode(55296|kA>>10,56320|1023&kA)}}else O+=String.fromCharCode((31&Z)<<6|q)}else O+=String.fromCharCode(Z)}return O},v=(h,f)=>h?u(o,h,f):"";class L{constructor(f){this.excPtr=f,this.ptr=f-24}set_type(f){r[this.ptr+4>>2]=f}get_type(){return r[this.ptr+4>>2]}set_destructor(f){r[this.ptr+8>>2]=f}get_destructor(){return r[this.ptr+8>>2]}set_caught(f){f=f?1:0,A[this.ptr+12]=f}get_caught(){return A[this.ptr+12]!=0}set_rethrown(f){f=f?1:0,A[this.ptr+13]=f}get_rethrown(){return A[this.ptr+13]!=0}init(f,w){this.set_adjusted_ptr(0),this.set_type(f),this.set_destructor(w)}set_adjusted_ptr(f){r[this.ptr+16>>2]=f}get_adjusted_ptr(){return r[this.ptr+16>>2]}}var x={isAbs:h=>h.charAt(0)==="/",splitPath:h=>/^(\/?|)([\s\S]*?)((?:\.{1,2}|[^\/]+?|)(\.[^.\/]*|))(?:[\/]*)$/.exec(h).slice(1),normalizeArray:(h,f)=>{for(var w=0,D=h.length-1;D>=0;D--){var O=h[D];O==="."?h.splice(D,1):O===".."?(h.splice(D,1),w++):w&&(h.splice(D,1),w--)}if(f)for(;w;w--)h.unshift("..");return h},normalize:h=>{var f=x.isAbs(h),w=h.substr(-1)==="/";return(h=x.normalizeArray(h.split("/").filter(D=>!!D),!f).join("/"))||f||(h="."),h&&w&&(h+="/"),(f?"/":"")+h},dirname:h=>{var f=x.splitPath(h),w=f[0],D=f[1];return w||D?(D&&(D=D.substr(0,D.length-1)),w+D):"."},basename:h=>{if(h==="/")return"/";var f=(h=(h=x.normalize(h)).replace(/\/$/,"")).lastIndexOf("/");return f===-1?h:h.substr(f+1)},join:function(){for(var h=arguments.length,f=new Array(h),w=0;w<h;w++)f[w]=arguments[w];return x.normalize(f.join("/"))},join2:(h,f)=>x.normalize(h+"/"+f)},y=h=>(y=(()=>{if(typeof crypto=="object"&&typeof crypto.getRandomValues=="function")return f=>crypto.getRandomValues(f);B("initRandomDevice")})())(h),F={resolve:function(){for(var h="",f=!1,w=arguments.length-1;w>=-1&&!f;w--){var D=w>=0?w<0||arguments.length<=w?void 0:arguments[w]:p.cwd();if(typeof D!="string")throw new TypeError("Arguments to path.resolve must be strings");if(!D)return"";h=D+"/"+h,f=x.isAbs(D)}return(f?"/":"")+(h=x.normalizeArray(h.split("/").filter(O=>!!O),!f).join("/"))||"."},relative:(h,f)=>{function w(KA){for(var Ie=0;Ie<KA.length&&KA[Ie]==="";Ie++);for(var GA=KA.length-1;GA>=0&&KA[GA]==="";GA--);return Ie>GA?[]:KA.slice(Ie,GA-Ie+1)}h=F.resolve(h).substr(1),f=F.resolve(f).substr(1);for(var D=w(h.split("/")),O=w(f.split("/")),Z=Math.min(D.length,O.length),q=Z,CA=0;CA<Z;CA++)if(D[CA]!==O[CA]){q=CA;break}var kA=[];for(CA=q;CA<D.length;CA++)kA.push("..");return(kA=kA.concat(O.slice(q))).join("/")}},U=[],T=h=>{for(var f=0,w=0;w<h.length;++w){var D=h.charCodeAt(w);D<=127?f++:D<=2047?f+=2:D>=55296&&D<=57343?(f+=4,++w):f+=3}return f},N=(h,f,w,D)=>{if(!(D>0))return 0;for(var O=w,Z=w+D-1,q=0;q<h.length;++q){var CA=h.charCodeAt(q);if(CA>=55296&&CA<=57343&&(CA=65536+((1023&CA)<<10)|1023&h.charCodeAt(++q)),CA<=127){if(w>=Z)break;f[w++]=CA}else if(CA<=2047){if(w+1>=Z)break;f[w++]=192|CA>>6,f[w++]=128|63&CA}else if(CA<=65535){if(w+2>=Z)break;f[w++]=224|CA>>12,f[w++]=128|CA>>6&63,f[w++]=128|63&CA}else{if(w+3>=Z)break;f[w++]=240|CA>>18,f[w++]=128|CA>>12&63,f[w++]=128|CA>>6&63,f[w++]=128|63&CA}}return f[w]=0,w-O};function K(h,f,w){var D=w>0?w:T(h)+1,O=new Array(D),Z=N(h,O,0,O.length);return f&&(O.length=Z),O}var H={ttys:[],init(){},shutdown(){},register(h,f){H.ttys[h]={input:[],output:[],ops:f},p.registerDevice(h,H.stream_ops)},stream_ops:{open(h){var f=H.ttys[h.node.rdev];if(!f)throw new p.ErrnoError(43);h.tty=f,h.seekable=!1},close(h){h.tty.ops.fsync(h.tty)},fsync(h){h.tty.ops.fsync(h.tty)},read(h,f,w,D,O){if(!h.tty||!h.tty.ops.get_char)throw new p.ErrnoError(60);for(var Z=0,q=0;q<D;q++){var CA;try{CA=h.tty.ops.get_char(h.tty)}catch{throw new p.ErrnoError(29)}if(CA===void 0&&Z===0)throw new p.ErrnoError(6);if(CA==null)break;Z++,f[w+q]=CA}return Z&&(h.node.timestamp=Date.now()),Z},write(h,f,w,D,O){if(!h.tty||!h.tty.ops.put_char)throw new p.ErrnoError(60);try{for(var Z=0;Z<D;Z++)h.tty.ops.put_char(h.tty,f[w+Z])}catch{throw new p.ErrnoError(29)}return D&&(h.node.timestamp=Date.now()),Z}},default_tty_ops:{get_char:h=>(()=>{if(!U.length){var f=null;if(typeof window<"u"&&typeof window.prompt=="function"&&(f=window.prompt("Input: "))!==null&&(f+=`
`),!f)return null;U=K(f,!0)}return U.shift()})(),put_char(h,f){f===null||f===10?(d(u(h.output)),h.output=[]):f!=0&&h.output.push(f)},fsync(h){h.output&&h.output.length>0&&(d(u(h.output)),h.output=[])},ioctl_tcgets:h=>({c_iflag:25856,c_oflag:5,c_cflag:191,c_lflag:35387,c_cc:[3,28,127,21,4,0,1,0,17,19,26,0,18,15,23,22,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0]}),ioctl_tcsets:(h,f,w)=>0,ioctl_tiocgwinsz:h=>[24,80]},default_tty1_ops:{put_char(h,f){f===null||f===10?(e(u(h.output)),h.output=[]):f!=0&&h.output.push(f)},fsync(h){h.output&&h.output.length>0&&(e(u(h.output)),h.output=[])}}},j=(h,f)=>Math.ceil(h/f)*f,IA=h=>{h=j(h,65536);var f=Re(65536,h);return f&&((w,D)=>{o.fill(0,w,w+D)})(f,h),f},lA={ops_table:null,mount:h=>lA.createNode(null,"/",16895,0),createNode(h,f,w,D){if(p.isBlkdev(w)||p.isFIFO(w))throw new p.ErrnoError(63);lA.ops_table||={dir:{node:{getattr:lA.node_ops.getattr,setattr:lA.node_ops.setattr,lookup:lA.node_ops.lookup,mknod:lA.node_ops.mknod,rename:lA.node_ops.rename,unlink:lA.node_ops.unlink,rmdir:lA.node_ops.rmdir,readdir:lA.node_ops.readdir,symlink:lA.node_ops.symlink},stream:{llseek:lA.stream_ops.llseek}},file:{node:{getattr:lA.node_ops.getattr,setattr:lA.node_ops.setattr},stream:{llseek:lA.stream_ops.llseek,read:lA.stream_ops.read,write:lA.stream_ops.write,allocate:lA.stream_ops.allocate,mmap:lA.stream_ops.mmap,msync:lA.stream_ops.msync}},link:{node:{getattr:lA.node_ops.getattr,setattr:lA.node_ops.setattr,readlink:lA.node_ops.readlink},stream:{}},chrdev:{node:{getattr:lA.node_ops.getattr,setattr:lA.node_ops.setattr},stream:p.chrdev_stream_ops}};var O=p.createNode(h,f,w,D);return p.isDir(O.mode)?(O.node_ops=lA.ops_table.dir.node,O.stream_ops=lA.ops_table.dir.stream,O.contents={}):p.isFile(O.mode)?(O.node_ops=lA.ops_table.file.node,O.stream_ops=lA.ops_table.file.stream,O.usedBytes=0,O.contents=null):p.isLink(O.mode)?(O.node_ops=lA.ops_table.link.node,O.stream_ops=lA.ops_table.link.stream):p.isChrdev(O.mode)&&(O.node_ops=lA.ops_table.chrdev.node,O.stream_ops=lA.ops_table.chrdev.stream),O.timestamp=Date.now(),h&&(h.contents[f]=O,h.timestamp=O.timestamp),O},getFileDataAsTypedArray:h=>h.contents?h.contents.subarray?h.contents.subarray(0,h.usedBytes):new Uint8Array(h.contents):new Uint8Array(0),expandFileStorage(h,f){var w=h.contents?h.contents.length:0;if(!(w>=f)){f=Math.max(f,w*(w<1048576?2:1.125)>>>0),w!=0&&(f=Math.max(f,256));var D=h.contents;h.contents=new Uint8Array(f),h.usedBytes>0&&h.contents.set(D.subarray(0,h.usedBytes),0)}},resizeFileStorage(h,f){if(h.usedBytes!=f)if(f==0)h.contents=null,h.usedBytes=0;else{var w=h.contents;h.contents=new Uint8Array(f),w&&h.contents.set(w.subarray(0,Math.min(f,h.usedBytes))),h.usedBytes=f}},node_ops:{getattr(h){var f={};return f.dev=p.isChrdev(h.mode)?h.id:1,f.ino=h.id,f.mode=h.mode,f.nlink=1,f.uid=0,f.gid=0,f.rdev=h.rdev,p.isDir(h.mode)?f.size=4096:p.isFile(h.mode)?f.size=h.usedBytes:p.isLink(h.mode)?f.size=h.link.length:f.size=0,f.atime=new Date(h.timestamp),f.mtime=new Date(h.timestamp),f.ctime=new Date(h.timestamp),f.blksize=4096,f.blocks=Math.ceil(f.size/f.blksize),f},setattr(h,f){f.mode!==void 0&&(h.mode=f.mode),f.timestamp!==void 0&&(h.timestamp=f.timestamp),f.size!==void 0&&lA.resizeFileStorage(h,f.size)},lookup(h,f){throw p.genericErrors[44]},mknod:(h,f,w,D)=>lA.createNode(h,f,w,D),rename(h,f,w){if(p.isDir(h.mode)){var D;try{D=p.lookupNode(f,w)}catch{}if(D)for(var O in D.contents)throw new p.ErrnoError(55)}delete h.parent.contents[h.name],h.parent.timestamp=Date.now(),h.name=w,f.contents[w]=h,f.timestamp=h.parent.timestamp},unlink(h,f){delete h.contents[f],h.timestamp=Date.now()},rmdir(h,f){var w=p.lookupNode(h,f);for(var D in w.contents)throw new p.ErrnoError(55);delete h.contents[f],h.timestamp=Date.now()},readdir(h){var f=[".",".."];for(var w of Object.keys(h.contents))f.push(w);return f},symlink(h,f,w){var D=lA.createNode(h,f,41471,0);return D.link=w,D},readlink(h){if(!p.isLink(h.mode))throw new p.ErrnoError(28);return h.link}},stream_ops:{read(h,f,w,D,O){var Z=h.node.contents;if(O>=h.node.usedBytes)return 0;var q=Math.min(h.node.usedBytes-O,D);if(q>8&&Z.subarray)f.set(Z.subarray(O,O+q),w);else for(var CA=0;CA<q;CA++)f[w+CA]=Z[O+CA];return q},write(h,f,w,D,O,Z){if(f.buffer===A.buffer&&(Z=!1),!D)return 0;var q=h.node;if(q.timestamp=Date.now(),f.subarray&&(!q.contents||q.contents.subarray)){if(Z)return q.contents=f.subarray(w,w+D),q.usedBytes=D,D;if(q.usedBytes===0&&O===0)return q.contents=f.slice(w,w+D),q.usedBytes=D,D;if(O+D<=q.usedBytes)return q.contents.set(f.subarray(w,w+D),O),D}if(lA.expandFileStorage(q,O+D),q.contents.subarray&&f.subarray)q.contents.set(f.subarray(w,w+D),O);else for(var CA=0;CA<D;CA++)q.contents[O+CA]=f[w+CA];return q.usedBytes=Math.max(q.usedBytes,O+D),D},llseek(h,f,w){var D=f;if(w===1?D+=h.position:w===2&&p.isFile(h.node.mode)&&(D+=h.node.usedBytes),D<0)throw new p.ErrnoError(28);return D},allocate(h,f,w){lA.expandFileStorage(h.node,f+w),h.node.usedBytes=Math.max(h.node.usedBytes,f+w)},mmap(h,f,w,D,O){if(!p.isFile(h.node.mode))throw new p.ErrnoError(43);var Z,q,CA=h.node.contents;if(2&O||!CA||CA.buffer!==A.buffer){if(q=!0,!(Z=IA(f)))throw new p.ErrnoError(48);CA&&((w>0||w+f<CA.length)&&(CA=CA.subarray?CA.subarray(w,w+f):Array.prototype.slice.call(CA,w,w+f)),A.set(CA,Z))}else q=!1,Z=CA.byteOffset;return{ptr:Z,allocated:q}},msync:(h,f,w,D,O)=>(lA.stream_ops.write(h,f,0,D,w,!1),0)}},uA=(h,f)=>{var w=0;return h&&(w|=365),f&&(w|=146),w},p={root:null,mounts:[],devices:{},streams:[],nextInode:1,nameTable:null,currentPath:"/",initialized:!1,ignorePermissions:!0,ErrnoError:class{constructor(h){this.name="ErrnoError",this.errno=h}},genericErrors:{},filesystems:null,syncFSRequests:0,FSStream:class{constructor(){this.shared={}}get object(){return this.node}set object(h){this.node=h}get isRead(){return(2097155&this.flags)!=1}get isWrite(){return!!(2097155&this.flags)}get isAppend(){return 1024&this.flags}get flags(){return this.shared.flags}set flags(h){this.shared.flags=h}get position(){return this.shared.position}set position(h){this.shared.position=h}},FSNode:class{constructor(h,f,w,D){h||(h=this),this.parent=h,this.mount=h.mount,this.mounted=null,this.id=p.nextInode++,this.name=f,this.mode=w,this.node_ops={},this.stream_ops={},this.rdev=D,this.readMode=365,this.writeMode=146}get read(){return(this.mode&this.readMode)===this.readMode}set read(h){h?this.mode|=this.readMode:this.mode&=~this.readMode}get write(){return(this.mode&this.writeMode)===this.writeMode}set write(h){h?this.mode|=this.writeMode:this.mode&=~this.writeMode}get isFolder(){return p.isDir(this.mode)}get isDevice(){return p.isChrdev(this.mode)}},lookupPath(h){let f=arguments.length>1&&arguments[1]!==void 0?arguments[1]:{};if(!(h=F.resolve(h)))return{path:"",node:null};if(f=Object.assign({follow_mount:!0,recurse_count:0},f),f.recurse_count>8)throw new p.ErrnoError(32);for(var w=h.split("/").filter(KA=>!!KA),D=p.root,O="/",Z=0;Z<w.length;Z++){var q=Z===w.length-1;if(q&&f.parent)break;if(D=p.lookupNode(D,w[Z]),O=x.join2(O,w[Z]),p.isMountpoint(D)&&(!q||q&&f.follow_mount)&&(D=D.mounted.root),!q||f.follow)for(var CA=0;p.isLink(D.mode);){var kA=p.readlink(O);if(O=F.resolve(x.dirname(O),kA),D=p.lookupPath(O,{recurse_count:f.recurse_count+1}).node,CA++>40)throw new p.ErrnoError(32)}}return{path:O,node:D}},getPath(h){for(var f;;){if(p.isRoot(h)){var w=h.mount.mountpoint;return f?w[w.length-1]!=="/"?`${w}/${f}`:w+f:w}f=f?`${h.name}/${f}`:h.name,h=h.parent}},hashName(h,f){for(var w=0,D=0;D<f.length;D++)w=(w<<5)-w+f.charCodeAt(D)|0;return(h+w>>>0)%p.nameTable.length},hashAddNode(h){var f=p.hashName(h.parent.id,h.name);h.name_next=p.nameTable[f],p.nameTable[f]=h},hashRemoveNode(h){var f=p.hashName(h.parent.id,h.name);if(p.nameTable[f]===h)p.nameTable[f]=h.name_next;else for(var w=p.nameTable[f];w;){if(w.name_next===h){w.name_next=h.name_next;break}w=w.name_next}},lookupNode(h,f){var w=p.mayLookup(h);if(w)throw new p.ErrnoError(w);for(var D=p.hashName(h.id,f),O=p.nameTable[D];O;O=O.name_next){var Z=O.name;if(O.parent.id===h.id&&Z===f)return O}return p.lookup(h,f)},createNode(h,f,w,D){var O=new p.FSNode(h,f,w,D);return p.hashAddNode(O),O},destroyNode(h){p.hashRemoveNode(h)},isRoot:h=>h===h.parent,isMountpoint:h=>!!h.mounted,isFile:h=>(61440&h)==32768,isDir:h=>(61440&h)==16384,isLink:h=>(61440&h)==40960,isChrdev:h=>(61440&h)==8192,isBlkdev:h=>(61440&h)==24576,isFIFO:h=>(61440&h)==4096,isSocket:h=>!(49152&~h),flagsToPermissionString(h){var f=["r","w","rw"][3&h];return 512&h&&(f+="w"),f},nodePermissions:(h,f)=>p.ignorePermissions||(!f.includes("r")||292&h.mode)&&(!f.includes("w")||146&h.mode)&&(!f.includes("x")||73&h.mode)?0:2,mayLookup(h){if(!p.isDir(h.mode))return 54;var f=p.nodePermissions(h,"x");return f||(h.node_ops.lookup?0:2)},mayCreate(h,f){try{return p.lookupNode(h,f),20}catch{}return p.nodePermissions(h,"wx")},mayDelete(h,f,w){var D;try{D=p.lookupNode(h,f)}catch(Z){return Z.errno}var O=p.nodePermissions(h,"wx");if(O)return O;if(w){if(!p.isDir(D.mode))return 54;if(p.isRoot(D)||p.getPath(D)===p.cwd())return 10}else if(p.isDir(D.mode))return 31;return 0},mayOpen:(h,f)=>h?p.isLink(h.mode)?32:p.isDir(h.mode)&&(p.flagsToPermissionString(f)!=="r"||512&f)?31:p.nodePermissions(h,p.flagsToPermissionString(f)):44,MAX_OPEN_FDS:4096,nextfd(){for(var h=0;h<=p.MAX_OPEN_FDS;h++)if(!p.streams[h])return h;throw new p.ErrnoError(33)},getStreamChecked(h){var f=p.getStream(h);if(!f)throw new p.ErrnoError(8);return f},getStream:h=>p.streams[h],createStream(h){let f=arguments.length>1&&arguments[1]!==void 0?arguments[1]:-1;return h=Object.assign(new p.FSStream,h),f==-1&&(f=p.nextfd()),h.fd=f,p.streams[f]=h,h},closeStream(h){p.streams[h]=null},dupStream(h){let f=arguments.length>1&&arguments[1]!==void 0?arguments[1]:-1;var w=p.createStream(h,f);return w.stream_ops?.dup?.(w),w},chrdev_stream_ops:{open(h){var f=p.getDevice(h.node.rdev);h.stream_ops=f.stream_ops,h.stream_ops.open?.(h)},llseek(){throw new p.ErrnoError(70)}},major:h=>h>>8,minor:h=>255&h,makedev:(h,f)=>h<<8|f,registerDevice(h,f){p.devices[h]={stream_ops:f}},getDevice:h=>p.devices[h],getMounts(h){for(var f=[],w=[h];w.length;){var D=w.pop();f.push(D),w.push(...D.mounts)}return f},syncfs(h,f){typeof h=="function"&&(f=h,h=!1),p.syncFSRequests++,p.syncFSRequests>1&&e(`warning: ${p.syncFSRequests} FS.syncfs operations in flight at once, probably just doing extra work`);var w=p.getMounts(p.root.mount),D=0;function O(q){return p.syncFSRequests--,f(q)}function Z(q){if(q)return Z.errored?void 0:(Z.errored=!0,O(q));++D>=w.length&&O(null)}w.forEach(q=>{if(!q.type.syncfs)return Z(null);q.type.syncfs(q,h,Z)})},mount(h,f,w){var D,O=w==="/",Z=!w;if(O&&p.root)throw new p.ErrnoError(10);if(!O&&!Z){var q=p.lookupPath(w,{follow_mount:!1});if(w=q.path,D=q.node,p.isMountpoint(D))throw new p.ErrnoError(10);if(!p.isDir(D.mode))throw new p.ErrnoError(54)}var CA={type:h,opts:f,mountpoint:w,mounts:[]},kA=h.mount(CA);return kA.mount=CA,CA.root=kA,O?p.root=kA:D&&(D.mounted=CA,D.mount&&D.mount.mounts.push(CA)),kA},unmount(h){var f=p.lookupPath(h,{follow_mount:!1});if(!p.isMountpoint(f.node))throw new p.ErrnoError(28);var w=f.node,D=w.mounted,O=p.getMounts(D);Object.keys(p.nameTable).forEach(q=>{for(var CA=p.nameTable[q];CA;){var kA=CA.name_next;O.includes(CA.mount)&&p.destroyNode(CA),CA=kA}}),w.mounted=null;var Z=w.mount.mounts.indexOf(D);w.mount.mounts.splice(Z,1)},lookup:(h,f)=>h.node_ops.lookup(h,f),mknod(h,f,w){var D=p.lookupPath(h,{parent:!0}).node,O=x.basename(h);if(!O||O==="."||O==="..")throw new p.ErrnoError(28);var Z=p.mayCreate(D,O);if(Z)throw new p.ErrnoError(Z);if(!D.node_ops.mknod)throw new p.ErrnoError(63);return D.node_ops.mknod(D,O,f,w)},create:(h,f)=>(f=f!==void 0?f:438,f&=4095,f|=32768,p.mknod(h,f,0)),mkdir:(h,f)=>(f=f!==void 0?f:511,f&=1023,f|=16384,p.mknod(h,f,0)),mkdirTree(h,f){for(var w=h.split("/"),D="",O=0;O<w.length;++O)if(w[O]){D+="/"+w[O];try{p.mkdir(D,f)}catch(Z){if(Z.errno!=20)throw Z}}},mkdev:(h,f,w)=>(w===void 0&&(w=f,f=438),f|=8192,p.mknod(h,f,w)),symlink(h,f){if(!F.resolve(h))throw new p.ErrnoError(44);var w=p.lookupPath(f,{parent:!0}).node;if(!w)throw new p.ErrnoError(44);var D=x.basename(f),O=p.mayCreate(w,D);if(O)throw new p.ErrnoError(O);if(!w.node_ops.symlink)throw new p.ErrnoError(63);return w.node_ops.symlink(w,D,h)},rename(h,f){var w,D,O=x.dirname(h),Z=x.dirname(f),q=x.basename(h),CA=x.basename(f);if(w=p.lookupPath(h,{parent:!0}).node,D=p.lookupPath(f,{parent:!0}).node,!w||!D)throw new p.ErrnoError(44);if(w.mount!==D.mount)throw new p.ErrnoError(75);var kA,KA=p.lookupNode(w,q),Ie=F.relative(h,Z);if(Ie.charAt(0)!==".")throw new p.ErrnoError(28);if((Ie=F.relative(f,O)).charAt(0)!==".")throw new p.ErrnoError(55);try{kA=p.lookupNode(D,CA)}catch{}if(KA!==kA){var GA=p.isDir(KA.mode),oe=p.mayDelete(w,q,GA);if(oe)throw new p.ErrnoError(oe);if(oe=kA?p.mayDelete(D,CA,GA):p.mayCreate(D,CA))throw new p.ErrnoError(oe);if(!w.node_ops.rename)throw new p.ErrnoError(63);if(p.isMountpoint(KA)||kA&&p.isMountpoint(kA))throw new p.ErrnoError(10);if(D!==w&&(oe=p.nodePermissions(w,"w")))throw new p.ErrnoError(oe);p.hashRemoveNode(KA);try{w.node_ops.rename(KA,D,CA),KA.parent=D}catch(M){throw M}finally{p.hashAddNode(KA)}}},rmdir(h){var f=p.lookupPath(h,{parent:!0}).node,w=x.basename(h),D=p.lookupNode(f,w),O=p.mayDelete(f,w,!0);if(O)throw new p.ErrnoError(O);if(!f.node_ops.rmdir)throw new p.ErrnoError(63);if(p.isMountpoint(D))throw new p.ErrnoError(10);f.node_ops.rmdir(f,w),p.destroyNode(D)},readdir(h){var f=p.lookupPath(h,{follow:!0}).node;if(!f.node_ops.readdir)throw new p.ErrnoError(54);return f.node_ops.readdir(f)},unlink(h){var f=p.lookupPath(h,{parent:!0}).node;if(!f)throw new p.ErrnoError(44);var w=x.basename(h),D=p.lookupNode(f,w),O=p.mayDelete(f,w,!1);if(O)throw new p.ErrnoError(O);if(!f.node_ops.unlink)throw new p.ErrnoError(63);if(p.isMountpoint(D))throw new p.ErrnoError(10);f.node_ops.unlink(f,w),p.destroyNode(D)},readlink(h){var f=p.lookupPath(h).node;if(!f)throw new p.ErrnoError(44);if(!f.node_ops.readlink)throw new p.ErrnoError(28);return F.resolve(p.getPath(f.parent),f.node_ops.readlink(f))},stat(h,f){var w=p.lookupPath(h,{follow:!f}).node;if(!w)throw new p.ErrnoError(44);if(!w.node_ops.getattr)throw new p.ErrnoError(63);return w.node_ops.getattr(w)},lstat:h=>p.stat(h,!0),chmod(h,f,w){var D;if(typeof h=="string"?D=p.lookupPath(h,{follow:!w}).node:D=h,!D.node_ops.setattr)throw new p.ErrnoError(63);D.node_ops.setattr(D,{mode:4095&f|-4096&D.mode,timestamp:Date.now()})},lchmod(h,f){p.chmod(h,f,!0)},fchmod(h,f){var w=p.getStreamChecked(h);p.chmod(w.node,f)},chown(h,f,w,D){var O;if(typeof h=="string"?O=p.lookupPath(h,{follow:!D}).node:O=h,!O.node_ops.setattr)throw new p.ErrnoError(63);O.node_ops.setattr(O,{timestamp:Date.now()})},lchown(h,f,w){p.chown(h,f,w,!0)},fchown(h,f,w){var D=p.getStreamChecked(h);p.chown(D.node,f,w)},truncate(h,f){if(f<0)throw new p.ErrnoError(28);var w;if(typeof h=="string"?w=p.lookupPath(h,{follow:!0}).node:w=h,!w.node_ops.setattr)throw new p.ErrnoError(63);if(p.isDir(w.mode))throw new p.ErrnoError(31);if(!p.isFile(w.mode))throw new p.ErrnoError(28);var D=p.nodePermissions(w,"w");if(D)throw new p.ErrnoError(D);w.node_ops.setattr(w,{size:f,timestamp:Date.now()})},ftruncate(h,f){var w=p.getStreamChecked(h);if(!(2097155&w.flags))throw new p.ErrnoError(28);p.truncate(w.node,f)},utime(h,f,w){var D=p.lookupPath(h,{follow:!0}).node;D.node_ops.setattr(D,{timestamp:Math.max(f,w)})},open(h,f,w){if(h==="")throw new p.ErrnoError(44);var D;if(w=64&(f=typeof f=="string"?(CA=>{var kA={r:0,"r+":2,w:577,"w+":578,a:1089,"a+":1090}[CA];if(kA===void 0)throw new Error(`Unknown file open mode: ${CA}`);return kA})(f):f)?4095&(w=w===void 0?438:w)|32768:0,typeof h=="object")D=h;else{h=x.normalize(h);try{D=p.lookupPath(h,{follow:!(131072&f)}).node}catch{}}var O=!1;if(64&f)if(D){if(128&f)throw new p.ErrnoError(20)}else D=p.mknod(h,w,0),O=!0;if(!D)throw new p.ErrnoError(44);if(p.isChrdev(D.mode)&&(f&=-513),65536&f&&!p.isDir(D.mode))throw new p.ErrnoError(54);if(!O){var Z=p.mayOpen(D,f);if(Z)throw new p.ErrnoError(Z)}512&f&&!O&&p.truncate(D,0),f&=-131713;var q=p.createStream({node:D,path:p.getPath(D),flags:f,seekable:!0,position:0,stream_ops:D.stream_ops,ungotten:[],error:!1});return q.stream_ops.open&&q.stream_ops.open(q),q},close(h){if(p.isClosed(h))throw new p.ErrnoError(8);h.getdents&&(h.getdents=null);try{h.stream_ops.close&&h.stream_ops.close(h)}catch(f){throw f}finally{p.closeStream(h.fd)}h.fd=null},isClosed:h=>h.fd===null,llseek(h,f,w){if(p.isClosed(h))throw new p.ErrnoError(8);if(!h.seekable||!h.stream_ops.llseek)throw new p.ErrnoError(70);if(w!=0&&w!=1&&w!=2)throw new p.ErrnoError(28);return h.position=h.stream_ops.llseek(h,f,w),h.ungotten=[],h.position},read(h,f,w,D,O){if(D<0||O<0)throw new p.ErrnoError(28);if(p.isClosed(h))throw new p.ErrnoError(8);if((2097155&h.flags)==1)throw new p.ErrnoError(8);if(p.isDir(h.node.mode))throw new p.ErrnoError(31);if(!h.stream_ops.read)throw new p.ErrnoError(28);var Z=O!==void 0;if(Z){if(!h.seekable)throw new p.ErrnoError(70)}else O=h.position;var q=h.stream_ops.read(h,f,w,D,O);return Z||(h.position+=q),q},write(h,f,w,D,O,Z){if(D<0||O<0)throw new p.ErrnoError(28);if(p.isClosed(h))throw new p.ErrnoError(8);if(!(2097155&h.flags))throw new p.ErrnoError(8);if(p.isDir(h.node.mode))throw new p.ErrnoError(31);if(!h.stream_ops.write)throw new p.ErrnoError(28);h.seekable&&1024&h.flags&&p.llseek(h,0,2);var q=O!==void 0;if(q){if(!h.seekable)throw new p.ErrnoError(70)}else O=h.position;var CA=h.stream_ops.write(h,f,w,D,O,Z);return q||(h.position+=CA),CA},allocate(h,f,w){if(p.isClosed(h))throw new p.ErrnoError(8);if(f<0||w<=0)throw new p.ErrnoError(28);if(!(2097155&h.flags))throw new p.ErrnoError(8);if(!p.isFile(h.node.mode)&&!p.isDir(h.node.mode))throw new p.ErrnoError(43);if(!h.stream_ops.allocate)throw new p.ErrnoError(138);h.stream_ops.allocate(h,f,w)},mmap(h,f,w,D,O){if(2&D&&!(2&O)&&(2097155&h.flags)!=2)throw new p.ErrnoError(2);if((2097155&h.flags)==1)throw new p.ErrnoError(2);if(!h.stream_ops.mmap)throw new p.ErrnoError(43);if(!f)throw new p.ErrnoError(28);return h.stream_ops.mmap(h,f,w,D,O)},msync:(h,f,w,D,O)=>h.stream_ops.msync?h.stream_ops.msync(h,f,w,D,O):0,ioctl(h,f,w){if(!h.stream_ops.ioctl)throw new p.ErrnoError(59);return h.stream_ops.ioctl(h,f,w)},readFile(h){let f=arguments.length>1&&arguments[1]!==void 0?arguments[1]:{};if(f.flags=f.flags||0,f.encoding=f.encoding||"binary",f.encoding!=="utf8"&&f.encoding!=="binary")throw new Error(`Invalid encoding type "${f.encoding}"`);var w,D=p.open(h,f.flags),O=p.stat(h).size,Z=new Uint8Array(O);return p.read(D,Z,0,O,0),f.encoding==="utf8"?w=u(Z):f.encoding==="binary"&&(w=Z),p.close(D),w},writeFile(h,f){let w=arguments.length>2&&arguments[2]!==void 0?arguments[2]:{};w.flags=w.flags||577;var D=p.open(h,w.flags,w.mode);if(typeof f=="string"){var O=new Uint8Array(T(f)+1),Z=N(f,O,0,O.length);p.write(D,O,0,Z,void 0,w.canOwn)}else{if(!ArrayBuffer.isView(f))throw new Error("Unsupported data type");p.write(D,f,0,f.byteLength,void 0,w.canOwn)}p.close(D)},cwd:()=>p.currentPath,chdir(h){var f=p.lookupPath(h,{follow:!0});if(f.node===null)throw new p.ErrnoError(44);if(!p.isDir(f.node.mode))throw new p.ErrnoError(54);var w=p.nodePermissions(f.node,"x");if(w)throw new p.ErrnoError(w);p.currentPath=f.path},createDefaultDirectories(){p.mkdir("/tmp"),p.mkdir("/home"),p.mkdir("/home/web_user")},createDefaultDevices(){p.mkdir("/dev"),p.registerDevice(p.makedev(1,3),{read:()=>0,write:(D,O,Z,q,CA)=>q}),p.mkdev("/dev/null",p.makedev(1,3)),H.register(p.makedev(5,0),H.default_tty_ops),H.register(p.makedev(6,0),H.default_tty1_ops),p.mkdev("/dev/tty",p.makedev(5,0)),p.mkdev("/dev/tty1",p.makedev(6,0));var h=new Uint8Array(1024),f=0,w=()=>(f===0&&(f=y(h).byteLength),h[--f]);p.createDevice("/dev","random",w),p.createDevice("/dev","urandom",w),p.mkdir("/dev/shm"),p.mkdir("/dev/shm/tmp")},createSpecialDirectories(){p.mkdir("/proc");var h=p.mkdir("/proc/self");p.mkdir("/proc/self/fd"),p.mount({mount(){var f=p.createNode(h,"fd",16895,73);return f.node_ops={lookup(w,D){var O=+D,Z=p.getStreamChecked(O),q={parent:null,mount:{mountpoint:"fake"},node_ops:{readlink:()=>Z.path}};return q.parent=q,q}},f}},{},"/proc/self/fd")},createStandardStreams(h,f,w){h?p.createDevice("/dev","stdin",h):p.symlink("/dev/tty","/dev/stdin"),f?p.createDevice("/dev","stdout",null,f):p.symlink("/dev/tty","/dev/stdout"),w?p.createDevice("/dev","stderr",null,w):p.symlink("/dev/tty1","/dev/stderr"),p.open("/dev/stdin",0),p.open("/dev/stdout",1),p.open("/dev/stderr",1)},staticInit(){[44].forEach(h=>{p.genericErrors[h]=new p.ErrnoError(h),p.genericErrors[h].stack="<generic error, no stack>"}),p.nameTable=new Array(4096),p.mount(lA,{},"/"),p.createDefaultDirectories(),p.createDefaultDevices(),p.createSpecialDirectories(),p.filesystems={MEMFS:lA}},init(h,f,w){p.initialized=!0,p.createStandardStreams(h,f,w)},quit(){p.initialized=!1;for(var h=0;h<p.streams.length;h++){var f=p.streams[h];f&&p.close(f)}},findObject(h,f){var w=p.analyzePath(h,f);return w.exists?w.object:null},analyzePath(h,f){try{h=(D=p.lookupPath(h,{follow:!f})).path}catch{}var w={isRoot:!1,exists:!1,error:0,name:null,path:null,object:null,parentExists:!1,parentPath:null,parentObject:null};try{var D=p.lookupPath(h,{parent:!0});w.parentExists=!0,w.parentPath=D.path,w.parentObject=D.node,w.name=x.basename(h),D=p.lookupPath(h,{follow:!f}),w.exists=!0,w.path=D.path,w.object=D.node,w.name=D.node.name,w.isRoot=D.path==="/"}catch(O){w.error=O.errno}return w},createPath(h,f,w,D){h=typeof h=="string"?h:p.getPath(h);for(var O=f.split("/").reverse();O.length;){var Z=O.pop();if(Z){var q=x.join2(h,Z);try{p.mkdir(q)}catch{}h=q}}return q},createFile(h,f,w,D,O){var Z=x.join2(typeof h=="string"?h:p.getPath(h),f),q=uA(D,O);return p.create(Z,q)},createDataFile(h,f,w,D,O,Z){var q=f;h&&(h=typeof h=="string"?h:p.getPath(h),q=f?x.join2(h,f):h);var CA=uA(D,O),kA=p.create(q,CA);if(w){if(typeof w=="string"){for(var KA=new Array(w.length),Ie=0,GA=w.length;Ie<GA;++Ie)KA[Ie]=w.charCodeAt(Ie);w=KA}p.chmod(kA,146|CA);var oe=p.open(kA,577);p.write(oe,w,0,w.length,0,Z),p.close(oe),p.chmod(kA,CA)}},createDevice(h,f,w,D){var O=x.join2(typeof h=="string"?h:p.getPath(h),f),Z=uA(!!w,!!D);p.createDevice.major??=64;var q=p.makedev(p.createDevice.major++,0);return p.registerDevice(q,{open(CA){CA.seekable=!1},close(CA){D?.buffer?.length&&D(10)},read(CA,kA,KA,Ie,GA){for(var oe=0,M=0;M<Ie;M++){var G;try{G=w()}catch{throw new p.ErrnoError(29)}if(G===void 0&&oe===0)throw new p.ErrnoError(6);if(G==null)break;oe++,kA[KA+M]=G}return oe&&(CA.node.timestamp=Date.now()),oe},write(CA,kA,KA,Ie,GA){for(var oe=0;oe<Ie;oe++)try{D(kA[KA+oe])}catch{throw new p.ErrnoError(29)}return Ie&&(CA.node.timestamp=Date.now()),oe}}),p.mkdev(O,Z,q)},forceLoadFile(h){if(h.isDevice||h.isFolder||h.link||h.contents)return!0;if(typeof XMLHttpRequest<"u")throw new Error("Lazy loading should have been performed (contents set) in createLazyFile, but it was not. Lazy loading only works in web workers. Use --embed-file or --preload-file in emcc on the main thread.");try{h.contents=readBinary(h.url),h.usedBytes=h.contents.length}catch{throw new p.ErrnoError(29)}},createLazyFile(h,f,w,D,O){class Z{constructor(){this.lengthKnown=!1,this.chunks=[]}get(GA){if(!(GA>this.length-1||GA<0)){var oe=GA%this.chunkSize,M=GA/this.chunkSize|0;return this.getter(M)[oe]}}setDataGetter(GA){this.getter=GA}cacheLength(){var GA=new XMLHttpRequest;if(GA.open("HEAD",w,!1),GA.send(null),!(GA.status>=200&&GA.status<300||GA.status===304))throw new Error("Couldn't load "+w+". Status: "+GA.status);var oe,M=Number(GA.getResponseHeader("Content-length")),G=(oe=GA.getResponseHeader("Accept-Ranges"))&&oe==="bytes",Y=(oe=GA.getResponseHeader("Content-Encoding"))&&oe==="gzip",AA=1048576;G||(AA=M);var dA=this;dA.setDataGetter(WA=>{var Qe=WA*AA,yA=(WA+1)*AA-1;if(yA=Math.min(yA,M-1),dA.chunks[WA]===void 0&&(dA.chunks[WA]=((DA,We)=>{if(DA>We)throw new Error("invalid range ("+DA+", "+We+") or no bytes requested!");if(We>M-1)throw new Error("only "+M+" bytes available! programmer error!");var be=new XMLHttpRequest;if(be.open("GET",w,!1),M!==AA&&be.setRequestHeader("Range","bytes="+DA+"-"+We),be.responseType="arraybuffer",be.overrideMimeType&&be.overrideMimeType("text/plain; charset=x-user-defined"),be.send(null),!(be.status>=200&&be.status<300||be.status===304))throw new Error("Couldn't load "+w+". Status: "+be.status);return be.response!==void 0?new Uint8Array(be.response||[]):K(be.responseText||"",!0)})(Qe,yA)),dA.chunks[WA]===void 0)throw new Error("doXHR failed!");return dA.chunks[WA]}),!Y&&M||(AA=M=1,M=this.getter(0).length,AA=M,d("LazyFiles on gzip forces download of the whole file when length is accessed")),this._length=M,this._chunkSize=AA,this.lengthKnown=!0}get length(){return this.lengthKnown||this.cacheLength(),this._length}get chunkSize(){return this.lengthKnown||this.cacheLength(),this._chunkSize}}if(typeof XMLHttpRequest<"u"){if(!ENVIRONMENT_IS_WORKER)throw"Cannot do synchronous binary XHRs outside webworkers in modern browsers. Use --embed-file or --preload-file in emcc";var q={isDevice:!1,contents:new Z}}else q={isDevice:!1,url:w};var CA=p.createFile(h,f,q,D,O);q.contents?CA.contents=q.contents:q.url&&(CA.contents=null,CA.url=q.url),Object.defineProperties(CA,{usedBytes:{get:function(){return this.contents.length}}});var kA={};function KA(Ie,GA,oe,M,G){var Y=Ie.node.contents;if(G>=Y.length)return 0;var AA=Math.min(Y.length-G,M);if(Y.slice)for(var dA=0;dA<AA;dA++)GA[oe+dA]=Y[G+dA];else for(dA=0;dA<AA;dA++)GA[oe+dA]=Y.get(G+dA);return AA}return Object.keys(CA.stream_ops).forEach(Ie=>{var GA=CA.stream_ops[Ie];kA[Ie]=function(){return p.forceLoadFile(CA),GA(...arguments)}}),kA.read=(Ie,GA,oe,M,G)=>(p.forceLoadFile(CA),KA(Ie,GA,oe,M,G)),kA.mmap=(Ie,GA,oe,M,G)=>{p.forceLoadFile(CA);var Y=IA(GA);if(!Y)throw new p.ErrnoError(48);return KA(Ie,A,Y,GA,oe),{ptr:Y,allocated:!0}},CA.stream_ops=kA,CA}},V={DEFAULT_POLLMASK:5,calculateAt(h,f,w){if(x.isAbs(f))return f;var D;if(h===-100?D=p.cwd():D=V.getStreamFromFD(h).path,f.length==0){if(!w)throw new p.ErrnoError(44);return D}return x.join2(D,f)},doStat(h,f,w){var D=h(f);n[w>>2]=D.dev,n[w+4>>2]=D.mode,r[w+8>>2]=D.nlink,n[w+12>>2]=D.uid,n[w+16>>2]=D.gid,n[w+20>>2]=D.rdev,c[w+24>>3]=BigInt(D.size),n[w+32>>2]=4096,n[w+36>>2]=D.blocks;var O=D.atime.getTime(),Z=D.mtime.getTime(),q=D.ctime.getTime();return c[w+40>>3]=BigInt(Math.floor(O/1e3)),r[w+48>>2]=O%1e3*1e3*1e3,c[w+56>>3]=BigInt(Math.floor(Z/1e3)),r[w+64>>2]=Z%1e3*1e3*1e3,c[w+72>>3]=BigInt(Math.floor(q/1e3)),r[w+80>>2]=q%1e3*1e3*1e3,c[w+88>>3]=BigInt(D.ino),0},doMsync(h,f,w,D,O){if(!p.isFile(f.node.mode))throw new p.ErrnoError(43);if(2&D)return 0;var Z=o.slice(h,h+w);p.msync(f,Z,O,w,D)},getStreamFromFD:h=>p.getStreamChecked(h),varargs:void 0,getStr:h=>v(h)};function cA(){var h=n[+V.varargs>>2];return V.varargs+=4,h}var aA=cA,jA=h=>h<-9007199254740992||h>9007199254740992?NaN:Number(h),VA=(h,f,w)=>N(h,o,f,w),ce=h=>{var f=(h-l.buffer.byteLength+65535)/65536|0;try{return l.grow(f),E(),1}catch{}},EA={},sA=()=>{if(!sA.strings){var h={USER:"web_user",LOGNAME:"web_user",PATH:"/",PWD:"/",HOME:"/home/web_user",LANG:(typeof navigator=="object"&&navigator.languages&&navigator.languages[0]||"C").replace("-","_")+".UTF-8",_:"./this.program"};for(var f in EA)EA[f]===void 0?delete h[f]:h[f]=EA[f];var w=[];for(var f in h)w.push(`${f}=${h[f]}`);sA.strings=w}return sA.strings},TA=h=>{throw`exit(${h})`},Ke=h=>eA(h);p.createPreloadedFile=(h,f,w,D,O,Z,q,CA,kA,KA)=>{var Ie=f?F.resolve(x.join2(h,f)):h,GA=getUniqueRunDependency(`cp ${Ie}`);function oe(M){(function(G){KA?.(),CA||((Y,AA,dA,WA,Qe,yA)=>{p.createDataFile(Y,AA,dA,WA,Qe,yA)})(h,f,G,D,O,kA),Z?.(),removeRunDependency(GA)})(M)}addRunDependency(GA),typeof w=="string"?((M,G,Y,AA)=>{var dA=AA?"":getUniqueRunDependency(`al ${M}`);readAsync(M).then(WA=>{G(new Uint8Array(WA)),dA&&removeRunDependency(dA)},WA=>{if(!Y)throw`Loading data file "${M}" failed.`;Y()}),dA&&addRunDependency(dA)})(w,oe,q):oe(w)},p.staticInit();var Re,hA,eA,RA,oA={a:(h,f,w,D)=>{B(`Assertion failed: ${v(h)}, at: `+[f?v(f):"unknown filename",w,D?v(D):"unknown function"])},b:(h,f,w)=>{throw new L(h).init(f,w),h},v:function(h,f,w,D){try{if(f=V.getStr(f),f=V.calculateAt(h,f),-8&w)return-28;var O=p.lookupPath(f,{follow:!0}).node;if(!O)return-44;var Z="";return 4&w&&(Z+="r"),2&w&&(Z+="w"),1&w&&(Z+="x"),Z&&p.nodePermissions(O,Z)?-2:0}catch(q){if(p===void 0||q.name!=="ErrnoError")throw q;return-q.errno}},f:function(h,f,w){V.varargs=w;try{var D=V.getStreamFromFD(h);switch(f){case 0:if((O=cA())<0)return-28;for(;p.streams[O];)O++;return p.dupStream(D,O).fd;case 1:case 2:case 13:case 14:return 0;case 3:return D.flags;case 4:var O=cA();return D.flags|=O,0;case 12:return O=aA(),i[O+0>>1]=2,0}return-28}catch(Z){if(p===void 0||Z.name!=="ErrnoError")throw Z;return-Z.errno}},u:function(h,f){try{var w=V.getStreamFromFD(h);return V.doStat(p.stat,w.path,f)}catch(D){if(p===void 0||D.name!=="ErrnoError")throw D;return-D.errno}},j:function(h,f,w){V.varargs=w;try{var D=V.getStreamFromFD(h);switch(f){case 21509:case 21510:case 21511:case 21512:case 21524:case 21515:return D.tty?0:-59;case 21505:if(!D.tty)return-59;if(D.tty.ops.ioctl_tcgets){var O=D.tty.ops.ioctl_tcgets(D),Z=aA();n[Z>>2]=O.c_iflag||0,n[Z+4>>2]=O.c_oflag||0,n[Z+8>>2]=O.c_cflag||0,n[Z+12>>2]=O.c_lflag||0;for(var q=0;q<32;q++)A[Z+q+17]=O.c_cc[q]||0;return 0}return 0;case 21506:case 21507:case 21508:if(!D.tty)return-59;if(D.tty.ops.ioctl_tcsets){Z=aA();var CA=n[Z>>2],kA=n[Z+4>>2],KA=n[Z+8>>2],Ie=n[Z+12>>2],GA=[];for(q=0;q<32;q++)GA.push(A[Z+q+17]);return D.tty.ops.ioctl_tcsets(D.tty,f,{c_iflag:CA,c_oflag:kA,c_cflag:KA,c_lflag:Ie,c_cc:GA})}return 0;case 21519:return D.tty?(Z=aA(),n[Z>>2]=0,0):-59;case 21520:return D.tty?-28:-59;case 21531:return Z=aA(),p.ioctl(D,f,Z);case 21523:if(!D.tty)return-59;if(D.tty.ops.ioctl_tiocgwinsz){var oe=D.tty.ops.ioctl_tiocgwinsz(D.tty);Z=aA(),i[Z>>1]=oe[0],i[Z+2>>1]=oe[1]}return 0;default:return-28}}catch(M){if(p===void 0||M.name!=="ErrnoError")throw M;return-M.errno}},s:function(h,f,w,D){try{f=V.getStr(f);var O=256&D,Z=4096&D;return D&=-6401,f=V.calculateAt(h,f,Z),V.doStat(O?p.lstat:p.stat,f,w)}catch(q){if(p===void 0||q.name!=="ErrnoError")throw q;return-q.errno}},m:function(h,f,w,D){V.varargs=D;try{f=V.getStr(f),f=V.calculateAt(h,f);var O=D?cA():0;return p.open(f,w,O).fd}catch(Z){if(p===void 0||Z.name!=="ErrnoError")throw Z;return-Z.errno}},t:function(h,f){try{return h=V.getStr(h),V.doStat(p.stat,h,f)}catch(w){if(p===void 0||w.name!=="ErrnoError")throw w;return-w.errno}},i:()=>{B("")},n:function(h,f,w,D,O,Z,q){O=jA(O);try{if(isNaN(O))return 61;var CA=V.getStreamFromFD(D),kA=p.mmap(CA,h,O,f,w),KA=kA.ptr;return n[Z>>2]=kA.allocated,r[q>>2]=KA,0}catch(Ie){if(p===void 0||Ie.name!=="ErrnoError")throw Ie;return-Ie.errno}},o:function(h,f,w,D,O,Z){Z=jA(Z);try{var q=V.getStreamFromFD(O);2&w&&V.doMsync(h,q,f,D,Z)}catch(CA){if(p===void 0||CA.name!=="ErrnoError")throw CA;return-CA.errno}},k:(h,f,w,D)=>{var O=new Date().getFullYear(),Z=new Date(O,0,1),q=new Date(O,6,1),CA=Z.getTimezoneOffset(),kA=q.getTimezoneOffset(),KA=Math.max(CA,kA);r[h>>2]=60*KA,n[f>>2]=+(CA!=kA);var Ie=M=>{var G=M>=0?"-":"+",Y=Math.abs(M);return`UTC${G}${String(Math.floor(Y/60)).padStart(2,"0")}${String(Y%60).padStart(2,"0")}`},GA=Ie(CA),oe=Ie(kA);kA<CA?(VA(GA,w,17),VA(oe,D,17)):(VA(GA,D,17),VA(oe,w,17))},h:()=>Date.now(),l:h=>{var f=o.length,w=2147483648;if((h>>>=0)>w)return!1;for(var D=1;D<=4;D*=2){var O=f*(1+.2/D);O=Math.min(O,h+100663296);var Z=Math.min(w,j(Math.max(h,O),65536));if(ce(Z))return!0}return!1},q:(h,f)=>{var w=0;return sA().forEach((D,O)=>{var Z=f+w;r[h+4*O>>2]=Z,((q,CA)=>{for(var kA=0;kA<q.length;++kA)A[CA++]=q.charCodeAt(kA);A[CA]=0})(D,Z),w+=D.length+1}),0},r:(h,f)=>{var w=sA();r[h>>2]=w.length;var D=0;return w.forEach(O=>D+=O.length+1),r[f>>2]=D,0},g:TA,e:function(h){try{var f=V.getStreamFromFD(h);return p.close(f),0}catch(w){if(p===void 0||w.name!=="ErrnoError")throw w;return w.errno}},d:function(h,f,w,D){try{var O=((Z,q,CA,kA)=>{for(var KA=0,Ie=0;Ie<CA;Ie++){var GA=r[q>>2],oe=r[q+4>>2];q+=8;var M=p.read(Z,A,GA,oe,kA);if(M<0)return-1;if(KA+=M,M<oe)break;kA!==void 0&&(kA+=M)}return KA})(V.getStreamFromFD(h),f,w);return r[D>>2]=O,0}catch(Z){if(p===void 0||Z.name!=="ErrnoError")throw Z;return Z.errno}},p:function(h,f,w,D){f=jA(f);try{if(isNaN(f))return 61;var O=V.getStreamFromFD(h);return p.llseek(O,f,w),c[D>>3]=BigInt(O.position),O.getdents&&f===0&&w===0&&(O.getdents=null),0}catch(Z){if(p===void 0||Z.name!=="ErrnoError")throw Z;return Z.errno}},c:function(h,f,w,D){try{var O=((Z,q,CA,kA)=>{for(var KA=0,Ie=0;Ie<CA;Ie++){var GA=r[q>>2],oe=r[q+4>>2];q+=8;var M=p.write(Z,A,GA,oe,kA);if(M<0)return-1;if(KA+=M,M<oe)break;kA!==void 0&&(kA+=M)}return KA})(V.getStreamFromFD(h),f,w);return r[D>>2]=O,0}catch(Z){if(p===void 0||Z.name!=="ErrnoError")throw Z;return Z.errno}},w:function(h){return I.agerrMessages.push(v(h)),0}};I.ccall=(h,f,w,D,O)=>{var Z={string:oe=>{var M=0;return oe!=null&&oe!==0&&(M=(G=>{var Y=T(G)+1,AA=Ke(Y);return VA(G,AA,Y),AA})(oe)),M},array:oe=>{var M,G,Y=Ke(oe.length);return M=oe,G=Y,A.set(M,G),Y}},q=(oe=>I["_"+oe])(h),CA=[],kA=0;if(D)for(var KA=0;KA<D.length;KA++){var Ie=Z[w[KA]];Ie?(kA===0&&(kA=RA()),CA[KA]=Ie(D[KA])):CA[KA]=D[KA]}var GA=q(...CA);return GA=function(oe){return kA!==0&&hA(kA),function(M){return f==="string"?v(M):f==="boolean"?!!M:M}(oe)}(GA)},I.getValue=function(h){let f=arguments.length>1&&arguments[1]!==void 0?arguments[1]:"i8";switch(f.endsWith("*")&&(f="*"),f){case"i1":case"i8":return A[h];case"i16":return i[h>>1];case"i32":return n[h>>2];case"i64":return c[h>>3];case"float":return s[h>>2];case"double":return a[h>>3];case"*":return r[h>>2];default:B(`invalid type for getValue: ${f}`)}},I.PATH=x,I.UTF8ToString=v,I.stringToUTF8=VA,I.lengthBytesUTF8=T,I.FS=p;var ne={a:oA};return WebAssembly.instantiate(I.wasm,ne).then(h=>{var f=h.instance.exports;I._viz_set_y_invert=f.z,I._viz_set_reduce=f.A,I._viz_get_graphviz_version=f.B,I._viz_get_plugin_list=f.C,I._viz_create_graph=f.D,I._viz_read_one_graph=f.E,I._viz_string_dup=f.F,I._viz_string_dup_html=f.G,I._viz_string_free=f.H,I._viz_add_node=f.I,I._viz_add_edge=f.J,I._viz_add_subgraph=f.K,I._viz_set_default_graph_attribute=f.L,I._viz_set_default_node_attribute=f.M,I._viz_set_default_edge_attribute=f.N,I._viz_set_attribute=f.O,I._viz_free_graph=f.P,I._viz_create_context=f.Q,I._viz_free_context=f.R,I._viz_layout=f.S,I._viz_free_layout=f.T,I._viz_reset_errors=f.U,I._viz_render=f.V,I._free=f.X,I._malloc=f.Y,Re=f.Z,hA=f._,eA=f.$,RA=f.aa,l=f.x,E(),function(w){w.y(),I.noFSInit||p.initialized||p.init(),p.ignorePermissions=!1}(f),t(I)}),C},wP=[[/^Error: (.*)/,"error"],[/^Warning: (.*)/,"warning"]];function DP(t,e){let A=t.ccall("viz_get_plugin_list","number",["string"],[e]);if(A==0)throw new Error(`couldn't get plugin list: ${e}`);let i=[],n,o=A;for(;n=t.getValue(o,"*");)i.push(t.UTF8ToString(n)),t.ccall("free","number",["number"],[n]),o+=4;return t.ccall("free","number",["number"],[A]),i}function yP(t,e,A,i){let n,o,r,s;try{if(t.agerrMessages=[],t.stderrMessages=[],s=function(c,l){return l?l.map(I=>{if(typeof I.name!="string")throw new Error("image name must be a string");if(typeof I.width!="number"&&typeof I.width!="string")throw new Error("image width must be a number or string");if(typeof I.height!="number"&&typeof I.height!="string")throw new Error("image height must be a number or string");let C=c.PATH.join("/",I.name),d=`<?xml version="1.0" encoding="UTF-8"?>
<svg xmlns="http://www.w3.org/2000/svg" width="${I.width}" height="${I.height}"></svg>
`;return c.FS.createPath("/",c.PATH.dirname(C)),c.FS.writeFile(C,d),C}):[]}(t,i.images),typeof e=="string")n=function(c,l){let I;try{let C=c.lengthBytesUTF8(l);return I=c.ccall("malloc","number",["number"],[C+1]),c.stringToUTF8(l,I,C+1),c.ccall("viz_read_one_graph","number",["number"],[I])}finally{I&&c.ccall("free","number",["number"],[I])}}(t,e);else{if(typeof e!="object")throw new Error("input must be a string or object");n=function(c,l){let I=c.ccall("viz_create_graph","number",["string","number","number"],[l.name,l.directed===void 0||l.directed,l.strict!==void 0&&l.strict]);return bP(c,I,l),I}(t,e)}if(n===0)return{status:"failure",output:void 0,errors:yu(t)};if(MP(t,n,i),t.ccall("viz_set_y_invert","number",["number"],[i.yInvert?1:0]),t.ccall("viz_set_reduce","number",["number"],[i.reduce?1:0]),o=t.ccall("viz_create_context"),t.ccall("viz_reset_errors"),t.ccall("viz_layout","number",["number","number","string"],[o,n,i.engine])!==0)return{status:"failure",output:void 0,errors:yu(t)};let a={};for(let c of A){if(r=t.ccall("viz_render","number",["number","number","string"],[o,n,c]),r===0)return{status:"failure",output:void 0,errors:yu(t)};a[c]=t.UTF8ToString(r),t.ccall("free","number",["number"],[r]),r=0}return{status:"success",output:a,errors:yu(t)}}catch(a){if(/^exit\(\d+\)/.test(a))return{status:"failure",output:void 0,errors:yu(t)};throw a}finally{o&&n&&t.ccall("viz_free_layout","number",["number"],[o,n]),n&&t.ccall("viz_free_graph","number",["number"],[n]),o&&t.ccall("viz_free_context","number",["number"],[o]),r&&t.ccall("free","number",["number"],[r]),s&&function(a,c){for(let l of c)a.FS.analyzePath(l).exists&&a.FS.unlink(l)}(t,s)}}function yu(t){return function(e){let A=[],i;for(let n=0;n<e.length;n++)e[n]=="Error"&&e[n+1]==": "?(i="error",n+=1):e[n]=="Warning"&&e[n+1]==": "?(i="warning",n+=1):A.push({message:e[n].trimEnd(),level:i});return A}(t.agerrMessages).concat(t.stderrMessages.map(e=>{for(let A=0;A<wP.length;A++){let[i,n]=wP[A],o;if((o=i.exec(e))!==null)return{message:o[1].trimEnd(),level:n}}return{message:e.trimEnd()}}))}function bP(t,e,A){MP(t,e,A),A.nodes&&A.nodes.forEach(i=>{let n=t.ccall("viz_add_node","number",["number","string"],[e,String(i.name)]);i.attributes&&vP(t,e,n,i.attributes)}),A.edges&&A.edges.forEach(i=>{let n=t.ccall("viz_add_edge","number",["number","string","string"],[e,String(i.tail),String(i.head)]);i.attributes&&vP(t,e,n,i.attributes)}),A.subgraphs&&A.subgraphs.forEach(i=>{let n=t.ccall("viz_add_subgraph","number",["number","string"],[e,String(i.name)]);bP(t,n,i)})}function MP(t,e,A){if(A.graphAttributes)for(let[i,n]of Object.entries(A.graphAttributes))l8(t,e,n,o=>{t.ccall("viz_set_default_graph_attribute","number",["number","string","number"],[e,i,o])});if(A.nodeAttributes)for(let[i,n]of Object.entries(A.nodeAttributes))l8(t,e,n,o=>{t.ccall("viz_set_default_node_attribute","number",["number","string","number"],[e,i,o])});if(A.edgeAttributes)for(let[i,n]of Object.entries(A.edgeAttributes))l8(t,e,n,o=>{t.ccall("viz_set_default_edge_attribute","number",["number","string","number"],[e,i,o])})}function vP(t,e,A,i){for(let[n,o]of Object.entries(i))l8(t,e,o,r=>{t.ccall("viz_set_attribute","number",["number","string","number"],[A,n,r])})}function l8(t,e,A,i){let n;if(n=typeof A=="object"&&"html"in A?t.ccall("viz_string_dup_html","number",["number","string"],[e,String(A.html)]):t.ccall("viz_string_dup","number",["number","string"],[e,String(A)]),n==0)throw new Error("couldn't dup string");i(n),t.ccall("viz_string_free","number",["number","number"],[e,n])}var Rk=class{constructor(e){this.module=e}get graphvizVersion(){return function(e){let A=e.ccall("viz_get_graphviz_version","number",[],[]);return e.UTF8ToString(A)}(this.module)}get formats(){return DP(this.module,"device")}get engines(){return DP(this.module,"layout")}renderFormats(e,A){let i=arguments.length>2&&arguments[2]!==void 0?arguments[2]:{};return yP(this.module,e,A,nA({engine:"dot"},i))}render(e){let A,i=arguments.length>1&&arguments[1]!==void 0?arguments[1]:{};A=i.format===void 0?"dot":i.format;let n=yP(this.module,e,[A],nA({engine:"dot"},i));return n.status==="success"&&(n.output=n.output[A]),n}renderString(e){let A=arguments.length>1&&arguments[1]!==void 0?arguments[1]:{},i=this.render(e,A);if(i.status!=="success")throw new Error(i.errors.find(n=>n.level=="error")?.message||"render failed");return i.output}renderSVGElement(e){let A=arguments.length>1&&arguments[1]!==void 0?arguments[1]:{},i=this.renderString(e,Ne(nA({},A),{format:"svg"}));return new DOMParser().parseFromString(i,"image/svg+xml").documentElement}renderJSON(e){let A=arguments.length>1&&arguments[1]!==void 0?arguments[1]:{},i=this.renderString(e,Ne(nA({},A),{format:"json"}));return JSON.parse(i)}};function X4A(){let t=atob(" "),e=new Uint8Array(t.length);for(let A=0;A<t.length;A++)e[A]=t.charCodeAt(A);return e.buffer}function vu(){return W4A({wasm:X4A()}).then(t=>new Rk(t))}var ZG=xh(Hj());var Es=class{static getBaseUrlWithoutPath(){let e=window.location.href;return new URL(e).origin+"/dev-ui/"}static getApiServerBaseUrl(){return window.runtimeConfig?.backendUrl}static getWSServerUrl(){let e=this.getApiServerBaseUrl();return!e||e==""?window.location.host:e.startsWith("http://")?e.slice(7):e.startsWith("https://")?e.slice(8):e}};var K2=class t{constructor(e,A){this.http=e;this.zone=A}apiServerDomain=Es.getApiServerBaseUrl();_currentApp=new li("");currentApp=this._currentApp.asObservable();isLoading=new li(!1);getApp(){return this.currentApp}setApp(e){this._currentApp.next(e)}getLoadingState(){return this.isLoading}runSse(e){let A=this.apiServerDomain+"/run_sse";return this.isLoading.next(!0),new Ze(i=>{let n=this;fetch(A,{method:"POST",headers:{"Content-Type":"application/json",Accept:"text/event-stream"},body:JSON.stringify(e)}).then(o=>{let r=o.body?.getReader(),s=new TextDecoder("utf-8"),a="",c=()=>{r?.read().then(({done:l,value:I})=>{if(this.isLoading.next(!0),l)return this.isLoading.next(!1),i.complete();let C=s.decode(I,{stream:!0});a+=C;try{a.split(/\r?\n/).filter(B=>B.startsWith("data:")).forEach(B=>{let E=B.replace(/^data:\s*/,"");JSON.parse(E),n.zone.run(()=>i.next(E))}),a=""}catch(d){d instanceof SyntaxError&&c()}c()}).catch(l=>{n.zone.run(()=>i.error(l))})};c()}).catch(o=>{n.zone.run(()=>i.error(o))})})}listApps(){if(this.apiServerDomain!=null){let e=this.apiServerDomain+"/list-apps?relative_path=./";return this.http.get(e)}return new Ze}static \u0275fac=function(A){return new(A||t)(he(Bs),he(de))};static \u0275prov=SA({token:t,factory:t.\u0275fac,providedIn:"root"})};var nmA="import_session",omA="edit_function_args";var rmA="a2a_card",vB=class t{route=m(ra);constructor(){}isImportSessionEnabled(){return this.route.queryParams.pipe(Je(e=>e[nmA]==="true"))}isEditFunctionArgsEnabled(){return this.route.queryParams.pipe(Je(e=>e[omA]==="true"))}isSessionUrlEnabled(){return ve(!0)}isA2ACardEnabled(){return this.route.queryParams.pipe(Je(e=>e[rmA]==="true"))}static \u0275fac=function(A){return new(A||t)};static \u0275prov=SA({token:t,factory:t.\u0275fac,providedIn:"root"})};function smA(t,e){}var Y2=class{viewContainerRef;injector;id;role="dialog";panelClass="";hasBackdrop=!0;backdropClass="";disableClose=!1;width="";height="";minWidth;minHeight;maxWidth;maxHeight;positionStrategy;data=null;direction;ariaDescribedBy=null;ariaLabelledBy=null;ariaLabel=null;ariaModal=!1;autoFocus="first-tabbable";restoreFocus=!0;scrollStrategy;closeOnNavigation=!0;closeOnDestroy=!0;closeOnOverlayDetachments=!0;componentFactoryResolver;providers;container;templateContext};var Ok=(()=>{class t extends _2{_elementRef=m(te);_focusTrapFactory=m(P6);_config;_interactivityChecker=m(hu);_ngZone=m(de);_overlayRef=m(fB);_focusMonitor=m(Jr);_renderer=m(Gi);_platform=m(Zt);_document=m(tt,{optional:!0});_portalOutlet;_focusTrap=null;_elementFocusedBeforeDialogWasOpened=null;_closeInteractionType=null;_ariaLabelledByQueue=[];_changeDetectorRef=m(lt);_injector=m(Dt);_isDestroyed=!1;constructor(){super(),this._config=m(Y2,{optional:!0})||new Y2,this._config.ariaLabelledBy&&this._ariaLabelledByQueue.push(this._config.ariaLabelledBy)}_addAriaLabelledBy(A){this._ariaLabelledByQueue.push(A),this._changeDetectorRef.markForCheck()}_removeAriaLabelledBy(A){let i=this._ariaLabelledByQueue.indexOf(A);i>-1&&(this._ariaLabelledByQueue.splice(i,1),this._changeDetectorRef.markForCheck())}_contentAttached(){this._initializeFocusTrap(),this._handleBackdropClicks(),this._captureInitialFocus()}_captureInitialFocus(){this._trapFocus()}ngOnDestroy(){this._isDestroyed=!0,this._restoreFocus()}attachComponentPortal(A){this._portalOutlet.hasAttached();let i=this._portalOutlet.attachComponentPortal(A);return this._contentAttached(),i}attachTemplatePortal(A){this._portalOutlet.hasAttached();let i=this._portalOutlet.attachTemplatePortal(A);return this._contentAttached(),i}attachDomPortal=A=>{this._portalOutlet.hasAttached();let i=this._portalOutlet.attachDomPortal(A);return this._contentAttached(),i};_recaptureFocus(){this._containsFocus()||this._trapFocus()}_forceFocus(A,i){this._interactivityChecker.isFocusable(A)||(A.tabIndex=-1,this._ngZone.runOutsideAngular(()=>{let n=()=>{o(),r(),A.removeAttribute("tabindex")},o=this._renderer.listen(A,"blur",n),r=this._renderer.listen(A,"mousedown",n)})),A.focus(i)}_focusByCssSelector(A,i){let n=this._elementRef.nativeElement.querySelector(A);n&&this._forceFocus(n,i)}_trapFocus(){this._isDestroyed||Vo(()=>{let A=this._elementRef.nativeElement;switch(this._config.autoFocus){case!1:case"dialog":this._containsFocus()||A.focus();break;case!0:case"first-tabbable":this._focusTrap?.focusInitialElement()||this._focusDialogContainer();break;case"first-heading":this._focusByCssSelector('h1, h2, h3, h4, h5, h6, [role="heading"]');break;default:this._focusByCssSelector(this._config.autoFocus);break}},{injector:this._injector})}_restoreFocus(){let A=this._config.restoreFocus,i=null;if(typeof A=="string"?i=this._document.querySelector(A):typeof A=="boolean"?i=A?this._elementFocusedBeforeDialogWasOpened:null:A&&(i=A),this._config.restoreFocus&&i&&typeof i.focus=="function"){let n=cB(),o=this._elementRef.nativeElement;(!n||n===this._document.body||n===o||o.contains(n))&&(this._focusMonitor?(this._focusMonitor.focusVia(i,this._closeInteractionType),this._closeInteractionType=null):i.focus())}this._focusTrap&&this._focusTrap.destroy()}_focusDialogContainer(){this._elementRef.nativeElement.focus&&this._elementRef.nativeElement.focus()}_containsFocus(){let A=this._elementRef.nativeElement,i=cB();return A===i||A.contains(i)}_initializeFocusTrap(){this._platform.isBrowser&&(this._focusTrap=this._focusTrapFactory.create(this._elementRef.nativeElement),this._document&&(this._elementFocusedBeforeDialogWasOpened=cB()))}_handleBackdropClicks(){this._overlayRef.backdropClick().subscribe(()=>{this._config.disableClose&&this._recaptureFocus()})}static \u0275fac=function(i){return new(i||t)};static \u0275cmp=YA({type:t,selectors:[["cdk-dialog-container"]],viewQuery:function(i,n){if(i&1&&Ge(ca,7),i&2){let o;$A(o=Ae())&&(n._portalOutlet=o.first)}},hostAttrs:["tabindex","-1",1,"cdk-dialog-container"],hostVars:6,hostBindings:function(i,n){i&2&&_e("id",n._config.id||null)("role",n._config.role)("aria-modal",n._config.ariaModal)("aria-labelledby",n._config.ariaLabel?null:n._ariaLabelledByQueue[0])("aria-label",n._config.ariaLabel)("aria-describedby",n._config.ariaDescribedBy||null)},features:[et],decls:1,vars:0,consts:[["cdkPortalOutlet",""]],template:function(i,n){i&1&&NA(0,smA,0,0,"ng-template",0)},dependencies:[ca],styles:[".cdk-dialog-container{display:block;width:100%;height:100%;min-height:inherit;max-height:inherit}"],encapsulation:2})}return t})(),Mu=class{overlayRef;config;componentInstance;componentRef;containerInstance;disableClose;closed=new HA;backdropClick;keydownEvents;outsidePointerEvents;id;_detachSubscription;constructor(e,A){this.overlayRef=e,this.config=A,this.disableClose=A.disableClose,this.backdropClick=e.backdropClick(),this.keydownEvents=e.keydownEvents(),this.outsidePointerEvents=e.outsidePointerEvents(),this.id=A.id,this.keydownEvents.subscribe(i=>{i.keyCode===27&&!this.disableClose&&!rr(i)&&(i.preventDefault(),this.close(void 0,{focusOrigin:"keyboard"}))}),this.backdropClick.subscribe(()=>{this.disableClose||this.close(void 0,{focusOrigin:"mouse"})}),this._detachSubscription=e.detachments().subscribe(()=>{A.closeOnOverlayDetachments!==!1&&this.close()})}close(e,A){if(this.containerInstance){let i=this.closed;this.containerInstance._closeInteractionType=A?.focusOrigin||"program",this._detachSubscription.unsubscribe(),this.overlayRef.dispose(),i.next(e),i.complete(),this.componentInstance=this.containerInstance=null}}updatePosition(){return this.overlayRef.updatePosition(),this}updateSize(e="",A=""){return this.overlayRef.updateSize({width:e,height:A}),this}addPanelClass(e){return this.overlayRef.addPanelClass(e),this}removePanelClass(e){return this.overlayRef.removePanelClass(e),this}},amA=new BA("DialogScrollStrategy",{providedIn:"root",factory:()=>{let t=m(Sr);return()=>t.scrollStrategies.block()}}),cmA=new BA("DialogData"),lmA=new BA("DefaultDialogConfig");var Pk=(()=>{class t{_overlay=m(Sr);_injector=m(Dt);_defaultOptions=m(lmA,{optional:!0});_parentDialog=m(t,{optional:!0,skipSelf:!0});_overlayContainer=m(i8);_idGenerator=m($i);_openDialogsAtThisLevel=[];_afterAllClosedAtThisLevel=new HA;_afterOpenedAtThisLevel=new HA;_ariaHiddenElements=new Map;_scrollStrategy=m(amA);get openDialogs(){return this._parentDialog?this._parentDialog.openDialogs:this._openDialogsAtThisLevel}get afterOpened(){return this._parentDialog?this._parentDialog.afterOpened:this._afterOpenedAtThisLevel}afterAllClosed=Yl(()=>this.openDialogs.length?this._getAfterAllClosed():this._getAfterAllClosed().pipe(Qo(void 0)));constructor(){}open(A,i){let n=this._defaultOptions||new Y2;i=nA(nA({},n),i),i.id=i.id||this._idGenerator.getId("cdk-dialog-"),i.id&&this.getDialogById(i.id);let o=this._getOverlayConfig(i),r=this._overlay.create(o),s=new Mu(r,i),a=this._attachContainer(r,s,i);return s.containerInstance=a,this._attachDialogContent(A,s,a,i),this.openDialogs.length||this._hideNonDialogContentFromAssistiveTechnology(),this.openDialogs.push(s),s.closed.subscribe(()=>this._removeOpenDialog(s,!0)),this.afterOpened.next(s),s}closeAll(){Hk(this.openDialogs,A=>A.close())}getDialogById(A){return this.openDialogs.find(i=>i.id===A)}ngOnDestroy(){Hk(this._openDialogsAtThisLevel,A=>{A.config.closeOnDestroy===!1&&this._removeOpenDialog(A,!1)}),Hk(this._openDialogsAtThisLevel,A=>A.close()),this._afterAllClosedAtThisLevel.complete(),this._afterOpenedAtThisLevel.complete(),this._openDialogsAtThisLevel=[]}_getOverlayConfig(A){let i=new G2({positionStrategy:A.positionStrategy||this._overlay.position().global().centerHorizontally().centerVertically(),scrollStrategy:A.scrollStrategy||this._scrollStrategy(),panelClass:A.panelClass,hasBackdrop:A.hasBackdrop,direction:A.direction,minWidth:A.minWidth,minHeight:A.minHeight,maxWidth:A.maxWidth,maxHeight:A.maxHeight,width:A.width,height:A.height,disposeOnNavigation:A.closeOnNavigation});return A.backdropClass&&(i.backdropClass=A.backdropClass),i}_attachContainer(A,i,n){let o=n.injector||n.viewContainerRef?.injector,r=[{provide:Y2,useValue:n},{provide:Mu,useValue:i},{provide:fB,useValue:A}],s;n.container?typeof n.container=="function"?s=n.container:(s=n.container.type,r.push(...n.container.providers(n))):s=Ok;let a=new sl(s,n.viewContainerRef,Dt.create({parent:o||this._injector,providers:r}));return A.attach(a).instance}_attachDialogContent(A,i,n,o){if(A instanceof vn){let r=this._createInjector(o,i,n,void 0),s={$implicit:o.data,dialogRef:i};o.templateContext&&(s=nA(nA({},s),typeof o.templateContext=="function"?o.templateContext():o.templateContext)),n.attachTemplatePortal(new aa(A,null,s,r))}else{let r=this._createInjector(o,i,n,this._injector),s=n.attachComponentPortal(new sl(A,o.viewContainerRef,r));i.componentRef=s,i.componentInstance=s.instance}}_createInjector(A,i,n,o){let r=A.injector||A.viewContainerRef?.injector,s=[{provide:cmA,useValue:A.data},{provide:Mu,useValue:i}];return A.providers&&(typeof A.providers=="function"?s.push(...A.providers(i,A,n)):s.push(...A.providers)),A.direction&&(!r||!r.get(bo,null,{optional:!0}))&&s.push({provide:bo,useValue:{value:A.direction,change:ve()}}),Dt.create({parent:r||o,providers:s})}_removeOpenDialog(A,i){let n=this.openDialogs.indexOf(A);n>-1&&(this.openDialogs.splice(n,1),this.openDialogs.length||(this._ariaHiddenElements.forEach((o,r)=>{o?r.setAttribute("aria-hidden",o):r.removeAttribute("aria-hidden")}),this._ariaHiddenElements.clear(),i&&this._getAfterAllClosed().next()))}_hideNonDialogContentFromAssistiveTechnology(){let A=this._overlayContainer.getContainerElement();if(A.parentElement){let i=A.parentElement.children;for(let n=i.length-1;n>-1;n--){let o=i[n];o!==A&&o.nodeName!=="SCRIPT"&&o.nodeName!=="STYLE"&&!o.hasAttribute("aria-live")&&(this._ariaHiddenElements.set(o,o.getAttribute("aria-hidden")),o.setAttribute("aria-hidden","true"))}}}_getAfterAllClosed(){let A=this._parentDialog;return A?A._getAfterAllClosed():this._afterAllClosedAtThisLevel}static \u0275fac=function(i){return new(i||t)};static \u0275prov=SA({token:t,factory:t.\u0275fac,providedIn:"root"})}return t})();function Hk(t,e){let A=t.length;for(;A--;)e(t[A])}var Oj=(()=>{class t{static \u0275fac=function(i){return new(i||t)};static \u0275mod=ge({type:t});static \u0275inj=le({providers:[Pk],imports:[u0,sg,q6,sg]})}return t})();function gmA(t,e){}var C8=class{viewContainerRef;injector;id;role="dialog";panelClass="";hasBackdrop=!0;backdropClass="";disableClose=!1;width="";height="";minWidth;minHeight;maxWidth;maxHeight;position;data=null;direction;ariaDescribedBy=null;ariaLabelledBy=null;ariaLabel=null;ariaModal=!1;autoFocus="first-tabbable";restoreFocus=!0;delayFocusTrap=!0;scrollStrategy;closeOnNavigation=!0;componentFactoryResolver;enterAnimationDuration;exitAnimationDuration},jk="mdc-dialog--open",Pj="mdc-dialog--opening",jj="mdc-dialog--closing",ImA=150,CmA=75,dmA=(()=>{class t extends Ok{_animationMode=m(mi,{optional:!0});_animationStateChanged=new XA;_animationsEnabled=this._animationMode!=="NoopAnimations";_actionSectionCount=0;_hostElement=this._elementRef.nativeElement;_enterAnimationDuration=this._animationsEnabled?Vj(this._config.enterAnimationDuration)??ImA:0;_exitAnimationDuration=this._animationsEnabled?Vj(this._config.exitAnimationDuration)??CmA:0;_animationTimer=null;_contentAttached(){super._contentAttached(),this._startOpenAnimation()}_startOpenAnimation(){this._animationStateChanged.emit({state:"opening",totalTime:this._enterAnimationDuration}),this._animationsEnabled?(this._hostElement.style.setProperty(qj,`${this._enterAnimationDuration}ms`),this._requestAnimationFrame(()=>this._hostElement.classList.add(Pj,jk)),this._waitForAnimationToComplete(this._enterAnimationDuration,this._finishDialogOpen)):(this._hostElement.classList.add(jk),Promise.resolve().then(()=>this._finishDialogOpen()))}_startExitAnimation(){this._animationStateChanged.emit({state:"closing",totalTime:this._exitAnimationDuration}),this._hostElement.classList.remove(jk),this._animationsEnabled?(this._hostElement.style.setProperty(qj,`${this._exitAnimationDuration}ms`),this._requestAnimationFrame(()=>this._hostElement.classList.add(jj)),this._waitForAnimationToComplete(this._exitAnimationDuration,this._finishDialogClose)):Promise.resolve().then(()=>this._finishDialogClose())}_updateActionSectionCount(A){this._actionSectionCount+=A,this._changeDetectorRef.markForCheck()}_finishDialogOpen=()=>{this._clearAnimationClasses(),this._openAnimationDone(this._enterAnimationDuration)};_finishDialogClose=()=>{this._clearAnimationClasses(),this._animationStateChanged.emit({state:"closed",totalTime:this._exitAnimationDuration})};_clearAnimationClasses(){this._hostElement.classList.remove(Pj,jj)}_waitForAnimationToComplete(A,i){this._animationTimer!==null&&clearTimeout(this._animationTimer),this._animationTimer=setTimeout(i,A)}_requestAnimationFrame(A){this._ngZone.runOutsideAngular(()=>{typeof requestAnimationFrame=="function"?requestAnimationFrame(A):A()})}_captureInitialFocus(){this._config.delayFocusTrap||this._trapFocus()}_openAnimationDone(A){this._config.delayFocusTrap&&this._trapFocus(),this._animationStateChanged.next({state:"opened",totalTime:A})}ngOnDestroy(){super.ngOnDestroy(),this._animationTimer!==null&&clearTimeout(this._animationTimer)}attachComponentPortal(A){let i=super.attachComponentPortal(A);return i.location.nativeElement.classList.add("mat-mdc-dialog-component-host"),i}static \u0275fac=(()=>{let A;return function(n){return(A||(A=bi(t)))(n||t)}})();static \u0275cmp=YA({type:t,selectors:[["mat-dialog-container"]],hostAttrs:["tabindex","-1",1,"mat-mdc-dialog-container","mdc-dialog"],hostVars:10,hostBindings:function(i,n){i&2&&(Fs("id",n._config.id),_e("aria-modal",n._config.ariaModal)("role",n._config.role)("aria-labelledby",n._config.ariaLabel?null:n._ariaLabelledByQueue[0])("aria-label",n._config.ariaLabel)("aria-describedby",n._config.ariaDescribedBy||null),ue("_mat-animation-noopable",!n._animationsEnabled)("mat-mdc-dialog-container-with-actions",n._actionSectionCount>0))},features:[et],decls:3,vars:0,consts:[[1,"mat-mdc-dialog-inner-container","mdc-dialog__container"],[1,"mat-mdc-dialog-surface","mdc-dialog__surface"],["cdkPortalOutlet",""]],template:function(i,n){i&1&&(S(0,"div",0)(1,"div",1),NA(2,gmA,0,0,"ng-template",2),R()())},dependencies:[ca],styles:['.mat-mdc-dialog-container{width:100%;height:100%;display:block;box-sizing:border-box;max-height:inherit;min-height:inherit;min-width:inherit;max-width:inherit;outline:0}.cdk-overlay-pane.mat-mdc-dialog-panel{max-width:var(--mat-dialog-container-max-width, 560px);min-width:var(--mat-dialog-container-min-width, 280px)}@media(max-width: 599px){.cdk-overlay-pane.mat-mdc-dialog-panel{max-width:var(--mat-dialog-container-small-max-width, calc(100vw - 32px))}}.mat-mdc-dialog-inner-container{display:flex;flex-direction:row;align-items:center;justify-content:space-around;box-sizing:border-box;height:100%;opacity:0;transition:opacity linear var(--mat-dialog-transition-duration, 0ms);max-height:inherit;min-height:inherit;min-width:inherit;max-width:inherit}.mdc-dialog--closing .mat-mdc-dialog-inner-container{transition:opacity 75ms linear;transform:none}.mdc-dialog--open .mat-mdc-dialog-inner-container{opacity:1}._mat-animation-noopable .mat-mdc-dialog-inner-container{transition:none}.mat-mdc-dialog-surface{display:flex;flex-direction:column;flex-grow:0;flex-shrink:0;box-sizing:border-box;width:100%;height:100%;position:relative;overflow-y:auto;outline:0;transform:scale(0.8);transition:transform var(--mat-dialog-transition-duration, 0ms) cubic-bezier(0, 0, 0.2, 1);max-height:inherit;min-height:inherit;min-width:inherit;max-width:inherit;box-shadow:var(--mat-dialog-container-elevation-shadow, none);border-radius:var(--mdc-dialog-container-shape, var(--mat-sys-corner-extra-large, 4px));background-color:var(--mdc-dialog-container-color, var(--mat-sys-surface, white))}[dir=rtl] .mat-mdc-dialog-surface{text-align:right}.mdc-dialog--open .mat-mdc-dialog-surface,.mdc-dialog--closing .mat-mdc-dialog-surface{transform:none}._mat-animation-noopable .mat-mdc-dialog-surface{transition:none}.mat-mdc-dialog-surface::before{position:absolute;box-sizing:border-box;width:100%;height:100%;top:0;left:0;border:2px solid rgba(0,0,0,0);border-radius:inherit;content:"";pointer-events:none}.mat-mdc-dialog-title{display:block;position:relative;flex-shrink:0;box-sizing:border-box;margin:0 0 1px;padding:var(--mat-dialog-headline-padding, 6px 24px 13px)}.mat-mdc-dialog-title::before{display:inline-block;width:0;height:40px;content:"";vertical-align:0}[dir=rtl] .mat-mdc-dialog-title{text-align:right}.mat-mdc-dialog-container .mat-mdc-dialog-title{color:var(--mdc-dialog-subhead-color, var(--mat-sys-on-surface, rgba(0, 0, 0, 0.87)));font-family:var(--mdc-dialog-subhead-font, var(--mat-sys-headline-small-font, inherit));line-height:var(--mdc-dialog-subhead-line-height, var(--mat-sys-headline-small-line-height, 1.5rem));font-size:var(--mdc-dialog-subhead-size, var(--mat-sys-headline-small-size, 1rem));font-weight:var(--mdc-dialog-subhead-weight, var(--mat-sys-headline-small-weight, 400));letter-spacing:var(--mdc-dialog-subhead-tracking, var(--mat-sys-headline-small-tracking, 0.03125em))}.mat-mdc-dialog-content{display:block;flex-grow:1;box-sizing:border-box;margin:0;overflow:auto;max-height:65vh}.mat-mdc-dialog-content>:first-child{margin-top:0}.mat-mdc-dialog-content>:last-child{margin-bottom:0}.mat-mdc-dialog-container .mat-mdc-dialog-content{color:var(--mdc-dialog-supporting-text-color, var(--mat-sys-on-surface-variant, rgba(0, 0, 0, 0.6)));font-family:var(--mdc-dialog-supporting-text-font, var(--mat-sys-body-medium-font, inherit));line-height:var(--mdc-dialog-supporting-text-line-height, var(--mat-sys-body-medium-line-height, 1.5rem));font-size:var(--mdc-dialog-supporting-text-size, var(--mat-sys-body-medium-size, 1rem));font-weight:var(--mdc-dialog-supporting-text-weight, var(--mat-sys-body-medium-weight, 400));letter-spacing:var(--mdc-dialog-supporting-text-tracking, var(--mat-sys-body-medium-tracking, 0.03125em))}.mat-mdc-dialog-container .mat-mdc-dialog-content{padding:var(--mat-dialog-content-padding, 20px 24px)}.mat-mdc-dialog-container-with-actions .mat-mdc-dialog-content{padding:var(--mat-dialog-with-actions-content-padding, 20px 24px 0)}.mat-mdc-dialog-container .mat-mdc-dialog-title+.mat-mdc-dialog-content{padding-top:0}.mat-mdc-dialog-actions{display:flex;position:relative;flex-shrink:0;flex-wrap:wrap;align-items:center;justify-content:flex-end;box-sizing:border-box;min-height:52px;margin:0;padding:8px;border-top:1px solid rgba(0,0,0,0);padding:var(--mat-dialog-actions-padding, 16px 24px);justify-content:var(--mat-dialog-actions-alignment, flex-end)}@media(forced-colors: active){.mat-mdc-dialog-actions{border-top-color:CanvasText}}.mat-mdc-dialog-actions.mat-mdc-dialog-actions-align-start,.mat-mdc-dialog-actions[align=start]{justify-content:start}.mat-mdc-dialog-actions.mat-mdc-dialog-actions-align-center,.mat-mdc-dialog-actions[align=center]{justify-content:center}.mat-mdc-dialog-actions.mat-mdc-dialog-actions-align-end,.mat-mdc-dialog-actions[align=end]{justify-content:flex-end}.mat-mdc-dialog-actions .mat-button-base+.mat-button-base,.mat-mdc-dialog-actions .mat-mdc-button-base+.mat-mdc-button-base{margin-left:8px}[dir=rtl] .mat-mdc-dialog-actions .mat-button-base+.mat-button-base,[dir=rtl] .mat-mdc-dialog-actions .mat-mdc-button-base+.mat-mdc-button-base{margin-left:0;margin-right:8px}.mat-mdc-dialog-component-host{display:contents}'],encapsulation:2})}return t})(),qj="--mat-dialog-transition-duration";function Vj(t){return t==null?null:typeof t=="number"?t:t.endsWith("ms")?Ns(t.substring(0,t.length-2)):t.endsWith("s")?Ns(t.substring(0,t.length-1))*1e3:t==="0"?0:null}var I8=function(t){return t[t.OPEN=0]="OPEN",t[t.CLOSING=1]="CLOSING",t[t.CLOSED=2]="CLOSED",t}(I8||{}),cr=class{_ref;_containerInstance;componentInstance;componentRef;disableClose;id;_afterOpened=new HA;_beforeClosed=new HA;_result;_closeFallbackTimeout;_state=I8.OPEN;_closeInteractionType;constructor(e,A,i){this._ref=e,this._containerInstance=i,this.disableClose=A.disableClose,this.id=e.id,e.addPanelClass("mat-mdc-dialog-panel"),i._animationStateChanged.pipe(pt(n=>n.state==="opened"),Pn(1)).subscribe(()=>{this._afterOpened.next(),this._afterOpened.complete()}),i._animationStateChanged.pipe(pt(n=>n.state==="closed"),Pn(1)).subscribe(()=>{clearTimeout(this._closeFallbackTimeout),this._finishDialogClose()}),e.overlayRef.detachments().subscribe(()=>{this._beforeClosed.next(this._result),this._beforeClosed.complete(),this._finishDialogClose()}),ho(this.backdropClick(),this.keydownEvents().pipe(pt(n=>n.keyCode===27&&!this.disableClose&&!rr(n)))).subscribe(n=>{this.disableClose||(n.preventDefault(),Zj(this,n.type==="keydown"?"keyboard":"mouse"))})}close(e){this._result=e,this._containerInstance._animationStateChanged.pipe(pt(A=>A.state==="closing"),Pn(1)).subscribe(A=>{this._beforeClosed.next(e),this._beforeClosed.complete(),this._ref.overlayRef.detachBackdrop(),this._closeFallbackTimeout=setTimeout(()=>this._finishDialogClose(),A.totalTime+100)}),this._state=I8.CLOSING,this._containerInstance._startExitAnimation()}afterOpened(){return this._afterOpened}afterClosed(){return this._ref.closed}beforeClosed(){return this._beforeClosed}backdropClick(){return this._ref.backdropClick}keydownEvents(){return this._ref.keydownEvents}updatePosition(e){let A=this._ref.config.positionStrategy;return e&&(e.left||e.right)?e.left?A.left(e.left):A.right(e.right):A.centerHorizontally(),e&&(e.top||e.bottom)?e.top?A.top(e.top):A.bottom(e.bottom):A.centerVertically(),this._ref.updatePosition(),this}updateSize(e="",A=""){return this._ref.updateSize(e,A),this}addPanelClass(e){return this._ref.addPanelClass(e),this}removePanelClass(e){return this._ref.removePanelClass(e),this}getState(){return this._state}_finishDialogClose(){this._state=I8.CLOSED,this._ref.close(this._result,{focusOrigin:this._closeInteractionType}),this.componentInstance=null}};function Zj(t,e,A){return t._closeInteractionType=e,t.close(A)}var $r=new BA("MatMdcDialogData"),BmA=new BA("mat-mdc-dialog-default-options"),EmA=new BA("mat-mdc-dialog-scroll-strategy",{providedIn:"root",factory:()=>{let t=m(Sr);return()=>t.scrollStrategies.block()}});var Us=(()=>{class t{_overlay=m(Sr);_defaultOptions=m(BmA,{optional:!0});_scrollStrategy=m(EmA);_parentDialog=m(t,{optional:!0,skipSelf:!0});_idGenerator=m($i);_dialog=m(Pk);_openDialogsAtThisLevel=[];_afterAllClosedAtThisLevel=new HA;_afterOpenedAtThisLevel=new HA;dialogConfigClass=C8;_dialogRefConstructor;_dialogContainerType;_dialogDataToken;get openDialogs(){return this._parentDialog?this._parentDialog.openDialogs:this._openDialogsAtThisLevel}get afterOpened(){return this._parentDialog?this._parentDialog.afterOpened:this._afterOpenedAtThisLevel}_getAfterAllClosed(){let A=this._parentDialog;return A?A._getAfterAllClosed():this._afterAllClosedAtThisLevel}afterAllClosed=Yl(()=>this.openDialogs.length?this._getAfterAllClosed():this._getAfterAllClosed().pipe(Qo(void 0)));constructor(){this._dialogRefConstructor=cr,this._dialogContainerType=dmA,this._dialogDataToken=$r}open(A,i){let n;i=nA(nA({},this._defaultOptions||new C8),i),i.id=i.id||this._idGenerator.getId("mat-mdc-dialog-"),i.scrollStrategy=i.scrollStrategy||this._scrollStrategy();let o=this._dialog.open(A,Ne(nA({},i),{positionStrategy:this._overlay.position().global().centerHorizontally().centerVertically(),disableClose:!0,closeOnDestroy:!1,closeOnOverlayDetachments:!1,container:{type:this._dialogContainerType,providers:()=>[{provide:this.dialogConfigClass,useValue:i},{provide:Y2,useValue:i}]},templateContext:()=>({dialogRef:n}),providers:(r,s,a)=>(n=new this._dialogRefConstructor(r,i,a),n.updatePosition(i?.position),[{provide:this._dialogContainerType,useValue:a},{provide:this._dialogDataToken,useValue:s.data},{provide:this._dialogRefConstructor,useValue:n}])}));return n.componentRef=o.componentRef,n.componentInstance=o.componentInstance,this.openDialogs.push(n),this.afterOpened.next(n),n.afterClosed().subscribe(()=>{let r=this.openDialogs.indexOf(n);r>-1&&(this.openDialogs.splice(r,1),this.openDialogs.length||this._getAfterAllClosed().next())}),n}closeAll(){this._closeDialogs(this.openDialogs)}getDialogById(A){return this.openDialogs.find(i=>i.id===A)}ngOnDestroy(){this._closeDialogs(this._openDialogsAtThisLevel),this._afterAllClosedAtThisLevel.complete(),this._afterOpenedAtThisLevel.complete()}_closeDialogs(A){let i=A.length;for(;i--;)A[i].close()}static \u0275fac=function(i){return new(i||t)};static \u0275prov=SA({token:t,factory:t.\u0275fac,providedIn:"root"})}return t})(),gg=(()=>{class t{dialogRef=m(cr,{optional:!0});_elementRef=m(te);_dialog=m(Us);ariaLabel;type="button";dialogResult;_matDialogClose;constructor(){}ngOnInit(){this.dialogRef||(this.dialogRef=Xj(this._elementRef,this._dialog.openDialogs))}ngOnChanges(A){let i=A._matDialogClose||A._matDialogCloseResult;i&&(this.dialogResult=i.currentValue)}_onButtonClick(A){Zj(this.dialogRef,A.screenX===0&&A.screenY===0?"keyboard":"mouse",this.dialogResult)}static \u0275fac=function(i){return new(i||t)};static \u0275dir=OA({type:t,selectors:[["","mat-dialog-close",""],["","matDialogClose",""]],hostVars:2,hostBindings:function(i,n){i&1&&mA("click",function(r){return n._onButtonClick(r)}),i&2&&_e("aria-label",n.ariaLabel||null)("type",n.type)},inputs:{ariaLabel:[0,"aria-label","ariaLabel"],type:"type",dialogResult:[0,"mat-dialog-close","dialogResult"],_matDialogClose:[0,"matDialogClose","_matDialogClose"]},exportAs:["matDialogClose"],features:[Kt]})}return t})(),Wj=(()=>{class t{_dialogRef=m(cr,{optional:!0});_elementRef=m(te);_dialog=m(Us);constructor(){}ngOnInit(){this._dialogRef||(this._dialogRef=Xj(this._elementRef,this._dialog.openDialogs)),this._dialogRef&&Promise.resolve().then(()=>{this._onAdd()})}ngOnDestroy(){this._dialogRef?._containerInstance&&Promise.resolve().then(()=>{this._onRemove()})}static \u0275fac=function(i){return new(i||t)};static \u0275dir=OA({type:t})}return t})(),hs=(()=>{class t extends Wj{id=m($i).getId("mat-mdc-dialog-title-");_onAdd(){this._dialogRef._containerInstance?._addAriaLabelledBy?.(this.id)}_onRemove(){this._dialogRef?._containerInstance?._removeAriaLabelledBy?.(this.id)}static \u0275fac=(()=>{let A;return function(n){return(A||(A=bi(t)))(n||t)}})();static \u0275dir=OA({type:t,selectors:[["","mat-dialog-title",""],["","matDialogTitle",""]],hostAttrs:[1,"mat-mdc-dialog-title","mdc-dialog__title"],hostVars:1,hostBindings:function(i,n){i&2&&Fs("id",n.id)},inputs:{id:"id"},exportAs:["matDialogTitle"],features:[et]})}return t})(),ga=(()=>{class t{static \u0275fac=function(i){return new(i||t)};static \u0275dir=OA({type:t,selectors:[["","mat-dialog-content",""],["mat-dialog-content"],["","matDialogContent",""]],hostAttrs:[1,"mat-mdc-dialog-content","mdc-dialog__content"],features:[DT([h0])]})}return t})(),Ia=(()=>{class t extends Wj{align;_onAdd(){this._dialogRef._containerInstance?._updateActionSectionCount?.(1)}_onRemove(){this._dialogRef._containerInstance?._updateActionSectionCount?.(-1)}static \u0275fac=(()=>{let A;return function(n){return(A||(A=bi(t)))(n||t)}})();static \u0275dir=OA({type:t,selectors:[["","mat-dialog-actions",""],["mat-dialog-actions"],["","matDialogActions",""]],hostAttrs:[1,"mat-mdc-dialog-actions","mdc-dialog__actions"],hostVars:6,hostBindings:function(i,n){i&2&&ue("mat-mdc-dialog-actions-align-start",n.align==="start")("mat-mdc-dialog-actions-align-center",n.align==="center")("mat-mdc-dialog-actions-align-end",n.align==="end")},inputs:{align:"align"},features:[et]})}return t})();function Xj(t,e){let A=t.nativeElement.parentElement;for(;A&&!A.classList.contains("mat-mdc-dialog-container");)A=A.parentElement;return A?e.find(i=>i.id===A.id):null}var $j=(()=>{class t{static \u0275fac=function(i){return new(i||t)};static \u0275mod=ge({type:t});static \u0275inj=le({providers:[Us],imports:[Oj,u0,sg,Ve,Ve]})}return t})();function hmA(t,e){if(t&1&&UA(0,"img",5),t&2){let A=P(2);vA("src",A.displayContent,Ka)}}function QmA(t,e){t&1&&(S(0,"div",6),tA(1," No image data provided. "),R())}function umA(t,e){if(t&1&&(S(0,"div",3),NA(1,hmA,1,1,"img",5)(2,QmA,2,0,"div",6),R()),t&2){let A=P();_(),FA(A.displayContent?1:-1),_(),FA(A.displayContent?-1:2)}}function fmA(t,e){if(t&1&&UA(0,"div",4),t&2){let A=P();vA("innerHTML",A.displayContent,mI)}}var m0=class t{constructor(e,A,i){this.dialogRef=e;this.data=A;this.sanitizer=i}displayContent=null;isSvgContent=!1;ngOnInit(){this.processImageData()}processImageData(){let e=this.data.imageData;if(!e){this.displayContent=null,this.isSvgContent=!1;return}if(e.trim().includes("<svg"))this.isSvgContent=!0,this.displayContent=this.sanitizer.bypassSecurityTrustHtml(e);else{let A=e.startsWith("data:image/")?"":"data:image/png;base64,";this.isSvgContent=!1,this.displayContent=this.sanitizer.bypassSecurityTrustUrl(A+e)}}close(){this.dialogRef.close()}static \u0275fac=function(A){return new(A||t)(zA(cr),zA($r),zA(il))};static \u0275cmp=YA({type:t,selectors:[["app-view-image-dialog"]],standalone:!1,decls:6,vars:2,consts:[[1,"close-button",3,"click"],["xmlns","[http://www.w3.org/2000/svg](http://www.w3.org/2000/svg)","viewBox","0 0 24 24","fill","currentColor","width","24px","height","24px"],["d","M19 6.41L17.59 5 12 10.59 6.41 5 5 6.41 10.59 12 5 17.59 6.41 19 12 13.41 17.59 19 19 17.59 13.41 12z"],[1,"image-wrapper"],[3,"innerHTML"],["alt","Viewed Image",3,"src"],[1,"no-image-placeholder"]],template:function(A,i){A&1&&(S(0,"div")(1,"button",0),mA("click",function(){return i.close()}),hr(),S(2,"svg",1),UA(3,"path",2),R()(),NA(4,umA,3,2,"div",3)(5,fmA,1,1,"div",4),R()),A&2&&(_(4),FA(i.isSvgContent?-1:4),_(),FA(i.isSvgContent?5:-1))},styles:[".close-button[_ngcontent-%COMP%]{position:absolute;top:5px;right:10px;background:none;border:none;cursor:pointer;padding:8px;border-radius:50%;transition:background-color .2s ease;color:#666;display:flex;align-items:center;justify-content:center;z-index:10;margin-bottom:15px}.close-button[_ngcontent-%COMP%]:hover{background-color:#f0f0f0;color:#333}.close-button[_ngcontent-%COMP%]   svg[_ngcontent-%COMP%]{width:24px;height:24px;fill:currentColor}.image-wrapper[_ngcontent-%COMP%]{flex-grow:1;display:flex;justify-content:center;align-items:center;overflow:auto}.image-wrapper[_ngcontent-%COMP%]   img[_ngcontent-%COMP%], .image-wrapper[_ngcontent-%COMP%]   .svg-container[_ngcontent-%COMP%]{max-width:90vw;max-height:90vh;object-fit:contain;border-radius:8px}.no-image-placeholder[_ngcontent-%COMP%]{color:#888;font-style:italic;text-align:center;padding:20px}@media (max-width: 1768px){.close-button[_ngcontent-%COMP%]{top:5px;right:5px;padding:5px}}"]})};var J2=class t{downloadBase64Data(e,A,i="image.png"){try{let n=document.createElement("a");n.href=e,n.download=i,document.body.appendChild(n),n.click(),document.body.removeChild(n)}catch(n){throw console.error("Error downloading base64 data:",n),n}}downloadObjectAsJson(e,A="session.json"){let i=JSON.stringify(e,null,2),n=new Blob([i],{type:"application/json"}),o=URL.createObjectURL(n),r=document.createElement("a");r.href=o,r.download=A,document.body.appendChild(r),r.click(),document.body.removeChild(r),URL.revokeObjectURL(o)}static \u0275fac=function(A){return new(A||t)};static \u0275prov=SA({token:t,factory:t.\u0275fac,providedIn:"root"})};var mmA=["*"],d8;function pmA(){if(d8===void 0&&(d8=null,typeof window<"u")){let t=window;t.trustedTypes!==void 0&&(d8=t.trustedTypes.createPolicy("angular#components",{createHTML:e=>e}))}return d8}function ku(t){return pmA()?.createHTML(t)||t}function eq(t){return Error(`Unable to find icon with the name "${t}"`)}function wmA(){return Error("Could not find HttpClient for use with Angular Material icons. Please add provideHttpClient() to your providers.")}function tq(t){return Error(`The URL provided to MatIconRegistry was not trusted as a resource URL via Angular's DomSanitizer. Attempted URL was "${t}".`)}function iq(t){return Error(`The literal provided to MatIconRegistry was not trusted as safe HTML by Angular's DomSanitizer. Attempted literal was "${t}".`)}var p0=class{url;svgText;options;svgElement;constructor(e,A,i){this.url=e,this.svgText=A,this.options=i}},DmA=(()=>{class t{_httpClient;_sanitizer;_errorHandler;_document;_svgIconConfigs=new Map;_iconSetConfigs=new Map;_cachedIconsByUrl=new Map;_inProgressUrlFetches=new Map;_fontCssClassesByAlias=new Map;_resolvers=[];_defaultFontSetClass=["material-icons","mat-ligature-font"];constructor(A,i,n,o){this._httpClient=A,this._sanitizer=i,this._errorHandler=o,this._document=n}addSvgIcon(A,i,n){return this.addSvgIconInNamespace("",A,i,n)}addSvgIconLiteral(A,i,n){return this.addSvgIconLiteralInNamespace("",A,i,n)}addSvgIconInNamespace(A,i,n,o){return this._addSvgIconConfig(A,i,new p0(n,null,o))}addSvgIconResolver(A){return this._resolvers.push(A),this}addSvgIconLiteralInNamespace(A,i,n,o){let r=this._sanitizer.sanitize(Kr.HTML,n);if(!r)throw iq(n);let s=ku(r);return this._addSvgIconConfig(A,i,new p0("",s,o))}addSvgIconSet(A,i){return this.addSvgIconSetInNamespace("",A,i)}addSvgIconSetLiteral(A,i){return this.addSvgIconSetLiteralInNamespace("",A,i)}addSvgIconSetInNamespace(A,i,n){return this._addSvgIconSetConfig(A,new p0(i,null,n))}addSvgIconSetLiteralInNamespace(A,i,n){let o=this._sanitizer.sanitize(Kr.HTML,i);if(!o)throw iq(i);let r=ku(o);return this._addSvgIconSetConfig(A,new p0("",r,n))}registerFontClassAlias(A,i=A){return this._fontCssClassesByAlias.set(A,i),this}classNameForFontAlias(A){return this._fontCssClassesByAlias.get(A)||A}setDefaultFontSetClass(...A){return this._defaultFontSetClass=A,this}getDefaultFontSetClass(){return this._defaultFontSetClass}getSvgIconFromUrl(A){let i=this._sanitizer.sanitize(Kr.RESOURCE_URL,A);if(!i)throw tq(A);let n=this._cachedIconsByUrl.get(i);return n?ve(B8(n)):this._loadSvgIconFromConfig(new p0(A,null)).pipe(oo(o=>this._cachedIconsByUrl.set(i,o)),Je(o=>B8(o)))}getNamedSvgIcon(A,i=""){let n=nq(i,A),o=this._svgIconConfigs.get(n);if(o)return this._getSvgFromConfig(o);if(o=this._getIconConfigFromResolvers(i,A),o)return this._svgIconConfigs.set(n,o),this._getSvgFromConfig(o);let r=this._iconSetConfigs.get(i);return r?this._getSvgFromIconSetConfigs(A,r):s2(eq(n))}ngOnDestroy(){this._resolvers=[],this._svgIconConfigs.clear(),this._iconSetConfigs.clear(),this._cachedIconsByUrl.clear()}_getSvgFromConfig(A){return A.svgText?ve(B8(this._svgElementFromConfig(A))):this._loadSvgIconFromConfig(A).pipe(Je(i=>B8(i)))}_getSvgFromIconSetConfigs(A,i){let n=this._extractIconWithNameFromAnySet(A,i);if(n)return ve(n);let o=i.filter(r=>!r.svgText).map(r=>this._loadSvgIconSetFromConfig(r).pipe(dr(s=>{let c=`Loading icon set URL: ${this._sanitizer.sanitize(Kr.RESOURCE_URL,r.url)} failed: ${s.message}`;return this._errorHandler.handleError(new Error(c)),ve(null)})));return Hh(o).pipe(Je(()=>{let r=this._extractIconWithNameFromAnySet(A,i);if(!r)throw eq(A);return r}))}_extractIconWithNameFromAnySet(A,i){for(let n=i.length-1;n>=0;n--){let o=i[n];if(o.svgText&&o.svgText.toString().indexOf(A)>-1){let r=this._svgElementFromConfig(o),s=this._extractSvgIconFromSet(r,A,o.options);if(s)return s}}return null}_loadSvgIconFromConfig(A){return this._fetchIcon(A).pipe(oo(i=>A.svgText=i),Je(()=>this._svgElementFromConfig(A)))}_loadSvgIconSetFromConfig(A){return A.svgText?ve(null):this._fetchIcon(A).pipe(oo(i=>A.svgText=i))}_extractSvgIconFromSet(A,i,n){let o=A.querySelector(`[id="${i}"]`);if(!o)return null;let r=o.cloneNode(!0);if(r.removeAttribute("id"),r.nodeName.toLowerCase()==="svg")return this._setSvgAttributes(r,n);if(r.nodeName.toLowerCase()==="symbol")return this._setSvgAttributes(this._toSvgElement(r),n);let s=this._svgElementFromString(ku("<svg></svg>"));return s.appendChild(r),this._setSvgAttributes(s,n)}_svgElementFromString(A){let i=this._document.createElement("DIV");i.innerHTML=A;let n=i.querySelector("svg");if(!n)throw Error("<svg> tag not found");return n}_toSvgElement(A){let i=this._svgElementFromString(ku("<svg></svg>")),n=A.attributes;for(let o=0;o<n.length;o++){let{name:r,value:s}=n[o];r!=="id"&&i.setAttribute(r,s)}for(let o=0;o<A.childNodes.length;o++)A.childNodes[o].nodeType===this._document.ELEMENT_NODE&&i.appendChild(A.childNodes[o].cloneNode(!0));return i}_setSvgAttributes(A,i){return A.setAttribute("fit",""),A.setAttribute("height","100%"),A.setAttribute("width","100%"),A.setAttribute("preserveAspectRatio","xMidYMid meet"),A.setAttribute("focusable","false"),i&&i.viewBox&&A.setAttribute("viewBox",i.viewBox),A}_fetchIcon(A){let{url:i,options:n}=A,o=n?.withCredentials??!1;if(!this._httpClient)throw wmA();if(i==null)throw Error(`Cannot fetch icon from URL "${i}".`);let r=this._sanitizer.sanitize(Kr.RESOURCE_URL,i);if(!r)throw tq(i);let s=this._inProgressUrlFetches.get(r);if(s)return s;let a=this._httpClient.get(r,{responseType:"text",withCredentials:o}).pipe(Je(c=>ku(c)),Tl(()=>this._inProgressUrlFetches.delete(r)),Ph());return this._inProgressUrlFetches.set(r,a),a}_addSvgIconConfig(A,i,n){return this._svgIconConfigs.set(nq(A,i),n),this}_addSvgIconSetConfig(A,i){let n=this._iconSetConfigs.get(A);return n?n.push(i):this._iconSetConfigs.set(A,[i]),this}_svgElementFromConfig(A){if(!A.svgElement){let i=this._svgElementFromString(A.svgText);this._setSvgAttributes(i,A.options),A.svgElement=i}return A.svgElement}_getIconConfigFromResolvers(A,i){for(let n=0;n<this._resolvers.length;n++){let o=this._resolvers[n](i,A);if(o)return ymA(o)?new p0(o.url,null,o.options):new p0(o,null)}}static \u0275fac=function(i){return new(i||t)(he(Bs,8),he(il),he(tt,8),he(Xs))};static \u0275prov=SA({token:t,factory:t.\u0275fac,providedIn:"root"})}return t})();function B8(t){return t.cloneNode(!0)}function nq(t,e){return t+":"+e}function ymA(t){return!!(t.url&&t.options)}var vmA=new BA("MAT_ICON_DEFAULT_OPTIONS"),bmA=new BA("mat-icon-location",{providedIn:"root",factory:MmA});function MmA(){let t=m(tt),e=t?t.location:null;return{getPathname:()=>e?e.pathname+e.search:""}}var oq=["clip-path","color-profile","src","cursor","fill","filter","marker","marker-start","marker-mid","marker-end","mask","stroke"],kmA=oq.map(t=>`[${t}]`).join(", "),SmA=/^url\(['"]?#(.*?)['"]?\)$/,T2=(()=>{class t{_elementRef=m(te);_iconRegistry=m(DmA);_location=m(bmA);_errorHandler=m(Xs);_defaultColor;get color(){return this._color||this._defaultColor}set color(A){this._color=A}_color;inline=!1;get svgIcon(){return this._svgIcon}set svgIcon(A){A!==this._svgIcon&&(A?this._updateSvgIcon(A):this._svgIcon&&this._clearSvgElement(),this._svgIcon=A)}_svgIcon;get fontSet(){return this._fontSet}set fontSet(A){let i=this._cleanupFontValue(A);i!==this._fontSet&&(this._fontSet=i,this._updateFontIconClasses())}_fontSet;get fontIcon(){return this._fontIcon}set fontIcon(A){let i=this._cleanupFontValue(A);i!==this._fontIcon&&(this._fontIcon=i,this._updateFontIconClasses())}_fontIcon;_previousFontSetClass=[];_previousFontIconClass;_svgName;_svgNamespace;_previousPath;_elementsWithExternalReferences;_currentIconFetch=_t.EMPTY;constructor(){let A=m(new Er("aria-hidden"),{optional:!0}),i=m(vmA,{optional:!0});i&&(i.color&&(this.color=this._defaultColor=i.color),i.fontSet&&(this.fontSet=i.fontSet)),A||this._elementRef.nativeElement.setAttribute("aria-hidden","true")}_splitIconName(A){if(!A)return["",""];let i=A.split(":");switch(i.length){case 1:return["",i[0]];case 2:return i;default:throw Error(`Invalid icon name: "${A}"`)}}ngOnInit(){this._updateFontIconClasses()}ngAfterViewChecked(){let A=this._elementsWithExternalReferences;if(A&&A.size){let i=this._location.getPathname();i!==this._previousPath&&(this._previousPath=i,this._prependPathToReferences(i))}}ngOnDestroy(){this._currentIconFetch.unsubscribe(),this._elementsWithExternalReferences&&this._elementsWithExternalReferences.clear()}_usingFontIcon(){return!this.svgIcon}_setSvgElement(A){this._clearSvgElement();let i=this._location.getPathname();this._previousPath=i,this._cacheChildrenWithExternalReferences(A),this._prependPathToReferences(i),this._elementRef.nativeElement.appendChild(A)}_clearSvgElement(){let A=this._elementRef.nativeElement,i=A.childNodes.length;for(this._elementsWithExternalReferences&&this._elementsWithExternalReferences.clear();i--;){let n=A.childNodes[i];(n.nodeType!==1||n.nodeName.toLowerCase()==="svg")&&n.remove()}}_updateFontIconClasses(){if(!this._usingFontIcon())return;let A=this._elementRef.nativeElement,i=(this.fontSet?this._iconRegistry.classNameForFontAlias(this.fontSet).split(/ +/):this._iconRegistry.getDefaultFontSetClass()).filter(n=>n.length>0);this._previousFontSetClass.forEach(n=>A.classList.remove(n)),i.forEach(n=>A.classList.add(n)),this._previousFontSetClass=i,this.fontIcon!==this._previousFontIconClass&&!i.includes("mat-ligature-font")&&(this._previousFontIconClass&&A.classList.remove(this._previousFontIconClass),this.fontIcon&&A.classList.add(this.fontIcon),this._previousFontIconClass=this.fontIcon)}_cleanupFontValue(A){return typeof A=="string"?A.trim().split(" ")[0]:A}_prependPathToReferences(A){let i=this._elementsWithExternalReferences;i&&i.forEach((n,o)=>{n.forEach(r=>{o.setAttribute(r.name,`url('${A}#${r.value}')`)})})}_cacheChildrenWithExternalReferences(A){let i=A.querySelectorAll(kmA),n=this._elementsWithExternalReferences=this._elementsWithExternalReferences||new Map;for(let o=0;o<i.length;o++)oq.forEach(r=>{let s=i[o],a=s.getAttribute(r),c=a?a.match(SmA):null;if(c){let l=n.get(s);l||(l=[],n.set(s,l)),l.push({name:r,value:c[1]})}})}_updateSvgIcon(A){if(this._svgNamespace=null,this._svgName=null,this._currentIconFetch.unsubscribe(),A){let[i,n]=this._splitIconName(A);i&&(this._svgNamespace=i),n&&(this._svgName=n),this._currentIconFetch=this._iconRegistry.getNamedSvgIcon(n,i).pipe(Pn(1)).subscribe(o=>this._setSvgElement(o),o=>{let r=`Error retrieving icon ${i}:${n}! ${o.message}`;this._errorHandler.handleError(new Error(r))})}}static \u0275fac=function(i){return new(i||t)};static \u0275cmp=YA({type:t,selectors:[["mat-icon"]],hostAttrs:["role","img",1,"mat-icon","notranslate"],hostVars:10,hostBindings:function(i,n){i&2&&(_e("data-mat-icon-type",n._usingFontIcon()?"font":"svg")("data-mat-icon-name",n._svgName||n.fontIcon)("data-mat-icon-namespace",n._svgNamespace||n.fontSet)("fontIcon",n._usingFontIcon()?n.fontIcon:null),vo(n.color?"mat-"+n.color:""),ue("mat-icon-inline",n.inline)("mat-icon-no-color",n.color!=="primary"&&n.color!=="accent"&&n.color!=="warn"))},inputs:{color:"color",inline:[2,"inline","inline",ae],svgIcon:"svgIcon",fontSet:"fontSet",fontIcon:"fontIcon"},exportAs:["matIcon"],ngContentSelectors:mmA,decls:1,vars:0,template:function(i,n){i&1&&(Yt(),xe(0))},styles:["mat-icon,mat-icon.mat-primary,mat-icon.mat-accent,mat-icon.mat-warn{color:var(--mat-icon-color, inherit)}.mat-icon{-webkit-user-select:none;user-select:none;background-repeat:no-repeat;display:inline-block;fill:currentColor;height:24px;width:24px;overflow:hidden}.mat-icon.mat-icon-inline{font-size:inherit;height:inherit;line-height:inherit;width:inherit}.mat-icon.mat-ligature-font[fontIcon]::before{content:attr(fontIcon)}[dir=rtl] .mat-icon-rtl-mirror{transform:scale(-1, 1)}.mat-form-field:not(.mat-form-field-appearance-legacy) .mat-form-field-prefix .mat-icon,.mat-form-field:not(.mat-form-field-appearance-legacy) .mat-form-field-suffix .mat-icon{display:block}.mat-form-field:not(.mat-form-field-appearance-legacy) .mat-form-field-prefix .mat-icon-button .mat-icon,.mat-form-field:not(.mat-form-field-appearance-legacy) .mat-form-field-suffix .mat-icon-button .mat-icon{margin:auto}"],encapsulation:2,changeDetection:0})}return t})(),rq=(()=>{class t{static \u0275fac=function(i){return new(i||t)};static \u0275mod=ge({type:t});static \u0275inj=le({imports:[Ve,Ve]})}return t})();var RmA=["audioPlayer"],zI=class t{base64data="";audioPlayerRef;audioSrc="";constructor(){}ngOnChanges(e){e.base64data&&this.base64data&&this.setAudioSource(this.base64data)}setAudioSource(e){e.startsWith("data:")?this.audioSrc=e:this.audioSrc=`data:audio/mpeg;base64,${e}`,this.audioPlayerRef&&this.audioPlayerRef.nativeElement&&this.audioPlayerRef.nativeElement.load()}play(){this.audioPlayerRef&&this.audioPlayerRef.nativeElement&&this.audioPlayerRef.nativeElement.play()}pause(){this.audioPlayerRef&&this.audioPlayerRef.nativeElement&&this.audioPlayerRef.nativeElement.pause()}stop(){this.audioPlayerRef&&this.audioPlayerRef.nativeElement&&(this.audioPlayerRef.nativeElement.pause(),this.audioPlayerRef.nativeElement.currentTime=0)}static \u0275fac=function(A){return new(A||t)};static \u0275cmp=YA({type:t,selectors:[["app-audio-player"]],viewQuery:function(A,i){if(A&1&&Ge(RmA,5),A&2){let n;$A(n=Ae())&&(i.audioPlayerRef=n.first)}},inputs:{base64data:"base64data"},standalone:!1,features:[Kt],decls:3,vars:1,consts:[["audioPlayer",""],["controls","",3,"src"]],template:function(A,i){A&1&&(S(0,"div"),UA(1,"audio",1,0),R()),A&2&&(_(),vA("src",i.audioSrc,Ka))},styles:[".audio-player-container[_ngcontent-%COMP%]{display:flex;justify-content:center;align-items:center;padding:15px;background-color:#f0f0f0;border-radius:8px;box-shadow:0 2px 5px #0000001a;margin:20px auto;max-width:350px}audio[_ngcontent-%COMP%]{outline:none;border-radius:5px;width:350px}.custom-controls[_ngcontent-%COMP%]{margin-top:10px;display:flex;gap:10px}.custom-controls[_ngcontent-%COMP%]   button[_ngcontent-%COMP%]{padding:8px 15px;border:none;border-radius:5px;background-color:#007bff;color:#fff;cursor:pointer;font-size:14px;transition:background-color .2s ease}.custom-controls[_ngcontent-%COMP%]   button[_ngcontent-%COMP%]:hover{background-color:#0056b3}"]})};function LmA(t,e){t&1&&UA(0,"hr",2)}function xmA(t,e){if(t&1&&(S(0,"mat-option",7),tA(1),R()),t&2){let A=e.$implicit;vA("value",A),_(),Mt(A.versionId)}}function FmA(t,e){if(t&1){let A=De();S(0,"div")(1,"img",9),mA("click",function(){LA(A);let n=P().$index,o=P();return xA(o.openViewImageDialog(o.selectedArtifacts[n].data))}),R()()}if(t&2){let A,i=P().$index,n=P();_(),vA("src",(A=n.selectedArtifacts[i].data)!==null&&A!==void 0?A:"",Ka)}}function NmA(t,e){if(t&1&&(S(0,"div"),UA(1,"app-audio-player",10),R()),t&2){let A=P().$index,i=P();_(),vA("base64data",i.selectedArtifacts[A].data)}}function _mA(t,e){if(t&1){let A=De();S(0,"div",1),NA(1,LmA,1,0,"hr",2),S(2,"div",3)(3,"button",4),mA("click",function(){let n=LA(A).$index,o=P();return xA(o.openArtifact(o.selectedArtifacts[n].data,o.selectedArtifacts[n].mimeType))}),tA(4),R()(),S(5,"div",3)(6,"span"),tA(7," Version: "),R(),S(8,"div",5)(9,"mat-select",6),ta("ngModelChange",function(n){let o=LA(A).$index,r=P();return Ja(r.selectedArtifacts[o],n)||(r.selectedArtifacts[o]=n),xA(n)}),mA("selectionChange",function(n){let o=LA(A).$index,r=P();return xA(r.onArtifactVersionChange(n,o))}),ln(10,xmA,2,2,"mat-option",7,Kn),R()(),S(12,"button",8),mA("click",function(){let n=LA(A).$index,o=P();return xA(o.downloadArtifact(o.selectedArtifacts[n]))}),S(13,"mat-icon"),tA(14,"file_download"),R(),tA(15," Download "),R()(),S(16,"div"),NA(17,FmA,2,1,"div")(18,NmA,2,1,"div"),R()()}if(t&2){let A,i=e.$implicit,n=e.$index,o=P();_(),FA(n>0?1:-1),_(3),ot(" ",o.getArtifactName(i)," "),_(5),ea("ngModel",o.selectedArtifacts[n]),_(),gn(o.getSortedArtifactsFromId(i)),_(7),FA((A=o.selectedArtifacts[n].mediaType)===o.MediaType.IMAGE?17:A===o.MediaType.AUDIO?18:-1)}}var GmA="default_artifact_name",Ru=(n=>(n.IMAGE="image",n.AUDIO="audio",n.TEXT="text",n.UNSPECIFIED="unspecified",n))(Ru||{});function h8(t){let e=t.toLowerCase();for(let A of Object.values(Ru))if(A!=="unspecified"&&e.startsWith(A+"/"))return A;return"unspecified"}function UmA(t){return t?t.startsWith("image/"):!1}function KmA(t){return t?t.startsWith("audio/"):!1}function qk(t,e){try{if(!t)return;let A=t;if(t.startsWith("data:")&&t.includes(";base64,")&&(A=A.substring(A.indexOf(";base64,")+8)),!e||!A)return;let i=atob(A),n=new Array(i.length);for(let c=0;c<i.length;c++)n[c]=i.charCodeAt(c);let o=new Uint8Array(n),r=new Blob([o],{type:e}),s=URL.createObjectURL(r),a=window.open(s,"_blank");a?a.focus():alert("Pop-up blocked! Please allow pop-ups for this site to open the data in a new tab.")}catch{alert("Could not open the data. It might be invalid or too large. Check the browser console for errors.")}}var Su=class t{constructor(e,A){this.downloadService=e;this.dialog=A}artifacts=[];selectedArtifacts=[];isArtifactAudio=KmA;isArtifactImage=UmA;MediaType=Ru;openBase64InNewTab=qk;ngOnChanges(e){if(e.artifacts){this.selectedArtifacts=[];for(let A of this.getDistinctArtifactIds())this.selectedArtifacts.push(this.getSortedArtifactsFromId(A)[0])}}downloadArtifact(e){this.downloadService.downloadBase64Data(e.data,e.mimeType,e.id)}getArtifactName(e){return e??GmA}getDistinctArtifactIds(){return[...new Set(this.artifacts.map(e=>e.id))]}getSortedArtifactsFromId(e){return this.artifacts.filter(A=>A.id===e).sort((A,i)=>i.versionId-A.versionId)}onArtifactVersionChange(e,A){this.selectedArtifacts[A]=e.value}openViewImageDialog(e){if(!e||!e.startsWith("data:")||e.indexOf(";base64,")===-1)return;let A=this.dialog.open(m0,{maxWidth:"90vw",maxHeight:"90vh",data:{imageData:e}})}openArtifact(e,A){if(this.isArtifactImage(A)){this.openViewImageDialog(e);return}this.openBase64InNewTab(e,A)}static \u0275fac=function(A){return new(A||t)(zA(J2),zA(Us))};static \u0275cmp=YA({type:t,selectors:[["app-artifact-tab"]],inputs:{artifacts:"artifacts"},standalone:!1,features:[Kt],decls:3,vars:0,consts:[[1,"artifact-container"],[1,"artifact-box"],[1,"white-separator"],[1,"artifact-metadata"],[1,"link-style-button",3,"click"],[1,"version-select-container"],[3,"ngModelChange","selectionChange","ngModel"],[3,"value"],["mat-flat-button","",1,"download-button",3,"click"],["alt","artifact.id",1,"generated-image",3,"click","src"],[3,"base64data"]],template:function(A,i){A&1&&(S(0,"div",0),ln(1,_mA,19,4,"div",1,Kn),R()),A&2&&(_(),gn(i.getDistinctArtifactIds()))},dependencies:[na,ja,T2,ur,pB,x2,zI],styles:[".artifact-container[_ngcontent-%COMP%]{display:flex;flex-wrap:wrap}.artifact-box[_ngcontent-%COMP%]{padding:10px;max-width:100%;margin-left:26px;display:flex;flex-direction:column}.artifact-metadata[_ngcontent-%COMP%]{display:flex;align-items:center;margin-bottom:15px;flex-wrap:wrap;gap:5px}.download-button[_ngcontent-%COMP%]{background-color:#8ab4f8!important;margin-left:35px;width:130px;height:28px;font-size:14px}.generated-image[_ngcontent-%COMP%]{max-width:60%;border-radius:8px;cursor:pointer}hr.white-separator[_ngcontent-%COMP%]{border:none;border-top:1px solid white;margin-bottom:1.2em;margin-right:15px}.version-select-container[_ngcontent-%COMP%]{background-color:#212123;width:80px;margin-left:15px}.link-style-button[_ngcontent-%COMP%]{background:none;border:none;padding:0;font:inherit;color:#007bff!important;text-decoration:underline;cursor:pointer;outline:none}.link-style-button[_ngcontent-%COMP%]:hover{color:#0056b3;text-decoration:underline}.link-style-button[_ngcontent-%COMP%]:focus{outline:1px dotted #007bff}.link-style-button[_ngcontent-%COMP%]:active{color:#004085}.link-style-button[_ngcontent-%COMP%]:disabled{color:#6c757d;text-decoration:none;cursor:not-allowed}"]})};function ao(t){return Array.isArray(t)}function Mo(t){return t!==null&&typeof t=="object"&&(t.constructor===void 0||t.constructor.name==="Object")}function Vk(t){return t&&typeof t=="object"?t.op==="add":!1}function Zk(t){return t&&typeof t=="object"?t.op==="remove":!1}function Q8(t){return t&&typeof t=="object"?t.op==="replace":!1}function u8(t){return t&&typeof t=="object"?t.op==="copy":!1}function HI(t){return t&&typeof t=="object"?t.op==="move":!1}function aq(t,e){return JSON.stringify(t)===JSON.stringify(e)}function JmA(t,e){return t===e}function Wk(t){return t.slice(0,t.length-1)}function cq(t){return t[t.length-1]}function lq(t,e){let A=arguments.length>2&&arguments[2]!==void 0?arguments[2]:JmA;if(t.length<e.length)return!1;for(let i=0;i<e.length;i++)if(!A(t[i],e[i]))return!1;return!0}function Xk(t){return typeof t=="object"&&t!==null}function $k(t){if(ao(t)){let e=t.slice();return Object.getOwnPropertySymbols(t).forEach(A=>{e[A]=t[A]}),e}else if(Mo(t)){let e=nA({},t);return Object.getOwnPropertySymbols(t).forEach(A=>{e[A]=t[A]}),e}else return t}function AS(t,e,A){if(t[e]===A)return t;{let i=$k(t);return i[e]=A,i}}function Fe(t,e){let A=t,i=0;for(;i<e.length;)Mo(A)?A=A[e[i]]:ao(A)?A=A[parseInt(e[i])]:A=void 0,i++;return A}function As(t,e,A){let i=arguments.length>3&&arguments[3]!==void 0?arguments[3]:!1;if(e.length===0)return A;let n=e[0],o=As(t?t[n]:void 0,e.slice(1),A,i);if(Mo(t)||ao(t))return AS(t,n,o);if(i){let r=TmA.test(n)?[]:{};return r[n]=o,r}else throw new Error("Path does not exist")}var TmA=/^\d+$/;function Lu(t,e,A){if(e.length===0)return A(t);if(!Xk(t))throw new Error("Path doesn't exist");let i=e[0],n=Lu(t[i],e.slice(1),A);return AS(t,i,n)}function OI(t,e){if(e.length===0)return t;if(!Xk(t))throw new Error("Path does not exist");if(e.length===1){let n=e[0];if(n in t){let o=$k(t);return ao(o)&&o.splice(parseInt(n),1),Mo(o)&&delete o[n],o}else return t}let A=e[0],i=OI(t[A],e.slice(1));return AS(t,A,i)}function xu(t,e,A){let i=e.slice(0,e.length-1),n=e[e.length-1];return Lu(t,i,o=>{if(!Array.isArray(o))throw new TypeError("Array expected at path "+JSON.stringify(i));let r=$k(o);return r.splice(parseInt(n),0,A),r})}function Qs(t,e){return t===void 0?!1:e.length===0?!0:t===null?!1:Qs(t[e[0]],e.slice(1))}function da(t){let e=t.split("/");return e.shift(),e.map(A=>A.replace(/~1/g,"/").replace(/~0/g,"~"))}function nt(t){return t.map(gq).join("")}function gq(t){return"/"+String(t).replace(/~/g,"~0").replace(/\//g,"~1")}function eS(t,e){return t+gq(e)}function Ba(t,e,A){let i=t;for(let n=0;n<e.length;n++){ZmA(e[n]);let o=e[n];if(A&&A.before){let a=A.before(i,o);if(a!==void 0){if(a.document!==void 0&&(i=a.document),a.json!==void 0)throw new Error('Deprecation warning: returned object property ".json" has been renamed to ".document"');a.operation!==void 0&&(o=a.operation)}}let r=i,s=Ea(i,o.path);if(o.op==="add")i=OmA(i,s,o.value);else if(o.op==="remove")i=HmA(i,s);else if(o.op==="replace")i=zmA(i,s,o.value);else if(o.op==="copy")i=PmA(i,s,Fu(o.from));else if(o.op==="move")i=jmA(i,s,Fu(o.from));else if(o.op==="test")qmA(i,s,o.value);else throw new Error("Unknown JSONPatch operation "+JSON.stringify(o));if(A&&A.after){let a=A.after(i,o,r);a!==void 0&&(i=a)}}return i}function zmA(t,e,A){return As(t,e,A)}function HmA(t,e){return OI(t,e)}function OmA(t,e,A){return bB(t,e)?xu(t,e,A):As(t,e,A)}function PmA(t,e,A){let i=Fe(t,A);if(bB(t,e))return xu(t,e,i);{let n=Fe(t,A);return As(t,e,n)}}function jmA(t,e,A){let i=Fe(t,A),n=OI(t,A);return bB(n,e)?xu(n,e,i):As(n,e,i)}function qmA(t,e,A){if(A===void 0)throw new Error(`Test failed: no value provided (path: "${nt(e)}")`);if(!Qs(t,e))throw new Error(`Test failed: path not found (path: "${nt(e)}")`);let i=Fe(t,e);if(!aq(i,A))throw new Error(`Test failed, value differs (path: "${nt(e)}")`)}function bB(t,e){if(e.length===0)return!1;let A=Fe(t,Wk(e));return Array.isArray(A)}function VmA(t,e){if(cq(e)!=="-")return e;let A=Wk(e),i=Fe(t,A);return A.concat(i.length)}function ZmA(t){if(!["add","remove","replace","copy","move","test"].includes(t.op))throw new Error("Unknown JSONPatch op "+JSON.stringify(t.op));if(typeof t.path!="string")throw new Error('Required property "path" missing or not a string in operation '+JSON.stringify(t));if((t.op==="copy"||t.op==="move")&&typeof t.from!="string")throw new Error('Required property "from" missing or not a string in operation '+JSON.stringify(t))}function Ea(t,e){return VmA(t,da(e))}function Fu(t){return da(t)}function f8(t,e,A){let i=[];return Ba(t,e,{before:(o,r)=>{let s,a=Ea(o,r.path);if(r.op==="add")s=dq(o,a);else if(r.op==="remove")s=Cq(o,a);else if(r.op==="replace")s=Iq(o,a);else if(r.op==="copy")s=WmA(o,a);else if(r.op==="move")s=XmA(o,a,Fu(r.from));else if(r.op==="test")s=[];else throw new Error("Unknown JSONPatch operation "+JSON.stringify(r));let c;if(A&&A.before){let l=A.before(o,r,s);if(l&&l.revertOperations&&(s=l.revertOperations),l&&l.document&&(c=l.document),l&&l.json)throw new Error('Deprecation warning: returned object property ".json" has been renamed to ".document"')}if(i=s.concat(i),c!==void 0)return{document:c}}}),i}function Iq(t,e){return[{op:"replace",path:nt(e),value:Fe(t,e)}]}function Cq(t,e){return[{op:"add",path:nt(e),value:Fe(t,e)}]}function dq(t,e){return bB(t,e)||!Qs(t,e)?[{op:"remove",path:nt(e)}]:Iq(t,e)}function WmA(t,e){return dq(t,e)}function XmA(t,e,A){if(e.length<A.length&&lq(A,e))return[{op:"replace",path:nt(e),value:t}];let i={op:"move",from:nt(e),path:nt(A)};return!bB(t,e)&&Qs(t,e)?[i,...Cq(t,e)]:[i]}var qN=xh(Eq(),1);var w0=class extends Error{constructor(e,A){super("".concat(e," at position ").concat(A)),this.position=A}};function hq(t){return/^[0-9A-Fa-f]$/.test(t)}function H2(t){return t>="0"&&t<="9"}function Qq(t){return t>=" "}function Nu(t){return`,:[]/{}()
+`.includes(t)}function nS(t){return t>="a"&&t<="z"||t>="A"&&t<="Z"||t==="_"||t==="$"}function oS(t){return t>="a"&&t<="z"||t>="A"&&t<="Z"||t==="_"||t==="$"||t>="0"&&t<="9"}var rS=/^(http|https|ftp|mailto|file|data|irc):\/\/$/,sS=/^[A-Za-z0-9-._~:/?#@!$&'()*+;=]$/;function aS(t){return`,[]/{}
+`.includes(t)}function cS(t){return _u(t)||cpA.test(t)}var cpA=/^[[{\w-]$/;function uq(t){return t===`
`||t==="\r"||t==="	"||t==="\b"||t==="\f"}function z2(t,e){let A=t.charCodeAt(e);return A===32||A===10||A===9||A===13}function fq(t,e){let A=t.charCodeAt(e);return A===32||A===9||A===13}function mq(t,e){let A=t.charCodeAt(e);return A===160||A>=8192&&A<=8202||A===8239||A===8287||A===12288}function _u(t){return lS(t)||w8(t)}function lS(t){return t==='"'||t==="\u201C"||t==="\u201D"}function gS(t){return t==='"'}function w8(t){return t==="'"||t==="\u2018"||t==="\u2019"||t==="`"||t==="\xB4"}function IS(t){return t==="'"}function MB(t,e){let A=arguments.length>2&&arguments[2]!==void 0?arguments[2]:!1,i=t.lastIndexOf(e);return i!==-1?t.substring(0,i)+(A?"":t.substring(i+1)):t}function Dc(t,e){let A=t.length;if(!z2(t,A-1))return t+e;for(;z2(t,A-1);)A--;return t.substring(0,A)+e+t.substring(A)}function pq(t,e,A){return t.substring(0,e)+t.substring(e+A)}function wq(t){return/[,\n][ \t\r]*$/.test(t)}var lpA={"\b":"\\b","\f":"\\f","\n":"\\n","\r":"\\r","	":"\\t"},gpA={'"':'"',"\\":"\\","/":"/",b:"\b",f:"\f",n:`
`,r:"\r",t:"	"};function yc(t){let e=0,A="";c(),o()||IA(),c();let n=l(",");for(n&&r(),cS(t[e])&&wq(A)?(n||(A=Dc(A,",")),Q()):n&&(A=MB(A,","));t[e]==="}"||t[e]==="]";)e++,r();if(e>=t.length)return A;j();function o(){r();let V=B()||E()||u()||L()||x()||F(!1)||U();return r(),V}function r(){let V=arguments.length>0&&arguments[0]!==void 0?arguments[0]:!0,cA=e,aA=s(V);do aA=a(),aA&&(aA=s(V));while(aA);return e>cA}function s(V){let cA=V?z2:fq,aA="";for(;;)if(cA(t,e))aA+=t[e],e++;else if(mq(t,e))aA+=" ",e++;else break;return aA.length>0?(A+=aA,!0):!1}function a(){if(t[e]==="/"&&t[e+1]==="*"){for(;e<t.length&&!IpA(t,e);)e++;return e+=2,!0}if(t[e]==="/"&&t[e+1]==="/"){for(;e<t.length&&t[e]!==`
`;)e++;return!0}return!1}function c(){if(t.slice(e,e+3)==="```"){if(e+=3,nS(t[e]))for(;e<t.length&&oS(t[e]);)e++;return r(),!0}return!1}function l(V){return t[e]===V?(A+=t[e],e++,!0):!1}function I(V){return t[e]===V?(e++,!0):!1}function C(){return I("\\")}function d(){return r(),t[e]==="."&&t[e+1]==="."&&t[e+2]==="."?(e+=3,r(),I(","),!0):!1}function B(){if(t[e]==="{"){A+="{",e++,r(),I(",")&&r();let V=!0;for(;e<t.length&&t[e]!=="}";){let cA;if(V?(cA=!0,V=!1):(cA=l(","),cA||(A=Dc(A,",")),r()),d(),!(u()||F(!0))){t[e]==="}"||t[e]==="{"||t[e]==="]"||t[e]==="["||t[e]===void 0?A=MB(A,","):lA();break}r();let jA=l(":"),VA=e>=t.length;jA||(cS(t[e])||VA?A=Dc(A,":"):uA()),o()||(jA||VA?A+="null":uA())}return t[e]==="}"?(A+="}",e++):A=Dc(A,"}"),!0}return!1}function E(){if(t[e]==="["){A+="[",e++,r(),I(",")&&r();let V=!0;for(;e<t.length&&t[e]!=="]";)if(V?V=!1:l(",")||(A=Dc(A,",")),d(),!o()){A=MB(A,",");break}return t[e]==="]"?(A+="]",e++):A=Dc(A,"]"),!0}return!1}function Q(){let V=!0,cA=!0;for(;cA;)V?V=!1:l(",")||(A=Dc(A,",")),cA=o();cA||(A=MB(A,",")),A=`[
`.concat(A,`
]`)}function u(){let V=arguments.length>0&&arguments[0]!==void 0?arguments[0]:!1,cA=arguments.length>1&&arguments[1]!==void 0?arguments[1]:-1,aA=t[e]==="\\";if(aA&&(e++,aA=!0),_u(t[e])){let jA=gS(t[e])?gS:IS(t[e])?IS:w8(t[e])?w8:lS,VA=e,ce=A.length,EA='"';for(e++;;){if(e>=t.length){let sA=T(e-1);return!V&&Nu(t.charAt(sA))?(e=VA,A=A.substring(0,ce),u(!0)):(EA=Dc(EA,'"'),A+=EA,!0)}else{if(e===cA)return EA=Dc(EA,'"'),A+=EA,!0;if(jA(t[e])){let sA=e,TA=EA.length;if(EA+='"',e++,A+=EA,r(!1),V||e>=t.length||Nu(t[e])||_u(t[e])||H2(t[e]))return v(),!0;let Ke=T(sA-1),Re=t.charAt(Ke);if(Re===",")return e=VA,A=A.substring(0,ce),u(!1,Ke);if(Nu(Re))return e=VA,A=A.substring(0,ce),u(!0);A=A.substring(0,ce),e=sA+1,EA="".concat(EA.substring(0,TA),"\\").concat(EA.substring(TA))}else if(V&&aS(t[e])){if(t[e-1]===":"&&rS.test(t.substring(VA+1,e+2)))for(;e<t.length&&sS.test(t[e]);)EA+=t[e],e++;return EA=Dc(EA,'"'),A+=EA,v(),!0}else if(t[e]==="\\"){let sA=t.charAt(e+1);if(gpA[sA]!==void 0)EA+=t.slice(e,e+2),e+=2;else if(sA==="u"){let Ke=2;for(;Ke<6&&hq(t[e+Ke]);)Ke++;Ke===6?(EA+=t.slice(e,e+6),e+=6):e+Ke>=t.length?e=t.length:p()}else EA+=sA,e+=2}else{let sA=t.charAt(e);sA==='"'&&t[e-1]!=="\\"?(EA+="\\".concat(sA),e++):uq(sA)?(EA+=lpA[sA],e++):(Qq(sA)||H(sA),EA+=sA,e++)}}aA&&C()}}return!1}function v(){let V=!1;for(r();t[e]==="+";){V=!0,e++,r(),A=MB(A,'"',!0);let cA=A.length;u()?A=pq(A,cA,1):A=Dc(A,'"')}return V}function L(){let V=e;if(t[e]==="-"){if(e++,N())return K(V),!0;if(!H2(t[e]))return e=V,!1}for(;H2(t[e]);)e++;if(t[e]==="."){if(e++,N())return K(V),!0;if(!H2(t[e]))return e=V,!1;for(;H2(t[e]);)e++}if(t[e]==="e"||t[e]==="E"){if(e++,(t[e]==="-"||t[e]==="+")&&e++,N())return K(V),!0;if(!H2(t[e]))return e=V,!1;for(;H2(t[e]);)e++}if(!N())return e=V,!1;if(e>V){let cA=t.slice(V,e),aA=/^0\d/.test(cA);return A+=aA?'"'.concat(cA,'"'):cA,!0}return!1}function x(){return y("true","true")||y("false","false")||y("null","null")||y("True","true")||y("False","false")||y("None","null")}function y(V,cA){return t.slice(e,e+V.length)===V?(A+=cA,e+=V.length,!0):!1}function F(V){let cA=e;if(nS(t[e])){for(;e<t.length&&oS(t[e]);)e++;let aA=e;for(;z2(t,aA);)aA++;if(t[aA]==="(")return e=aA+1,o(),t[e]===")"&&(e++,t[e]===";"&&e++),!0}for(;e<t.length&&!aS(t[e])&&!_u(t[e])&&(!V||t[e]!==":");)e++;if(t[e-1]===":"&&rS.test(t.substring(cA,e+2)))for(;e<t.length&&sS.test(t[e]);)e++;if(e>cA){for(;z2(t,e-1)&&e>0;)e--;let aA=t.slice(cA,e);return A+=aA==="undefined"?"null":JSON.stringify(aA),t[e]==='"'&&e++,!0}}function U(){if(t[e]==="/"){let V=e;for(e++;e<t.length&&(t[e]!=="/"||t[e-1]==="\\");)e++;return e++,A+='"'.concat(t.substring(V,e),'"'),!0}}function T(V){let cA=V;for(;cA>0&&z2(t,cA);)cA--;return cA}function N(){return e>=t.length||Nu(t[e])||z2(t,e)}function K(V){A+="".concat(t.slice(V,e),"0")}function H(V){throw new w0("Invalid character ".concat(JSON.stringify(V)),e)}function j(){throw new w0("Unexpected character ".concat(JSON.stringify(t[e])),e)}function IA(){throw new w0("Unexpected end of json string",t.length)}function lA(){throw new w0("Object key expected",e)}function uA(){throw new w0("Colon expected",e)}function p(){let V=t.slice(e,e+6);throw new w0('Invalid unicode character "'.concat(V,'"'),e)}}function IpA(t,e){return t[e]==="*"&&t[e+1]==="/"}var CpA=typeof global=="object"&&global&&global.Object===Object&&global,D8=CpA;var dpA=typeof self=="object"&&self&&self.Object===Object&&self,BpA=D8||dpA||Function("return this")(),er=BpA;var EpA=er.Symbol,Tr=EpA;var Dq=Object.prototype,hpA=Dq.hasOwnProperty,QpA=Dq.toString,Gu=Tr?Tr.toStringTag:void 0;function upA(t){var e=hpA.call(t,Gu),A=t[Gu];try{t[Gu]=void 0;var i=!0}catch{}var n=QpA.call(t);return i&&(e?t[Gu]=A:delete t[Gu]),n}var yq=upA;var fpA=Object.prototype,mpA=fpA.toString;function ppA(t){return mpA.call(t)}var vq=ppA;var wpA="[object Null]",DpA="[object Undefined]",bq=Tr?Tr.toStringTag:void 0;function ypA(t){return t==null?t===void 0?DpA:wpA:bq&&bq in Object(t)?yq(t):vq(t)}var al=ypA;function vpA(t){return t!=null&&typeof t=="object"}var Ks=vpA;var bpA="[object Symbol]";function MpA(t){return typeof t=="symbol"||Ks(t)&&al(t)==bpA}var Ac=MpA;function kpA(t,e){for(var A=-1,i=t==null?0:t.length,n=Array(i);++A<i;)n[A]=e(t[A],A,t);return n}var O2=kpA;var SpA=Array.isArray,Mn=SpA;var RpA=1/0,Mq=Tr?Tr.prototype:void 0,kq=Mq?Mq.toString:void 0;function Sq(t){if(typeof t=="string")return t;if(Mn(t))return O2(t,Sq)+"";if(Ac(t))return kq?kq.call(t):"";var e=t+"";return e=="0"&&1/t==-RpA?"-0":e}var Rq=Sq;var LpA=/\s/;function xpA(t){for(var e=t.length;e--&&LpA.test(t.charAt(e)););return e}var Lq=xpA;var FpA=/^\s+/;function NpA(t){return t&&t.slice(0,Lq(t)+1).replace(FpA,"")}var xq=NpA;function _pA(t){var e=typeof t;return t!=null&&(e=="object"||e=="function")}var Lr=_pA;var Fq=NaN,GpA=/^[-+]0x[0-9a-f]+$/i,UpA=/^0b[01]+$/i,KpA=/^0o[0-7]+$/i,YpA=parseInt;function JpA(t){if(typeof t=="number")return t;if(Ac(t))return Fq;if(Lr(t)){var e=typeof t.valueOf=="function"?t.valueOf():t;t=Lr(e)?e+"":e}if(typeof t!="string")return t===0?t:+t;t=xq(t);var A=UpA.test(t);return A||KpA.test(t)?YpA(t.slice(2),A?2:8):GpA.test(t)?Fq:+t}var Uu=JpA;var Nq=1/0,TpA=17976931348623157e292;function zpA(t){if(!t)return t===0?t:0;if(t=Uu(t),t===Nq||t===-Nq){var e=t<0?-1:1;return e*TpA}return t===t?t:0}var kB=zpA;function HpA(t){var e=kB(t),A=e%1;return e===e?A?e-A:e:0}var _q=HpA;function OpA(t){return t}var Ig=OpA;var PpA="[object AsyncFunction]",jpA="[object Function]",qpA="[object GeneratorFunction]",VpA="[object Proxy]";function ZpA(t){if(!Lr(t))return!1;var e=al(t);return e==jpA||e==qpA||e==PpA||e==VpA}var y8=ZpA;var WpA=er["__core-js_shared__"],v8=WpA;var Gq=function(){var t=/[^.]+$/.exec(v8&&v8.keys&&v8.keys.IE_PROTO||"");return t?"Symbol(src)_1."+t:""}();function XpA(t){return!!Gq&&Gq in t}var Uq=XpA;var $pA=Function.prototype,A6A=$pA.toString;function e6A(t){if(t!=null){try{return A6A.call(t)}catch{}try{return t+""}catch{}}return""}var D0=e6A;var t6A=/[\\^$.*+?()[\]{}|]/g,i6A=/^\[object .+?Constructor\]$/,n6A=Function.prototype,o6A=Object.prototype,r6A=n6A.toString,s6A=o6A.hasOwnProperty,a6A=RegExp("^"+r6A.call(s6A).replace(t6A,"\\$&").replace(/hasOwnProperty|(function).*?(?=\\\()| for .+?(?=\\\])/g,"$1.*?")+"$");function c6A(t){if(!Lr(t)||Uq(t))return!1;var e=y8(t)?a6A:i6A;return e.test(D0(t))}var Kq=c6A;function l6A(t,e){return t?.[e]}var Yq=l6A;function g6A(t,e){var A=Yq(t,e);return Kq(A)?A:void 0}var ha=g6A;var I6A=ha(er,"WeakMap"),b8=I6A;var Jq=Object.create,C6A=function(){function t(){}return function(e){if(!Lr(e))return{};if(Jq)return Jq(e);t.prototype=e;var A=new t;return t.prototype=void 0,A}}(),Tq=C6A;function d6A(t,e,A){switch(A.length){case 0:return t.call(e);case 1:return t.call(e,A[0]);case 2:return t.call(e,A[0],A[1]);case 3:return t.call(e,A[0],A[1],A[2])}return t.apply(e,A)}var zq=d6A;function B6A(){}var Jo=B6A;function E6A(t,e){var A=-1,i=t.length;for(e||(e=Array(i));++A<i;)e[A]=t[A];return e}var Hq=E6A;var h6A=800,Q6A=16,u6A=Date.now;function f6A(t){var e=0,A=0;return function(){var i=u6A(),n=Q6A-(i-A);if(A=i,n>0){if(++e>=h6A)return arguments[0]}else e=0;return t.apply(void 0,arguments)}}var Oq=f6A;function m6A(t){return function(){return t}}var Pq=m6A;var p6A=function(){try{var t=ha(Object,"defineProperty");return t({},"",{}),t}catch{}}(),SB=p6A;var w6A=SB?function(t,e){return SB(t,"toString",{configurable:!0,enumerable:!1,value:Pq(e),writable:!0})}:Ig,jq=w6A;var D6A=Oq(jq),qq=D6A;function y6A(t,e){for(var A=-1,i=t==null?0:t.length;++A<i&&e(t[A],A,t)!==!1;);return t}var Vq=y6A;var v6A=9007199254740991,b6A=/^(?:0|[1-9]\d*)$/;function M6A(t,e){var A=typeof t;return e=e??v6A,!!e&&(A=="number"||A!="symbol"&&b6A.test(t))&&t>-1&&t%1==0&&t<e}var RB=M6A;function k6A(t,e,A){e=="__proto__"&&SB?SB(t,e,{configurable:!0,enumerable:!0,value:A,writable:!0}):t[e]=A}var P2=k6A;function S6A(t,e){return t===e||t!==t&&e!==e}var j2=S6A;var R6A=Object.prototype,L6A=R6A.hasOwnProperty;function x6A(t,e,A){var i=t[e];(!(L6A.call(t,e)&&j2(i,A))||A===void 0&&!(e in t))&&P2(t,e,A)}var M8=x6A;function F6A(t,e,A,i){var n=!A;A||(A={});for(var o=-1,r=e.length;++o<r;){var s=e[o],a=i?i(A[s],t[s],s,A,t):void 0;a===void 0&&(a=t[s]),n?P2(A,s,a):M8(A,s,a)}return A}var q2=F6A;var Zq=Math.max;function N6A(t,e,A){return e=Zq(e===void 0?t.length-1:e,0),function(){for(var i=arguments,n=-1,o=Zq(i.length-e,0),r=Array(o);++n<o;)r[n]=i[e+n];n=-1;for(var s=Array(e+1);++n<e;)s[n]=i[n];return s[e]=A(r),zq(t,this,s)}}var Wq=N6A;function _6A(t,e){return qq(Wq(t,e,Ig),t+"")}var Xq=_6A;var G6A=9007199254740991;function U6A(t){return typeof t=="number"&&t>-1&&t%1==0&&t<=G6A}var LB=U6A;function K6A(t){return t!=null&&LB(t.length)&&!y8(t)}var vc=K6A;function Y6A(t,e,A){if(!Lr(A))return!1;var i=typeof e;return(i=="number"?vc(A)&&RB(e,A.length):i=="string"&&e in A)?j2(A[e],t):!1}var Ku=Y6A;var J6A=Object.prototype;function T6A(t){var e=t&&t.constructor,A=typeof e=="function"&&e.prototype||J6A;return t===A}var V2=T6A;function z6A(t,e){for(var A=-1,i=Array(t);++A<t;)i[A]=e(A);return i}var k8=z6A;var H6A="[object Arguments]";function O6A(t){return Ks(t)&&al(t)==H6A}var CS=O6A;var $q=Object.prototype,P6A=$q.hasOwnProperty,j6A=$q.propertyIsEnumerable,q6A=CS(function(){return arguments}())?CS:function(t){return Ks(t)&&P6A.call(t,"callee")&&!j6A.call(t,"callee")},Z2=q6A;function V6A(){return!1}var AV=V6A;var iV=typeof exports=="object"&&exports&&!exports.nodeType&&exports,eV=iV&&typeof module=="object"&&module&&!module.nodeType&&module,Z6A=eV&&eV.exports===iV,tV=Z6A?er.Buffer:void 0,W6A=tV?tV.isBuffer:void 0,X6A=W6A||AV,y0=X6A;var $6A="[object Arguments]",A8A="[object Array]",e8A="[object Boolean]",t8A="[object Date]",i8A="[object Error]",n8A="[object Function]",o8A="[object Map]",r8A="[object Number]",s8A="[object Object]",a8A="[object RegExp]",c8A="[object Set]",l8A="[object String]",g8A="[object WeakMap]",I8A="[object ArrayBuffer]",C8A="[object DataView]",d8A="[object Float32Array]",B8A="[object Float64Array]",E8A="[object Int8Array]",h8A="[object Int16Array]",Q8A="[object Int32Array]",u8A="[object Uint8Array]",f8A="[object Uint8ClampedArray]",m8A="[object Uint16Array]",p8A="[object Uint32Array]",ko={};ko[d8A]=ko[B8A]=ko[E8A]=ko[h8A]=ko[Q8A]=ko[u8A]=ko[f8A]=ko[m8A]=ko[p8A]=!0;ko[$6A]=ko[A8A]=ko[I8A]=ko[e8A]=ko[C8A]=ko[t8A]=ko[i8A]=ko[n8A]=ko[o8A]=ko[r8A]=ko[s8A]=ko[a8A]=ko[c8A]=ko[l8A]=ko[g8A]=!1;function w8A(t){return Ks(t)&&LB(t.length)&&!!ko[al(t)]}var nV=w8A;function D8A(t){return function(e){return t(e)}}var W2=D8A;var oV=typeof exports=="object"&&exports&&!exports.nodeType&&exports,Yu=oV&&typeof module=="object"&&module&&!module.nodeType&&module,y8A=Yu&&Yu.exports===oV,dS=y8A&&D8.process,v8A=function(){try{var t=Yu&&Yu.require&&Yu.require("util").types;return t||dS&&dS.binding&&dS.binding("util")}catch{}}(),v0=v8A;var rV=v0&&v0.isTypedArray,b8A=rV?W2(rV):nV,xB=b8A;var M8A=Object.prototype,k8A=M8A.hasOwnProperty;function S8A(t,e){var A=Mn(t),i=!A&&Z2(t),n=!A&&!i&&y0(t),o=!A&&!i&&!n&&xB(t),r=A||i||n||o,s=r?k8(t.length,String):[],a=s.length;for(var c in t)(e||k8A.call(t,c))&&!(r&&(c=="length"||n&&(c=="offset"||c=="parent")||o&&(c=="buffer"||c=="byteLength"||c=="byteOffset")||RB(c,a)))&&s.push(c);return s}var S8=S8A;function R8A(t,e){return function(A){return t(e(A))}}var R8=R8A;var L8A=R8(Object.keys,Object),sV=L8A;var x8A=Object.prototype,F8A=x8A.hasOwnProperty;function N8A(t){if(!V2(t))return sV(t);var e=[];for(var A in Object(t))F8A.call(t,A)&&A!="constructor"&&e.push(A);return e}var L8=N8A;function _8A(t){return vc(t)?S8(t):L8(t)}var bc=_8A;function G8A(t){var e=[];if(t!=null)for(var A in Object(t))e.push(A);return e}var aV=G8A;var U8A=Object.prototype,K8A=U8A.hasOwnProperty;function Y8A(t){if(!Lr(t))return aV(t);var e=V2(t),A=[];for(var i in t)i=="constructor"&&(e||!K8A.call(t,i))||A.push(i);return A}var cV=Y8A;function J8A(t){return vc(t)?S8(t,!0):cV(t)}var FB=J8A;var T8A=/\.|\[(?:[^[\]]*|(["'])(?:(?!\1)[^\\]|\\.)*?\1)\]/,z8A=/^\w*$/;function H8A(t,e){if(Mn(t))return!1;var A=typeof t;return A=="number"||A=="symbol"||A=="boolean"||t==null||Ac(t)?!0:z8A.test(t)||!T8A.test(t)||e!=null&&t in Object(e)}var NB=H8A;var O8A=ha(Object,"create"),b0=O8A;function P8A(){this.__data__=b0?b0(null):{},this.size=0}var lV=P8A;function j8A(t){var e=this.has(t)&&delete this.__data__[t];return this.size-=e?1:0,e}var gV=j8A;var q8A="__lodash_hash_undefined__",V8A=Object.prototype,Z8A=V8A.hasOwnProperty;function W8A(t){var e=this.__data__;if(b0){var A=e[t];return A===q8A?void 0:A}return Z8A.call(e,t)?e[t]:void 0}var IV=W8A;var X8A=Object.prototype,$8A=X8A.hasOwnProperty;function A5A(t){var e=this.__data__;return b0?e[t]!==void 0:$8A.call(e,t)}var CV=A5A;var e5A="__lodash_hash_undefined__";function t5A(t,e){var A=this.__data__;return this.size+=this.has(t)?0:1,A[t]=b0&&e===void 0?e5A:e,this}var dV=t5A;function _B(t){var e=-1,A=t==null?0:t.length;for(this.clear();++e<A;){var i=t[e];this.set(i[0],i[1])}}_B.prototype.clear=lV;_B.prototype.delete=gV;_B.prototype.get=IV;_B.prototype.has=CV;_B.prototype.set=dV;var BS=_B;function i5A(){this.__data__=[],this.size=0}var BV=i5A;function n5A(t,e){for(var A=t.length;A--;)if(j2(t[A][0],e))return A;return-1}var X2=n5A;var o5A=Array.prototype,r5A=o5A.splice;function s5A(t){var e=this.__data__,A=X2(e,t);if(A<0)return!1;var i=e.length-1;return A==i?e.pop():r5A.call(e,A,1),--this.size,!0}var EV=s5A;function a5A(t){var e=this.__data__,A=X2(e,t);return A<0?void 0:e[A][1]}var hV=a5A;function c5A(t){return X2(this.__data__,t)>-1}var QV=c5A;function l5A(t,e){var A=this.__data__,i=X2(A,t);return i<0?(++this.size,A.push([t,e])):A[i][1]=e,this}var uV=l5A;function GB(t){var e=-1,A=t==null?0:t.length;for(this.clear();++e<A;){var i=t[e];this.set(i[0],i[1])}}GB.prototype.clear=BV;GB.prototype.delete=EV;GB.prototype.get=hV;GB.prototype.has=QV;GB.prototype.set=uV;var $2=GB;var g5A=ha(er,"Map"),A1=g5A;function I5A(){this.size=0,this.__data__={hash:new BS,map:new(A1||$2),string:new BS}}var fV=I5A;function C5A(t){var e=typeof t;return e=="string"||e=="number"||e=="symbol"||e=="boolean"?t!=="__proto__":t===null}var mV=C5A;function d5A(t,e){var A=t.__data__;return mV(e)?A[typeof e=="string"?"string":"hash"]:A.map}var e1=d5A;function B5A(t){var e=e1(this,t).delete(t);return this.size-=e?1:0,e}var pV=B5A;function E5A(t){return e1(this,t).get(t)}var wV=E5A;function h5A(t){return e1(this,t).has(t)}var DV=h5A;function Q5A(t,e){var A=e1(this,t),i=A.size;return A.set(t,e),this.size+=A.size==i?0:1,this}var yV=Q5A;function UB(t){var e=-1,A=t==null?0:t.length;for(this.clear();++e<A;){var i=t[e];this.set(i[0],i[1])}}UB.prototype.clear=fV;UB.prototype.delete=pV;UB.prototype.get=wV;UB.prototype.has=DV;UB.prototype.set=yV;var PI=UB;var u5A="Expected a function";function ES(t,e){if(typeof t!="function"||e!=null&&typeof e!="function")throw new TypeError(u5A);var A=function(){var i=arguments,n=e?e.apply(this,i):i[0],o=A.cache;if(o.has(n))return o.get(n);var r=t.apply(this,i);return A.cache=o.set(n,r)||o,r};return A.cache=new(ES.Cache||PI),A}ES.Cache=PI;var vV=ES;var f5A=500;function m5A(t){var e=vV(t,function(i){return A.size===f5A&&A.clear(),i}),A=e.cache;return e}var bV=m5A;var p5A=/[^.[\]]+|\[(?:(-?\d+(?:\.\d+)?)|(["'])((?:(?!\2)[^\\]|\\.)*?)\2)\]|(?=(?:\.|\[\])(?:\.|\[\]|$))/g,w5A=/\\(\\)?/g,D5A=bV(function(t){var e=[];return t.charCodeAt(0)===46&&e.push(""),t.replace(p5A,function(A,i,n,o){e.push(n?o.replace(w5A,"$1"):i||A)}),e}),MV=D5A;function y5A(t){return t==null?"":Rq(t)}var x8=y5A;function v5A(t,e){return Mn(t)?t:NB(t,e)?[t]:MV(x8(t))}var F8=v5A;var b5A=1/0;function M5A(t){if(typeof t=="string"||Ac(t))return t;var e=t+"";return e=="0"&&1/t==-b5A?"-0":e}var t1=M5A;function k5A(t,e){e=F8(e,t);for(var A=0,i=e.length;t!=null&&A<i;)t=t[t1(e[A++])];return A&&A==i?t:void 0}var KB=k5A;function S5A(t,e,A){var i=t==null?void 0:KB(t,e);return i===void 0?A:i}var kV=S5A;function R5A(t,e){for(var A=-1,i=e.length,n=t.length;++A<i;)t[n+A]=e[A];return t}var YB=R5A;var SV=Tr?Tr.isConcatSpreadable:void 0;function L5A(t){return Mn(t)||Z2(t)||!!(SV&&t&&t[SV])}var RV=L5A;function LV(t,e,A,i,n){var o=-1,r=t.length;for(A||(A=RV),n||(n=[]);++o<r;){var s=t[o];e>0&&A(s)?e>1?LV(s,e-1,A,i,n):YB(n,s):i||(n[n.length]=s)}return n}var xV=LV;var x5A=R8(Object.getPrototypeOf,Object),N8=x5A;function F5A(t,e,A){var i=-1,n=t.length;e<0&&(e=-e>n?0:n+e),A=A>n?n:A,A<0&&(A+=n),n=e>A?0:A-e>>>0,e>>>=0;for(var o=Array(n);++i<n;)o[i]=t[i+e];return o}var FV=F5A;function N5A(){this.__data__=new $2,this.size=0}var NV=N5A;function _5A(t){var e=this.__data__,A=e.delete(t);return this.size=e.size,A}var _V=_5A;function G5A(t){return this.__data__.get(t)}var GV=G5A;function U5A(t){return this.__data__.has(t)}var UV=U5A;var K5A=200;function Y5A(t,e){var A=this.__data__;if(A instanceof $2){var i=A.__data__;if(!A1||i.length<K5A-1)return i.push([t,e]),this.size=++A.size,this;A=this.__data__=new PI(i)}return A.set(t,e),this.size=A.size,this}var KV=Y5A;function JB(t){var e=this.__data__=new $2(t);this.size=e.size}JB.prototype.clear=NV;JB.prototype.delete=_V;JB.prototype.get=GV;JB.prototype.has=UV;JB.prototype.set=KV;var i1=JB;function J5A(t,e){return t&&q2(e,bc(e),t)}var YV=J5A;function T5A(t,e){return t&&q2(e,FB(e),t)}var JV=T5A;var OV=typeof exports=="object"&&exports&&!exports.nodeType&&exports,TV=OV&&typeof module=="object"&&module&&!module.nodeType&&module,z5A=TV&&TV.exports===OV,zV=z5A?er.Buffer:void 0,HV=zV?zV.allocUnsafe:void 0;function H5A(t,e){if(e)return t.slice();var A=t.length,i=HV?HV(A):new t.constructor(A);return t.copy(i),i}var PV=H5A;function O5A(t,e){for(var A=-1,i=t==null?0:t.length,n=0,o=[];++A<i;){var r=t[A];e(r,A,t)&&(o[n++]=r)}return o}var jV=O5A;function P5A(){return[]}var _8=P5A;var j5A=Object.prototype,q5A=j5A.propertyIsEnumerable,qV=Object.getOwnPropertySymbols,V5A=qV?function(t){return t==null?[]:(t=Object(t),jV(qV(t),function(e){return q5A.call(t,e)}))}:_8,TB=V5A;function Z5A(t,e){return q2(t,TB(t),e)}var VV=Z5A;var W5A=Object.getOwnPropertySymbols,X5A=W5A?function(t){for(var e=[];t;)YB(e,TB(t)),t=N8(t);return e}:_8,G8=X5A;function $5A(t,e){return q2(t,G8(t),e)}var ZV=$5A;function AwA(t,e,A){var i=e(t);return Mn(t)?i:YB(i,A(t))}var U8=AwA;function ewA(t){return U8(t,bc,TB)}var Ju=ewA;function twA(t){return U8(t,FB,G8)}var WV=twA;var iwA=ha(er,"DataView"),K8=iwA;var nwA=ha(er,"Promise"),Y8=nwA;var owA=ha(er,"Set"),J8=owA;var XV="[object Map]",rwA="[object Object]",$V="[object Promise]",AZ="[object Set]",eZ="[object WeakMap]",tZ="[object DataView]",swA=D0(K8),awA=D0(A1),cwA=D0(Y8),lwA=D0(J8),gwA=D0(b8),jI=al;(K8&&jI(new K8(new ArrayBuffer(1)))!=tZ||A1&&jI(new A1)!=XV||Y8&&jI(Y8.resolve())!=$V||J8&&jI(new J8)!=AZ||b8&&jI(new b8)!=eZ)&&(jI=function(t){var e=al(t),A=e==rwA?t.constructor:void 0,i=A?D0(A):"";if(i)switch(i){case swA:return tZ;case awA:return XV;case cwA:return $V;case lwA:return AZ;case gwA:return eZ}return e});var cl=jI;var IwA=Object.prototype,CwA=IwA.hasOwnProperty;function dwA(t){var e=t.length,A=new t.constructor(e);return e&&typeof t[0]=="string"&&CwA.call(t,"index")&&(A.index=t.index,A.input=t.input),A}var iZ=dwA;var BwA=er.Uint8Array,zB=BwA;function EwA(t){var e=new t.constructor(t.byteLength);return new zB(e).set(new zB(t)),e}var HB=EwA;function hwA(t,e){var A=e?HB(t.buffer):t.buffer;return new t.constructor(A,t.byteOffset,t.byteLength)}var nZ=hwA;var QwA=/\w*$/;function uwA(t){var e=new t.constructor(t.source,QwA.exec(t));return e.lastIndex=t.lastIndex,e}var oZ=uwA;var rZ=Tr?Tr.prototype:void 0,sZ=rZ?rZ.valueOf:void 0;function fwA(t){return sZ?Object(sZ.call(t)):{}}var aZ=fwA;function mwA(t,e){var A=e?HB(t.buffer):t.buffer;return new t.constructor(A,t.byteOffset,t.length)}var cZ=mwA;var pwA="[object Boolean]",wwA="[object Date]",DwA="[object Map]",ywA="[object Number]",vwA="[object RegExp]",bwA="[object Set]",MwA="[object String]",kwA="[object Symbol]",SwA="[object ArrayBuffer]",RwA="[object DataView]",LwA="[object Float32Array]",xwA="[object Float64Array]",FwA="[object Int8Array]",NwA="[object Int16Array]",_wA="[object Int32Array]",GwA="[object Uint8Array]",UwA="[object Uint8ClampedArray]",KwA="[object Uint16Array]",YwA="[object Uint32Array]";function JwA(t,e,A){var i=t.constructor;switch(e){case SwA:return HB(t);case pwA:case wwA:return new i(+t);case RwA:return nZ(t,A);case LwA:case xwA:case FwA:case NwA:case _wA:case GwA:case UwA:case KwA:case YwA:return cZ(t,A);case DwA:return new i;case ywA:case MwA:return new i(t);case vwA:return oZ(t);case bwA:return new i;case kwA:return aZ(t)}}var lZ=JwA;function TwA(t){return typeof t.constructor=="function"&&!V2(t)?Tq(N8(t)):{}}var gZ=TwA;var zwA="[object Map]";function HwA(t){return Ks(t)&&cl(t)==zwA}var IZ=HwA;var CZ=v0&&v0.isMap,OwA=CZ?W2(CZ):IZ,dZ=OwA;var PwA="[object Set]";function jwA(t){return Ks(t)&&cl(t)==PwA}var BZ=jwA;var EZ=v0&&v0.isSet,qwA=EZ?W2(EZ):BZ,hZ=qwA;var VwA=1,ZwA=2,WwA=4,QZ="[object Arguments]",XwA="[object Array]",$wA="[object Boolean]",ADA="[object Date]",eDA="[object Error]",uZ="[object Function]",tDA="[object GeneratorFunction]",iDA="[object Map]",nDA="[object Number]",fZ="[object Object]",oDA="[object RegExp]",rDA="[object Set]",sDA="[object String]",aDA="[object Symbol]",cDA="[object WeakMap]",lDA="[object ArrayBuffer]",gDA="[object DataView]",IDA="[object Float32Array]",CDA="[object Float64Array]",dDA="[object Int8Array]",BDA="[object Int16Array]",EDA="[object Int32Array]",hDA="[object Uint8Array]",QDA="[object Uint8ClampedArray]",uDA="[object Uint16Array]",fDA="[object Uint32Array]",fo={};fo[QZ]=fo[XwA]=fo[lDA]=fo[gDA]=fo[$wA]=fo[ADA]=fo[IDA]=fo[CDA]=fo[dDA]=fo[BDA]=fo[EDA]=fo[iDA]=fo[nDA]=fo[fZ]=fo[oDA]=fo[rDA]=fo[sDA]=fo[aDA]=fo[hDA]=fo[QDA]=fo[uDA]=fo[fDA]=!0;fo[eDA]=fo[uZ]=fo[cDA]=!1;function T8(t,e,A,i,n,o){var r,s=e&VwA,a=e&ZwA,c=e&WwA;if(A&&(r=n?A(t,i,n,o):A(t)),r!==void 0)return r;if(!Lr(t))return t;var l=Mn(t);if(l){if(r=iZ(t),!s)return Hq(t,r)}else{var I=cl(t),C=I==uZ||I==tDA;if(y0(t))return PV(t,s);if(I==fZ||I==QZ||C&&!n){if(r=a||C?{}:gZ(t),!s)return a?ZV(t,JV(r,t)):VV(t,YV(r,t))}else{if(!fo[I])return n?t:{};r=lZ(t,I,s)}}o||(o=new i1);var d=o.get(t);if(d)return d;o.set(t,r),hZ(t)?t.forEach(function(Q){r.add(T8(Q,e,A,Q,t,o))}):dZ(t)&&t.forEach(function(Q,u){r.set(u,T8(Q,e,A,u,t,o))});var B=c?a?WV:Ju:a?FB:bc,E=l?void 0:B(t);return Vq(E||t,function(Q,u){E&&(u=Q,Q=t[u]),M8(r,u,T8(Q,e,A,u,t,o))}),r}var z8=T8;var mDA=1,pDA=4;function wDA(t){return z8(t,mDA|pDA)}var Tu=wDA;var DDA=1,yDA=4;function vDA(t,e){return e=typeof e=="function"?e:void 0,z8(t,DDA|yDA,e)}var hS=vDA;var bDA="__lodash_hash_undefined__";function MDA(t){return this.__data__.set(t,bDA),this}var mZ=MDA;function kDA(t){return this.__data__.has(t)}var pZ=kDA;function H8(t){var e=-1,A=t==null?0:t.length;for(this.__data__=new PI;++e<A;)this.add(t[e])}H8.prototype.add=H8.prototype.push=mZ;H8.prototype.has=pZ;var wZ=H8;function SDA(t,e){for(var A=-1,i=t==null?0:t.length;++A<i;)if(e(t[A],A,t))return!0;return!1}var DZ=SDA;function RDA(t,e){return t.has(e)}var yZ=RDA;var LDA=1,xDA=2;function FDA(t,e,A,i,n,o){var r=A&LDA,s=t.length,a=e.length;if(s!=a&&!(r&&a>s))return!1;var c=o.get(t),l=o.get(e);if(c&&l)return c==e&&l==t;var I=-1,C=!0,d=A&xDA?new wZ:void 0;for(o.set(t,e),o.set(e,t);++I<s;){var B=t[I],E=e[I];if(i)var Q=r?i(E,B,I,e,t,o):i(B,E,I,t,e,o);if(Q!==void 0){if(Q)continue;C=!1;break}if(d){if(!DZ(e,function(u,v){if(!yZ(d,v)&&(B===u||n(B,u,A,i,o)))return d.push(v)})){C=!1;break}}else if(!(B===E||n(B,E,A,i,o))){C=!1;break}}return o.delete(t),o.delete(e),C}var O8=FDA;function NDA(t){var e=-1,A=Array(t.size);return t.forEach(function(i,n){A[++e]=[n,i]}),A}var vZ=NDA;function _DA(t){var e=-1,A=Array(t.size);return t.forEach(function(i){A[++e]=i}),A}var bZ=_DA;var GDA=1,UDA=2,KDA="[object Boolean]",YDA="[object Date]",JDA="[object Error]",TDA="[object Map]",zDA="[object Number]",HDA="[object RegExp]",ODA="[object Set]",PDA="[object String]",jDA="[object Symbol]",qDA="[object ArrayBuffer]",VDA="[object DataView]",MZ=Tr?Tr.prototype:void 0,QS=MZ?MZ.valueOf:void 0;function ZDA(t,e,A,i,n,o,r){switch(A){case VDA:if(t.byteLength!=e.byteLength||t.byteOffset!=e.byteOffset)return!1;t=t.buffer,e=e.buffer;case qDA:return!(t.byteLength!=e.byteLength||!o(new zB(t),new zB(e)));case KDA:case YDA:case zDA:return j2(+t,+e);case JDA:return t.name==e.name&&t.message==e.message;case HDA:case PDA:return t==e+"";case TDA:var s=vZ;case ODA:var a=i&GDA;if(s||(s=bZ),t.size!=e.size&&!a)return!1;var c=r.get(t);if(c)return c==e;i|=UDA,r.set(t,e);var l=O8(s(t),s(e),i,n,o,r);return r.delete(t),l;case jDA:if(QS)return QS.call(t)==QS.call(e)}return!1}var kZ=ZDA;var WDA=1,XDA=Object.prototype,$DA=XDA.hasOwnProperty;function AyA(t,e,A,i,n,o){var r=A&WDA,s=Ju(t),a=s.length,c=Ju(e),l=c.length;if(a!=l&&!r)return!1;for(var I=a;I--;){var C=s[I];if(!(r?C in e:$DA.call(e,C)))return!1}var d=o.get(t),B=o.get(e);if(d&&B)return d==e&&B==t;var E=!0;o.set(t,e),o.set(e,t);for(var Q=r;++I<a;){C=s[I];var u=t[C],v=e[C];if(i)var L=r?i(v,u,C,e,t,o):i(u,v,C,t,e,o);if(!(L===void 0?u===v||n(u,v,A,i,o):L)){E=!1;break}Q||(Q=C=="constructor")}if(E&&!Q){var x=t.constructor,y=e.constructor;x!=y&&"constructor"in t&&"constructor"in e&&!(typeof x=="function"&&x instanceof x&&typeof y=="function"&&y instanceof y)&&(E=!1)}return o.delete(t),o.delete(e),E}var SZ=AyA;var eyA=1,RZ="[object Arguments]",LZ="[object Array]",P8="[object Object]",tyA=Object.prototype,xZ=tyA.hasOwnProperty;function iyA(t,e,A,i,n,o){var r=Mn(t),s=Mn(e),a=r?LZ:cl(t),c=s?LZ:cl(e);a=a==RZ?P8:a,c=c==RZ?P8:c;var l=a==P8,I=c==P8,C=a==c;if(C&&y0(t)){if(!y0(e))return!1;r=!0,l=!1}if(C&&!l)return o||(o=new i1),r||xB(t)?O8(t,e,A,i,n,o):kZ(t,e,a,A,i,n,o);if(!(A&eyA)){var d=l&&xZ.call(t,"__wrapped__"),B=I&&xZ.call(e,"__wrapped__");if(d||B){var E=d?t.value():t,Q=B?e.value():e;return o||(o=new i1),n(E,Q,A,i,o)}}return C?(o||(o=new i1),SZ(t,e,A,i,n,o)):!1}var FZ=iyA;function NZ(t,e,A,i,n){return t===e?!0:t==null||e==null||!Ks(t)&&!Ks(e)?t!==t&&e!==e:FZ(t,e,A,i,NZ,n)}var OB=NZ;var nyA=1,oyA=2;function ryA(t,e,A,i){var n=A.length,o=n,r=!i;if(t==null)return!o;for(t=Object(t);n--;){var s=A[n];if(r&&s[2]?s[1]!==t[s[0]]:!(s[0]in t))return!1}for(;++n<o;){s=A[n];var a=s[0],c=t[a],l=s[1];if(r&&s[2]){if(c===void 0&&!(a in t))return!1}else{var I=new i1;if(i)var C=i(c,l,a,t,e,I);if(!(C===void 0?OB(l,c,nyA|oyA,i,I):C))return!1}}return!0}var _Z=ryA;function syA(t){return t===t&&!Lr(t)}var j8=syA;function ayA(t){for(var e=bc(t),A=e.length;A--;){var i=e[A],n=t[i];e[A]=[i,n,j8(n)]}return e}var GZ=ayA;function cyA(t,e){return function(A){return A==null?!1:A[t]===e&&(e!==void 0||t in Object(A))}}var q8=cyA;function lyA(t){var e=GZ(t);return e.length==1&&e[0][2]?q8(e[0][0],e[0][1]):function(A){return A===t||_Z(A,t,e)}}var UZ=lyA;function gyA(t,e){return t!=null&&e in Object(t)}var KZ=gyA;function IyA(t,e,A){e=F8(e,t);for(var i=-1,n=e.length,o=!1;++i<n;){var r=t1(e[i]);if(!(o=t!=null&&A(t,r)))break;t=t[r]}return o||++i!=n?o:(n=t==null?0:t.length,!!n&&LB(n)&&RB(r,n)&&(Mn(t)||Z2(t)))}var YZ=IyA;function CyA(t,e){return t!=null&&YZ(t,e,KZ)}var JZ=CyA;var dyA=1,ByA=2;function EyA(t,e){return NB(t)&&j8(e)?q8(t1(t),e):function(A){var i=kV(A,t);return i===void 0&&i===e?JZ(A,t):OB(e,i,dyA|ByA)}}var TZ=EyA;function hyA(t){return function(e){return e?.[t]}}var zZ=hyA;function QyA(t){return function(e){return KB(e,t)}}var HZ=QyA;function uyA(t){return NB(t)?zZ(t1(t)):HZ(t)}var OZ=uyA;function fyA(t){return typeof t=="function"?t:t==null?Ig:typeof t=="object"?Mn(t)?TZ(t[0],t[1]):UZ(t):OZ(t)}var Cg=fyA;function myA(t,e,A,i){for(var n=-1,o=t==null?0:t.length;++n<o;){var r=t[n];e(i,r,A(r),t)}return i}var PZ=myA;function pyA(t){return function(e,A,i){for(var n=-1,o=Object(e),r=i(e),s=r.length;s--;){var a=r[t?s:++n];if(A(o[a],a,o)===!1)break}return e}}var V8=pyA;var wyA=V8(),jZ=wyA;function DyA(t,e){return t&&jZ(t,e,bc)}var Z8=DyA;function yyA(t,e){return function(A,i){if(A==null)return A;if(!vc(A))return t(A,i);for(var n=A.length,o=e?n:-1,r=Object(A);(e?o--:++o<n)&&i(r[o],o,r)!==!1;);return A}}var W8=yyA;var vyA=W8(Z8),X8=vyA;function byA(t,e,A,i){return X8(t,function(n,o,r){e(i,n,A(n),r)}),i}var qZ=byA;function MyA(t,e){return function(A,i){var n=Mn(A)?PZ:qZ,o=e?e():{};return n(A,t,Cg(i,2),o)}}var $8=MyA;var kyA=function(){return er.Date.now()},A5=kyA;var SyA="Expected a function",RyA=Math.max,LyA=Math.min;function xyA(t,e,A){var i,n,o,r,s,a,c=0,l=!1,I=!1,C=!0;if(typeof t!="function")throw new TypeError(SyA);e=Uu(e)||0,Lr(A)&&(l=!!A.leading,I="maxWait"in A,o=I?RyA(Uu(A.maxWait)||0,e):o,C="trailing"in A?!!A.trailing:C);function d(F){var U=i,T=n;return i=n=void 0,c=F,r=t.apply(T,U),r}function B(F){return c=F,s=setTimeout(u,e),l?d(F):r}function E(F){var U=F-a,T=F-c,N=e-U;return I?LyA(N,o-T):N}function Q(F){var U=F-a,T=F-c;return a===void 0||U>=e||U<0||I&&T>=o}function u(){var F=A5();if(Q(F))return v(F);s=setTimeout(u,E(F))}function v(F){return s=void 0,C&&i?d(F):(i=n=void 0,r)}function L(){s!==void 0&&clearTimeout(s),c=0,i=a=n=s=void 0}function x(){return s===void 0?r:v(A5())}function y(){var F=A5(),U=Q(F);if(i=arguments,n=this,a=F,U){if(s===void 0)return B(a);if(I)return clearTimeout(s),s=setTimeout(u,e),d(a)}return s===void 0&&(s=setTimeout(u,e)),r}return y.cancel=L,y.flush=x,y}var PB=xyA;function FyA(t){var e=t==null?0:t.length;return e?t[e-1]:void 0}var ri=FyA;function NyA(t){return typeof t=="function"?t:Ig}var e5=NyA;function _yA(t,e){for(var A=t==null?0:t.length;A--&&e(t[A],A,t)!==!1;);return t}var VZ=_yA;var GyA=V8(!0),ZZ=GyA;function UyA(t,e){return t&&ZZ(t,e,bc)}var WZ=UyA;var KyA=W8(WZ,!0),XZ=KyA;function YyA(t,e){var A=Mn(t)?VZ:XZ;return A(t,e5(e))}var uS=YyA;function JyA(t){return t&&t.length?t[0]:void 0}var Mc=JyA;function TyA(t,e){var A=-1,i=vc(t)?Array(t.length):[];return X8(t,function(n,o,r){i[++A]=e(n,o,r)}),i}var t5=TyA;function zyA(t,e){var A=Mn(t)?O2:t5;return A(t,Cg(e,3))}var fS=zyA;var HyA=Object.prototype,OyA=HyA.hasOwnProperty,PyA=$8(function(t,e,A){OyA.call(t,A)?t[A].push(e):P2(t,A,[e])}),mS=PyA;function jyA(t){var e=t==null?0:t.length;return e?FV(t,0,-1):[]}var pi=jyA;var qyA="[object Map]",VyA="[object Set]",ZyA=Object.prototype,WyA=ZyA.hasOwnProperty;function XyA(t){if(t==null)return!0;if(vc(t)&&(Mn(t)||typeof t=="string"||typeof t.splice=="function"||y0(t)||xB(t)||Z2(t)))return!t.length;var e=cl(t);if(e==qyA||e==VyA)return!t.size;if(V2(t))return!L8(t).length;for(var A in t)if(WyA.call(t,A))return!1;return!0}var sn=XyA;function $yA(t,e){return OB(t,e)}var Ei=$yA;function A7A(t,e){return t<e}var $Z=A7A;function e7A(t,e){var A={};return e=Cg(e,3),Z8(t,function(i,n,o){P2(A,n,e(i,n,o))}),A}var pS=e7A;function t7A(t,e,A){for(var i=-1,n=t.length;++i<n;){var o=t[i],r=e(o);if(r!=null&&(s===void 0?r===r&&!Ac(r):A(r,s)))var s=r,a=o}return a}var AW=t7A;function i7A(t,e){return t&&t.length?AW(t,Cg(e,2),$Z):void 0}var jB=i7A;function n7A(t,e){var A=t.length;for(t.sort(e);A--;)t[A]=t[A].value;return t}var eW=n7A;function o7A(t,e){if(t!==e){var A=t!==void 0,i=t===null,n=t===t,o=Ac(t),r=e!==void 0,s=e===null,a=e===e,c=Ac(e);if(!s&&!c&&!o&&t>e||o&&r&&a&&!s&&!c||i&&r&&a||!A&&a||!n)return 1;if(!i&&!o&&!c&&t<e||c&&A&&n&&!i&&!o||s&&A&&n||!r&&n||!a)return-1}return 0}var tW=o7A;function r7A(t,e,A){for(var i=-1,n=t.criteria,o=e.criteria,r=n.length,s=A.length;++i<r;){var a=tW(n[i],o[i]);if(a){if(i>=s)return a;var c=A[i];return a*(c=="desc"?-1:1)}}return t.index-e.index}var iW=r7A;function s7A(t,e,A){e.length?e=O2(e,function(o){return Mn(o)?function(r){return KB(r,o.length===1?o[0]:o)}:o}):e=[Ig];var i=-1;e=O2(e,W2(Cg));var n=t5(t,function(o,r,s){var a=O2(e,function(c){return c(o)});return{criteria:a,index:++i,value:o}});return eW(n,function(o,r){return iW(o,r,A)})}var nW=s7A;var a7A=$8(function(t,e,A){t[A?0:1].push(e)},function(){return[[],[]]}),wS=a7A;var c7A=Math.ceil,l7A=Math.max;function g7A(t,e,A,i){for(var n=-1,o=l7A(c7A((e-t)/(A||1)),0),r=Array(o);o--;)r[i?o:++n]=t,t+=A;return r}var oW=g7A;function I7A(t){return function(e,A,i){return i&&typeof i!="number"&&Ku(e,A,i)&&(A=i=void 0),e=kB(e),A===void 0?(A=e,e=0):A=kB(A),i=i===void 0?e<A?1:-1:kB(i),oW(e,A,i,t)}}var rW=I7A;var C7A=rW(),i5=C7A;var d7A=Xq(function(t,e){if(t==null)return[];var A=e.length;return A>1&&Ku(t,e[0],e[1])?e=[]:A>2&&Ku(e[0],e[1],e[2])&&(e=[e[0]]),nW(t,xV(e,1),[])}),DS=d7A;var B7A=9007199254740991,yS=4294967295,E7A=Math.min;function h7A(t,e){if(t=_q(t),t<1||t>B7A)return[];var A=yS,i=E7A(t,yS);e=e5(e),t-=yS;for(var n=k8(i,e);++A<t;)e(A);return n}var vS=h7A;var Q7A=0;function u7A(t){var e=++Q7A;return x8(t)+e}var n1=u7A;var o1=t=>Array.isArray(t),f7A=t=>t!==null&&typeof t=="object"&&!o1(t),m7A=t=>typeof t=="string",qI=(t,e)=>t===e?!0:t!==null&&e!==null&&typeof t=="object"&&typeof e=="object"&&Object.keys(t).length===Object.keys(e).length&&Object.entries(t).every(([A,i])=>qI(i,e[A]));function lr(t){return(...e)=>{let A=e.map(o=>xr(o)),i=A[0],n=A[1];return A.length===1?o=>t(i(o)):A.length===2?o=>t(i(o),n(o)):o=>t(...A.map(r=>r(o)))}}var Ou={boolean:0,number:1,string:2},sW=3,cW=(t,e)=>typeof t==typeof e&&typeof t in Ou?t>e:!1,p7A=(t,e)=>qI(t,e)||cW(t,e),lW=(t,e)=>typeof t==typeof e&&typeof t in Ou?t<e:!1,w7A=(t,e)=>qI(t,e)||lW(t,e),Hu={pipe:(...t)=>{let e=t.map(A=>xr(A));return A=>e.reduce((i,n)=>n(i),A)},object:t=>{let e=Object.keys(t).map(A=>[A,xr(t[A])]);return A=>{let i={};for(let[n,o]of e)i[n]=o(A);return i}},array:(...t)=>{let e=t.map(A=>xr(A));return A=>e.map(i=>i(A))},get:(...t)=>{if(t.length===0)return e=>e??null;if(t.length===1){let e=t[0];return A=>A?.[e]??null}return e=>{let A=e;for(let i of t)A=A?.[i];return A??null}},map:t=>{let e=xr(t);return A=>A.map(e)},mapObject:t=>{let e=xr(t);return A=>{let i={};for(let n of Object.keys(A)){let o=e({key:n,value:A[n]});i[o.key]=o.value}return i}},mapKeys:t=>{let e=xr(t);return A=>{let i={};for(let n of Object.keys(A)){let o=e(n);i[o]=A[n]}return i}},mapValues:t=>{let e=xr(t);return A=>{let i={};for(let n of Object.keys(A))i[n]=e(A[n]);return i}},filter:t=>{let e=xr(t);return A=>A.filter(i=>aW(e(i)))},sort:(t=["get"],e)=>{let A=xr(t),i=e==="desc"?-1:1;function n(o,r){let s=A(o),a=A(r);if(typeof s!=typeof a){let c=Ou[typeof s]??sW,l=Ou[typeof a]??sW;return c>l?i:c<l?-i:0}return typeof s in Ou?s>a?i:s<a?-i:0:0}return o=>o.slice().sort(n)},reverse:()=>t=>t.toReversed(),pick:(...t)=>{let e=t.map(([i,...n])=>[n[n.length-1],Hu.get(...n)]),A=(i,n)=>{let o={};for(let[r,s]of n)o[r]=s(i);return o};return i=>o1(i)?i.map(n=>A(n,e)):A(i,e)},groupBy:t=>{let e=xr(t);return A=>{let i={};for(let n of A){let o=e(n);i[o]?i[o].push(n):i[o]=[n]}return i}},keyBy:t=>{let e=xr(t);return A=>{let i={};for(let n of A){let o=e(n);o in i||(i[o]=n)}return i}},flatten:()=>t=>t.flat(),join:(t="")=>e=>e.join(t),split:lr((t,e)=>e!==void 0?t.split(e):t.trim().split(/\s+/)),substring:lr((t,e,A)=>t.slice(Math.max(e,0),A)),uniq:()=>t=>{let e=[];for(let A of t)e.findIndex(i=>qI(i,A))===-1&&e.push(A);return e},uniqBy:t=>e=>Object.values(Hu.keyBy(t)(e)),limit:t=>e=>e.slice(0,Math.max(t,0)),size:()=>t=>t.length,keys:()=>Object.keys,values:()=>Object.values,prod:()=>t=>zu(t,(e,A)=>e*A),sum:()=>t=>o1(t)?t.reduce((e,A)=>e+A,0):bS(),average:()=>t=>o1(t)?t.length>0?t.reduce((e,A)=>e+A)/t.length:null:bS(),min:()=>t=>zu(t,(e,A)=>Math.min(e,A)),max:()=>t=>zu(t,(e,A)=>Math.max(e,A)),and:lr((...t)=>zu(t,(e,A)=>!!(e&&A))),or:lr((...t)=>zu(t,(e,A)=>!!(e||A))),not:lr(t=>!t),exists:t=>{let e=t.slice(1),A=e.pop(),i=Hu.get(...e);return n=>{let o=i(n);return!!o&&Object.hasOwnProperty.call(o,A)}},if:(t,e,A)=>{let i=xr(t),n=xr(e),o=xr(A);return r=>aW(i(r))?n(r):o(r)},in:(t,e)=>{let A=xr(t),i=xr(e);return n=>{let o=A(n);return i(n).findIndex(r=>qI(r,o))!==-1}},"not in":(t,e)=>{let A=Hu.in(t,e);return i=>!A(i)},regex:(t,e,A)=>{let i=new RegExp(e,A),n=xr(t);return o=>i.test(n(o))},eq:lr(qI),gt:lr(cW),gte:lr(p7A),lt:lr(lW),lte:lr(w7A),ne:lr((t,e)=>!qI(t,e)),add:lr((t,e)=>t+e),subtract:lr((t,e)=>t-e),multiply:lr((t,e)=>t*e),divide:lr((t,e)=>t/e),mod:lr((t,e)=>t%e),pow:lr((t,e)=>t**e),abs:lr(Math.abs),round:lr((t,e=0)=>+`${Math.round(+`${t}e${e}`)}e${-e}`),number:lr(t=>{let e=Number(t);return Number.isNaN(Number(t))?null:e}),string:lr(String)},aW=t=>t!==null&&t!==0&&t!==!1,zu=(t,e)=>(o1(t)||bS(),t.length===0?null:t.reduce(e)),bS=()=>{MS("Array expected")},MS=t=>{throw new TypeError(t)},n5=[];function xr(t,e){n5.unshift(nA(nA(nA({},Hu),n5[0]),e?.functions));try{let A=o1(t)?D7A(t,n5[0]):f7A(t)?MS(`Function notation ["object", {...}] expected but got ${JSON.stringify(t)}`):()=>t;return i=>{try{return A(i)}catch(n){throw n.jsonquery=[{data:i,query:t},...n.jsonquery??[]],n}}}finally{n5.shift()}}function D7A(t,e){let[A,...i]=t,n=e[A];return n||MS(`Unknown function '${A}'`),n(...i)}var gW=[{pow:"^"},{multiply:"*",divide:"/",mod:"%"},{add:"+",subtract:"-"},{gt:">",gte:">=",lt:"<",lte:"<=",in:"in","not in":"not in"},{eq:"==",ne:"!="},{and:"and"},{or:"or"},{pipe:"|"}],y7A=["|","and","or"],IW=["|","and","or","*","/","%","+","-"];function CW(t,e){if(!o1(e))throw new Error("Invalid custom operators");return e.reduce(v7A,t)}function v7A(t,{name:e,op:A,at:i,after:n,before:o}){if(i)return t.map(a=>Object.values(a).includes(i)?Ne(nA({},a),{[e]:A}):a);let r=n??o,s=t.findIndex(a=>Object.values(a).includes(r));if(s!==-1)return t.toSpliced(s+(n?1:0),0,{[e]:A});throw new Error("Invalid custom operator")}var b7A=/^[a-zA-Z_$][a-zA-Z\d_$]*$/,M7A=/^[a-zA-Z_$][a-zA-Z\d_$]*/,k7A=/^"(?:[^"\\]|\\.)*"/,S7A=/^-?(?:0|[1-9]\d*)(?:\.\d+)?(?:[eE][+-]?\d+)?/,R7A=/^(0|[1-9][0-9]*)/,L7A=/^(true|false|null)/,x7A=/^[ \n\t\r]+/;function kS(t,e){let A=e?.operators??[],i=CW(gW,A),n=Object.assign({},...i),o=y7A.concat(A.filter(K=>K.vararg).map(K=>K.op)),r=IW.concat(A.filter(K=>K.leftAssociative).map(K=>K.op)),s=(K=i.length-1)=>{let H=i[K];if(!H)return c();let j=t[T]==="(",IA=s(K-1);for(;;){y();let lA=T,uA=a(H);if(!uA)break;let p=s(K-1),V=IA[0],cA=uA===V&&!j;if(cA&&!r.includes(n[uA])){T=lA;break}IA=cA&&o.includes(n[uA])?[...IA,p]:[uA,IA,p]}return IA},a=K=>{let H=Object.keys(K).sort((j,IA)=>IA.length-j.length);for(let j of H){let IA=K[j];if(t.substring(T,T+IA.length)===IA)return T+=IA.length,y(),j}},c=()=>{if(y(),t[T]==="("){T++;let K=s();return F(")"),K}return l()},l=()=>{if(t[T]==="."){let K=[];for(;t[T]===".";)T++,K.push(B()??E()??u()??U("Property expected"));return["get",...K]}return I()},I=()=>{let K=T,H=E();if(y(),!H||t[T]!=="(")return T=K,C();T++,y();let j=t[T]!==")"?[s()]:[];for(;T<t.length&&t[T]!==")";)y(),F(","),j.push(s());return F(")"),[H,...j]},C=()=>{if(t[T]==="{"){T++,y();let K={},H=!0;for(;T<t.length&&t[T]!=="}";){H?H=!1:(F(","),y());let j=B()??E()??u()??U("Key expected");y(),F(":"),K[j]=s()}return F("}"),["object",K]}return d()},d=()=>{if(t[T]==="["){T++,y();let K=[],H=!0;for(;T<t.length&&t[T]!=="]";)H?H=!1:(F(","),y()),K.push(s());return F("]"),["array",...K]}return B()??Q()??v()},B=()=>x(k7A,JSON.parse),E=()=>x(M7A,K=>K),Q=()=>x(S7A,JSON.parse),u=()=>x(R7A,JSON.parse),v=()=>{let K=x(L7A,JSON.parse);if(K!==void 0)return K;U("Value expected")},L=()=>{y(),T<t.length&&U(`Unexpected part '${t.substring(T)}'`)},x=(K,H)=>{let j=t.substring(T).match(K);if(j)return T+=j[0].length,H(j[0])},y=()=>x(x7A,K=>K),F=K=>{t[T]!==K&&U(`Character '${K}' expected`),T++},U=(K,H=T)=>{throw new SyntaxError(`${K} (pos: ${H})`)},T=0,N=s();return L(),N}var F7A=40,N7A="  ",dW=(t,e)=>{let A=e?.indentation??N7A,i=e?.operators??[],n=CW(gW,i),o=Object.assign({},...n),r=IW.concat(i.filter(d=>d.leftAssociative).map(d=>d.op)),s=(d,B,E=!1)=>o1(d)?a(d,B,E):JSON.stringify(d),a=(d,B,E)=>{let[Q,...u]=d;if(Q==="get"&&u.length>0)return l(u);if(Q==="object")return c(u[0],B);if(Q==="array"){let y=u.map(F=>s(F,B));return C(y,["[",", ","]"],[`[
${B+A}`,`,
${B+A}`,`
${B}]`])}let v=o[Q];if(v){let y=E?"(":"",F=E?")":"",U=u.map((T,N)=>{let K=T?.[0],H=n.findIndex(lA=>Q in lA),j=n.findIndex(lA=>K in lA),IA=H<j||H===j&&N>0||Q===K&&!r.includes(v);return s(T,B+A,IA)});return C(U,[y,` ${v} `,F],[y,`
${B+A}${v} `,F])}let L=u.length===1?B:B+A,x=u.map(y=>s(y,L));return C(x,[`${Q}(`,", ",")"],u.length===1?[`${Q}(`,`,
${B}`,")"]:[`${Q}(
${L}`,`,
${L}`,`
${B})`])},c=(d,B)=>{let E=B+A,Q=Object.entries(d).map(([u,v])=>`${I(u)}: ${s(v,E)}`);return C(Q,["{ ",", "," }"],[`{
${E}`,`,
${E}`,`
${B}}`])},l=d=>d.map(B=>`.${I(B)}`).join(""),I=d=>b7A.test(d)?d:JSON.stringify(d),C=(d,[B,E,Q],[u,v,L])=>B.length+d.reduce((x,y)=>x+y.length+E.length,0)-E.length+Q.length<=(e?.maxLineLength??F7A)?B+d.join(E)+Q:u+d.join(v)+L;return s(t,"")};function BW(t,e,A){return xr(m7A(e)?kS(e,A):e,A)(t)}var EW={prefix:"far",iconName:"lightbulb",icon:[384,512,[128161],"f0eb","M297.2 248.9C311.6 228.3 320 203.2 320 176c0-70.7-57.3-128-128-128S64 105.3 64 176c0 27.2 8.4 52.3 22.8 72.9c3.7 5.3 8.1 11.3 12.8 17.7c0 0 0 0 0 0c12.9 17.7 28.3 38.9 39.8 59.8c10.4 19 15.7 38.8 18.3 57.5L109 384c-2.2-12-5.9-23.7-11.8-34.5c-9.9-18-22.2-34.9-34.5-51.8c0 0 0 0 0 0s0 0 0 0c-5.2-7.1-10.4-14.2-15.4-21.4C27.6 247.9 16 213.3 16 176C16 78.8 94.8 0 192 0s176 78.8 176 176c0 37.3-11.6 71.9-31.4 100.3c-5 7.2-10.2 14.3-15.4 21.4c0 0 0 0 0 0s0 0 0 0c-12.3 16.8-24.6 33.7-34.5 51.8c-5.9 10.8-9.6 22.5-11.8 34.5l-48.6 0c2.6-18.7 7.9-38.6 18.3-57.5c11.5-20.9 26.9-42.1 39.8-59.8c0 0 0 0 0 0s0 0 0 0s0 0 0 0c4.7-6.4 9-12.4 12.7-17.7zM192 128c-26.5 0-48 21.5-48 48c0 8.8-7.2 16-16 16s-16-7.2-16-16c0-44.2 35.8-80 80-80c8.8 0 16 7.2 16 16s-7.2 16-16 16zm0 384c-44.2 0-80-35.8-80-80l0-16 160 0 0 16c0 44.2-35.8 80-80 80z"]};var _7A={prefix:"far",iconName:"square-check",icon:[448,512,[9745,9989,61510,"check-square"],"f14a","M64 80c-8.8 0-16 7.2-16 16l0 320c0 8.8 7.2 16 16 16l320 0c8.8 0 16-7.2 16-16l0-320c0-8.8-7.2-16-16-16L64 80zM0 96C0 60.7 28.7 32 64 32l320 0c35.3 0 64 28.7 64 64l0 320c0 35.3-28.7 64-64 64L64 480c-35.3 0-64-28.7-64-64L0 96zM337 209L209 337c-9.4 9.4-24.6 9.4-33.9 0l-64-64c-9.4-9.4-9.4-24.6 0-33.9s24.6-9.4 33.9 0l47 47L303 175c9.4-9.4 24.6-9.4 33.9 0s9.4 24.6 0 33.9z"]},SS=_7A;var RS={prefix:"far",iconName:"square",icon:[448,512,[9632,9723,9724,61590],"f0c8","M384 80c8.8 0 16 7.2 16 16l0 320c0 8.8-7.2 16-16 16L64 432c-8.8 0-16-7.2-16-16L48 96c0-8.8 7.2-16 16-16l320 0zM64 32C28.7 32 0 60.7 0 96L0 416c0 35.3 28.7 64 64 64l320 0c35.3 0 64-28.7 64-64l0-320c0-35.3-28.7-64-64-64L64 32z"]};var hW={prefix:"far",iconName:"clock",icon:[512,512,[128339,"clock-four"],"f017","M464 256A208 208 0 1 1 48 256a208 208 0 1 1 416 0zM0 256a256 256 0 1 0 512 0A256 256 0 1 0 0 256zM232 120l0 136c0 8 4 15.5 10.7 20l96 64c11 7.4 25.9 4.4 33.3-6.7s4.4-25.9-6.7-33.3L280 243.2 280 120c0-13.3-10.7-24-24-24s-24 10.7-24 24z"]};var o5={prefix:"fas",iconName:"trash-can",icon:[448,512,[61460,"trash-alt"],"f2ed","M135.2 17.7C140.6 6.8 151.7 0 163.8 0L284.2 0c12.1 0 23.2 6.8 28.6 17.7L320 32l96 0c17.7 0 32 14.3 32 32s-14.3 32-32 32L32 96C14.3 96 0 81.7 0 64S14.3 32 32 32l96 0 7.2-14.3zM32 128l384 0 0 320c0 35.3-28.7 64-64 64L96 512c-35.3 0-64-28.7-64-64l0-320zm96 64c-8.8 0-16 7.2-16 16l0 224c0 8.8 7.2 16 16 16s16-7.2 16-16l0-224c0-8.8-7.2-16-16-16zm96 0c-8.8 0-16 7.2-16 16l0 224c0 8.8 7.2 16 16 16s16-7.2 16-16l0-224c0-8.8-7.2-16-16-16zm96 0c-8.8 0-16 7.2-16 16l0 224c0 8.8 7.2 16 16 16s16-7.2 16-16l0-224c0-8.8-7.2-16-16-16z"]};var QW={prefix:"fas",iconName:"down-left-and-up-right-to-center",icon:[512,512,["compress-alt"],"f422","M439 7c9.4-9.4 24.6-9.4 33.9 0l32 32c9.4 9.4 9.4 24.6 0 33.9l-87 87 39 39c6.9 6.9 8.9 17.2 5.2 26.2s-12.5 14.8-22.2 14.8l-144 0c-13.3 0-24-10.7-24-24l0-144c0-9.7 5.8-18.5 14.8-22.2s19.3-1.7 26.2 5.2l39 39L439 7zM72 272l144 0c13.3 0 24 10.7 24 24l0 144c0 9.7-5.8 18.5-14.8 22.2s-19.3 1.7-26.2-5.2l-39-39L73 505c-9.4 9.4-24.6 9.4-33.9 0L7 473c-9.4-9.4-9.4-24.6 0-33.9l87-87L55 313c-6.9-6.9-8.9-17.2-5.2-26.2s12.5-14.8 22.2-14.8z"]};var qB={prefix:"fas",iconName:"caret-right",icon:[256,512,[],"f0da","M246.6 278.6c12.5-12.5 12.5-32.8 0-45.3l-128-128c-9.2-9.2-22.9-11.9-34.9-6.9s-19.8 16.6-19.8 29.6l0 256c0 12.9 7.8 24.6 19.8 29.6s25.7 2.2 34.9-6.9l128-128z"]};var LS={prefix:"fas",iconName:"paste",icon:[512,512,["file-clipboard"],"f0ea","M160 0c-23.7 0-44.4 12.9-55.4 32L48 32C21.5 32 0 53.5 0 80L0 400c0 26.5 21.5 48 48 48l144 0 0-272c0-44.2 35.8-80 80-80l48 0 0-16c0-26.5-21.5-48-48-48l-56.6 0C204.4 12.9 183.7 0 160 0zM272 128c-26.5 0-48 21.5-48 48l0 272 0 16c0 26.5 21.5 48 48 48l192 0c26.5 0 48-21.5 48-48l0-220.1c0-12.7-5.1-24.9-14.1-33.9l-67.9-67.9c-9-9-21.2-14.1-33.9-14.1L320 128l-48 0zM160 40a24 24 0 1 1 0 48 24 24 0 1 1 0-48z"]};var uW={prefix:"fas",iconName:"circle-notch",icon:[512,512,[],"f1ce","M222.7 32.1c5 16.9-4.6 34.8-21.5 39.8C121.8 95.6 64 169.1 64 256c0 106 86 192 192 192s192-86 192-192c0-86.9-57.8-160.4-137.1-184.1c-16.9-5-26.6-22.9-21.5-39.8s22.9-26.6 39.8-21.5C434.9 42.1 512 140 512 256c0 141.4-114.6 256-256 256S0 397.4 0 256C0 140 77.1 42.1 182.9 10.6c16.9-5 34.8 4.6 39.8 21.5z"]};var G7A={prefix:"fas",iconName:"scissors",icon:[512,512,[9984,9986,9988,"cut"],"f0c4","M256 192l-39.5-39.5c4.9-12.6 7.5-26.2 7.5-40.5C224 50.1 173.9 0 112 0S0 50.1 0 112s50.1 112 112 112c14.3 0 27.9-2.7 40.5-7.5L192 256l-39.5 39.5c-12.6-4.9-26.2-7.5-40.5-7.5C50.1 288 0 338.1 0 400s50.1 112 112 112s112-50.1 112-112c0-14.3-2.7-27.9-7.5-40.5L499.2 76.8c7.1-7.1 7.1-18.5 0-25.6c-28.3-28.3-74.1-28.3-102.4 0L256 192zm22.6 150.6L396.8 460.8c28.3 28.3 74.1 28.3 102.4 0c7.1-7.1 7.1-18.5 0-25.6L342.6 278.6l-64 64zM64 112a48 48 0 1 1 96 0 48 48 0 1 1 -96 0zm48 240a48 48 0 1 1 0 96 48 48 0 1 1 0-96z"]},VI=G7A;var U7A={prefix:"fas",iconName:"square-caret-down",icon:[448,512,["caret-square-down"],"f150","M384 480c35.3 0 64-28.7 64-64l0-320c0-35.3-28.7-64-64-64L64 32C28.7 32 0 60.7 0 96L0 416c0 35.3 28.7 64 64 64l320 0zM224 352c-6.7 0-13-2.8-17.6-7.7l-104-112c-6.5-7-8.2-17.2-4.4-25.9s12.5-14.4 22-14.4l208 0c9.5 0 18.2 5.7 22 14.4s2.1 18.9-4.4 25.9l-104 112c-4.5 4.9-10.9 7.7-17.6 7.7z"]},fW=U7A;var mW={prefix:"fas",iconName:"caret-left",icon:[256,512,[],"f0d9","M9.4 278.6c-12.5-12.5-12.5-32.8 0-45.3l128-128c9.2-9.2 22.9-11.9 34.9-6.9s19.8 16.6 19.8 29.6l0 256c0 12.9-7.8 24.6-19.8 29.6s-25.7 2.2-34.9-6.9l-128-128z"]};var K7A={prefix:"fas",iconName:"square-check",icon:[448,512,[9745,9989,61510,"check-square"],"f14a","M64 32C28.7 32 0 60.7 0 96L0 416c0 35.3 28.7 64 64 64l320 0c35.3 0 64-28.7 64-64l0-320c0-35.3-28.7-64-64-64L64 32zM337 209L209 337c-9.4 9.4-24.6 9.4-33.9 0l-64-64c-9.4-9.4-9.4-24.6 0-33.9s24.6-9.4 33.9 0l47 47L303 175c9.4-9.4 24.6-9.4 33.9 0s9.4 24.6 0 33.9z"]},xS=K7A;var Y7A={prefix:"fas",iconName:"pen-to-square",icon:[512,512,["edit"],"f044","M471.6 21.7c-21.9-21.9-57.3-21.9-79.2 0L362.3 51.7l97.9 97.9 30.1-30.1c21.9-21.9 21.9-57.3 0-79.2L471.6 21.7zm-299.2 220c-6.1 6.1-10.8 13.6-13.5 21.9l-29.6 88.8c-2.9 8.6-.6 18.1 5.8 24.6s15.9 8.7 24.6 5.8l88.8-29.6c8.2-2.7 15.7-7.4 21.9-13.5L437.7 172.3 339.7 74.3 172.4 241.7zM96 64C43 64 0 107 0 160L0 416c0 53 43 96 96 96l256 0c53 0 96-43 96-96l0-96c0-17.7-14.3-32-32-32s-32 14.3-32 32l0 96c0 17.7-14.3 32-32 32L96 448c-17.7 0-32-14.3-32-32l0-256c0-17.7 14.3-32 32-32l96 0c17.7 0 32-14.3 32-32s-14.3-32-32-32L96 64z"]},pW=Y7A;var wW={prefix:"fas",iconName:"chevron-up",icon:[512,512,[],"f077","M233.4 105.4c12.5-12.5 32.8-12.5 45.3 0l192 192c12.5 12.5 12.5 32.8 0 45.3s-32.8 12.5-45.3 0L256 173.3 86.6 342.6c-12.5 12.5-32.8 12.5-45.3 0s-12.5-32.8 0-45.3l192-192z"]};var FS={prefix:"fas",iconName:"angle-right",icon:[320,512,[8250],"f105","M278.6 233.4c12.5 12.5 12.5 32.8 0 45.3l-160 160c-12.5 12.5-32.8 12.5-45.3 0s-12.5-32.8 0-45.3L210.7 256 73.4 118.6c-12.5-12.5-12.5-32.8 0-45.3s32.8-12.5 45.3 0l160 160z"]};var J7A={prefix:"fas",iconName:"square-caret-up",icon:[448,512,["caret-square-up"],"f151","M64 32C28.7 32 0 60.7 0 96L0 416c0 35.3 28.7 64 64 64l320 0c35.3 0 64-28.7 64-64l0-320c0-35.3-28.7-64-64-64L64 32zM224 160c6.7 0 13 2.8 17.6 7.7l104 112c6.5 7 8.2 17.2 4.4 25.9s-12.5 14.4-22 14.4l-208 0c-9.5 0-18.2-5.7-22-14.4s-2.1-18.9 4.4-25.9l104-112c4.5-4.9 10.9-7.7 17.6-7.7z"]},DW=J7A;var yW={prefix:"fas",iconName:"caret-up",icon:[320,512,[],"f0d8","M182.6 137.4c-12.5-12.5-32.8-12.5-45.3 0l-128 128c-9.2 9.2-11.9 22.9-6.9 34.9s16.6 19.8 29.6 19.8l256 0c12.9 0 24.6-7.8 29.6-19.8s2.2-25.7-6.9-34.9l-128-128z"]};var NS={prefix:"fas",iconName:"square",icon:[448,512,[9632,9723,9724,61590],"f0c8","M0 96C0 60.7 28.7 32 64 32H384c35.3 0 64 28.7 64 64V416c0 35.3-28.7 64-64 64H64c-35.3 0-64-28.7-64-64V96z"]};var Pu={prefix:"fas",iconName:"filter",icon:[512,512,[],"f0b0","M3.9 54.9C10.5 40.9 24.5 32 40 32l432 0c15.5 0 29.5 8.9 36.1 22.9s4.6 30.5-5.2 42.5L320 320.9 320 448c0 12.1-6.8 23.2-17.7 28.6s-23.8 4.3-33.5-3l-64-48c-8.1-6-12.8-15.5-12.8-25.6l0-79.1L9 97.3C-.7 85.4-2.8 68.8 3.9 54.9z"]};var ju={prefix:"fas",iconName:"code",icon:[640,512,[],"f121","M392.8 1.2c-17-4.9-34.7 5-39.6 22l-128 448c-4.9 17 5 34.7 22 39.6s34.7-5 39.6-22l128-448c4.9-17-5-34.7-22-39.6zm80.6 120.1c-12.5 12.5-12.5 32.8 0 45.3L562.7 256l-89.4 89.4c-12.5 12.5-12.5 32.8 0 45.3s32.8 12.5 45.3 0l112-112c12.5-12.5 12.5-32.8 0-45.3l-112-112c-12.5-12.5-32.8-12.5-45.3 0zm-306.7 0c-12.5-12.5-32.8-12.5-45.3 0l-112 112c-12.5 12.5-12.5 32.8 0 45.3l112 112c12.5 12.5 32.8 12.5 45.3 0s12.5-32.8 0-45.3L77.3 256l89.4-89.4c12.5-12.5 12.5-32.8 0-45.3z"]};var M0={prefix:"fas",iconName:"wrench",icon:[512,512,[128295],"f0ad","M352 320c88.4 0 160-71.6 160-160c0-15.3-2.2-30.1-6.2-44.2c-3.1-10.8-16.4-13.2-24.3-5.3l-76.8 76.8c-3 3-7.1 4.7-11.3 4.7L336 192c-8.8 0-16-7.2-16-16l0-57.4c0-4.2 1.7-8.3 4.7-11.3l76.8-76.8c7.9-7.9 5.4-21.2-5.3-24.3C382.1 2.2 367.3 0 352 0C263.6 0 192 71.6 192 160c0 19.1 3.4 37.5 9.5 54.5L19.9 396.1C7.2 408.8 0 426.1 0 444.1C0 481.6 30.4 512 67.9 512c18 0 35.3-7.2 48-19.9L297.5 310.5c17 6.2 35.4 9.5 54.5 9.5zM80 408a24 24 0 1 1 0 48 24 24 0 1 1 0-48z"]};var vW={prefix:"fas",iconName:"eye",icon:[576,512,[128065],"f06e","M288 32c-80.8 0-145.5 36.8-192.6 80.6C48.6 156 17.3 208 2.5 243.7c-3.3 7.9-3.3 16.7 0 24.6C17.3 304 48.6 356 95.4 399.4C142.5 443.2 207.2 480 288 480s145.5-36.8 192.6-80.6c46.8-43.5 78.1-95.4 93-131.1c3.3-7.9 3.3-16.7 0-24.6c-14.9-35.7-46.2-87.7-93-131.1C433.5 68.8 368.8 32 288 32zM144 256a144 144 0 1 1 288 0 144 144 0 1 1 -288 0zm144-64c0 35.3-28.7 64-64 64c-7.1 0-13.9-1.2-20.3-3.3c-5.5-1.8-11.9 1.6-11.7 7.4c.3 6.9 1.3 13.8 3.2 20.7c13.7 51.2 66.4 81.6 117.6 67.9s81.6-66.4 67.9-117.6c-11.1-41.5-47.8-69.4-88.6-71.1c-5.8-.2-9.2 6.1-7.4 11.7c2.1 6.4 3.3 13.2 3.3 20.3z"]};var ZI={prefix:"fas",iconName:"pen",icon:[512,512,[128394],"f304","M362.7 19.3L314.3 67.7 444.3 197.7l48.4-48.4c25-25 25-65.5 0-90.5L453.3 19.3c-25-25-65.5-25-90.5 0zm-71 71L58.6 323.5c-10.4 10.4-18 23.3-22.2 37.4L1 481.2C-1.5 489.7 .8 498.8 7 505s15.3 8.5 23.7 6.1l120.3-35.4c14.1-4.2 27-11.8 37.4-22.2L421.7 220.3 291.7 90.3z"]};var T7A={prefix:"fas",iconName:"arrow-rotate-right",icon:[512,512,[8635,"arrow-right-rotate","arrow-rotate-forward","redo"],"f01e","M386.3 160L336 160c-17.7 0-32 14.3-32 32s14.3 32 32 32l128 0c17.7 0 32-14.3 32-32l0-128c0-17.7-14.3-32-32-32s-32 14.3-32 32l0 51.2L414.4 97.6c-87.5-87.5-229.3-87.5-316.8 0s-87.5 229.3 0 316.8s229.3 87.5 316.8 0c12.5-12.5 12.5-32.8 0-45.3s-32.8-12.5-45.3 0c-62.5 62.5-163.8 62.5-226.3 0s-62.5-163.8 0-226.3s163.8-62.5 226.3 0L386.3 160z"]};var r5=T7A;var z7A={prefix:"fas",iconName:"arrow-rotate-left",icon:[512,512,[8634,"arrow-left-rotate","arrow-rotate-back","arrow-rotate-backward","undo"],"f0e2","M125.7 160l50.3 0c17.7 0 32 14.3 32 32s-14.3 32-32 32L48 224c-17.7 0-32-14.3-32-32L16 64c0-17.7 14.3-32 32-32s32 14.3 32 32l0 51.2L97.6 97.6c87.5-87.5 229.3-87.5 316.8 0s87.5 229.3 0 316.8s-229.3 87.5-316.8 0c-12.5-12.5-12.5-32.8 0-45.3s32.8-12.5 45.3 0c62.5 62.5 163.8 62.5 226.3 0s62.5-163.8 0-226.3s-163.8-62.5-226.3 0L125.7 160z"]};var s5=z7A;var H7A={prefix:"fas",iconName:"crop-simple",icon:[512,512,["crop-alt"],"f565","M128 32c0-17.7-14.3-32-32-32S64 14.3 64 32l0 32L32 64C14.3 64 0 78.3 0 96s14.3 32 32 32l32 0 0 256c0 35.3 28.7 64 64 64l224 0 0-64-224 0 0-352zM384 480c0 17.7 14.3 32 32 32s32-14.3 32-32l0-32 32 0c17.7 0 32-14.3 32-32s-14.3-32-32-32l-32 0 0-256c0-35.3-28.7-64-64-64L160 64l0 64 224 0 0 352z"]},bW=H7A;var O7A={prefix:"fas",iconName:"gear",icon:[512,512,[9881,"cog"],"f013","M495.9 166.6c3.2 8.7 .5 18.4-6.4 24.6l-43.3 39.4c1.1 8.3 1.7 16.8 1.7 25.4s-.6 17.1-1.7 25.4l43.3 39.4c6.9 6.2 9.6 15.9 6.4 24.6c-4.4 11.9-9.7 23.3-15.8 34.3l-4.7 8.1c-6.6 11-14 21.4-22.1 31.2c-5.9 7.2-15.7 9.6-24.5 6.8l-55.7-17.7c-13.4 10.3-28.2 18.9-44 25.4l-12.5 57.1c-2 9.1-9 16.3-18.2 17.8c-13.8 2.3-28 3.5-42.5 3.5s-28.7-1.2-42.5-3.5c-9.2-1.5-16.2-8.7-18.2-17.8l-12.5-57.1c-15.8-6.5-30.6-15.1-44-25.4L83.1 425.9c-8.8 2.8-18.6 .3-24.5-6.8c-8.1-9.8-15.5-20.2-22.1-31.2l-4.7-8.1c-6.1-11-11.4-22.4-15.8-34.3c-3.2-8.7-.5-18.4 6.4-24.6l43.3-39.4C64.6 273.1 64 264.6 64 256s.6-17.1 1.7-25.4L22.4 191.2c-6.9-6.2-9.6-15.9-6.4-24.6c4.4-11.9 9.7-23.3 15.8-34.3l4.7-8.1c6.6-11 14-21.4 22.1-31.2c5.9-7.2 15.7-9.6 24.5-6.8l55.7 17.7c13.4-10.3 28.2-18.9 44-25.4l12.5-57.1c2-9.1 9-16.3 18.2-17.8C227.3 1.2 241.5 0 256 0s28.7 1.2 42.5 3.5c9.2 1.5 16.2 8.7 18.2 17.8l12.5 57.1c15.8 6.5 30.6 15.1 44 25.4l55.7-17.7c8.8-2.8 18.6-.3 24.5 6.8c8.1 9.8 15.5 20.2 22.1 31.2l4.7 8.1c6.1 11 11.4 22.4 15.8 34.3zM256 336a80 80 0 1 0 0-160 80 80 0 1 0 0 160z"]},MW=O7A;var k0={prefix:"fas",iconName:"caret-down",icon:[320,512,[],"f0d7","M137.4 374.6c12.5 12.5 32.8 12.5 45.3 0l128-128c9.2-9.2 11.9-22.9 6.9-34.9s-16.6-19.8-29.6-19.8L32 192c-12.9 0-24.6 7.8-29.6 19.8s-2.2 25.7 6.9 34.9l128 128z"]};var P7A={prefix:"fas",iconName:"ellipsis-vertical",icon:[128,512,["ellipsis-v"],"f142","M64 360a56 56 0 1 0 0 112 56 56 0 1 0 0-112zm0-160a56 56 0 1 0 0 112 56 56 0 1 0 0-112zM120 96A56 56 0 1 0 8 96a56 56 0 1 0 112 0z"]},_S=P7A;var qu={prefix:"fas",iconName:"arrow-right-arrow-left",icon:[448,512,[8644,"exchange"],"f0ec","M438.6 150.6c12.5-12.5 12.5-32.8 0-45.3l-96-96c-12.5-12.5-32.8-12.5-45.3 0s-12.5 32.8 0 45.3L338.7 96 32 96C14.3 96 0 110.3 0 128s14.3 32 32 32l306.7 0-41.4 41.4c-12.5 12.5-12.5 32.8 0 45.3s32.8 12.5 45.3 0l96-96zm-333.3 352c12.5 12.5 32.8 12.5 45.3 0s12.5-32.8 0-45.3L109.3 416 416 416c17.7 0 32-14.3 32-32s-14.3-32-32-32l-306.7 0 41.4-41.4c12.5-12.5 12.5-32.8 0-45.3s-32.8-12.5-45.3 0l-96 96c-12.5 12.5-12.5 32.8 0 45.3l96 96z"]};var j7A={prefix:"fas",iconName:"arrow-down-short-wide",icon:[576,512,["sort-amount-desc","sort-amount-down-alt"],"f884","M151.6 469.6C145.5 476.2 137 480 128 480s-17.5-3.8-23.6-10.4l-88-96c-11.9-13-11.1-33.3 2-45.2s33.3-11.1 45.2 2L96 365.7 96 64c0-17.7 14.3-32 32-32s32 14.3 32 32l0 301.7 32.4-35.4c11.9-13 32.2-13.9 45.2-2s13.9 32.2 2 45.2l-88 96zM320 32l32 0c17.7 0 32 14.3 32 32s-14.3 32-32 32l-32 0c-17.7 0-32-14.3-32-32s14.3-32 32-32zm0 128l96 0c17.7 0 32 14.3 32 32s-14.3 32-32 32l-96 0c-17.7 0-32-14.3-32-32s14.3-32 32-32zm0 128l160 0c17.7 0 32 14.3 32 32s-14.3 32-32 32l-160 0c-17.7 0-32-14.3-32-32s14.3-32 32-32zm0 128l224 0c17.7 0 32 14.3 32 32s-14.3 32-32 32l-224 0c-17.7 0-32-14.3-32-32s14.3-32 32-32z"]};var Vu=j7A;var kW={prefix:"fas",iconName:"angle-down",icon:[448,512,[8964],"f107","M201.4 374.6c12.5 12.5 32.8 12.5 45.3 0l160-160c12.5-12.5 12.5-32.8 0-45.3s-32.8-12.5-45.3 0L224 306.7 86.6 169.4c-12.5-12.5-32.8-12.5-45.3 0s-12.5 32.8 0 45.3l160 160z"]};var GS={prefix:"fas",iconName:"arrow-down",icon:[384,512,[8595],"f063","M169.4 470.6c12.5 12.5 32.8 12.5 45.3 0l160-160c12.5-12.5 12.5-32.8 0-45.3s-32.8-12.5-45.3 0L224 370.8 224 64c0-17.7-14.3-32-32-32s-32 14.3-32 32l0 306.7L54.6 265.4c-12.5-12.5-32.8-12.5-45.3 0s-12.5 32.8 0 45.3l160 160z"]};var q7A={prefix:"fas",iconName:"magnifying-glass",icon:[512,512,[128269,"search"],"f002","M416 208c0 45.9-14.9 88.3-40 122.7L502.6 457.4c12.5 12.5 12.5 32.8 0 45.3s-32.8 12.5-45.3 0L330.7 376c-34.4 25.2-76.8 40-122.7 40C93.1 416 0 322.9 0 208S93.1 0 208 0S416 93.1 416 208zM208 352a144 144 0 1 0 0-288 144 144 0 1 0 0 288z"]},Zu=q7A;var SW={prefix:"fas",iconName:"chevron-down",icon:[512,512,[],"f078","M233.4 406.6c12.5 12.5 32.8 12.5 45.3 0l192-192c12.5-12.5 12.5-32.8 0-45.3s-32.8-12.5-45.3 0L256 338.7 86.6 169.4c-12.5-12.5-32.8-12.5-45.3 0s-12.5 32.8 0 45.3l192 192z"]};var S0={prefix:"fas",iconName:"copy",icon:[448,512,[],"f0c5","M208 0L332.1 0c12.7 0 24.9 5.1 33.9 14.1l67.9 67.9c9 9 14.1 21.2 14.1 33.9L448 336c0 26.5-21.5 48-48 48l-192 0c-26.5 0-48-21.5-48-48l0-288c0-26.5 21.5-48 48-48zM48 128l80 0 0 64-64 0 0 256 192 0 0-32 64 0 0 48c0 26.5-21.5 48-48 48L48 512c-26.5 0-48-21.5-48-48L0 176c0-26.5 21.5-48 48-48z"]};var WI={prefix:"fas",iconName:"plus",icon:[448,512,[10133,61543,"add"],"2b","M256 80c0-17.7-14.3-32-32-32s-32 14.3-32 32l0 144L48 224c-17.7 0-32 14.3-32 32s14.3 32 32 32l144 0 0 144c0 17.7 14.3 32 32 32s32-14.3 32-32l0-144 144 0c17.7 0 32-14.3 32-32s-14.3-32-32-32l-144 0 0-144z"]};var RW={prefix:"fas",iconName:"xmark",icon:[384,512,[128473,10005,10006,10060,215,"close","multiply","remove","times"],"f00d","M342.6 150.6c12.5-12.5 12.5-32.8 0-45.3s-32.8-12.5-45.3 0L192 210.7 86.6 105.4c-12.5-12.5-32.8-12.5-45.3 0s-12.5 32.8 0 45.3L146.7 256 41.4 361.4c-12.5 12.5-12.5 32.8 0 45.3s32.8 12.5 45.3 0L192 301.3 297.4 406.6c12.5 12.5 32.8 12.5 45.3 0s12.5-32.8 0-45.3L237.3 256 342.6 150.6z"]},LW=RW;var Wu=RW;var xW={prefix:"fas",iconName:"rotate",icon:[512,512,[128260,"sync-alt"],"f2f1","M142.9 142.9c-17.5 17.5-30.1 38-37.8 59.8c-5.9 16.7-24.2 25.4-40.8 19.5s-25.4-24.2-19.5-40.8C55.6 150.7 73.2 122 97.6 97.6c87.2-87.2 228.3-87.5 315.8-1L455 55c6.9-6.9 17.2-8.9 26.2-5.2s14.8 12.5 14.8 22.2l0 128c0 13.3-10.7 24-24 24l-8.4 0c0 0 0 0 0 0L344 224c-9.7 0-18.5-5.8-22.2-14.8s-1.7-19.3 5.2-26.2l41.1-41.1c-62.6-61.5-163.1-61.2-225.3 1zM16 312c0-13.3 10.7-24 24-24l7.6 0 .7 0L168 288c9.7 0 18.5 5.8 22.2 14.8s1.7 19.3-5.2 26.2l-41.1 41.1c62.6 61.5 163.1 61.2 225.3-1c17.5-17.5 30.1-38 37.8-59.8c5.9-16.7 24.2-25.4 40.8-19.5s25.4 24.2 19.5 40.8c-10.8 30.6-28.4 59.3-52.9 83.8c-87.2 87.2-228.3 87.5-315.8 1L57 457c-6.9 6.9-17.2 8.9-26.2 5.2S16 449.7 16 440l0-119.6 0-.7 0-7.6z"]};var FW={prefix:"fas",iconName:"up-right-and-down-left-from-center",icon:[512,512,["expand-alt"],"f424","M344 0L488 0c13.3 0 24 10.7 24 24l0 144c0 9.7-5.8 18.5-14.8 22.2s-19.3 1.7-26.2-5.2l-39-39-87 87c-9.4 9.4-24.6 9.4-33.9 0l-32-32c-9.4-9.4-9.4-24.6 0-33.9l87-87L327 41c-6.9-6.9-8.9-17.2-5.2-26.2S334.3 0 344 0zM168 512L24 512c-13.3 0-24-10.7-24-24L0 344c0-9.7 5.8-18.5 14.8-22.2s19.3-1.7 26.2 5.2l39 39 87-87c9.4-9.4 24.6-9.4 33.9 0l32 32c9.4 9.4 9.4 24.6 0 33.9l-87 87 39 39c6.9 6.9 8.9 17.2 5.2 26.2s-12.5 14.8-22.2 14.8z"]};var US={prefix:"fas",iconName:"clone",icon:[512,512,[],"f24d","M288 448L64 448l0-224 64 0 0-64-64 0c-35.3 0-64 28.7-64 64L0 448c0 35.3 28.7 64 64 64l224 0c35.3 0 64-28.7 64-64l0-64-64 0 0 64zm-64-96l224 0c35.3 0 64-28.7 64-64l0-224c0-35.3-28.7-64-64-64L224 0c-35.3 0-64 28.7-64 64l0 224c0 35.3 28.7 64 64 64z"]};var a5={prefix:"fas",iconName:"check",icon:[448,512,[10003,10004],"f00c","M438.6 105.4c12.5 12.5 12.5 32.8 0 45.3l-256 256c-12.5 12.5-32.8 12.5-45.3 0l-128-128c-12.5-12.5-12.5-32.8 0-45.3s32.8-12.5 45.3 0L160 338.7 393.4 105.4c12.5-12.5 32.8-12.5 45.3 0z"]};var V7A={prefix:"fas",iconName:"triangle-exclamation",icon:[512,512,[9888,"exclamation-triangle","warning"],"f071","M256 32c14.2 0 27.3 7.5 34.5 19.8l216 368c7.3 12.4 7.3 27.7 .2 40.1S486.3 480 472 480L40 480c-14.3 0-27.6-7.7-34.7-20.1s-7-27.8 .2-40.1l216-368C228.7 39.5 241.8 32 256 32zm0 128c-13.3 0-24 10.7-24 24l0 112c0 13.3 10.7 24 24 24s24-10.7 24-24l0-112c0-13.3-10.7-24-24-24zm32 224a32 32 0 1 0 -64 0 32 32 0 1 0 64 0z"]},r1=V7A;var mrA=xh(GW(),1);var UW=Number.isNaN||function(e){return typeof e=="number"&&e!==e};function Z7A(t,e){return!!(t===e||UW(t)&&UW(e))}function W7A(t,e){if(t.length!==e.length)return!1;for(var A=0;A<t.length;A++)if(!Z7A(t[A],e[A]))return!1;return!0}function VB(t,e){e===void 0&&(e=W7A);var A=null;function i(){for(var n=[],o=0;o<arguments.length;o++)n[o]=arguments[o];if(A&&A.lastThis===this&&e(n,A.lastArgs))return A.lastResult;var r=t.apply(this,n);return A={lastResult:r,lastArgs:n,lastThis:this},r}return i.clear=function(){A=null},i}var a_A=xh(mAA(),1),c_A=xh(pAA(),1);var DL=class{add(e,A,i){if(typeof arguments[0]!="string")for(let n in arguments[0])this.add(n,arguments[0][n],arguments[1]);else(Array.isArray(e)?e:[e]).forEach(function(n){this[n]=this[n]||[],A&&this[n][i?"unshift":"push"](A)},this)}run(e,A){this[e]=this[e]||[],this[e].forEach(function(i){i.call(A&&A.context?A.context:A,A)})}},yL=class{constructor(e){this.jsep=e,this.registered={}}register(){for(var e=arguments.length,A=new Array(e),i=0;i<e;i++)A[i]=arguments[i];A.forEach(n=>{if(typeof n!="object"||!n.name||!n.init)throw new Error("Invalid JSEP plugin format");this.registered[n.name]||(n.init(this.jsep),this.registered[n.name]=n)})}},pa=class t{static get version(){return"1.4.0"}static toString(){return"JavaScript Expression Parser (JSEP) v"+t.version}static addUnaryOp(e){return t.max_unop_len=Math.max(e.length,t.max_unop_len),t.unary_ops[e]=1,t}static addBinaryOp(e,A,i){return t.max_binop_len=Math.max(e.length,t.max_binop_len),t.binary_ops[e]=A,i?t.right_associative.add(e):t.right_associative.delete(e),t}static addIdentifierChar(e){return t.additional_identifier_chars.add(e),t}static addLiteral(e,A){return t.literals[e]=A,t}static removeUnaryOp(e){return delete t.unary_ops[e],e.length===t.max_unop_len&&(t.max_unop_len=t.getMaxKeyLen(t.unary_ops)),t}static removeAllUnaryOps(){return t.unary_ops={},t.max_unop_len=0,t}static removeIdentifierChar(e){return t.additional_identifier_chars.delete(e),t}static removeBinaryOp(e){return delete t.binary_ops[e],e.length===t.max_binop_len&&(t.max_binop_len=t.getMaxKeyLen(t.binary_ops)),t.right_associative.delete(e),t}static removeAllBinaryOps(){return t.binary_ops={},t.max_binop_len=0,t}static removeLiteral(e){return delete t.literals[e],t}static removeAllLiterals(){return t.literals={},t}get char(){return this.expr.charAt(this.index)}get code(){return this.expr.charCodeAt(this.index)}constructor(e){this.expr=e,this.index=0}static parse(e){return new t(e).parse()}static getMaxKeyLen(e){return Math.max(0,...Object.keys(e).map(A=>A.length))}static isDecimalDigit(e){return e>=48&&e<=57}static binaryPrecedence(e){return t.binary_ops[e]||0}static isIdentifierStart(e){return e>=65&&e<=90||e>=97&&e<=122||e>=128&&!t.binary_ops[String.fromCharCode(e)]||t.additional_identifier_chars.has(String.fromCharCode(e))}static isIdentifierPart(e){return t.isIdentifierStart(e)||t.isDecimalDigit(e)}throwError(e){let A=new Error(e+" at character "+this.index);throw A.index=this.index,A.description=e,A}runHook(e,A){if(t.hooks[e]){let i={context:this,node:A};return t.hooks.run(e,i),i.node}return A}searchHook(e){if(t.hooks[e]){let A={context:this};return t.hooks[e].find(function(i){return i.call(A.context,A),A.node}),A.node}}gobbleSpaces(){let e=this.code;for(;e===t.SPACE_CODE||e===t.TAB_CODE||e===t.LF_CODE||e===t.CR_CODE;)e=this.expr.charCodeAt(++this.index);this.runHook("gobble-spaces")}parse(){this.runHook("before-all");let e=this.gobbleExpressions(),A=e.length===1?e[0]:{type:t.COMPOUND,body:e};return this.runHook("after-all",A)}gobbleExpressions(e){let A=[],i,n;for(;this.index<this.expr.length;)if(i=this.code,i===t.SEMCOL_CODE||i===t.COMMA_CODE)this.index++;else if(n=this.gobbleExpression())A.push(n);else if(this.index<this.expr.length){if(i===e)break;this.throwError('Unexpected "'+this.char+'"')}return A}gobbleExpression(){let e=this.searchHook("gobble-expression")||this.gobbleBinaryExpression();return this.gobbleSpaces(),this.runHook("after-expression",e)}gobbleBinaryOp(){this.gobbleSpaces();let e=this.expr.substr(this.index,t.max_binop_len),A=e.length;for(;A>0;){if(t.binary_ops.hasOwnProperty(e)&&(!t.isIdentifierStart(this.code)||this.index+e.length<this.expr.length&&!t.isIdentifierPart(this.expr.charCodeAt(this.index+e.length))))return this.index+=A,e;e=e.substr(0,--A)}return!1}gobbleBinaryExpression(){let e,A,i,n,o,r,s,a,c;if(r=this.gobbleToken(),!r||(A=this.gobbleBinaryOp(),!A))return r;for(o={value:A,prec:t.binaryPrecedence(A),right_a:t.right_associative.has(A)},s=this.gobbleToken(),s||this.throwError("Expected expression after "+A),n=[r,o,s];A=this.gobbleBinaryOp();){if(i=t.binaryPrecedence(A),i===0){this.index-=A.length;break}o={value:A,prec:i,right_a:t.right_associative.has(A)},c=A;let l=I=>o.right_a&&I.right_a?i>I.prec:i<=I.prec;for(;n.length>2&&l(n[n.length-2]);)s=n.pop(),A=n.pop().value,r=n.pop(),e={type:t.BINARY_EXP,operator:A,left:r,right:s},n.push(e);e=this.gobbleToken(),e||this.throwError("Expected expression after "+c),n.push(o,e)}for(a=n.length-1,e=n[a];a>1;)e={type:t.BINARY_EXP,operator:n[a-1].value,left:n[a-2],right:e},a-=2;return e}gobbleToken(){let e,A,i,n;if(this.gobbleSpaces(),n=this.searchHook("gobble-token"),n)return this.runHook("after-token",n);if(e=this.code,t.isDecimalDigit(e)||e===t.PERIOD_CODE)return this.gobbleNumericLiteral();if(e===t.SQUOTE_CODE||e===t.DQUOTE_CODE)n=this.gobbleStringLiteral();else if(e===t.OBRACK_CODE)n=this.gobbleArray();else{for(A=this.expr.substr(this.index,t.max_unop_len),i=A.length;i>0;){if(t.unary_ops.hasOwnProperty(A)&&(!t.isIdentifierStart(this.code)||this.index+A.length<this.expr.length&&!t.isIdentifierPart(this.expr.charCodeAt(this.index+A.length)))){this.index+=i;let o=this.gobbleToken();return o||this.throwError("missing unaryOp argument"),this.runHook("after-token",{type:t.UNARY_EXP,operator:A,argument:o,prefix:!0})}A=A.substr(0,--i)}t.isIdentifierStart(e)?(n=this.gobbleIdentifier(),t.literals.hasOwnProperty(n.name)?n={type:t.LITERAL,value:t.literals[n.name],raw:n.name}:n.name===t.this_str&&(n={type:t.THIS_EXP})):e===t.OPAREN_CODE&&(n=this.gobbleGroup())}return n?(n=this.gobbleTokenProperty(n),this.runHook("after-token",n)):this.runHook("after-token",!1)}gobbleTokenProperty(e){this.gobbleSpaces();let A=this.code;for(;A===t.PERIOD_CODE||A===t.OBRACK_CODE||A===t.OPAREN_CODE||A===t.QUMARK_CODE;){let i;if(A===t.QUMARK_CODE){if(this.expr.charCodeAt(this.index+1)!==t.PERIOD_CODE)break;i=!0,this.index+=2,this.gobbleSpaces(),A=this.code}this.index++,A===t.OBRACK_CODE?(e={type:t.MEMBER_EXP,computed:!0,object:e,property:this.gobbleExpression()},e.property||this.throwError('Unexpected "'+this.char+'"'),this.gobbleSpaces(),A=this.code,A!==t.CBRACK_CODE&&this.throwError("Unclosed ["),this.index++):A===t.OPAREN_CODE?e={type:t.CALL_EXP,arguments:this.gobbleArguments(t.CPAREN_CODE),callee:e}:(A===t.PERIOD_CODE||i)&&(i&&this.index--,this.gobbleSpaces(),e={type:t.MEMBER_EXP,computed:!1,object:e,property:this.gobbleIdentifier()}),i&&(e.optional=!0),this.gobbleSpaces(),A=this.code}return e}gobbleNumericLiteral(){let e="",A,i;for(;t.isDecimalDigit(this.code);)e+=this.expr.charAt(this.index++);if(this.code===t.PERIOD_CODE)for(e+=this.expr.charAt(this.index++);t.isDecimalDigit(this.code);)e+=this.expr.charAt(this.index++);if(A=this.char,A==="e"||A==="E"){for(e+=this.expr.charAt(this.index++),A=this.char,(A==="+"||A==="-")&&(e+=this.expr.charAt(this.index++));t.isDecimalDigit(this.code);)e+=this.expr.charAt(this.index++);t.isDecimalDigit(this.expr.charCodeAt(this.index-1))||this.throwError("Expected exponent ("+e+this.char+")")}return i=this.code,t.isIdentifierStart(i)?this.throwError("Variable names cannot start with a number ("+e+this.char+")"):(i===t.PERIOD_CODE||e.length===1&&e.charCodeAt(0)===t.PERIOD_CODE)&&this.throwError("Unexpected period"),{type:t.LITERAL,value:parseFloat(e),raw:e}}gobbleStringLiteral(){let e="",A=this.index,i=this.expr.charAt(this.index++),n=!1;for(;this.index<this.expr.length;){let o=this.expr.charAt(this.index++);if(o===i){n=!0;break}else if(o==="\\")switch(o=this.expr.charAt(this.index++),o){case"n":e+=`
`;break;case"r":e+="\r";break;case"t":e+="	";break;case"b":e+="\b";break;case"f":e+="\f";break;case"v":e+="\v";break;default:e+=o}else e+=o}return n||this.throwError('Unclosed quote after "'+e+'"'),{type:t.LITERAL,value:e,raw:this.expr.substring(A,this.index)}}gobbleIdentifier(){let e=this.code,A=this.index;for(t.isIdentifierStart(e)?this.index++:this.throwError("Unexpected "+this.char);this.index<this.expr.length&&(e=this.code,t.isIdentifierPart(e));)this.index++;return{type:t.IDENTIFIER,name:this.expr.slice(A,this.index)}}gobbleArguments(e){let A=[],i=!1,n=0;for(;this.index<this.expr.length;){this.gobbleSpaces();let o=this.code;if(o===e){i=!0,this.index++,e===t.CPAREN_CODE&&n&&n>=A.length&&this.throwError("Unexpected token "+String.fromCharCode(e));break}else if(o===t.COMMA_CODE){if(this.index++,n++,n!==A.length){if(e===t.CPAREN_CODE)this.throwError("Unexpected token ,");else if(e===t.CBRACK_CODE)for(let r=A.length;r<n;r++)A.push(null)}}else if(A.length!==n&&n!==0)this.throwError("Expected comma");else{let r=this.gobbleExpression();(!r||r.type===t.COMPOUND)&&this.throwError("Expected comma"),A.push(r)}}return i||this.throwError("Expected "+String.fromCharCode(e)),A}gobbleGroup(){this.index++;let e=this.gobbleExpressions(t.CPAREN_CODE);if(this.code===t.CPAREN_CODE)return this.index++,e.length===1?e[0]:e.length?{type:t.SEQUENCE_EXP,expressions:e}:!1;this.throwError("Unclosed (")}gobbleArray(){return this.index++,{type:t.ARRAY_EXP,elements:this.gobbleArguments(t.CBRACK_CODE)}}},pSA=new DL;Object.assign(pa,{hooks:pSA,plugins:new yL(pa),COMPOUND:"Compound",SEQUENCE_EXP:"SequenceExpression",IDENTIFIER:"Identifier",MEMBER_EXP:"MemberExpression",LITERAL:"Literal",THIS_EXP:"ThisExpression",CALL_EXP:"CallExpression",UNARY_EXP:"UnaryExpression",BINARY_EXP:"BinaryExpression",ARRAY_EXP:"ArrayExpression",TAB_CODE:9,LF_CODE:10,CR_CODE:13,SPACE_CODE:32,PERIOD_CODE:46,COMMA_CODE:44,SQUOTE_CODE:39,DQUOTE_CODE:34,OPAREN_CODE:40,CPAREN_CODE:41,OBRACK_CODE:91,CBRACK_CODE:93,QUMARK_CODE:63,SEMCOL_CODE:59,COLON_CODE:58,unary_ops:{"-":1,"!":1,"~":1,"+":1},binary_ops:{"||":1,"??":1,"&&":2,"|":3,"^":4,"&":5,"==":6,"!=":6,"===":6,"!==":6,"<":7,">":7,"<=":7,">=":7,"<<":8,">>":8,">>>":8,"+":9,"-":9,"*":10,"/":10,"%":10,"**":11},right_associative:new Set(["**"]),additional_identifier_chars:new Set(["$","_"]),literals:{true:!0,false:!1,null:null},this_str:"this"});pa.max_unop_len=pa.getMaxKeyLen(pa.unary_ops);pa.max_binop_len=pa.getMaxKeyLen(pa.binary_ops);var _0=t=>new pa(t).parse(),wSA=Object.getOwnPropertyNames(class{});Object.getOwnPropertyNames(pa).filter(t=>!wSA.includes(t)&&_0[t]===void 0).forEach(t=>{_0[t]=pa[t]});_0.Jsep=pa;var DSA="ConditionalExpression",ySA={name:"ternary",init(t){t.hooks.add("after-expression",function(A){if(A.node&&this.code===t.QUMARK_CODE){this.index++;let i=A.node,n=this.gobbleExpression();if(n||this.throwError("Expected expression"),this.gobbleSpaces(),this.code===t.COLON_CODE){this.index++;let o=this.gobbleExpression();if(o||this.throwError("Expected expression"),A.node={type:DSA,test:i,consequent:n,alternate:o},i.operator&&t.binary_ops[i.operator]<=.9){let r=i;for(;r.right.operator&&t.binary_ops[r.right.operator]<=.9;)r=r.right;A.node.test=r.right,r.right=A.node,A.node=i}}else this.throwError("Expected :")}})}};_0.plugins.register(ySA);var wAA=47,vSA=92,bSA={name:"regex",init(t){t.hooks.add("gobble-token",function(A){if(this.code===wAA){let i=++this.index,n=!1;for(;this.index<this.expr.length;){if(this.code===wAA&&!n){let o=this.expr.slice(i,this.index),r="";for(;++this.index<this.expr.length;){let a=this.code;if(a>=97&&a<=122||a>=65&&a<=90||a>=48&&a<=57)r+=this.char;else break}let s;try{s=new RegExp(o,r)}catch(a){this.throwError(a.message)}return A.node={type:t.LITERAL,value:s,raw:this.expr.slice(i-1,this.index)},A.node=this.gobbleTokenProperty(A.node),A.node}this.code===t.OBRACK_CODE?n=!0:n&&this.code===t.CBRACK_CODE&&(n=!1),this.index+=this.code===vSA?2:1}this.throwError("Unclosed Regex")}})}},wL=43,MSA=45,cE={name:"assignment",assignmentOperators:new Set(["=","*=","**=","/=","%=","+=","-=","<<=",">>=",">>>=","&=","^=","|=","||=","&&=","??="]),updateOperators:[wL,MSA],assignmentPrecedence:.9,init(t){let e=[t.IDENTIFIER,t.MEMBER_EXP];cE.assignmentOperators.forEach(i=>t.addBinaryOp(i,cE.assignmentPrecedence,!0)),t.hooks.add("gobble-token",function(n){let o=this.code;cE.updateOperators.some(r=>r===o&&r===this.expr.charCodeAt(this.index+1))&&(this.index+=2,n.node={type:"UpdateExpression",operator:o===wL?"++":"--",argument:this.gobbleTokenProperty(this.gobbleIdentifier()),prefix:!0},(!n.node.argument||!e.includes(n.node.argument.type))&&this.throwError(`Unexpected ${n.node.operator}`))}),t.hooks.add("after-token",function(n){if(n.node){let o=this.code;cE.updateOperators.some(r=>r===o&&r===this.expr.charCodeAt(this.index+1))&&(e.includes(n.node.type)||this.throwError(`Unexpected ${n.node.operator}`),this.index+=2,n.node={type:"UpdateExpression",operator:o===wL?"++":"--",argument:n.node,prefix:!1})}}),t.hooks.add("after-expression",function(n){n.node&&A(n.node)});function A(i){cE.assignmentOperators.has(i.operator)?(i.type="AssignmentExpression",A(i.left),A(i.right)):i.operator||Object.values(i).forEach(n=>{n&&typeof n=="object"&&A(n)})}}};_0.plugins.register(bSA,cE);_0.addUnaryOp("typeof");_0.addLiteral("null",null);_0.addLiteral("undefined",void 0);var kSA=new Set(["constructor","__proto__","__defineGetter__","__defineSetter__"]),qn={evalAst(t,e){switch(t.type){case"BinaryExpression":case"LogicalExpression":return qn.evalBinaryExpression(t,e);case"Compound":return qn.evalCompound(t,e);case"ConditionalExpression":return qn.evalConditionalExpression(t,e);case"Identifier":return qn.evalIdentifier(t,e);case"Literal":return qn.evalLiteral(t,e);case"MemberExpression":return qn.evalMemberExpression(t,e);case"UnaryExpression":return qn.evalUnaryExpression(t,e);case"ArrayExpression":return qn.evalArrayExpression(t,e);case"CallExpression":return qn.evalCallExpression(t,e);case"AssignmentExpression":return qn.evalAssignmentExpression(t,e);default:throw SyntaxError("Unexpected expression",t)}},evalBinaryExpression(t,e){return{"||":(i,n)=>i||n(),"&&":(i,n)=>i&&n(),"|":(i,n)=>i|n(),"^":(i,n)=>i^n(),"&":(i,n)=>i&n(),"==":(i,n)=>i==n(),"!=":(i,n)=>i!=n(),"===":(i,n)=>i===n(),"!==":(i,n)=>i!==n(),"<":(i,n)=>i<n(),">":(i,n)=>i>n(),"<=":(i,n)=>i<=n(),">=":(i,n)=>i>=n(),"<<":(i,n)=>i<<n(),">>":(i,n)=>i>>n(),">>>":(i,n)=>i>>>n(),"+":(i,n)=>i+n(),"-":(i,n)=>i-n(),"*":(i,n)=>i*n(),"/":(i,n)=>i/n(),"%":(i,n)=>i%n()}[t.operator](qn.evalAst(t.left,e),()=>qn.evalAst(t.right,e))},evalCompound(t,e){let A;for(let i=0;i<t.body.length;i++){t.body[i].type==="Identifier"&&["var","let","const"].includes(t.body[i].name)&&t.body[i+1]&&t.body[i+1].type==="AssignmentExpression"&&(i+=1);let n=t.body[i];A=qn.evalAst(n,e)}return A},evalConditionalExpression(t,e){return qn.evalAst(t.test,e)?qn.evalAst(t.consequent,e):qn.evalAst(t.alternate,e)},evalIdentifier(t,e){if(Object.hasOwn(e,t.name))return e[t.name];throw ReferenceError(`${t.name} is not defined`)},evalLiteral(t){return t.value},evalMemberExpression(t,e){let A=String(t.computed?qn.evalAst(t.property):t.property.name),i=qn.evalAst(t.object,e);if(i==null)throw TypeError(`Cannot read properties of ${i} (reading '${A}')`);if(!Object.hasOwn(i,A)&&kSA.has(A))throw TypeError(`Cannot read properties of ${i} (reading '${A}')`);let n=i[A];return typeof n=="function"?n.bind(i):n},evalUnaryExpression(t,e){return{"-":i=>-qn.evalAst(i,e),"!":i=>!qn.evalAst(i,e),"~":i=>~qn.evalAst(i,e),"+":i=>+qn.evalAst(i,e),typeof:i=>typeof qn.evalAst(i,e)}[t.operator](t.argument)},evalArrayExpression(t,e){return t.elements.map(A=>qn.evalAst(A,e))},evalCallExpression(t,e){let A=t.arguments.map(n=>qn.evalAst(n,e));return qn.evalAst(t.callee,e)(...A)},evalAssignmentExpression(t,e){if(t.left.type!=="Identifier")throw SyntaxError("Invalid left-hand side in assignment");let A=t.left.name,i=qn.evalAst(t.right,e);return e[A]=i,e[A]}},vL=class{constructor(e){this.code=e,this.ast=_0(this.code)}runInNewContext(e){let A=Object.assign(Object.create(null),e);return qn.evalAst(this.ast,A)}};function d1(t,e){return t=t.slice(),t.push(e),t}function bL(t,e){return e=e.slice(),e.unshift(t),e}var ML=class extends Error{constructor(e){super('JSONPath should not be called with "new" (it prevents return of (unwrapped) scalar values)'),this.avoidNew=!0,this.value=e,this.name="NewError"}};function pn(t,e,A,i,n){if(!(this instanceof pn))try{return new pn(t,e,A,i,n)}catch(r){if(!r.avoidNew)throw r;return r.value}typeof t=="string"&&(n=i,i=A,A=e,e=t,t=null);let o=t&&typeof t=="object";if(t=t||{},this.json=t.json||A,this.path=t.path||e,this.resultType=t.resultType||"value",this.flatten=t.flatten||!1,this.wrap=Object.hasOwn(t,"wrap")?t.wrap:!0,this.sandbox=t.sandbox||{},this.eval=t.eval===void 0?"safe":t.eval,this.ignoreEvalErrors=typeof t.ignoreEvalErrors>"u"?!1:t.ignoreEvalErrors,this.parent=t.parent||null,this.parentProperty=t.parentProperty||null,this.callback=t.callback||i||null,this.otherTypeCallback=t.otherTypeCallback||n||function(){throw new TypeError("You must supply an otherTypeCallback callback option with the @other() operator.")},t.autostart!==!1){let r={path:o?t.path:e};o?"json"in t&&(r.json=t.json):r.json=A;let s=this.evaluate(r);if(!s||typeof s!="object")throw new ML(s);return s}}pn.prototype.evaluate=function(t,e,A,i){let n=this.parent,o=this.parentProperty,{flatten:r,wrap:s}=this;if(this.currResultType=this.resultType,this.currEval=this.eval,this.currSandbox=this.sandbox,A=A||this.callback,this.currOtherTypeCallback=i||this.otherTypeCallback,e=e||this.json,t=t||this.path,t&&typeof t=="object"&&!Array.isArray(t)){if(!t.path&&t.path!=="")throw new TypeError('You must supply a "path" property when providing an object argument to JSONPath.evaluate().');if(!Object.hasOwn(t,"json"))throw new TypeError('You must supply a "json" property when providing an object argument to JSONPath.evaluate().');({json:e}=t),r=Object.hasOwn(t,"flatten")?t.flatten:r,this.currResultType=Object.hasOwn(t,"resultType")?t.resultType:this.currResultType,this.currSandbox=Object.hasOwn(t,"sandbox")?t.sandbox:this.currSandbox,s=Object.hasOwn(t,"wrap")?t.wrap:s,this.currEval=Object.hasOwn(t,"eval")?t.eval:this.currEval,A=Object.hasOwn(t,"callback")?t.callback:A,this.currOtherTypeCallback=Object.hasOwn(t,"otherTypeCallback")?t.otherTypeCallback:this.currOtherTypeCallback,n=Object.hasOwn(t,"parent")?t.parent:n,o=Object.hasOwn(t,"parentProperty")?t.parentProperty:o,t=t.path}if(n=n||null,o=o||null,Array.isArray(t)&&(t=pn.toPathString(t)),!t&&t!==""||!e)return;let a=pn.toPathArray(t);a[0]==="$"&&a.length>1&&a.shift(),this._hasParentSelector=null;let c=this._trace(a,e,["$"],n,o,A).filter(function(l){return l&&!l.isParentSelector});return c.length?!s&&c.length===1&&!c[0].hasArrExpr?this._getPreferredOutput(c[0]):c.reduce((l,I)=>{let C=this._getPreferredOutput(I);return r&&Array.isArray(C)?l=l.concat(C):l.push(C),l},[]):s?[]:void 0};pn.prototype._getPreferredOutput=function(t){let e=this.currResultType;switch(e){case"all":{let A=Array.isArray(t.path)?t.path:pn.toPathArray(t.path);return t.pointer=pn.toPointer(A),t.path=typeof t.path=="string"?t.path:pn.toPathString(t.path),t}case"value":case"parent":case"parentProperty":return t[e];case"path":return pn.toPathString(t[e]);case"pointer":return pn.toPointer(t.path);default:throw new TypeError("Unknown result type")}};pn.prototype._handleCallback=function(t,e,A){if(e){let i=this._getPreferredOutput(t);t.path=typeof t.path=="string"?t.path:pn.toPathString(t.path),e(i,A,t)}};pn.prototype._trace=function(t,e,A,i,n,o,r,s){let a;if(!t.length)return a={path:A,value:e,parent:i,parentProperty:n,hasArrExpr:r},this._handleCallback(a,o,"value"),a;let c=t[0],l=t.slice(1),I=[];function C(d){Array.isArray(d)?d.forEach(B=>{I.push(B)}):I.push(d)}if((typeof c!="string"||s)&&e&&Object.hasOwn(e,c))C(this._trace(l,e[c],d1(A,c),e,c,o,r));else if(c==="*")this._walk(e,d=>{C(this._trace(l,e[d],d1(A,d),e,d,o,!0,!0))});else if(c==="..")C(this._trace(l,e,A,i,n,o,r)),this._walk(e,d=>{typeof e[d]=="object"&&C(this._trace(t.slice(),e[d],d1(A,d),e,d,o,!0))});else{if(c==="^")return this._hasParentSelector=!0,{path:A.slice(0,-1),expr:l,isParentSelector:!0};if(c==="~")return a={path:d1(A,c),value:n,parent:i,parentProperty:null},this._handleCallback(a,o,"property"),a;if(c==="$")C(this._trace(l,e,A,null,null,o,r));else if(/^(-?\d*):(-?\d*):?(\d*)$/u.test(c))C(this._slice(c,l,e,A,i,n,o));else if(c.indexOf("?(")===0){if(this.currEval===!1)throw new Error("Eval [?(expr)] prevented in JSONPath expression.");let d=c.replace(/^\?\((.*?)\)$/u,"$1"),B=/@.?([^?]*)[['](\??\(.*?\))(?!.\)\])[\]']/gu.exec(d);B?this._walk(e,E=>{let Q=[B[2]],u=B[1]?e[E][B[1]]:e[E];this._trace(Q,u,A,i,n,o,!0).length>0&&C(this._trace(l,e[E],d1(A,E),e,E,o,!0))}):this._walk(e,E=>{this._eval(d,e[E],E,A,i,n)&&C(this._trace(l,e[E],d1(A,E),e,E,o,!0))})}else if(c[0]==="("){if(this.currEval===!1)throw new Error("Eval [(expr)] prevented in JSONPath expression.");C(this._trace(bL(this._eval(c,e,A.at(-1),A.slice(0,-1),i,n),l),e,A,i,n,o,r))}else if(c[0]==="@"){let d=!1,B=c.slice(1,-2);switch(B){case"scalar":(!e||!["object","function"].includes(typeof e))&&(d=!0);break;case"boolean":case"string":case"undefined":case"function":typeof e===B&&(d=!0);break;case"integer":Number.isFinite(e)&&!(e%1)&&(d=!0);break;case"number":Number.isFinite(e)&&(d=!0);break;case"nonFinite":typeof e=="number"&&!Number.isFinite(e)&&(d=!0);break;case"object":e&&typeof e===B&&(d=!0);break;case"array":Array.isArray(e)&&(d=!0);break;case"other":d=this.currOtherTypeCallback(e,A,i,n);break;case"null":e===null&&(d=!0);break;default:throw new TypeError("Unknown value type "+B)}if(d)return a={path:A,value:e,parent:i,parentProperty:n},this._handleCallback(a,o,"value"),a}else if(c[0]==="`"&&e&&Object.hasOwn(e,c.slice(1))){let d=c.slice(1);C(this._trace(l,e[d],d1(A,d),e,d,o,r,!0))}else if(c.includes(",")){let d=c.split(",");for(let B of d)C(this._trace(bL(B,l),e,A,i,n,o,!0))}else!s&&e&&Object.hasOwn(e,c)&&C(this._trace(l,e[c],d1(A,c),e,c,o,r,!0))}if(this._hasParentSelector)for(let d=0;d<I.length;d++){let B=I[d];if(B&&B.isParentSelector){let E=this._trace(B.expr,e,B.path,i,n,o,r);if(Array.isArray(E)){I[d]=E[0];let Q=E.length;for(let u=1;u<Q;u++)d++,I.splice(d,0,E[u])}else I[d]=E}}return I};pn.prototype._walk=function(t,e){if(Array.isArray(t)){let A=t.length;for(let i=0;i<A;i++)e(i)}else t&&typeof t=="object"&&Object.keys(t).forEach(A=>{e(A)})};pn.prototype._slice=function(t,e,A,i,n,o,r){if(!Array.isArray(A))return;let s=A.length,a=t.split(":"),c=a[2]&&Number.parseInt(a[2])||1,l=a[0]&&Number.parseInt(a[0])||0,I=a[1]&&Number.parseInt(a[1])||s;l=l<0?Math.max(0,l+s):Math.min(s,l),I=I<0?Math.max(0,I+s):Math.min(s,I);let C=[];for(let d=l;d<I;d+=c)this._trace(bL(d,e),A,i,n,o,r,!0).forEach(E=>{C.push(E)});return C};pn.prototype._eval=function(t,e,A,i,n,o){this.currSandbox._$_parentProperty=o,this.currSandbox._$_parent=n,this.currSandbox._$_property=A,this.currSandbox._$_root=this.json,this.currSandbox._$_v=e;let r=t.includes("@path");r&&(this.currSandbox._$_path=pn.toPathString(i.concat([A])));let s=this.currEval+"Script:"+t;if(!pn.cache[s]){let a=t.replaceAll("@parentProperty","_$_parentProperty").replaceAll("@parent","_$_parent").replaceAll("@property","_$_property").replaceAll("@root","_$_root").replaceAll(/@([.\s)[])/gu,"_$_v$1");if(r&&(a=a.replaceAll("@path","_$_path")),this.currEval==="safe"||this.currEval===!0||this.currEval===void 0)pn.cache[s]=new this.safeVm.Script(a);else if(this.currEval==="native")pn.cache[s]=new this.vm.Script(a);else if(typeof this.currEval=="function"&&this.currEval.prototype&&Object.hasOwn(this.currEval.prototype,"runInNewContext")){let c=this.currEval;pn.cache[s]=new c(a)}else if(typeof this.currEval=="function")pn.cache[s]={runInNewContext:c=>this.currEval(a,c)};else throw new TypeError(`Unknown "eval" property "${this.currEval}"`)}try{return pn.cache[s].runInNewContext(this.currSandbox)}catch(a){if(this.ignoreEvalErrors)return!1;throw new Error("jsonPath: "+a.message+": "+t)}};pn.cache={};pn.toPathString=function(t){let e=t,A=e.length,i="$";for(let n=1;n<A;n++)/^(~|\^|@.*?\(\))$/u.test(e[n])||(i+=/^[0-9*]+$/u.test(e[n])?"["+e[n]+"]":"['"+e[n]+"']");return i};pn.toPointer=function(t){let e=t,A=e.length,i="";for(let n=1;n<A;n++)/^(~|\^|@.*?\(\))$/u.test(e[n])||(i+="/"+e[n].toString().replaceAll("~","~0").replaceAll("/","~1"));return i};pn.toPathArray=function(t){let{cache:e}=pn;if(e[t])return e[t].concat();let A=[],n=t.replaceAll(/@(?:null|boolean|number|string|integer|undefined|nonFinite|scalar|array|object|function|other)\(\)/gu,";$&;").replaceAll(/[['](\??\(.*?\))[\]'](?!.\])/gu,function(o,r){return"[#"+(A.push(r)-1)+"]"}).replaceAll(/\[['"]([^'\]]*)['"]\]/gu,function(o,r){return"['"+r.replaceAll(".","%@%").replaceAll("~","%%@@%%")+"']"}).replaceAll("~",";~;").replaceAll(/['"]?\.['"]?(?![^[]*\])|\[['"]?/gu,";").replaceAll("%@%",".").replaceAll("%%@@%%","~").replaceAll(/(?:;)?(\^+)(?:;)?/gu,function(o,r){return";"+r.split("").join(";")+";"}).replaceAll(/;;;|;;/gu,";..;").replaceAll(/;$|'?\]|'$/gu,"").split(";").map(function(o){let r=o.match(/#(\d+)/u);return!r||!r[1]?o:A[r[1]]});return e[t]=n,e[t].concat()};pn.prototype.safeVm={Script:vL};var SSA=function(t,e,A){let i=t.length;for(let n=0;n<i;n++){let o=t[n];A(o)&&e.push(t.splice(n--,1)[0])}},kL=class{constructor(e){this.code=e}runInNewContext(e){let A=this.code,i=Object.keys(e),n=[];SSA(i,n,c=>typeof e[c]=="function");let o=i.map(c=>e[c]);A=n.reduce((c,l)=>{let I=e[l].toString();return/function/u.test(I)||(I="function "+I),"var "+l+"="+I+";"+c},"")+A,!/(['"])use strict\1/u.test(A)&&!i.includes("arguments")&&(A="var arguments = undefined;"+A),A=A.replace(/;\s*$/u,"");let s=A.lastIndexOf(";"),a=s!==-1?A.slice(0,s+1)+" return "+A.slice(s+1):" return "+A;return new Function(...i,a)(...o)}};pn.prototype.vm={Script:kL};var RL=[],bAA=[];(()=>{let t="lc,34,7n,7,7b,19,,,,2,,2,,,20,b,1c,l,g,,2t,7,2,6,2,2,,4,z,,u,r,2j,b,1m,9,9,,o,4,,9,,3,,5,17,3,3b,f,,w,1j,,,,4,8,4,,3,7,a,2,t,,1m,,,,2,4,8,,9,,a,2,q,,2,2,1l,,4,2,4,2,2,3,3,,u,2,3,,b,2,1l,,4,5,,2,4,,k,2,m,6,,,1m,,,2,,4,8,,7,3,a,2,u,,1n,,,,c,,9,,14,,3,,1l,3,5,3,,4,7,2,b,2,t,,1m,,2,,2,,3,,5,2,7,2,b,2,s,2,1l,2,,,2,4,8,,9,,a,2,t,,20,,4,,2,3,,,8,,29,,2,7,c,8,2q,,2,9,b,6,22,2,r,,,,,,1j,e,,5,,2,5,b,,10,9,,2u,4,,6,,2,2,2,p,2,4,3,g,4,d,,2,2,6,,f,,jj,3,qa,3,t,3,t,2,u,2,1s,2,,7,8,,2,b,9,,19,3,3b,2,y,,3a,3,4,2,9,,6,3,63,2,2,,1m,,,7,,,,,2,8,6,a,2,,1c,h,1r,4,1c,7,,,5,,14,9,c,2,w,4,2,2,,3,1k,,,2,3,,,3,1m,8,2,2,48,3,,d,,7,4,,6,,3,2,5i,1m,,5,ek,,5f,x,2da,3,3x,,2o,w,fe,6,2x,2,n9w,4,,a,w,2,28,2,7k,,3,,4,,p,2,5,,47,2,q,i,d,,12,8,p,b,1a,3,1c,,2,4,2,2,13,,1v,6,2,2,2,2,c,,8,,1b,,1f,,,3,2,2,5,2,,,16,2,8,,6m,,2,,4,,fn4,,kh,g,g,g,a6,2,gt,,6a,,45,5,1ae,3,,2,5,4,14,3,4,,4l,2,fx,4,ar,2,49,b,4w,,1i,f,1k,3,1d,4,2,2,1x,3,10,5,,8,1q,,c,2,1g,9,a,4,2,,2n,3,2,,,2,6,,4g,,3,8,l,2,1l,2,,,,,m,,e,7,3,5,5f,8,2,3,,,n,,29,,2,6,,,2,,,2,,2,6j,,2,4,6,2,,2,r,2,2d,8,2,,,2,2y,,,,2,6,,,2t,3,2,4,,5,77,9,,2,6t,,a,2,,,4,,40,4,2,2,4,,w,a,14,6,2,4,8,,9,6,2,3,1a,d,,2,ba,7,,6,,,2a,m,2,7,,2,,2,3e,6,3,,,2,,7,,,20,2,3,,,,9n,2,f0b,5,1n,7,t4,,1r,4,29,,f5k,2,43q,,,3,4,5,8,8,2,7,u,4,44,3,1iz,1j,4,1e,8,,e,,m,5,,f,11s,7,,h,2,7,,2,,5,79,7,c5,4,15s,7,31,7,240,5,gx7k,2o,3k,6o".split(",").map(e=>e?parseInt(e,36):1);for(let e=0,A=0;e<t.length;e++)(e%2?bAA:RL).push(A=A+t[e])})();function RSA(t){if(t<768)return!1;for(let e=0,A=RL.length;;){let i=e+A>>1;if(t<RL[i])A=i;else if(t>=bAA[i])e=i+1;else return!0;if(e==A)return!1}}function DAA(t){return t>=127462&&t<=127487}var yAA=8205;function MAA(t,e,A=!0,i=!0){return(A?kAA:LSA)(t,e,i)}function kAA(t,e,A){if(e==t.length)return e;e&&SAA(t.charCodeAt(e))&&RAA(t.charCodeAt(e-1))&&e--;let i=SL(t,e);for(e+=vAA(i);e<t.length;){let n=SL(t,e);if(i==yAA||n==yAA||A&&RSA(n))e+=vAA(n),i=n;else if(DAA(n)){let o=0,r=e-2;for(;r>=0&&DAA(SL(t,r));)o++,r-=2;if(o%2==0)break;e+=2}else break}return e}function LSA(t,e,A){for(;e>0;){let i=kAA(t,e-2,A);if(i<e)return i;e--}return 0}function SL(t,e){let A=t.charCodeAt(e);if(!RAA(A)||e+1==t.length)return A;let i=t.charCodeAt(e+1);return SAA(i)?(A-55296<<10)+(i-56320)+65536:A}function SAA(t){return t>=56320&&t<57344}function RAA(t){return t>=55296&&t<56320}function vAA(t){return t<65536?1:2}var qi=class t{lineAt(e){if(e<0||e>this.length)throw new RangeError(`Invalid position ${e} in document of length ${this.length}`);return this.lineInner(e,!1,1,0)}line(e){if(e<1||e>this.lines)throw new RangeError(`Invalid line number ${e} in ${this.lines}-line document`);return this.lineInner(e,!0,1,0)}replace(e,A,i){[e,A]=dE(this,e,A);let n=[];return this.decompose(0,e,n,2),i.length&&i.decompose(0,i.length,n,3),this.decompose(A,this.length,n,1),gE.from(n,this.length-(A-e)+i.length)}append(e){return this.replace(this.length,this.length,e)}slice(e,A=this.length){[e,A]=dE(this,e,A);let i=[];return this.decompose(e,A,i,0),gE.from(i,A-e)}eq(e){if(e==this)return!0;if(e.length!=this.length||e.lines!=this.lines)return!1;let A=this.scanIdentical(e,1),i=this.length-this.scanIdentical(e,-1),n=new aC(this),o=new aC(e);for(let r=A,s=A;;){if(n.next(r),o.next(r),r=0,n.lineBreak!=o.lineBreak||n.done!=o.done||n.value!=o.value)return!1;if(s+=n.value.length,n.done||s>=i)return!0}}iter(e=1){return new aC(this,e)}iterRange(e,A=this.length){return new Z5(this,e,A)}iterLines(e,A){let i;if(e==null)i=this.iter();else{A==null&&(A=this.lines+1);let n=this.line(e).from;i=this.iterRange(n,Math.max(n,A==this.lines+1?this.length:A<=1?0:this.line(A-1).to))}return new W5(i)}toString(){return this.sliceString(0)}toJSON(){let e=[];return this.flatten(e),e}constructor(){}static of(e){if(e.length==0)throw new RangeError("A document must have at least one line");return e.length==1&&!e[0]?t.empty:e.length<=32?new ec(e):gE.from(ec.split(e,[]))}},ec=class t extends qi{constructor(e,A=xSA(e)){super(),this.text=e,this.length=A}get lines(){return this.text.length}get children(){return null}lineInner(e,A,i,n){for(let o=0;;o++){let r=this.text[o],s=n+r.length;if((A?i:s)>=e)return new FL(n,s,i,r);n=s+1,i++}}decompose(e,A,i,n){let o=e<=0&&A>=this.length?this:new t(LAA(this.text,e,A),Math.min(A,this.length)-Math.max(0,e));if(n&1){let r=i.pop(),s=V5(o.text,r.text.slice(),0,o.length);if(s.length<=32)i.push(new t(s,r.length+o.length));else{let a=s.length>>1;i.push(new t(s.slice(0,a)),new t(s.slice(a)))}}else i.push(o)}replace(e,A,i){if(!(i instanceof t))return super.replace(e,A,i);[e,A]=dE(this,e,A);let n=V5(this.text,V5(i.text,LAA(this.text,0,e)),A),o=this.length+i.length-(A-e);return n.length<=32?new t(n,o):gE.from(t.split(n,[]),o)}sliceString(e,A=this.length,i=`
`){[e,A]=dE(this,e,A);let n="";for(let o=0,r=0;o<=A&&r<this.text.length;r++){let s=this.text[r],a=o+s.length;o>e&&r&&(n+=i),e<a&&A>o&&(n+=s.slice(Math.max(0,e-o),A-o)),o=a+1}return n}flatten(e){for(let A of this.text)e.push(A)}scanIdentical(){return 0}static split(e,A){let i=[],n=-1;for(let o of e)i.push(o),n+=o.length+1,i.length==32&&(A.push(new t(i,n)),i=[],n=-1);return n>-1&&A.push(new t(i,n)),A}},gE=class t extends qi{constructor(e,A){super(),this.children=e,this.length=A,this.lines=0;for(let i of e)this.lines+=i.lines}lineInner(e,A,i,n){for(let o=0;;o++){let r=this.children[o],s=n+r.length,a=i+r.lines-1;if((A?a:s)>=e)return r.lineInner(e,A,i,n);n=s+1,i=a+1}}decompose(e,A,i,n){for(let o=0,r=0;r<=A&&o<this.children.length;o++){let s=this.children[o],a=r+s.length;if(e<=a&&A>=r){let c=n&((r<=e?1:0)|(a>=A?2:0));r>=e&&a<=A&&!c?i.push(s):s.decompose(e-r,A-r,i,c)}r=a+1}}replace(e,A,i){if([e,A]=dE(this,e,A),i.lines<this.lines)for(let n=0,o=0;n<this.children.length;n++){let r=this.children[n],s=o+r.length;if(e>=o&&A<=s){let a=r.replace(e-o,A-o,i),c=this.lines-r.lines+a.lines;if(a.lines<c>>4&&a.lines>c>>6){let l=this.children.slice();return l[n]=a,new t(l,this.length-(A-e)+i.length)}return super.replace(o,s,a)}o=s+1}return super.replace(e,A,i)}sliceString(e,A=this.length,i=`
`){[e,A]=dE(this,e,A);let n="";for(let o=0,r=0;o<this.children.length&&r<=A;o++){let s=this.children[o],a=r+s.length;r>e&&o&&(n+=i),e<a&&A>r&&(n+=s.sliceString(e-r,A-r,i)),r=a+1}return n}flatten(e){for(let A of this.children)A.flatten(e)}scanIdentical(e,A){if(!(e instanceof t))return 0;let i=0,[n,o,r,s]=A>0?[0,0,this.children.length,e.children.length]:[this.children.length-1,e.children.length-1,-1,-1];for(;;n+=A,o+=A){if(n==r||o==s)return i;let a=this.children[n],c=e.children[o];if(a!=c)return i+a.scanIdentical(c,A);i+=a.length+1}}static from(e,A=e.reduce((i,n)=>i+n.length+1,-1)){let i=0;for(let d of e)i+=d.lines;if(i<32){let d=[];for(let B of e)B.flatten(d);return new ec(d,A)}let n=Math.max(32,i>>5),o=n<<1,r=n>>1,s=[],a=0,c=-1,l=[];function I(d){let B;if(d.lines>o&&d instanceof t)for(let E of d.children)I(E);else d.lines>r&&(a>r||!a)?(C(),s.push(d)):d instanceof ec&&a&&(B=l[l.length-1])instanceof ec&&d.lines+B.lines<=32?(a+=d.lines,c+=d.length+1,l[l.length-1]=new ec(B.text.concat(d.text),B.length+1+d.length)):(a+d.lines>n&&C(),a+=d.lines,c+=d.length+1,l.push(d))}function C(){a!=0&&(s.push(l.length==1?l[0]:t.from(l,c)),c=-1,a=l.length=0)}for(let d of e)I(d);return C(),s.length==1?s[0]:new t(s,A)}};qi.empty=new ec([""],0);function xSA(t){let e=-1;for(let A of t)e+=A.length+1;return e}function V5(t,e,A=0,i=1e9){for(let n=0,o=0,r=!0;o<t.length&&n<=i;o++){let s=t[o],a=n+s.length;a>=A&&(a>i&&(s=s.slice(0,i-n)),n<A&&(s=s.slice(A-n)),r?(e[e.length-1]+=s,r=!1):e.push(s)),n=a+1}return e}function LAA(t,e,A){return V5(t,[""],e,A)}var aC=class{constructor(e,A=1){this.dir=A,this.done=!1,this.lineBreak=!1,this.value="",this.nodes=[e],this.offsets=[A>0?1:(e instanceof ec?e.text.length:e.children.length)<<1]}nextInner(e,A){for(this.done=this.lineBreak=!1;;){let i=this.nodes.length-1,n=this.nodes[i],o=this.offsets[i],r=o>>1,s=n instanceof ec?n.text.length:n.children.length;if(r==(A>0?s:0)){if(i==0)return this.done=!0,this.value="",this;A>0&&this.offsets[i-1]++,this.nodes.pop(),this.offsets.pop()}else if((o&1)==(A>0?0:1)){if(this.offsets[i]+=A,e==0)return this.lineBreak=!0,this.value=`
`,this;e--}else if(n instanceof ec){let a=n.text[r+(A<0?-1:0)];if(this.offsets[i]+=A,a.length>Math.max(0,e))return this.value=e==0?a:A>0?a.slice(e):a.slice(0,a.length-e),this;e-=a.length}else{let a=n.children[r+(A<0?-1:0)];e>a.length?(e-=a.length,this.offsets[i]+=A):(A<0&&this.offsets[i]--,this.nodes.push(a),this.offsets.push(A>0?1:(a instanceof ec?a.text.length:a.children.length)<<1))}}}next(e=0){return e<0&&(this.nextInner(-e,-this.dir),e=this.value.length),this.nextInner(e,this.dir)}},Z5=class{constructor(e,A,i){this.value="",this.done=!1,this.cursor=new aC(e,A>i?-1:1),this.pos=A>i?e.length:0,this.from=Math.min(A,i),this.to=Math.max(A,i)}nextInner(e,A){if(A<0?this.pos<=this.from:this.pos>=this.to)return this.value="",this.done=!0,this;e+=Math.max(0,A<0?this.pos-this.to:this.from-this.pos);let i=A<0?this.pos-this.from:this.to-this.pos;e>i&&(e=i),i-=e;let{value:n}=this.cursor.next(e);return this.pos+=(n.length+e)*A,this.value=n.length<=i?n:A<0?n.slice(n.length-i):n.slice(0,i),this.done=!this.value,this}next(e=0){return e<0?e=Math.max(e,this.from-this.pos):e>0&&(e=Math.min(e,this.to-this.pos)),this.nextInner(e,this.cursor.dir)}get lineBreak(){return this.cursor.lineBreak&&this.value!=""}},W5=class{constructor(e){this.inner=e,this.afterBreak=!0,this.value="",this.done=!1}next(e=0){let{done:A,lineBreak:i,value:n}=this.inner.next(e);return A&&this.afterBreak?(this.value="",this.afterBreak=!1):A?(this.done=!0,this.value=""):i?this.afterBreak?this.value="":(this.afterBreak=!0,this.next()):(this.value=n,this.afterBreak=!1),this}get lineBreak(){return!1}};typeof Symbol<"u"&&(qi.prototype[Symbol.iterator]=function(){return this.iter()},aC.prototype[Symbol.iterator]=Z5.prototype[Symbol.iterator]=W5.prototype[Symbol.iterator]=function(){return this});var FL=class{constructor(e,A,i,n){this.from=e,this.to=A,this.number=i,this.text=n}get length(){return this.to-this.from}};function dE(t,e,A){return e=Math.max(0,Math.min(t.length,e)),[e,Math.max(e,Math.min(t.length,A))]}function fr(t,e,A=!0,i=!0){return MAA(t,e,A,i)}function FSA(t){return t>=56320&&t<57344}function NSA(t){return t>=55296&&t<56320}function rs(t,e){let A=t.charCodeAt(e);if(!NSA(A)||e+1==t.length)return A;let i=t.charCodeAt(e+1);return FSA(i)?(A-55296<<10)+(i-56320)+65536:A}function b4(t){return t<=65535?String.fromCharCode(t):(t-=65536,String.fromCharCode((t>>10)+55296,(t&1023)+56320))}function tc(t){return t<65536?1:2}var NL=/\r\n?|\n/,is=function(t){return t[t.Simple=0]="Simple",t[t.TrackDel=1]="TrackDel",t[t.TrackBefore=2]="TrackBefore",t[t.TrackAfter=3]="TrackAfter",t}(is||(is={})),E1=class t{constructor(e){this.sections=e}get length(){let e=0;for(let A=0;A<this.sections.length;A+=2)e+=this.sections[A];return e}get newLength(){let e=0;for(let A=0;A<this.sections.length;A+=2){let i=this.sections[A+1];e+=i<0?this.sections[A]:i}return e}get empty(){return this.sections.length==0||this.sections.length==2&&this.sections[1]<0}iterGaps(e){for(let A=0,i=0,n=0;A<this.sections.length;){let o=this.sections[A++],r=this.sections[A++];r<0?(e(i,n,o),n+=o):n+=r,i+=o}}iterChangedRanges(e,A=!1){_L(this,e,A)}get invertedDesc(){let e=[];for(let A=0;A<this.sections.length;){let i=this.sections[A++],n=this.sections[A++];n<0?e.push(i,n):e.push(n,i)}return new t(e)}composeDesc(e){return this.empty?e:e.empty?this:KAA(this,e)}mapDesc(e,A=!1){return e.empty?this:GL(this,e,A)}mapPos(e,A=-1,i=is.Simple){let n=0,o=0;for(let r=0;r<this.sections.length;){let s=this.sections[r++],a=this.sections[r++],c=n+s;if(a<0){if(c>e)return o+(e-n);o+=s}else{if(i!=is.Simple&&c>=e&&(i==is.TrackDel&&n<e&&c>e||i==is.TrackBefore&&n<e||i==is.TrackAfter&&c>e))return null;if(c>e||c==e&&A<0&&!s)return e==n||A<0?o:o+a;o+=a}n=c}if(e>n)throw new RangeError(`Position ${e} is out of range for changeset of length ${n}`);return o}touchesRange(e,A=e){for(let i=0,n=0;i<this.sections.length&&n<=A;){let o=this.sections[i++],r=this.sections[i++],s=n+o;if(r>=0&&n<=A&&s>=e)return n<e&&s>A?"cover":!0;n=s}return!1}toString(){let e="";for(let A=0;A<this.sections.length;){let i=this.sections[A++],n=this.sections[A++];e+=(e?" ":"")+i+(n>=0?":"+n:"")}return e}toJSON(){return this.sections}static fromJSON(e){if(!Array.isArray(e)||e.length%2||e.some(A=>typeof A!="number"))throw new RangeError("Invalid JSON representation of ChangeDesc");return new t(e)}static create(e){return new t(e)}},ns=class t extends E1{constructor(e,A){super(e),this.inserted=A}apply(e){if(this.length!=e.length)throw new RangeError("Applying change set to a document with the wrong length");return _L(this,(A,i,n,o,r)=>e=e.replace(n,n+(i-A),r),!1),e}mapDesc(e,A=!1){return GL(this,e,A,!0)}invert(e){let A=this.sections.slice(),i=[];for(let n=0,o=0;n<A.length;n+=2){let r=A[n],s=A[n+1];if(s>=0){A[n]=s,A[n+1]=r;let a=n>>1;for(;i.length<a;)i.push(qi.empty);i.push(r?e.slice(o,o+r):qi.empty)}o+=r}return new t(A,i)}compose(e){return this.empty?e:e.empty?this:KAA(this,e,!0)}map(e,A=!1){return e.empty?this:GL(this,e,A,!0)}iterChanges(e,A=!1){_L(this,e,A)}get desc(){return E1.create(this.sections)}filter(e){let A=[],i=[],n=[],o=new cC(this);A:for(let r=0,s=0;;){let a=r==e.length?1e9:e[r++];for(;s<a||s==a&&o.len==0;){if(o.done)break A;let l=Math.min(o.len,a-s);ps(n,l,-1);let I=o.ins==-1?-1:o.off==0?o.ins:0;ps(A,l,I),I>0&&B1(i,A,o.text),o.forward(l),s+=l}let c=e[r++];for(;s<c;){if(o.done)break A;let l=Math.min(o.len,c-s);ps(A,l,-1),ps(n,l,o.ins==-1?-1:o.off==0?o.ins:0),o.forward(l),s+=l}}return{changes:new t(A,i),filtered:E1.create(n)}}toJSON(){let e=[];for(let A=0;A<this.sections.length;A+=2){let i=this.sections[A],n=this.sections[A+1];n<0?e.push(i):n==0?e.push([i]):e.push([i].concat(this.inserted[A>>1].toJSON()))}return e}static of(e,A,i){let n=[],o=[],r=0,s=null;function a(l=!1){if(!l&&!n.length)return;r<A&&ps(n,A-r,-1);let I=new t(n,o);s=s?s.compose(I.map(s)):I,n=[],o=[],r=0}function c(l){if(Array.isArray(l))for(let I of l)c(I);else if(l instanceof t){if(l.length!=A)throw new RangeError(`Mismatched change set length (got ${l.length}, expected ${A})`);a(),s=s?s.compose(l.map(s)):l}else{let{from:I,to:C=I,insert:d}=l;if(I>C||I<0||C>A)throw new RangeError(`Invalid change range ${I} to ${C} (in doc of length ${A})`);let B=d?typeof d=="string"?qi.of(d.split(i||NL)):d:qi.empty,E=B.length;if(I==C&&E==0)return;I<r&&a(),I>r&&ps(n,I-r,-1),ps(n,C-I,E),B1(o,n,B),r=C}}return c(e),a(!s),s}static empty(e){return new t(e?[e,-1]:[],[])}static fromJSON(e){if(!Array.isArray(e))throw new RangeError("Invalid JSON representation of ChangeSet");let A=[],i=[];for(let n=0;n<e.length;n++){let o=e[n];if(typeof o=="number")A.push(o,-1);else{if(!Array.isArray(o)||typeof o[0]!="number"||o.some((r,s)=>s&&typeof r!="string"))throw new RangeError("Invalid JSON representation of ChangeSet");if(o.length==1)A.push(o[0],0);else{for(;i.length<n;)i.push(qi.empty);i[n]=qi.of(o.slice(1)),A.push(o[0],i[n].length)}}}return new t(A,i)}static createSet(e,A){return new t(e,A)}};function ps(t,e,A,i=!1){if(e==0&&A<=0)return;let n=t.length-2;n>=0&&A<=0&&A==t[n+1]?t[n]+=e:n>=0&&e==0&&t[n]==0?t[n+1]+=A:i?(t[n]+=e,t[n+1]+=A):t.push(e,A)}function B1(t,e,A){if(A.length==0)return;let i=e.length-2>>1;if(i<t.length)t[t.length-1]=t[t.length-1].append(A);else{for(;t.length<i;)t.push(qi.empty);t.push(A)}}function _L(t,e,A){let i=t.inserted;for(let n=0,o=0,r=0;r<t.sections.length;){let s=t.sections[r++],a=t.sections[r++];if(a<0)n+=s,o+=s;else{let c=n,l=o,I=qi.empty;for(;c+=s,l+=a,a&&i&&(I=I.append(i[r-2>>1])),!(A||r==t.sections.length||t.sections[r+1]<0);)s=t.sections[r++],a=t.sections[r++];e(n,c,o,l,I),n=c,o=l}}}function GL(t,e,A,i=!1){let n=[],o=i?[]:null,r=new cC(t),s=new cC(e);for(let a=-1;;){if(r.done&&s.len||s.done&&r.len)throw new Error("Mismatched change set lengths");if(r.ins==-1&&s.ins==-1){let c=Math.min(r.len,s.len);ps(n,c,-1),r.forward(c),s.forward(c)}else if(s.ins>=0&&(r.ins<0||a==r.i||r.off==0&&(s.len<r.len||s.len==r.len&&!A))){let c=s.len;for(ps(n,s.ins,-1);c;){let l=Math.min(r.len,c);r.ins>=0&&a<r.i&&r.len<=l&&(ps(n,0,r.ins),o&&B1(o,n,r.text),a=r.i),r.forward(l),c-=l}s.next()}else if(r.ins>=0){let c=0,l=r.len;for(;l;)if(s.ins==-1){let I=Math.min(l,s.len);c+=I,l-=I,s.forward(I)}else if(s.ins==0&&s.len<l)l-=s.len,s.next();else break;ps(n,c,a<r.i?r.ins:0),o&&a<r.i&&B1(o,n,r.text),a=r.i,r.forward(r.len-l)}else{if(r.done&&s.done)return o?ns.createSet(n,o):E1.create(n);throw new Error("Mismatched change set lengths")}}}function KAA(t,e,A=!1){let i=[],n=A?[]:null,o=new cC(t),r=new cC(e);for(let s=!1;;){if(o.done&&r.done)return n?ns.createSet(i,n):E1.create(i);if(o.ins==0)ps(i,o.len,0,s),o.next();else if(r.len==0&&!r.done)ps(i,0,r.ins,s),n&&B1(n,i,r.text),r.next();else{if(o.done||r.done)throw new Error("Mismatched change set lengths");{let a=Math.min(o.len2,r.len),c=i.length;if(o.ins==-1){let l=r.ins==-1?-1:r.off?0:r.ins;ps(i,a,l,s),n&&l&&B1(n,i,r.text)}else r.ins==-1?(ps(i,o.off?0:o.len,a,s),n&&B1(n,i,o.textBit(a))):(ps(i,o.off?0:o.len,r.off?0:r.ins,s),n&&!r.off&&B1(n,i,r.text));s=(o.ins>a||r.ins>=0&&r.len>a)&&(s||i.length>c),o.forward2(a),r.forward(a)}}}}var cC=class{constructor(e){this.set=e,this.i=0,this.next()}next(){let{sections:e}=this.set;this.i<e.length?(this.len=e[this.i++],this.ins=e[this.i++]):(this.len=0,this.ins=-2),this.off=0}get done(){return this.ins==-2}get len2(){return this.ins<0?this.len:this.ins}get text(){let{inserted:e}=this.set,A=this.i-2>>1;return A>=e.length?qi.empty:e[A]}textBit(e){let{inserted:A}=this.set,i=this.i-2>>1;return i>=A.length&&!e?qi.empty:A[i].slice(this.off,e==null?void 0:this.off+e)}forward(e){e==this.len?this.next():(this.len-=e,this.off+=e)}forward2(e){this.ins==-1?this.forward(e):e==this.ins?this.next():(this.ins-=e,this.off+=e)}},lE=class t{constructor(e,A,i){this.from=e,this.to=A,this.flags=i}get anchor(){return this.flags&32?this.to:this.from}get head(){return this.flags&32?this.from:this.to}get empty(){return this.from==this.to}get assoc(){return this.flags&8?-1:this.flags&16?1:0}get bidiLevel(){let e=this.flags&7;return e==7?null:e}get goalColumn(){let e=this.flags>>6;return e==16777215?void 0:e}map(e,A=-1){let i,n;return this.empty?i=n=e.mapPos(this.from,A):(i=e.mapPos(this.from,1),n=e.mapPos(this.to,-1)),i==this.from&&n==this.to?this:new t(i,n,this.flags)}extend(e,A=e){if(e<=this.anchor&&A>=this.anchor)return ie.range(e,A);let i=Math.abs(e-this.anchor)>Math.abs(A-this.anchor)?e:A;return ie.range(this.anchor,i)}eq(e,A=!1){return this.anchor==e.anchor&&this.head==e.head&&(!A||!this.empty||this.assoc==e.assoc)}toJSON(){return{anchor:this.anchor,head:this.head}}static fromJSON(e){if(!e||typeof e.anchor!="number"||typeof e.head!="number")throw new RangeError("Invalid JSON representation for SelectionRange");return ie.range(e.anchor,e.head)}static create(e,A,i){return new t(e,A,i)}},ie=class t{constructor(e,A){this.ranges=e,this.mainIndex=A}map(e,A=-1){return e.empty?this:t.create(this.ranges.map(i=>i.map(e,A)),this.mainIndex)}eq(e,A=!1){if(this.ranges.length!=e.ranges.length||this.mainIndex!=e.mainIndex)return!1;for(let i=0;i<this.ranges.length;i++)if(!this.ranges[i].eq(e.ranges[i],A))return!1;return!0}get main(){return this.ranges[this.mainIndex]}asSingle(){return this.ranges.length==1?this:new t([this.main],0)}addRange(e,A=!0){return t.create([e].concat(this.ranges),A?0:this.mainIndex+1)}replaceRange(e,A=this.mainIndex){let i=this.ranges.slice();return i[A]=e,t.create(i,this.mainIndex)}toJSON(){return{ranges:this.ranges.map(e=>e.toJSON()),main:this.mainIndex}}static fromJSON(e){if(!e||!Array.isArray(e.ranges)||typeof e.main!="number"||e.main>=e.ranges.length)throw new RangeError("Invalid JSON representation for EditorSelection");return new t(e.ranges.map(A=>lE.fromJSON(A)),e.main)}static single(e,A=e){return new t([t.range(e,A)],0)}static create(e,A=0){if(e.length==0)throw new RangeError("A selection needs at least one range");for(let i=0,n=0;n<e.length;n++){let o=e[n];if(o.empty?o.from<=i:o.from<i)return t.normalized(e.slice(),A);i=o.to}return new t(e,A)}static cursor(e,A=0,i,n){return lE.create(e,e,(A==0?0:A<0?8:16)|(i==null?7:Math.min(6,i))|(n??16777215)<<6)}static range(e,A,i,n){let o=(i??16777215)<<6|(n==null?7:Math.min(6,n));return A<e?lE.create(A,e,48|o):lE.create(e,A,(A>e?8:0)|o)}static normalized(e,A=0){let i=e[A];e.sort((n,o)=>n.from-o.from),A=e.indexOf(i);for(let n=1;n<e.length;n++){let o=e[n],r=e[n-1];if(o.empty?o.from<=r.to:o.from<r.to){let s=r.from,a=Math.max(o.to,r.to);n<=A&&A--,e.splice(--n,2,o.anchor>o.head?t.range(a,s):t.range(s,a))}}return new t(e,A)}};function YAA(t,e){for(let A of t.ranges)if(A.to>e)throw new RangeError("Selection points outside of document")}var PL=0,Te=class t{constructor(e,A,i,n,o){this.combine=e,this.compareInput=A,this.compare=i,this.isStatic=n,this.id=PL++,this.default=e([]),this.extensions=typeof o=="function"?o(this):o}get reader(){return this}static define(e={}){return new t(e.combine||(A=>A),e.compareInput||((A,i)=>A===i),e.compare||(e.combine?(A,i)=>A===i:jL),!!e.static,e.enables)}of(e){return new IE([],this,0,e)}compute(e,A){if(this.isStatic)throw new Error("Can't compute a static facet");return new IE(e,this,1,A)}computeN(e,A){if(this.isStatic)throw new Error("Can't compute a static facet");return new IE(e,this,2,A)}from(e,A){return A||(A=i=>i),this.compute([e],i=>A(i.field(e)))}};function jL(t,e){return t==e||t.length==e.length&&t.every((A,i)=>A===e[i])}var IE=class{constructor(e,A,i,n){this.dependencies=e,this.facet=A,this.type=i,this.value=n,this.id=PL++}dynamicSlot(e){var A;let i=this.value,n=this.facet.compareInput,o=this.id,r=e[o]>>1,s=this.type==2,a=!1,c=!1,l=[];for(let I of this.dependencies)I=="doc"?a=!0:I=="selection"?c=!0:(((A=e[I.id])!==null&&A!==void 0?A:1)&1)==0&&l.push(e[I.id]);return{create(I){return I.values[r]=i(I),1},update(I,C){if(a&&C.docChanged||c&&(C.docChanged||C.selection)||UL(I,l)){let d=i(I);if(s?!xAA(d,I.values[r],n):!n(d,I.values[r]))return I.values[r]=d,1}return 0},reconfigure:(I,C)=>{let d,B=C.config.address[o];if(B!=null){let E=Aw(C,B);if(this.dependencies.every(Q=>Q instanceof Te?C.facet(Q)===I.facet(Q):Q instanceof To?C.field(Q,!1)==I.field(Q,!1):!0)||(s?xAA(d=i(I),E,n):n(d=i(I),E)))return I.values[r]=E,0}else d=i(I);return I.values[r]=d,1}}}};function xAA(t,e,A){if(t.length!=e.length)return!1;for(let i=0;i<t.length;i++)if(!A(t[i],e[i]))return!1;return!0}function UL(t,e){let A=!1;for(let i of e)w4(t,i)&1&&(A=!0);return A}function _SA(t,e,A){let i=A.map(a=>t[a.id]),n=A.map(a=>a.type),o=i.filter(a=>!(a&1)),r=t[e.id]>>1;function s(a){let c=[];for(let l=0;l<i.length;l++){let I=Aw(a,i[l]);if(n[l]==2)for(let C of I)c.push(C);else c.push(I)}return e.combine(c)}return{create(a){for(let c of i)w4(a,c);return a.values[r]=s(a),1},update(a,c){if(!UL(a,o))return 0;let l=s(a);return e.compare(l,a.values[r])?0:(a.values[r]=l,1)},reconfigure(a,c){let l=UL(a,i),I=c.config.facets[e.id],C=c.facet(e);if(I&&!l&&jL(A,I))return a.values[r]=C,0;let d=s(a);return e.compare(d,C)?(a.values[r]=C,0):(a.values[r]=d,1)}}}var P5=Te.define({static:!0}),To=class t{constructor(e,A,i,n,o){this.id=e,this.createF=A,this.updateF=i,this.compareF=n,this.spec=o,this.provides=void 0}static define(e){let A=new t(PL++,e.create,e.update,e.compare||((i,n)=>i===n),e);return e.provide&&(A.provides=e.provide(A)),A}create(e){let A=e.facet(P5).find(i=>i.field==this);return(A?.create||this.createF)(e)}slot(e){let A=e[this.id]>>1;return{create:i=>(i.values[A]=this.create(i),1),update:(i,n)=>{let o=i.values[A],r=this.updateF(o,n);return this.compareF(o,r)?0:(i.values[A]=r,1)},reconfigure:(i,n)=>{let o=i.facet(P5),r=n.facet(P5),s;return(s=o.find(a=>a.field==this))&&s!=r.find(a=>a.field==this)?(i.values[A]=s.create(i),1):n.config.address[this.id]!=null?(i.values[A]=n.field(this),0):(i.values[A]=this.create(i),1)}}}init(e){return[this,P5.of({field:this,create:e})]}get extension(){return this}},rC={lowest:4,low:3,default:2,high:1,highest:0};function p4(t){return e=>new X5(e,t)}var Bl={highest:p4(rC.highest),high:p4(rC.high),default:p4(rC.default),low:p4(rC.low),lowest:p4(rC.lowest)},X5=class{constructor(e,A){this.inner=e,this.prec=A}},ug=class t{of(e){return new D4(this,e)}reconfigure(e){return t.reconfigure.of({compartment:this,extension:e})}get(e){return e.config.compartments.get(this)}},D4=class{constructor(e,A){this.compartment=e,this.inner=A}},$5=class t{constructor(e,A,i,n,o,r){for(this.base=e,this.compartments=A,this.dynamicSlots=i,this.address=n,this.staticValues=o,this.facets=r,this.statusTemplate=[];this.statusTemplate.length<i.length;)this.statusTemplate.push(0)}staticFacet(e){let A=this.address[e.id];return A==null?e.default:this.staticValues[A>>1]}static resolve(e,A,i){let n=[],o=Object.create(null),r=new Map;for(let C of GSA(e,A,r))C instanceof To?n.push(C):(o[C.facet.id]||(o[C.facet.id]=[])).push(C);let s=Object.create(null),a=[],c=[];for(let C of n)s[C.id]=c.length<<1,c.push(d=>C.slot(d));let l=i?.config.facets;for(let C in o){let d=o[C],B=d[0].facet,E=l&&l[C]||[];if(d.every(Q=>Q.type==0))if(s[B.id]=a.length<<1|1,jL(E,d))a.push(i.facet(B));else{let Q=B.combine(d.map(u=>u.value));a.push(i&&B.compare(Q,i.facet(B))?i.facet(B):Q)}else{for(let Q of d)Q.type==0?(s[Q.id]=a.length<<1|1,a.push(Q.value)):(s[Q.id]=c.length<<1,c.push(u=>Q.dynamicSlot(u)));s[B.id]=c.length<<1,c.push(Q=>_SA(Q,B,d))}}let I=c.map(C=>C(s));return new t(e,r,I,s,a,o)}};function GSA(t,e,A){let i=[[],[],[],[],[]],n=new Map;function o(r,s){let a=n.get(r);if(a!=null){if(a<=s)return;let c=i[a].indexOf(r);c>-1&&i[a].splice(c,1),r instanceof D4&&A.delete(r.compartment)}if(n.set(r,s),Array.isArray(r))for(let c of r)o(c,s);else if(r instanceof D4){if(A.has(r.compartment))throw new RangeError("Duplicate use of compartment in extensions");let c=e.get(r.compartment)||r.inner;A.set(r.compartment,c),o(c,s)}else if(r instanceof X5)o(r.inner,r.prec);else if(r instanceof To)i[s].push(r),r.provides&&o(r.provides,s);else if(r instanceof IE)i[s].push(r),r.facet.extensions&&o(r.facet.extensions,rC.default);else{let c=r.extension;if(!c)throw new Error(`Unrecognized extension value in extension set (${r}). This sometimes happens because multiple instances of @codemirror/state are loaded, breaking instanceof checks.`);o(c,s)}}return o(t,rC.default),i.reduce((r,s)=>r.concat(s))}function w4(t,e){if(e&1)return 2;let A=e>>1,i=t.status[A];if(i==4)throw new Error("Cyclic dependency between fields and/or facets");if(i&2)return i;t.status[A]=4;let n=t.computeSlot(t,t.config.dynamicSlots[A]);return t.status[A]=2|n}function Aw(t,e){return e&1?t.config.staticValues[e>>1]:t.values[e>>1]}var FAA=Te.define(),LL=Te.define({combine:t=>t.some(e=>e),static:!0}),JAA=Te.define({combine:t=>t.length?t[0]:void 0,static:!0}),TAA=Te.define(),zAA=Te.define(),HAA=Te.define(),NAA=Te.define({combine:t=>t.length?t[0]:!1}),wa=class{constructor(e,A){this.type=e,this.value=A}static define(){return new KL}},KL=class{of(e){return new wa(this,e)}},YL=class{constructor(e){this.map=e}of(e){return new ki(this,e)}},ki=(()=>{class t{constructor(A,i){this.type=A,this.value=i}map(A){let i=this.type.map(this.value,A);return i===void 0?void 0:i==this.value?this:new t(this.type,i)}is(A){return this.type==A}static define(A={}){return new YL(A.map||(i=>i))}static mapEffects(A,i){if(!A.length)return A;let n=[];for(let o of A){let r=o.map(i);r&&n.push(r)}return n}}return t.reconfigure=t.define(),t.appendConfig=t.define(),t})(),Qg=(()=>{class t{constructor(A,i,n,o,r,s){this.startState=A,this.changes=i,this.selection=n,this.effects=o,this.annotations=r,this.scrollIntoView=s,this._doc=null,this._state=null,n&&YAA(n,i.newLength),r.some(a=>a.type==t.time)||(this.annotations=r.concat(t.time.of(Date.now())))}static create(A,i,n,o,r,s){return new t(A,i,n,o,r,s)}get newDoc(){return this._doc||(this._doc=this.changes.apply(this.startState.doc))}get newSelection(){return this.selection||this.startState.selection.map(this.changes)}get state(){return this._state||this.startState.applyTransaction(this),this._state}annotation(A){for(let i of this.annotations)if(i.type==A)return i.value}get docChanged(){return!this.changes.empty}get reconfigured(){return this.startState.config!=this.state.config}isUserEvent(A){let i=this.annotation(t.userEvent);return!!(i&&(i==A||i.length>A.length&&i.slice(0,A.length)==A&&i[A.length]=="."))}}return t.time=wa.define(),t.userEvent=wa.define(),t.addToHistory=wa.define(),t.remote=wa.define(),t})();function USA(t,e){let A=[];for(let i=0,n=0;;){let o,r;if(i<t.length&&(n==e.length||e[n]>=t[i]))o=t[i++],r=t[i++];else if(n<e.length)o=e[n++],r=e[n++];else return A;!A.length||A[A.length-1]<o?A.push(o,r):A[A.length-1]<r&&(A[A.length-1]=r)}}function OAA(t,e,A){var i;let n,o,r;return A?(n=e.changes,o=ns.empty(e.changes.length),r=t.changes.compose(e.changes)):(n=e.changes.map(t.changes),o=t.changes.mapDesc(e.changes,!0),r=t.changes.compose(n)),{changes:r,selection:e.selection?e.selection.map(o):(i=t.selection)===null||i===void 0?void 0:i.map(n),effects:ki.mapEffects(t.effects,n).concat(ki.mapEffects(e.effects,o)),annotations:t.annotations.length?t.annotations.concat(e.annotations):e.annotations,scrollIntoView:t.scrollIntoView||e.scrollIntoView}}function JL(t,e,A){let i=e.selection,n=CE(e.annotations);return e.userEvent&&(n=n.concat(Qg.userEvent.of(e.userEvent))),{changes:e.changes instanceof ns?e.changes:ns.of(e.changes||[],A,t.facet(JAA)),selection:i&&(i instanceof ie?i:ie.single(i.anchor,i.head)),effects:CE(e.effects),annotations:n,scrollIntoView:!!e.scrollIntoView}}function PAA(t,e,A){let i=JL(t,e.length?e[0]:{},t.doc.length);e.length&&e[0].filter===!1&&(A=!1);for(let o=1;o<e.length;o++){e[o].filter===!1&&(A=!1);let r=!!e[o].sequential;i=OAA(i,JL(t,e[o],r?i.changes.newLength:t.doc.length),r)}let n=Qg.create(t,i.changes,i.selection,i.effects,i.annotations,i.scrollIntoView);return YSA(A?KSA(n):n)}function KSA(t){let e=t.startState,A=!0;for(let n of e.facet(TAA)){let o=n(t);if(o===!1){A=!1;break}Array.isArray(o)&&(A=A===!0?o:USA(A,o))}if(A!==!0){let n,o;if(A===!1)o=t.changes.invertedDesc,n=ns.empty(e.doc.length);else{let r=t.changes.filter(A);n=r.changes,o=r.filtered.mapDesc(r.changes).invertedDesc}t=Qg.create(e,n,t.selection&&t.selection.map(o),ki.mapEffects(t.effects,o),t.annotations,t.scrollIntoView)}let i=e.facet(zAA);for(let n=i.length-1;n>=0;n--){let o=i[n](t);o instanceof Qg?t=o:Array.isArray(o)&&o.length==1&&o[0]instanceof Qg?t=o[0]:t=PAA(e,CE(o),!1)}return t}function YSA(t){let e=t.startState,A=e.facet(HAA),i=t;for(let n=A.length-1;n>=0;n--){let o=A[n](t);o&&Object.keys(o).length&&(i=OAA(i,JL(e,o,t.changes.newLength),!0))}return i==t?t:Qg.create(e,t.changes,t.selection,i.effects,i.annotations,i.scrollIntoView)}var JSA=[];function CE(t){return t==null?JSA:Array.isArray(t)?t:[t]}var Vn=function(t){return t[t.Word=0]="Word",t[t.Space=1]="Space",t[t.Other=2]="Other",t}(Vn||(Vn={})),TSA=/[\u00df\u0587\u0590-\u05f4\u0600-\u06ff\u3040-\u309f\u30a0-\u30ff\u3400-\u4db5\u4e00-\u9fcc\uac00-\ud7af]/,TL;try{TL=new RegExp("[\\p{Alphabetic}\\p{Number}_]","u")}catch{}function zSA(t){if(TL)return TL.test(t);for(let e=0;e<t.length;e++){let A=t[e];if(/\w/.test(A)||A>"\x80"&&(A.toUpperCase()!=A.toLowerCase()||TSA.test(A)))return!0}return!1}function HSA(t){return e=>{if(!/\S/.test(e))return Vn.Space;if(zSA(e))return Vn.Word;for(let A=0;A<t.length;A++)if(e.indexOf(t[A])>-1)return Vn.Word;return Vn.Other}}var Ir=(()=>{class t{constructor(A,i,n,o,r,s){this.config=A,this.doc=i,this.selection=n,this.values=o,this.status=A.statusTemplate.slice(),this.computeSlot=r,s&&(s._state=this);for(let a=0;a<this.config.dynamicSlots.length;a++)w4(this,a<<1);this.computeSlot=null}field(A,i=!0){let n=this.config.address[A.id];if(n==null){if(i)throw new RangeError("Field is not present in this state");return}return w4(this,n),Aw(this,n)}update(...A){return PAA(this,A,!0)}applyTransaction(A){let i=this.config,{base:n,compartments:o}=i;for(let a of A.effects)a.is(ug.reconfigure)?(i&&(o=new Map,i.compartments.forEach((c,l)=>o.set(l,c)),i=null),o.set(a.value.compartment,a.value.extension)):a.is(ki.reconfigure)?(i=null,n=a.value):a.is(ki.appendConfig)&&(i=null,n=CE(n).concat(a.value));let r;i?r=A.startState.values.slice():(i=$5.resolve(n,o,this),r=new t(i,this.doc,this.selection,i.dynamicSlots.map(()=>null),(c,l)=>l.reconfigure(c,this),null).values);let s=A.startState.facet(LL)?A.newSelection:A.newSelection.asSingle();new t(i,A.newDoc,s,r,(a,c)=>c.update(a,A),A)}replaceSelection(A){return typeof A=="string"&&(A=this.toText(A)),this.changeByRange(i=>({changes:{from:i.from,to:i.to,insert:A},range:ie.cursor(i.from+A.length)}))}changeByRange(A){let i=this.selection,n=A(i.ranges[0]),o=this.changes(n.changes),r=[n.range],s=CE(n.effects);for(let a=1;a<i.ranges.length;a++){let c=A(i.ranges[a]),l=this.changes(c.changes),I=l.map(o);for(let d=0;d<a;d++)r[d]=r[d].map(I);let C=o.mapDesc(l,!0);r.push(c.range.map(C)),o=o.compose(I),s=ki.mapEffects(s,I).concat(ki.mapEffects(CE(c.effects),C))}return{changes:o,selection:ie.create(r,i.mainIndex),effects:s}}changes(A=[]){return A instanceof ns?A:ns.of(A,this.doc.length,this.facet(t.lineSeparator))}toText(A){return qi.of(A.split(this.facet(t.lineSeparator)||NL))}sliceDoc(A=0,i=this.doc.length){return this.doc.sliceString(A,i,this.lineBreak)}facet(A){let i=this.config.address[A.id];return i==null?A.default:(w4(this,i),Aw(this,i))}toJSON(A){let i={doc:this.sliceDoc(),selection:this.selection.toJSON()};if(A)for(let n in A){let o=A[n];o instanceof To&&this.config.address[o.id]!=null&&(i[n]=o.spec.toJSON(this.field(A[n]),this))}return i}static fromJSON(A,i={},n){if(!A||typeof A.doc!="string")throw new RangeError("Invalid JSON representation for EditorState");let o=[];if(n){for(let r in n)if(Object.prototype.hasOwnProperty.call(A,r)){let s=n[r],a=A[r];o.push(s.init(c=>s.spec.fromJSON(a,c)))}}return t.create({doc:A.doc,selection:ie.fromJSON(A.selection),extensions:i.extensions?o.concat([i.extensions]):o})}static create(A={}){let i=$5.resolve(A.extensions||[],new Map),n=A.doc instanceof qi?A.doc:qi.of((A.doc||"").split(i.staticFacet(t.lineSeparator)||NL)),o=A.selection?A.selection instanceof ie?A.selection:ie.single(A.selection.anchor,A.selection.head):ie.single(0);return YAA(o,n.length),i.staticFacet(LL)||(o=o.asSingle()),new t(i,n,o,i.dynamicSlots.map(()=>null),(r,s)=>s.create(r),null)}get tabSize(){return this.facet(t.tabSize)}get lineBreak(){return this.facet(t.lineSeparator)||`
`}get readOnly(){return this.facet(NAA)}phrase(A,...i){for(let n of this.facet(t.phrases))if(Object.prototype.hasOwnProperty.call(n,A)){A=n[A];break}return i.length&&(A=A.replace(/\$(\$|\d*)/g,(n,o)=>{if(o=="$")return"$";let r=+(o||1);return!r||r>i.length?n:i[r-1]})),A}languageDataAt(A,i,n=-1){let o=[];for(let r of this.facet(FAA))for(let s of r(this,i,n))Object.prototype.hasOwnProperty.call(s,A)&&o.push(s[A]);return o}charCategorizer(A){return HSA(this.languageDataAt("wordChars",A).join(""))}wordAt(A){let{text:i,from:n,length:o}=this.doc.lineAt(A),r=this.charCategorizer(A),s=A-n,a=A-n;for(;s>0;){let c=fr(i,s,!1);if(r(i.slice(c,s))!=Vn.Word)break;s=c}for(;a<o;){let c=fr(i,a);if(r(i.slice(a,c))!=Vn.Word)break;a=c}return s==a?null:ie.range(s+n,a+n)}}return t.allowMultipleSelections=LL,t.tabSize=Te.define({combine:e=>e.length?e[0]:4}),t.lineSeparator=JAA,t.readOnly=NAA,t.phrases=Te.define({compare(e,A){let i=Object.keys(e),n=Object.keys(A);return i.length==n.length&&i.every(o=>e[o]==A[o])}}),t.languageData=FAA,t.changeFilter=TAA,t.transactionFilter=zAA,t.transactionExtender=HAA,t})();ug.reconfigure=ki.define();function zr(t,e,A={}){let i={};for(let n of t)for(let o of Object.keys(n)){let r=n[o],s=i[o];if(s===void 0)i[o]=r;else if(!(s===r||r===void 0))if(Object.hasOwnProperty.call(A,o))i[o]=A[o](s,r);else throw new Error("Config merge conflict for field "+o)}for(let n in e)i[n]===void 0&&(i[n]=e[n]);return i}var dl=class{eq(e){return this==e}range(e,A=e){return y4.create(e,A,this)}};dl.prototype.startSide=dl.prototype.endSide=0;dl.prototype.point=!1;dl.prototype.mapMode=is.TrackDel;var y4=class t{constructor(e,A,i){this.from=e,this.to=A,this.value=i}static create(e,A,i){return new t(e,A,i)}};function zL(t,e){return t.from-e.from||t.value.startSide-e.value.startSide}var HL=class t{constructor(e,A,i,n){this.from=e,this.to=A,this.value=i,this.maxPoint=n}get length(){return this.to[this.to.length-1]}findIndex(e,A,i,n=0){let o=i?this.to:this.from;for(let r=n,s=o.length;;){if(r==s)return r;let a=r+s>>1,c=o[a]-e||(i?this.value[a].endSide:this.value[a].startSide)-A;if(a==r)return c>=0?r:s;c>=0?s=a:r=a+1}}between(e,A,i,n){for(let o=this.findIndex(A,-1e9,!0),r=this.findIndex(i,1e9,!1,o);o<r;o++)if(n(this.from[o]+e,this.to[o]+e,this.value[o])===!1)return!1}map(e,A){let i=[],n=[],o=[],r=-1,s=-1;for(let a=0;a<this.value.length;a++){let c=this.value[a],l=this.from[a]+e,I=this.to[a]+e,C,d;if(l==I){let B=A.mapPos(l,c.startSide,c.mapMode);if(B==null||(C=d=B,c.startSide!=c.endSide&&(d=A.mapPos(l,c.endSide),d<C)))continue}else if(C=A.mapPos(l,c.startSide),d=A.mapPos(I,c.endSide),C>d||C==d&&c.startSide>0&&c.endSide<=0)continue;(d-C||c.endSide-c.startSide)<0||(r<0&&(r=C),c.point&&(s=Math.max(s,d-C)),i.push(c),n.push(C-r),o.push(d-r))}return{mapped:i.length?new t(n,o,i,s):null,pos:r}}},Zn=(()=>{class t{constructor(A,i,n,o){this.chunkPos=A,this.chunk=i,this.nextLayer=n,this.maxPoint=o}static create(A,i,n,o){return new t(A,i,n,o)}get length(){let A=this.chunk.length-1;return A<0?0:Math.max(this.chunkEnd(A),this.nextLayer.length)}get size(){if(this.isEmpty)return 0;let A=this.nextLayer.size;for(let i of this.chunk)A+=i.value.length;return A}chunkEnd(A){return this.chunkPos[A]+this.chunk[A].length}update(A){let{add:i=[],sort:n=!1,filterFrom:o=0,filterTo:r=this.length}=A,s=A.filter;if(i.length==0&&!s)return this;if(n&&(i=i.slice().sort(zL)),this.isEmpty)return i.length?t.of(i):this;let a=new ew(this,null,-1).goto(0),c=0,l=[],I=new os;for(;a.value||c<i.length;)if(c<i.length&&(a.from-i[c].from||a.startSide-i[c].value.startSide)>=0){let C=i[c++];I.addInner(C.from,C.to,C.value)||l.push(C)}else a.rangeIndex==1&&a.chunkIndex<this.chunk.length&&(c==i.length||this.chunkEnd(a.chunkIndex)<i[c].from)&&(!s||o>this.chunkEnd(a.chunkIndex)||r<this.chunkPos[a.chunkIndex])&&I.addChunk(this.chunkPos[a.chunkIndex],this.chunk[a.chunkIndex])?a.nextChunk():((!s||o>a.to||r<a.from||s(a.from,a.to,a.value))&&(I.addInner(a.from,a.to,a.value)||l.push(y4.create(a.from,a.to,a.value))),a.next());return I.finishInner(this.nextLayer.isEmpty&&!l.length?t.empty:this.nextLayer.update({add:l,filter:s,filterFrom:o,filterTo:r}))}map(A){if(A.empty||this.isEmpty)return this;let i=[],n=[],o=-1;for(let s=0;s<this.chunk.length;s++){let a=this.chunkPos[s],c=this.chunk[s],l=A.touchesRange(a,a+c.length);if(l===!1)o=Math.max(o,c.maxPoint),i.push(c),n.push(A.mapPos(a));else if(l===!0){let{mapped:I,pos:C}=c.map(a,A);I&&(o=Math.max(o,I.maxPoint),i.push(I),n.push(C))}}let r=this.nextLayer.map(A);return i.length==0?r:new t(n,i,r||t.empty,o)}between(A,i,n){if(!this.isEmpty){for(let o=0;o<this.chunk.length;o++){let r=this.chunkPos[o],s=this.chunk[o];if(i>=r&&A<=r+s.length&&s.between(r,A-r,i-r,n)===!1)return}this.nextLayer.between(A,i,n)}}iter(A=0){return v4.from([this]).goto(A)}get isEmpty(){return this.nextLayer==this}static iter(A,i=0){return v4.from(A).goto(i)}static compare(A,i,n,o,r=-1){let s=A.filter(C=>C.maxPoint>0||!C.isEmpty&&C.maxPoint>=r),a=i.filter(C=>C.maxPoint>0||!C.isEmpty&&C.maxPoint>=r),c=_AA(s,a,n),l=new sC(s,c,r),I=new sC(a,c,r);n.iterGaps((C,d,B)=>GAA(l,C,I,d,B,o)),n.empty&&n.length==0&&GAA(l,0,I,0,0,o)}static eq(A,i,n=0,o){o==null&&(o=999999999);let r=A.filter(I=>!I.isEmpty&&i.indexOf(I)<0),s=i.filter(I=>!I.isEmpty&&A.indexOf(I)<0);if(r.length!=s.length)return!1;if(!r.length)return!0;let a=_AA(r,s),c=new sC(r,a,0).goto(n),l=new sC(s,a,0).goto(n);for(;;){if(c.to!=l.to||!OL(c.active,l.active)||c.point&&(!l.point||!c.point.eq(l.point)))return!1;if(c.to>o)return!0;c.next(),l.next()}}static spans(A,i,n,o,r=-1){let s=new sC(A,null,r).goto(i),a=i,c=s.openStart;for(;;){let l=Math.min(s.to,n);if(s.point){let I=s.activeForPoint(s.to),C=s.pointFrom<i?I.length+1:s.point.startSide<0?I.length:Math.min(I.length,c);o.point(a,l,s.point,I,C,s.pointRank),c=Math.min(s.openEnd(l),I.length)}else l>a&&(o.span(a,l,s.active,c),c=s.openEnd(l));if(s.to>n)return c+(s.point&&s.to>n?1:0);a=s.to,s.next()}}static of(A,i=!1){let n=new os;for(let o of A instanceof y4?[A]:i?OSA(A):A)n.add(o.from,o.to,o.value);return n.finish()}static join(A){if(!A.length)return t.empty;let i=A[A.length-1];for(let n=A.length-2;n>=0;n--)for(let o=A[n];o!=t.empty;o=o.nextLayer)i=new t(o.chunkPos,o.chunk,i,Math.max(o.maxPoint,i.maxPoint));return i}}return t.empty=new t([],[],null,-1),t})();function OSA(t){if(t.length>1)for(let e=t[0],A=1;A<t.length;A++){let i=t[A];if(zL(e,i)>0)return t.slice().sort(zL);e=i}return t}Zn.empty.nextLayer=Zn.empty;var os=class t{finishChunk(e){this.chunks.push(new HL(this.from,this.to,this.value,this.maxPoint)),this.chunkPos.push(this.chunkStart),this.chunkStart=-1,this.setMaxPoint=Math.max(this.setMaxPoint,this.maxPoint),this.maxPoint=-1,e&&(this.from=[],this.to=[],this.value=[])}constructor(){this.chunks=[],this.chunkPos=[],this.chunkStart=-1,this.last=null,this.lastFrom=-1e9,this.lastTo=-1e9,this.from=[],this.to=[],this.value=[],this.maxPoint=-1,this.setMaxPoint=-1,this.nextLayer=null}add(e,A,i){this.addInner(e,A,i)||(this.nextLayer||(this.nextLayer=new t)).add(e,A,i)}addInner(e,A,i){let n=e-this.lastTo||i.startSide-this.last.endSide;if(n<=0&&(e-this.lastFrom||i.startSide-this.last.startSide)<0)throw new Error("Ranges must be added sorted by `from` position and `startSide`");return n<0?!1:(this.from.length==250&&this.finishChunk(!0),this.chunkStart<0&&(this.chunkStart=e),this.from.push(e-this.chunkStart),this.to.push(A-this.chunkStart),this.last=i,this.lastFrom=e,this.lastTo=A,this.value.push(i),i.point&&(this.maxPoint=Math.max(this.maxPoint,A-e)),!0)}addChunk(e,A){if((e-this.lastTo||A.value[0].startSide-this.last.endSide)<0)return!1;this.from.length&&this.finishChunk(!0),this.setMaxPoint=Math.max(this.setMaxPoint,A.maxPoint),this.chunks.push(A),this.chunkPos.push(e);let i=A.value.length-1;return this.last=A.value[i],this.lastFrom=A.from[i]+e,this.lastTo=A.to[i]+e,!0}finish(){return this.finishInner(Zn.empty)}finishInner(e){if(this.from.length&&this.finishChunk(!1),this.chunks.length==0)return e;let A=Zn.create(this.chunkPos,this.chunks,this.nextLayer?this.nextLayer.finishInner(e):e,this.setMaxPoint);return this.from=null,A}};function _AA(t,e,A){let i=new Map;for(let o of t)for(let r=0;r<o.chunk.length;r++)o.chunk[r].maxPoint<=0&&i.set(o.chunk[r],o.chunkPos[r]);let n=new Set;for(let o of e)for(let r=0;r<o.chunk.length;r++){let s=i.get(o.chunk[r]);s!=null&&(A?A.mapPos(s):s)==o.chunkPos[r]&&!A?.touchesRange(s,s+o.chunk[r].length)&&n.add(o.chunk[r])}return n}var ew=class{constructor(e,A,i,n=0){this.layer=e,this.skip=A,this.minPoint=i,this.rank=n}get startSide(){return this.value?this.value.startSide:0}get endSide(){return this.value?this.value.endSide:0}goto(e,A=-1e9){return this.chunkIndex=this.rangeIndex=0,this.gotoInner(e,A,!1),this}gotoInner(e,A,i){for(;this.chunkIndex<this.layer.chunk.length;){let n=this.layer.chunk[this.chunkIndex];if(!(this.skip&&this.skip.has(n)||this.layer.chunkEnd(this.chunkIndex)<e||n.maxPoint<this.minPoint))break;this.chunkIndex++,i=!1}if(this.chunkIndex<this.layer.chunk.length){let n=this.layer.chunk[this.chunkIndex].findIndex(e-this.layer.chunkPos[this.chunkIndex],A,!0);(!i||this.rangeIndex<n)&&this.setRangeIndex(n)}this.next()}forward(e,A){(this.to-e||this.endSide-A)<0&&this.gotoInner(e,A,!0)}next(){for(;;)if(this.chunkIndex==this.layer.chunk.length){this.from=this.to=1e9,this.value=null;break}else{let e=this.layer.chunkPos[this.chunkIndex],A=this.layer.chunk[this.chunkIndex],i=e+A.from[this.rangeIndex];if(this.from=i,this.to=e+A.to[this.rangeIndex],this.value=A.value[this.rangeIndex],this.setRangeIndex(this.rangeIndex+1),this.minPoint<0||this.value.point&&this.to-this.from>=this.minPoint)break}}setRangeIndex(e){if(e==this.layer.chunk[this.chunkIndex].value.length){if(this.chunkIndex++,this.skip)for(;this.chunkIndex<this.layer.chunk.length&&this.skip.has(this.layer.chunk[this.chunkIndex]);)this.chunkIndex++;this.rangeIndex=0}else this.rangeIndex=e}nextChunk(){this.chunkIndex++,this.rangeIndex=0,this.next()}compare(e){return this.from-e.from||this.startSide-e.startSide||this.rank-e.rank||this.to-e.to||this.endSide-e.endSide}},v4=class t{constructor(e){this.heap=e}static from(e,A=null,i=-1){let n=[];for(let o=0;o<e.length;o++)for(let r=e[o];!r.isEmpty;r=r.nextLayer)r.maxPoint>=i&&n.push(new ew(r,A,i,o));return n.length==1?n[0]:new t(n)}get startSide(){return this.value?this.value.startSide:0}goto(e,A=-1e9){for(let i of this.heap)i.goto(e,A);for(let i=this.heap.length>>1;i>=0;i--)xL(this.heap,i);return this.next(),this}forward(e,A){for(let i of this.heap)i.forward(e,A);for(let i=this.heap.length>>1;i>=0;i--)xL(this.heap,i);(this.to-e||this.value.endSide-A)<0&&this.next()}next(){if(this.heap.length==0)this.from=this.to=1e9,this.value=null,this.rank=-1;else{let e=this.heap[0];this.from=e.from,this.to=e.to,this.value=e.value,this.rank=e.rank,e.value&&e.next(),xL(this.heap,0)}}};function xL(t,e){for(let A=t[e];;){let i=(e<<1)+1;if(i>=t.length)break;let n=t[i];if(i+1<t.length&&n.compare(t[i+1])>=0&&(n=t[i+1],i++),A.compare(n)<0)break;t[i]=A,t[e]=n,e=i}}var sC=class{constructor(e,A,i){this.minPoint=i,this.active=[],this.activeTo=[],this.activeRank=[],this.minActive=-1,this.point=null,this.pointFrom=0,this.pointRank=0,this.to=-1e9,this.endSide=0,this.openStart=-1,this.cursor=v4.from(e,A,i)}goto(e,A=-1e9){return this.cursor.goto(e,A),this.active.length=this.activeTo.length=this.activeRank.length=0,this.minActive=-1,this.to=e,this.endSide=A,this.openStart=-1,this.next(),this}forward(e,A){for(;this.minActive>-1&&(this.activeTo[this.minActive]-e||this.active[this.minActive].endSide-A)<0;)this.removeActive(this.minActive);this.cursor.forward(e,A)}removeActive(e){j5(this.active,e),j5(this.activeTo,e),j5(this.activeRank,e),this.minActive=UAA(this.active,this.activeTo)}addActive(e){let A=0,{value:i,to:n,rank:o}=this.cursor;for(;A<this.activeRank.length&&(o-this.activeRank[A]||n-this.activeTo[A])>0;)A++;q5(this.active,A,i),q5(this.activeTo,A,n),q5(this.activeRank,A,o),e&&q5(e,A,this.cursor.from),this.minActive=UAA(this.active,this.activeTo)}next(){let e=this.to,A=this.point;this.point=null;let i=this.openStart<0?[]:null;for(;;){let n=this.minActive;if(n>-1&&(this.activeTo[n]-this.cursor.from||this.active[n].endSide-this.cursor.startSide)<0){if(this.activeTo[n]>e){this.to=this.activeTo[n],this.endSide=this.active[n].endSide;break}this.removeActive(n),i&&j5(i,n)}else if(this.cursor.value)if(this.cursor.from>e){this.to=this.cursor.from,this.endSide=this.cursor.startSide;break}else{let o=this.cursor.value;if(!o.point)this.addActive(i),this.cursor.next();else if(A&&this.cursor.to==this.to&&this.cursor.from<this.cursor.to)this.cursor.next();else{this.point=o,this.pointFrom=this.cursor.from,this.pointRank=this.cursor.rank,this.to=this.cursor.to,this.endSide=o.endSide,this.cursor.next(),this.forward(this.to,this.endSide);break}}else{this.to=this.endSide=1e9;break}}if(i){this.openStart=0;for(let n=i.length-1;n>=0&&i[n]<e;n--)this.openStart++}}activeForPoint(e){if(!this.active.length)return this.active;let A=[];for(let i=this.active.length-1;i>=0&&!(this.activeRank[i]<this.pointRank);i--)(this.activeTo[i]>e||this.activeTo[i]==e&&this.active[i].endSide>=this.point.endSide)&&A.push(this.active[i]);return A.reverse()}openEnd(e){let A=0;for(let i=this.activeTo.length-1;i>=0&&this.activeTo[i]>e;i--)A++;return A}};function GAA(t,e,A,i,n,o){t.goto(e),A.goto(i);let r=i+n,s=i,a=i-e;for(;;){let c=t.to+a-A.to,l=c||t.endSide-A.endSide,I=l<0?t.to+a:A.to,C=Math.min(I,r);if(t.point||A.point?t.point&&A.point&&(t.point==A.point||t.point.eq(A.point))&&OL(t.activeForPoint(t.to),A.activeForPoint(A.to))||o.comparePoint(s,C,t.point,A.point):C>s&&!OL(t.active,A.active)&&o.compareRange(s,C,t.active,A.active),I>r)break;(c||t.openEnd!=A.openEnd)&&o.boundChange&&o.boundChange(I),s=I,l<=0&&t.next(),l>=0&&A.next()}}function OL(t,e){if(t.length!=e.length)return!1;for(let A=0;A<t.length;A++)if(t[A]!=e[A]&&!t[A].eq(e[A]))return!1;return!0}function j5(t,e){for(let A=e,i=t.length-1;A<i;A++)t[A]=t[A+1];t.pop()}function q5(t,e,A){for(let i=t.length-1;i>=e;i--)t[i+1]=t[i];t[e]=A}function UAA(t,e){let A=-1,i=1e9;for(let n=0;n<e.length;n++)(e[n]-i||t[n].endSide-t[A].endSide)<0&&(A=n,i=e[n]);return A}function G0(t,e,A=t.length){let i=0;for(let n=0;n<A&&n<t.length;)t.charCodeAt(n)==9?(i+=e-i%e,n++):(i++,n=fr(t,n));return i}function tw(t,e,A,i){for(let n=0,o=0;;){if(o>=e)return n;if(n==t.length)break;o+=t.charCodeAt(n)==9?A-o%A:1,n=fr(t,n)}return i===!0?-1:t.length}var qL="\u037C",jAA=typeof Symbol>"u"?"__"+qL:Symbol.for(qL),VL=typeof Symbol>"u"?"__styleSet"+Math.floor(Math.random()*1e8):Symbol("styleSet"),qAA=typeof globalThis<"u"?globalThis:typeof window<"u"?window:{},xc=class{constructor(e,A){this.rules=[];let{finish:i}=A||{};function n(r){return/^@/.test(r)?[r]:r.split(/,\s*/)}function o(r,s,a,c){let l=[],I=/^@(\w+)\b/.exec(r[0]),C=I&&I[1]=="keyframes";if(I&&s==null)return a.push(r[0]+";");for(let d in s){let B=s[d];if(/&/.test(d))o(d.split(/,\s*/).map(E=>r.map(Q=>E.replace(/&/,Q))).reduce((E,Q)=>E.concat(Q)),B,a);else if(B&&typeof B=="object"){if(!I)throw new RangeError("The value of a property ("+d+") should be a primitive value.");o(n(d),B,l,C)}else B!=null&&l.push(d.replace(/_.*/,"").replace(/[A-Z]/g,E=>"-"+E.toLowerCase())+": "+B+";")}(l.length||C)&&a.push((i&&!I&&!c?r.map(i):r).join(", ")+" {"+l.join(" ")+"}")}for(let r in e)o(n(r),e[r],this.rules)}getRules(){return this.rules.join(`
`)}static newName(){let e=qAA[jAA]||1;return qAA[jAA]=e+1,qL+e.toString(36)}static mount(e,A,i){let n=e[VL],o=i&&i.nonce;n?o&&n.setNonce(o):n=new ZL(e,o),n.mount(Array.isArray(A)?A:[A],e)}},VAA=new Map,ZL=class{constructor(e,A){let i=e.ownerDocument||e,n=i.defaultView;if(!e.head&&e.adoptedStyleSheets&&n.CSSStyleSheet){let o=VAA.get(i);if(o)return e[VL]=o;this.sheet=new n.CSSStyleSheet,VAA.set(i,this)}else this.styleTag=i.createElement("style"),A&&this.styleTag.setAttribute("nonce",A);this.modules=[],e[VL]=this}mount(e,A){let i=this.sheet,n=0,o=0;for(let r=0;r<e.length;r++){let s=e[r],a=this.modules.indexOf(s);if(a<o&&a>-1&&(this.modules.splice(a,1),o--,a=-1),a==-1){if(this.modules.splice(o++,0,s),i)for(let c=0;c<s.rules.length;c++)i.insertRule(s.rules[c],n++)}else{for(;o<a;)n+=this.modules[o++].rules.length;n+=s.rules.length,o++}}if(i)A.adoptedStyleSheets.indexOf(this.sheet)<0&&(A.adoptedStyleSheets=[this.sheet,...A.adoptedStyleSheets]);else{let r="";for(let a=0;a<this.modules.length;a++)r+=this.modules[a].getRules()+`
`;this.styleTag.textContent=r;let s=A.head||A;this.styleTag.parentNode!=s&&s.insertBefore(this.styleTag,s.firstChild)}}setNonce(e){this.styleTag&&this.styleTag.getAttribute("nonce")!=e&&this.styleTag.setAttribute("nonce",e)}};var U0={8:"Backspace",9:"Tab",10:"Enter",12:"NumLock",13:"Enter",16:"Shift",17:"Control",18:"Alt",20:"CapsLock",27:"Escape",32:" ",33:"PageUp",34:"PageDown",35:"End",36:"Home",37:"ArrowLeft",38:"ArrowUp",39:"ArrowRight",40:"ArrowDown",44:"PrintScreen",45:"Insert",46:"Delete",59:";",61:"=",91:"Meta",92:"Meta",106:"*",107:"+",108:",",109:"-",110:".",111:"/",144:"NumLock",145:"ScrollLock",160:"Shift",161:"Shift",162:"Control",163:"Control",164:"Alt",165:"Alt",173:"-",186:";",187:"=",188:",",189:"-",190:".",191:"/",192:"`",219:"[",220:"\\",221:"]",222:"'"},BE={48:")",49:"!",50:"@",51:"#",52:"$",53:"%",54:"^",55:"&",56:"*",57:"(",59:":",61:"+",173:"_",186:":",187:"+",188:"<",189:"_",190:">",191:"?",192:"~",219:"{",220:"|",221:"}",222:'"'},PSA=typeof navigator<"u"&&/Mac/.test(navigator.platform),jSA=typeof navigator<"u"&&/MSIE \d|Trident\/(?:[7-9]|\d{2,})\..*rv:(\d+)/.exec(navigator.userAgent);for(mr=0;mr<10;mr++)U0[48+mr]=U0[96+mr]=String(mr);var mr;for(mr=1;mr<=24;mr++)U0[mr+111]="F"+mr;var mr;for(mr=65;mr<=90;mr++)U0[mr]=String.fromCharCode(mr+32),BE[mr]=String.fromCharCode(mr);var mr;for(iw in U0)BE.hasOwnProperty(iw)||(BE[iw]=U0[iw]);var iw;function ZAA(t){var e=PSA&&t.metaKey&&t.shiftKey&&!t.ctrlKey&&!t.altKey||jSA&&t.shiftKey&&t.key&&t.key.length==1||t.key=="Unidentified",A=!e&&t.key||(t.shiftKey?BE:U0)[t.keyCode]||t.key||"Unidentified";return A=="Esc"&&(A="Escape"),A=="Del"&&(A="Delete"),A=="Left"&&(A="ArrowLeft"),A=="Up"&&(A="ArrowUp"),A=="Right"&&(A="ArrowRight"),A=="Down"&&(A="ArrowDown"),A}function kn(){var t=arguments[0];typeof t=="string"&&(t=document.createElement(t));var e=1,A=arguments[1];if(A&&typeof A=="object"&&A.nodeType==null&&!Array.isArray(A)){for(var i in A)if(Object.prototype.hasOwnProperty.call(A,i)){var n=A[i];typeof n=="string"?t.setAttribute(i,n):n!=null&&(t[i]=n)}e++}for(;e<arguments.length;e++)WAA(t,arguments[e]);return t}function WAA(t,e){if(typeof e=="string")t.appendChild(document.createTextNode(e));else if(e!=null)if(e.nodeType!=null)t.appendChild(e);else if(Array.isArray(e))for(var A=0;A<e.length;A++)WAA(t,e[A]);else throw new RangeError("Unsupported child node: "+e)}function Y4(t){let e;return t.nodeType==11?e=t.getSelection?t:t.ownerDocument:e=t,e.getSelection()}function rx(t,e){return e?t==e||t.contains(e.nodeType!=1?e.parentNode:e):!1}function Cw(t,e){if(!e.anchorNode)return!1;try{return rx(t,e.anchorNode)}catch{return!1}}function J4(t){return t.nodeType==3?IC(t,0,t.nodeValue.length).getClientRects():t.nodeType==1?t.getClientRects():[]}function x4(t,e,A,i){return A?XAA(t,e,A,i,-1)||XAA(t,e,A,i,1):!1}function gC(t){for(var e=0;;e++)if(t=t.previousSibling,!t)return e}function fw(t){return t.nodeType==1&&/^(DIV|P|LI|UL|OL|BLOCKQUOTE|DD|DT|H\d|SECTION|PRE)$/.test(t.nodeName)}function XAA(t,e,A,i,n){for(;;){if(t==A&&e==i)return!0;if(e==(n<0?0:Dg(t))){if(t.nodeName=="DIV")return!1;let o=t.parentNode;if(!o||o.nodeType!=1)return!1;e=gC(t)+(n<0?0:1),t=o}else if(t.nodeType==1){if(t=t.childNodes[e+(n<0?-1:0)],t.nodeType==1&&t.contentEditable=="false")return!1;e=n<0?Dg(t):0}else return!1}}function Dg(t){return t.nodeType==3?t.nodeValue.length:t.childNodes.length}function Nw(t,e){let A=e?t.left:t.right;return{left:A,right:A,top:t.top,bottom:t.bottom}}function qSA(t){let e=t.visualViewport;return e?{left:0,right:e.width,top:0,bottom:e.height}:{left:0,right:t.innerWidth,top:0,bottom:t.innerHeight}}function zeA(t,e){let A=e.width/t.offsetWidth,i=e.height/t.offsetHeight;return(A>.995&&A<1.005||!isFinite(A)||Math.abs(e.width-t.offsetWidth)<1)&&(A=1),(i>.995&&i<1.005||!isFinite(i)||Math.abs(e.height-t.offsetHeight)<1)&&(i=1),{scaleX:A,scaleY:i}}function VSA(t,e,A,i,n,o,r,s){let a=t.ownerDocument,c=a.defaultView||window;for(let l=t,I=!1;l&&!I;)if(l.nodeType==1){let C,d=l==a.body,B=1,E=1;if(d)C=qSA(c);else{if(/^(fixed|sticky)$/.test(getComputedStyle(l).position)&&(I=!0),l.scrollHeight<=l.clientHeight&&l.scrollWidth<=l.clientWidth){l=l.assignedSlot||l.parentNode;continue}let v=l.getBoundingClientRect();({scaleX:B,scaleY:E}=zeA(l,v)),C={left:v.left,right:v.left+l.clientWidth*B,top:v.top,bottom:v.top+l.clientHeight*E}}let Q=0,u=0;if(n=="nearest")e.top<C.top?(u=e.top-(C.top+r),A>0&&e.bottom>C.bottom+u&&(u=e.bottom-C.bottom+r)):e.bottom>C.bottom&&(u=e.bottom-C.bottom+r,A<0&&e.top-u<C.top&&(u=e.top-(C.top+r)));else{let v=e.bottom-e.top,L=C.bottom-C.top;u=(n=="center"&&v<=L?e.top+v/2-L/2:n=="start"||n=="center"&&A<0?e.top-r:e.bottom-L+r)-C.top}if(i=="nearest"?e.left<C.left?(Q=e.left-(C.left+o),A>0&&e.right>C.right+Q&&(Q=e.right-C.right+o)):e.right>C.right&&(Q=e.right-C.right+o,A<0&&e.left<C.left+Q&&(Q=e.left-(C.left+o))):Q=(i=="center"?e.left+(e.right-e.left)/2-(C.right-C.left)/2:i=="start"==s?e.left-o:e.right-(C.right-C.left)+o)-C.left,Q||u)if(d)c.scrollBy(Q,u);else{let v=0,L=0;if(u){let x=l.scrollTop;l.scrollTop+=u/E,L=(l.scrollTop-x)*E}if(Q){let x=l.scrollLeft;l.scrollLeft+=Q/B,v=(l.scrollLeft-x)*B}e={left:e.left-v,top:e.top-L,right:e.right-v,bottom:e.bottom-L},v&&Math.abs(v-Q)<1&&(i="nearest"),L&&Math.abs(L-u)<1&&(n="nearest")}if(d)break;(e.top<C.top||e.bottom>C.bottom||e.left<C.left||e.right>C.right)&&(e={left:Math.max(e.left,C.left),right:Math.min(e.right,C.right),top:Math.max(e.top,C.top),bottom:Math.min(e.bottom,C.bottom)}),l=l.assignedSlot||l.parentNode}else if(l.nodeType==11)l=l.host;else break}function ZSA(t){let e=t.ownerDocument,A,i;for(let n=t.parentNode;n&&!(n==e.body||A&&i);)if(n.nodeType==1)!i&&n.scrollHeight>n.clientHeight&&(i=n),!A&&n.scrollWidth>n.clientWidth&&(A=n),n=n.assignedSlot||n.parentNode;else if(n.nodeType==11)n=n.host;else break;return{x:A,y:i}}var sx=class{constructor(){this.anchorNode=null,this.anchorOffset=0,this.focusNode=null,this.focusOffset=0}eq(e){return this.anchorNode==e.anchorNode&&this.anchorOffset==e.anchorOffset&&this.focusNode==e.focusNode&&this.focusOffset==e.focusOffset}setRange(e){let{anchorNode:A,focusNode:i}=e;this.set(A,Math.min(e.anchorOffset,A?Dg(A):0),i,Math.min(e.focusOffset,i?Dg(i):0))}set(e,A,i,n){this.anchorNode=e,this.anchorOffset=A,this.focusNode=i,this.focusOffset=n}},EE=null;function HeA(t){if(t.setActive)return t.setActive();if(EE)return t.focus(EE);let e=[];for(let A=t;A&&(e.push(A,A.scrollTop,A.scrollLeft),A!=A.ownerDocument);A=A.parentNode);if(t.focus(EE==null?{get preventScroll(){return EE={preventScroll:!0},!0}}:void 0),!EE){EE=!1;for(let A=0;A<e.length;){let i=e[A++],n=e[A++],o=e[A++];i.scrollTop!=n&&(i.scrollTop=n),i.scrollLeft!=o&&(i.scrollLeft=o)}}}var $AA;function IC(t,e,A=e){let i=$AA||($AA=document.createRange());return i.setEnd(t,A),i.setStart(t,e),i}function mE(t,e,A,i){let n={key:e,code:e,keyCode:A,which:A,cancelable:!0};i&&({altKey:n.altKey,ctrlKey:n.ctrlKey,shiftKey:n.shiftKey,metaKey:n.metaKey}=i);let o=new KeyboardEvent("keydown",n);o.synthetic=!0,t.dispatchEvent(o);let r=new KeyboardEvent("keyup",n);return r.synthetic=!0,t.dispatchEvent(r),o.defaultPrevented||r.defaultPrevented}function WSA(t){for(;t;){if(t&&(t.nodeType==9||t.nodeType==11&&t.host))return t;t=t.assignedSlot||t.parentNode}return null}function OeA(t){for(;t.attributes.length;)t.removeAttributeNode(t.attributes[0])}function XSA(t,e){let A=e.focusNode,i=e.focusOffset;if(!A||e.anchorNode!=A||e.anchorOffset!=i)return!1;for(i=Math.min(i,Dg(A));;)if(i){if(A.nodeType!=1)return!1;let n=A.childNodes[i-1];n.contentEditable=="false"?i--:(A=n,i=Dg(A))}else{if(A==t)return!0;i=gC(A),A=A.parentNode}}function PeA(t){return t.scrollTop>Math.max(1,t.scrollHeight-t.clientHeight-4)}function jeA(t,e){for(let A=t,i=e;;){if(A.nodeType==3&&i>0)return{node:A,offset:i};if(A.nodeType==1&&i>0){if(A.contentEditable=="false")return null;A=A.childNodes[i-1],i=Dg(A)}else if(A.parentNode&&!fw(A))i=gC(A),A=A.parentNode;else return null}}function qeA(t,e){for(let A=t,i=e;;){if(A.nodeType==3&&i<A.nodeValue.length)return{node:A,offset:i};if(A.nodeType==1&&i<A.childNodes.length){if(A.contentEditable=="false")return null;A=A.childNodes[i],i=0}else if(A.parentNode&&!fw(A))i=gC(A)+1,A=A.parentNode;else return null}}var Ts=class t{constructor(e,A,i=!0){this.node=e,this.offset=A,this.precise=i}static before(e,A){return new t(e.parentNode,gC(e),A)}static after(e,A){return new t(e.parentNode,gC(e)+1,A)}},Px=[],mo=class t{constructor(){this.parent=null,this.dom=null,this.flags=2}get overrideDOMText(){return null}get posAtStart(){return this.parent?this.parent.posBefore(this):0}get posAtEnd(){return this.posAtStart+this.length}posBefore(e){let A=this.posAtStart;for(let i of this.children){if(i==e)return A;A+=i.length+i.breakAfter}throw new RangeError("Invalid child in posBefore")}posAfter(e){return this.posBefore(e)+e.length}sync(e,A){if(this.flags&2){let i=this.dom,n=null,o;for(let r of this.children){if(r.flags&7){if(!r.dom&&(o=n?n.nextSibling:i.firstChild)){let s=t.get(o);(!s||!s.parent&&s.canReuseDOM(r))&&r.reuseDOM(o)}r.sync(e,A),r.flags&=-8}if(o=n?n.nextSibling:i.firstChild,A&&!A.written&&A.node==i&&o!=r.dom&&(A.written=!0),r.dom.parentNode==i)for(;o&&o!=r.dom;)o=AeA(o);else i.insertBefore(r.dom,o);n=r.dom}for(o=n?n.nextSibling:i.firstChild,o&&A&&A.node==i&&(A.written=!0);o;)o=AeA(o)}else if(this.flags&1)for(let i of this.children)i.flags&7&&(i.sync(e,A),i.flags&=-8)}reuseDOM(e){}localPosFromDOM(e,A){let i;if(e==this.dom)i=this.dom.childNodes[A];else{let n=Dg(e)==0?0:A==0?-1:1;for(;;){let o=e.parentNode;if(o==this.dom)break;n==0&&o.firstChild!=o.lastChild&&(e==o.firstChild?n=-1:n=1),e=o}n<0?i=e:i=e.nextSibling}if(i==this.dom.firstChild)return 0;for(;i&&!t.get(i);)i=i.nextSibling;if(!i)return this.length;for(let n=0,o=0;;n++){let r=this.children[n];if(r.dom==i)return o;o+=r.length+r.breakAfter}}domBoundsAround(e,A,i=0){let n=-1,o=-1,r=-1,s=-1;for(let a=0,c=i,l=i;a<this.children.length;a++){let I=this.children[a],C=c+I.length;if(c<e&&C>A)return I.domBoundsAround(e,A,c);if(C>=e&&n==-1&&(n=a,o=c),c>A&&I.dom.parentNode==this.dom){r=a,s=l;break}l=C,c=C+I.breakAfter}return{from:o,to:s<0?i+this.length:s,startDOM:(n?this.children[n-1].dom.nextSibling:null)||this.dom.firstChild,endDOM:r<this.children.length&&r>=0?this.children[r].dom:null}}markDirty(e=!1){this.flags|=2,this.markParentsDirty(e)}markParentsDirty(e){for(let A=this.parent;A;A=A.parent){if(e&&(A.flags|=2),A.flags&1)return;A.flags|=1,e=!1}}setParent(e){this.parent!=e&&(this.parent=e,this.flags&7&&this.markParentsDirty(!0))}setDOM(e){this.dom!=e&&(this.dom&&(this.dom.cmView=null),this.dom=e,e.cmView=this)}get rootView(){for(let e=this;;){let A=e.parent;if(!A)return e;e=A}}replaceChildren(e,A,i=Px){this.markDirty();for(let n=e;n<A;n++){let o=this.children[n];o.parent==this&&i.indexOf(o)<0&&o.destroy()}i.length<250?this.children.splice(e,A-e,...i):this.children=[].concat(this.children.slice(0,e),i,this.children.slice(A));for(let n=0;n<i.length;n++)i[n].setParent(this)}ignoreMutation(e){return!1}ignoreEvent(e){return!1}childCursor(e=this.length){return new mw(this.children,e,this.children.length)}childPos(e,A=1){return this.childCursor().findPos(e,A)}toString(){let e=this.constructor.name.replace("View","");return e+(this.children.length?"("+this.children.join()+")":this.length?"["+(e=="Text"?this.text:this.length)+"]":"")+(this.breakAfter?"#":"")}static get(e){return e.cmView}get isEditable(){return!0}get isWidget(){return!1}get isHidden(){return!1}merge(e,A,i,n,o,r){return!1}become(e){return!1}canReuseDOM(e){return e.constructor==this.constructor&&!((this.flags|e.flags)&8)}getSide(){return 0}destroy(){for(let e of this.children)e.parent==this&&e.destroy();this.parent=null}};mo.prototype.breakAfter=0;function AeA(t){let e=t.nextSibling;return t.parentNode.removeChild(t),e}var mw=class{constructor(e,A,i){this.children=e,this.pos=A,this.i=i,this.off=0}findPos(e,A=1){for(;;){if(e>this.pos||e==this.pos&&(A>0||this.i==0||this.children[this.i-1].breakAfter))return this.off=e-this.pos,this;let i=this.children[--this.i];this.pos-=i.length+i.breakAfter}}};function VeA(t,e,A,i,n,o,r,s,a){let{children:c}=t,l=c.length?c[e]:null,I=o.length?o[o.length-1]:null,C=I?I.breakAfter:r;if(!(e==i&&l&&!r&&!C&&o.length<2&&l.merge(A,n,o.length?I:null,A==0,s,a))){if(i<c.length){let d=c[i];d&&(n<d.length||d.breakAfter&&I?.breakAfter)?(e==i&&(d=d.split(n),n=0),!C&&I&&d.merge(0,n,I,!0,0,a)?o[o.length-1]=d:((n||d.children.length&&!d.children[0].length)&&d.merge(0,n,null,!1,0,a),o.push(d))):d?.breakAfter&&(I?I.breakAfter=1:r=1),i++}for(l&&(l.breakAfter=r,A>0&&(!r&&o.length&&l.merge(A,l.length,o[0],!1,s,0)?l.breakAfter=o.shift().breakAfter:(A<l.length||l.children.length&&l.children[l.children.length-1].length==0)&&l.merge(A,l.length,null,!1,s,0),e++));e<i&&o.length;)if(c[i-1].become(o[o.length-1]))i--,o.pop(),a=o.length?0:s;else if(c[e].become(o[0]))e++,o.shift(),s=o.length?0:a;else break;!o.length&&e&&i<c.length&&!c[e-1].breakAfter&&c[i].merge(0,0,c[e-1],!1,s,a)&&e--,(e<i||o.length)&&t.replaceChildren(e,i,o)}}function ZeA(t,e,A,i,n,o){let r=t.childCursor(),{i:s,off:a}=r.findPos(A,1),{i:c,off:l}=r.findPos(e,-1),I=e-A;for(let C of i)I+=C.length;t.length+=I,VeA(t,c,l,s,a,i,0,n,o)}var Da=typeof navigator<"u"?navigator:{userAgent:"",vendor:"",platform:""},ax=typeof document<"u"?document:{documentElement:{style:{}}},cx=/Edge\/(\d+)/.exec(Da.userAgent),WeA=/MSIE \d/.test(Da.userAgent),lx=/Trident\/(?:[7-9]|\d{2,})\..*rv:(\d+)/.exec(Da.userAgent),_w=!!(WeA||lx||cx),eeA=!_w&&/gecko\/(\d+)/i.test(Da.userAgent),WL=!_w&&/Chrome\/(\d+)/.exec(Da.userAgent),teA="webkitFontSmoothing"in ax.documentElement.style,XeA=!_w&&/Apple Computer/.test(Da.vendor),ieA=XeA&&(/Mobile\/\w+/.test(Da.userAgent)||Da.maxTouchPoints>2),He={mac:ieA||/Mac/.test(Da.platform),windows:/Win/.test(Da.platform),linux:/Linux|X11/.test(Da.platform),ie:_w,ie_version:WeA?ax.documentMode||6:lx?+lx[1]:cx?+cx[1]:0,gecko:eeA,gecko_version:eeA?+(/Firefox\/(\d+)/.exec(Da.userAgent)||[0,0])[1]:0,chrome:!!WL,chrome_version:WL?+WL[1]:0,ios:ieA,android:/Android\b/.test(Da.userAgent),webkit:teA,safari:XeA,webkit_version:teA?+(/\bAppleWebKit\/(\d+)/.exec(Da.userAgent)||[0,0])[1]:0,tabSize:ax.documentElement.style.tabSize!=null?"tab-size":"-moz-tab-size"},$SA=256,yg=class t extends mo{constructor(e){super(),this.text=e}get length(){return this.text.length}createDOM(e){this.setDOM(e||document.createTextNode(this.text))}sync(e,A){this.dom||this.createDOM(),this.dom.nodeValue!=this.text&&(A&&A.node==this.dom&&(A.written=!0),this.dom.nodeValue=this.text)}reuseDOM(e){e.nodeType==3&&this.createDOM(e)}merge(e,A,i){return this.flags&8||i&&(!(i instanceof t)||this.length-(A-e)+i.length>$SA||i.flags&8)?!1:(this.text=this.text.slice(0,e)+(i?i.text:"")+this.text.slice(A),this.markDirty(),!0)}split(e){let A=new t(this.text.slice(e));return this.text=this.text.slice(0,e),this.markDirty(),A.flags|=this.flags&8,A}localPosFromDOM(e,A){return e==this.dom?A:A?this.text.length:0}domAtPos(e){return new Ts(this.dom,e)}domBoundsAround(e,A,i){return{from:i,to:i+this.length,startDOM:this.dom,endDOM:this.dom.nextSibling}}coordsAt(e,A){return ARA(this.dom,e,A)}},u1=class t extends mo{constructor(e,A=[],i=0){super(),this.mark=e,this.children=A,this.length=i;for(let n of A)n.setParent(this)}setAttrs(e){if(OeA(e),this.mark.class&&(e.className=this.mark.class),this.mark.attrs)for(let A in this.mark.attrs)e.setAttribute(A,this.mark.attrs[A]);return e}canReuseDOM(e){return super.canReuseDOM(e)&&!((this.flags|e.flags)&8)}reuseDOM(e){e.nodeName==this.mark.tagName.toUpperCase()&&(this.setDOM(e),this.flags|=6)}sync(e,A){this.dom?this.flags&4&&this.setAttrs(this.dom):this.setDOM(this.setAttrs(document.createElement(this.mark.tagName))),super.sync(e,A)}merge(e,A,i,n,o,r){return i&&(!(i instanceof t&&i.mark.eq(this.mark))||e&&o<=0||A<this.length&&r<=0)?!1:(ZeA(this,e,A,i?i.children.slice():[],o-1,r-1),this.markDirty(),!0)}split(e){let A=[],i=0,n=-1,o=0;for(let s of this.children){let a=i+s.length;a>e&&A.push(i<e?s.split(e-i):s),n<0&&i>=e&&(n=o),i=a,o++}let r=this.length-e;return this.length=e,n>-1&&(this.children.length=n,this.markDirty()),new t(this.mark,A,r)}domAtPos(e){return $eA(this,e)}coordsAt(e,A){return etA(this,e,A)}};function ARA(t,e,A){let i=t.nodeValue.length;e>i&&(e=i);let n=e,o=e,r=0;e==0&&A<0||e==i&&A>=0?He.chrome||He.gecko||(e?(n--,r=1):o<i&&(o++,r=-1)):A<0?n--:o<i&&o++;let s=IC(t,n,o).getClientRects();if(!s.length)return null;let a=s[(r?r<0:A>=0)?0:s.length-1];return He.safari&&!r&&a.width==0&&(a=Array.prototype.find.call(s,c=>c.width)||a),r?Nw(a,r<0):a||null}var T4=class t extends mo{static create(e,A,i){return new t(e,A,i)}constructor(e,A,i){super(),this.widget=e,this.length=A,this.side=i,this.prevWidget=null}split(e){let A=t.create(this.widget,this.length-e,this.side);return this.length-=e,A}sync(e){(!this.dom||!this.widget.updateDOM(this.dom,e))&&(this.dom&&this.prevWidget&&this.prevWidget.destroy(this.dom),this.prevWidget=null,this.setDOM(this.widget.toDOM(e)),this.widget.editable||(this.dom.contentEditable="false"))}getSide(){return this.side}merge(e,A,i,n,o,r){return i&&(!(i instanceof t)||!this.widget.compare(i.widget)||e>0&&o<=0||A<this.length&&r<=0)?!1:(this.length=e+(i?i.length:0)+(this.length-A),!0)}become(e){return e instanceof t&&e.side==this.side&&this.widget.constructor==e.widget.constructor?(this.widget.compare(e.widget)||this.markDirty(!0),this.dom&&!this.prevWidget&&(this.prevWidget=this.widget),this.widget=e.widget,this.length=e.length,!0):!1}ignoreMutation(){return!0}ignoreEvent(e){return this.widget.ignoreEvent(e)}get overrideDOMText(){if(this.length==0)return qi.empty;let e=this;for(;e.parent;)e=e.parent;let{view:A}=e,i=A&&A.state.doc,n=this.posAtStart;return i?i.slice(n,n+this.length):qi.empty}domAtPos(e){return(this.length?e==0:this.side>0)?Ts.before(this.dom):Ts.after(this.dom,e==this.length)}domBoundsAround(){return null}coordsAt(e,A){let i=this.widget.coordsAt(this.dom,e,A);if(i)return i;let n=this.dom.getClientRects(),o=null;if(!n.length)return null;let r=this.side?this.side<0:e>0;for(let s=r?n.length-1:0;o=n[s],!(e>0?s==0:s==n.length-1||o.top<o.bottom);s+=r?-1:1);return Nw(o,!r)}get isEditable(){return!1}get isWidget(){return!0}get isHidden(){return this.widget.isHidden}destroy(){super.destroy(),this.dom&&this.widget.destroy(this.dom)}},z4=class t extends mo{constructor(e){super(),this.side=e}get length(){return 0}merge(){return!1}become(e){return e instanceof t&&e.side==this.side}split(){return new t(this.side)}sync(){if(!this.dom){let e=document.createElement("img");e.className="cm-widgetBuffer",e.setAttribute("aria-hidden","true"),this.setDOM(e)}}getSide(){return this.side}domAtPos(e){return this.side>0?Ts.before(this.dom):Ts.after(this.dom)}localPosFromDOM(){return 0}domBoundsAround(){return null}coordsAt(e){return this.dom.getBoundingClientRect()}get overrideDOMText(){return qi.empty}get isHidden(){return!0}};yg.prototype.children=T4.prototype.children=z4.prototype.children=Px;function $eA(t,e){let A=t.dom,{children:i}=t,n=0;for(let o=0;n<i.length;n++){let r=i[n],s=o+r.length;if(!(s==o&&r.getSide()<=0)){if(e>o&&e<s&&r.dom.parentNode==A)return r.domAtPos(e-o);if(e<=o)break;o=s}}for(let o=n;o>0;o--){let r=i[o-1];if(r.dom.parentNode==A)return r.domAtPos(r.length)}for(let o=n;o<i.length;o++){let r=i[o];if(r.dom.parentNode==A)return r.domAtPos(0)}return new Ts(A,0)}function AtA(t,e,A){let i,{children:n}=t;A>0&&e instanceof u1&&n.length&&(i=n[n.length-1])instanceof u1&&i.mark.eq(e.mark)?AtA(i,e.children[0],A-1):(n.push(e),e.setParent(t)),t.length+=e.length}function etA(t,e,A){let i=null,n=-1,o=null,r=-1;function s(c,l){for(let I=0,C=0;I<c.children.length&&C<=l;I++){let d=c.children[I],B=C+d.length;B>=l&&(d.children.length?s(d,l-C):(!o||o.isHidden&&(A>0||tRA(o,d)))&&(B>l||C==B&&d.getSide()>0)?(o=d,r=l-C):(C<l||C==B&&d.getSide()<0&&!d.isHidden)&&(i=d,n=l-C)),C=B}}s(t,e);let a=(A<0?i:o)||i||o;return a?a.coordsAt(Math.max(0,a==i?n:r),A):eRA(t)}function eRA(t){let e=t.dom.lastChild;if(!e)return t.dom.getBoundingClientRect();let A=J4(e);return A[A.length-1]||null}function tRA(t,e){let A=t.coordsAt(0,1),i=e.coordsAt(0,1);return A&&i&&i.top<A.bottom}function gx(t,e){for(let A in t)A=="class"&&e.class?e.class+=" "+t.class:A=="style"&&e.style?e.style+=";"+t.style:e[A]=t[A];return e}var neA=Object.create(null);function pw(t,e,A){if(t==e)return!0;t||(t=neA),e||(e=neA);let i=Object.keys(t),n=Object.keys(e);if(i.length-(A&&i.indexOf(A)>-1?1:0)!=n.length-(A&&n.indexOf(A)>-1?1:0))return!1;for(let o of i)if(o!=A&&(n.indexOf(o)==-1||t[o]!==e[o]))return!1;return!0}function Ix(t,e,A){let i=!1;if(e)for(let n in e)A&&n in A||(i=!0,n=="style"?t.style.cssText="":t.removeAttribute(n));if(A)for(let n in A)e&&e[n]==A[n]||(i=!0,n=="style"?t.style.cssText=A[n]:t.setAttribute(n,A[n]));return i}function iRA(t){let e=Object.create(null);for(let A=0;A<t.attributes.length;A++){let i=t.attributes[A];e[i.name]=i.value}return e}var nc=class{eq(e){return!1}updateDOM(e,A){return!1}compare(e){return this==e||this.constructor==e.constructor&&this.eq(e)}get estimatedHeight(){return-1}get lineBreaks(){return 0}ignoreEvent(e){return!0}coordsAt(e,A,i){return null}get isHidden(){return!1}get editable(){return!1}destroy(e){}},zs=function(t){return t[t.Text=0]="Text",t[t.WidgetBefore=1]="WidgetBefore",t[t.WidgetAfter=2]="WidgetAfter",t[t.WidgetRange=3]="WidgetRange",t}(zs||(zs={})),rt=class extends dl{constructor(e,A,i,n){super(),this.startSide=e,this.endSide=A,this.widget=i,this.spec=n}get heightRelevant(){return!1}static mark(e){return new H4(e)}static widget(e){let A=Math.max(-1e4,Math.min(1e4,e.side||0)),i=!!e.block;return A+=i&&!e.inlineOrder?A>0?3e8:-4e8:A>0?1e8:-1e8,new f1(e,A,A,i,e.widget||null,!1)}static replace(e){let A=!!e.block,i,n;if(e.isBlockGap)i=-5e8,n=4e8;else{let{start:o,end:r}=ttA(e,A);i=(o?A?-3e8:-1:5e8)-1,n=(r?A?2e8:1:-6e8)+1}return new f1(e,i,n,A,e.widget||null,!0)}static line(e){return new O4(e)}static set(e,A=!1){return Zn.of(e,A)}hasHeight(){return this.widget?this.widget.estimatedHeight>-1:!1}};rt.none=Zn.empty;var H4=class t extends rt{constructor(e){let{start:A,end:i}=ttA(e);super(A?-1:5e8,i?1:-6e8,null,e),this.tagName=e.tagName||"span",this.class=e.class||"",this.attrs=e.attributes||null}eq(e){var A,i;return this==e||e instanceof t&&this.tagName==e.tagName&&(this.class||((A=this.attrs)===null||A===void 0?void 0:A.class))==(e.class||((i=e.attrs)===null||i===void 0?void 0:i.class))&&pw(this.attrs,e.attrs,"class")}range(e,A=e){if(e>=A)throw new RangeError("Mark decorations may not be empty");return super.range(e,A)}};H4.prototype.point=!1;var O4=class t extends rt{constructor(e){super(-2e8,-2e8,null,e)}eq(e){return e instanceof t&&this.spec.class==e.spec.class&&pw(this.spec.attributes,e.spec.attributes)}range(e,A=e){if(A!=e)throw new RangeError("Line decoration ranges must be zero-length");return super.range(e,A)}};O4.prototype.mapMode=is.TrackBefore;O4.prototype.point=!0;var f1=class t extends rt{constructor(e,A,i,n,o,r){super(A,i,o,e),this.block=n,this.isReplace=r,this.mapMode=n?A<=0?is.TrackBefore:is.TrackAfter:is.TrackDel}get type(){return this.startSide!=this.endSide?zs.WidgetRange:this.startSide<=0?zs.WidgetBefore:zs.WidgetAfter}get heightRelevant(){return this.block||!!this.widget&&(this.widget.estimatedHeight>=5||this.widget.lineBreaks>0)}eq(e){return e instanceof t&&nRA(this.widget,e.widget)&&this.block==e.block&&this.startSide==e.startSide&&this.endSide==e.endSide}range(e,A=e){if(this.isReplace&&(e>A||e==A&&this.startSide>0&&this.endSide<=0))throw new RangeError("Invalid range for replacement decoration");if(!this.isReplace&&A!=e)throw new RangeError("Widget decorations can only have zero-length ranges");return super.range(e,A)}};f1.prototype.point=!0;function ttA(t,e=!1){let{inclusiveStart:A,inclusiveEnd:i}=t;return A==null&&(A=t.inclusive),i==null&&(i=t.inclusive),{start:A??e,end:i??e}}function nRA(t,e){return t==e||!!(t&&e&&t.compare(e))}function dw(t,e,A,i=0){let n=A.length-1;n>=0&&A[n]+i>=t?A[n]=Math.max(A[n],e):A.push(t,e)}var ss=class t extends mo{constructor(){super(...arguments),this.children=[],this.length=0,this.prevAttrs=void 0,this.attrs=null,this.breakAfter=0}merge(e,A,i,n,o,r){if(i){if(!(i instanceof t))return!1;this.dom||i.transferDOM(this)}return n&&this.setDeco(i?i.attrs:null),ZeA(this,e,A,i?i.children.slice():[],o,r),!0}split(e){let A=new t;if(A.breakAfter=this.breakAfter,this.length==0)return A;let{i,off:n}=this.childPos(e);n&&(A.append(this.children[i].split(n),0),this.children[i].merge(n,this.children[i].length,null,!1,0,0),i++);for(let o=i;o<this.children.length;o++)A.append(this.children[o],0);for(;i>0&&this.children[i-1].length==0;)this.children[--i].destroy();return this.children.length=i,this.markDirty(),this.length=e,A}transferDOM(e){this.dom&&(this.markDirty(),e.setDOM(this.dom),e.prevAttrs=this.prevAttrs===void 0?this.attrs:this.prevAttrs,this.prevAttrs=void 0,this.dom=null)}setDeco(e){pw(this.attrs,e)||(this.dom&&(this.prevAttrs=this.attrs,this.markDirty()),this.attrs=e)}append(e,A){AtA(this,e,A)}addLineDeco(e){let A=e.spec.attributes,i=e.spec.class;A&&(this.attrs=gx(A,this.attrs||{})),i&&(this.attrs=gx({class:i},this.attrs||{}))}domAtPos(e){return $eA(this,e)}reuseDOM(e){e.nodeName=="DIV"&&(this.setDOM(e),this.flags|=6)}sync(e,A){var i;this.dom?this.flags&4&&(OeA(this.dom),this.dom.className="cm-line",this.prevAttrs=this.attrs?null:void 0):(this.setDOM(document.createElement("div")),this.dom.className="cm-line",this.prevAttrs=this.attrs?null:void 0),this.prevAttrs!==void 0&&(Ix(this.dom,this.prevAttrs,this.attrs),this.dom.classList.add("cm-line"),this.prevAttrs=void 0),super.sync(e,A);let n=this.dom.lastChild;for(;n&&mo.get(n)instanceof u1;)n=n.lastChild;if(!n||!this.length||n.nodeName!="BR"&&((i=mo.get(n))===null||i===void 0?void 0:i.isEditable)==!1&&(!He.ios||!this.children.some(o=>o instanceof yg))){let o=document.createElement("BR");o.cmIgnore=!0,this.dom.appendChild(o)}}measureTextSize(){if(this.children.length==0||this.length>20)return null;let e=0,A;for(let i of this.children){if(!(i instanceof yg)||/[^ -~]/.test(i.text))return null;let n=J4(i.dom);if(n.length!=1)return null;e+=n[0].width,A=n[0].height}return e?{lineHeight:this.dom.getBoundingClientRect().height,charWidth:e/this.length,textHeight:A}:null}coordsAt(e,A){let i=etA(this,e,A);if(!this.children.length&&i&&this.parent){let{heightOracle:n}=this.parent.view.viewState,o=i.bottom-i.top;if(Math.abs(o-n.lineHeight)<2&&n.textHeight<o){let r=(o-n.textHeight)/2;return{top:i.top+r,bottom:i.bottom-r,left:i.left,right:i.left}}}return i}become(e){return e instanceof t&&this.children.length==0&&e.children.length==0&&pw(this.attrs,e.attrs)&&this.breakAfter==e.breakAfter}covers(){return!0}static find(e,A){for(let i=0,n=0;i<e.children.length;i++){let o=e.children[i],r=n+o.length;if(r>=A){if(o instanceof t)return o;if(r>A)break}n=r+o.breakAfter}return null}},lC=class t extends mo{constructor(e,A,i){super(),this.widget=e,this.length=A,this.deco=i,this.breakAfter=0,this.prevWidget=null}merge(e,A,i,n,o,r){return i&&(!(i instanceof t)||!this.widget.compare(i.widget)||e>0&&o<=0||A<this.length&&r<=0)?!1:(this.length=e+(i?i.length:0)+(this.length-A),!0)}domAtPos(e){return e==0?Ts.before(this.dom):Ts.after(this.dom,e==this.length)}split(e){let A=this.length-e;this.length=e;let i=new t(this.widget,A,this.deco);return i.breakAfter=this.breakAfter,i}get children(){return Px}sync(e){(!this.dom||!this.widget.updateDOM(this.dom,e))&&(this.dom&&this.prevWidget&&this.prevWidget.destroy(this.dom),this.prevWidget=null,this.setDOM(this.widget.toDOM(e)),this.widget.editable||(this.dom.contentEditable="false"))}get overrideDOMText(){return this.parent?this.parent.view.state.doc.slice(this.posAtStart,this.posAtEnd):qi.empty}domBoundsAround(){return null}become(e){return e instanceof t&&e.widget.constructor==this.widget.constructor?(e.widget.compare(this.widget)||this.markDirty(!0),this.dom&&!this.prevWidget&&(this.prevWidget=this.widget),this.widget=e.widget,this.length=e.length,this.deco=e.deco,this.breakAfter=e.breakAfter,!0):!1}ignoreMutation(){return!0}ignoreEvent(e){return this.widget.ignoreEvent(e)}get isEditable(){return!1}get isWidget(){return!0}coordsAt(e,A){let i=this.widget.coordsAt(this.dom,e,A);return i||(this.widget instanceof P4?null:Nw(this.dom.getBoundingClientRect(),this.length?e==0:A<=0))}destroy(){super.destroy(),this.dom&&this.widget.destroy(this.dom)}covers(e){let{startSide:A,endSide:i}=this.deco;return A==i?!1:e<0?A<0:i>0}},P4=class extends nc{constructor(e){super(),this.height=e}toDOM(){let e=document.createElement("div");return e.className="cm-gap",this.updateDOM(e),e}eq(e){return e.height==this.height}updateDOM(e){return e.style.height=this.height+"px",!0}get editable(){return!0}get estimatedHeight(){return this.height}ignoreEvent(){return!1}},F4=class t{constructor(e,A,i,n){this.doc=e,this.pos=A,this.end=i,this.disallowBlockEffectsFor=n,this.content=[],this.curLine=null,this.breakAtStart=0,this.pendingBuffer=0,this.bufferMarks=[],this.atCursorPos=!0,this.openStart=-1,this.openEnd=-1,this.text="",this.textOff=0,this.cursor=e.iter(),this.skip=A}posCovered(){if(this.content.length==0)return!this.breakAtStart&&this.doc.lineAt(this.pos).from!=this.pos;let e=this.content[this.content.length-1];return!(e.breakAfter||e instanceof lC&&e.deco.endSide<0)}getLine(){return this.curLine||(this.content.push(this.curLine=new ss),this.atCursorPos=!0),this.curLine}flushBuffer(e=this.bufferMarks){this.pendingBuffer&&(this.curLine.append(nw(new z4(-1),e),e.length),this.pendingBuffer=0)}addBlockWidget(e){this.flushBuffer(),this.curLine=null,this.content.push(e)}finish(e){this.pendingBuffer&&e<=this.bufferMarks.length?this.flushBuffer():this.pendingBuffer=0,!this.posCovered()&&!(e&&this.content.length&&this.content[this.content.length-1]instanceof lC)&&this.getLine()}buildText(e,A,i){for(;e>0;){if(this.textOff==this.text.length){let{value:o,lineBreak:r,done:s}=this.cursor.next(this.skip);if(this.skip=0,s)throw new Error("Ran out of text content when drawing inline views");if(r){this.posCovered()||this.getLine(),this.content.length?this.content[this.content.length-1].breakAfter=1:this.breakAtStart=1,this.flushBuffer(),this.curLine=null,this.atCursorPos=!0,e--;continue}else this.text=o,this.textOff=0}let n=Math.min(this.text.length-this.textOff,e,512);this.flushBuffer(A.slice(A.length-i)),this.getLine().append(nw(new yg(this.text.slice(this.textOff,this.textOff+n)),A),i),this.atCursorPos=!0,this.textOff+=n,e-=n,i=0}}span(e,A,i,n){this.buildText(A-e,i,n),this.pos=A,this.openStart<0&&(this.openStart=n)}point(e,A,i,n,o,r){if(this.disallowBlockEffectsFor[r]&&i instanceof f1){if(i.block)throw new RangeError("Block decorations may not be specified via plugins");if(A>this.doc.lineAt(this.pos).to)throw new RangeError("Decorations that replace line breaks may not be specified via plugins")}let s=A-e;if(i instanceof f1)if(i.block)i.startSide>0&&!this.posCovered()&&this.getLine(),this.addBlockWidget(new lC(i.widget||oeA.block,s,i));else{let a=T4.create(i.widget||oeA.inline,s,s?0:i.startSide),c=this.atCursorPos&&!a.isEditable&&o<=n.length&&(e<A||i.startSide>0),l=!a.isEditable&&(e<A||o>n.length||i.startSide<=0),I=this.getLine();this.pendingBuffer==2&&!c&&!a.isEditable&&(this.pendingBuffer=0),this.flushBuffer(n),c&&(I.append(nw(new z4(1),n),o),o=n.length+Math.max(0,o-n.length)),I.append(nw(a,n),o),this.atCursorPos=l,this.pendingBuffer=l?e<A||o>n.length?1:2:0,this.pendingBuffer&&(this.bufferMarks=n.slice())}else this.doc.lineAt(this.pos).from==this.pos&&this.getLine().addLineDeco(i);s&&(this.textOff+s<=this.text.length?this.textOff+=s:(this.skip+=s-(this.text.length-this.textOff),this.text="",this.textOff=0),this.pos=A),this.openStart<0&&(this.openStart=o)}static build(e,A,i,n,o){let r=new t(e,A,i,o);return r.openEnd=Zn.spans(n,A,i,r),r.openStart<0&&(r.openStart=r.openEnd),r.finish(r.openEnd),r}};function nw(t,e){for(let A of e)t=new u1(A,[t],t.length);return t}var oeA=(()=>{class t extends nc{constructor(A){super(),this.tag=A}eq(A){return A.tag==this.tag}toDOM(){return document.createElement(this.tag)}updateDOM(A){return A.nodeName.toLowerCase()==this.tag}get isHidden(){return!0}}return t.inline=new t("span"),t.block=new t("div"),t})(),Wn=function(t){return t[t.LTR=0]="LTR",t[t.RTL=1]="RTL",t}(Wn||(Wn={})),CC=Wn.LTR,jx=Wn.RTL;function itA(t){let e=[];for(let A=0;A<t.length;A++)e.push(1<<+t[A]);return e}var oRA=itA("88888888888888888888888888888888888666888888787833333333337888888000000000000000000000000008888880000000000000000000000000088888888888888888888888888888888888887866668888088888663380888308888800000000000000000000000800000000000000000000000000000008"),rRA=itA("4444448826627288999999999992222222222222222222222222222222222222222222222229999999999999999999994444444444644222822222222222222222222222222222222222222222222222222222222222222222222222222222222222222222222222222222999999949999999229989999223333333333"),Cx=Object.create(null),fg=[];for(let t of["()","[]","{}"]){let e=t.charCodeAt(0),A=t.charCodeAt(1);Cx[e]=A,Cx[A]=-e}function ntA(t){return t<=247?oRA[t]:1424<=t&&t<=1524?2:1536<=t&&t<=1785?rRA[t-1536]:1774<=t&&t<=2220?4:8192<=t&&t<=8204?256:64336<=t&&t<=65023?4:1}var sRA=/[\u0590-\u05f4\u0600-\u06ff\u0700-\u08ac\ufb50-\ufdff]/,pg=class{get dir(){return this.level%2?jx:CC}constructor(e,A,i){this.from=e,this.to=A,this.level=i}side(e,A){return this.dir==A==e?this.to:this.from}forward(e,A){return e==(this.dir==A)}static find(e,A,i,n){let o=-1;for(let r=0;r<e.length;r++){let s=e[r];if(s.from<=A&&s.to>=A){if(s.level==i)return r;(o<0||(n!=0?n<0?s.from<A:s.to>A:e[o].level>s.level))&&(o=r)}}if(o<0)throw new RangeError("Index out of range");return o}};function otA(t,e){if(t.length!=e.length)return!1;for(let A=0;A<t.length;A++){let i=t[A],n=e[A];if(i.from!=n.from||i.to!=n.to||i.direction!=n.direction||!otA(i.inner,n.inner))return!1}return!0}var lo=[];function aRA(t,e,A,i,n){for(let o=0;o<=i.length;o++){let r=o?i[o-1].to:e,s=o<i.length?i[o].from:A,a=o?256:n;for(let c=r,l=a,I=a;c<s;c++){let C=ntA(t.charCodeAt(c));C==512?C=l:C==8&&I==4&&(C=16),lo[c]=C==4?2:C,C&7&&(I=C),l=C}for(let c=r,l=a,I=a;c<s;c++){let C=lo[c];if(C==128)c<s-1&&l==lo[c+1]&&l&24?C=lo[c]=l:lo[c]=256;else if(C==64){let d=c+1;for(;d<s&&lo[d]==64;)d++;let B=c&&l==8||d<A&&lo[d]==8?I==1?1:8:256;for(let E=c;E<d;E++)lo[E]=B;c=d-1}else C==8&&I==1&&(lo[c]=1);l=C,C&7&&(I=C)}}}function cRA(t,e,A,i,n){let o=n==1?2:1;for(let r=0,s=0,a=0;r<=i.length;r++){let c=r?i[r-1].to:e,l=r<i.length?i[r].from:A;for(let I=c,C,d,B;I<l;I++)if(d=Cx[C=t.charCodeAt(I)])if(d<0){for(let E=s-3;E>=0;E-=3)if(fg[E+1]==-d){let Q=fg[E+2],u=Q&2?n:Q&4?Q&1?o:n:0;u&&(lo[I]=lo[fg[E]]=u),s=E;break}}else{if(fg.length==189)break;fg[s++]=I,fg[s++]=C,fg[s++]=a}else if((B=lo[I])==2||B==1){let E=B==n;a=E?0:1;for(let Q=s-3;Q>=0;Q-=3){let u=fg[Q+2];if(u&2)break;if(E)fg[Q+2]|=2;else{if(u&4)break;fg[Q+2]|=4}}}}}function lRA(t,e,A,i){for(let n=0,o=i;n<=A.length;n++){let r=n?A[n-1].to:t,s=n<A.length?A[n].from:e;for(let a=r;a<s;){let c=lo[a];if(c==256){let l=a+1;for(;;)if(l==s){if(n==A.length)break;l=A[n++].to,s=n<A.length?A[n].from:e}else if(lo[l]==256)l++;else break;let I=o==1,C=(l<e?lo[l]:i)==1,d=I==C?I?1:2:i;for(let B=l,E=n,Q=E?A[E-1].to:t;B>a;)B==Q&&(B=A[--E].from,Q=E?A[E-1].to:t),lo[--B]=d;a=l}else o=c,a++}}}function dx(t,e,A,i,n,o,r){let s=i%2?2:1;if(i%2==n%2)for(let a=e,c=0;a<A;){let l=!0,I=!1;if(c==o.length||a<o[c].from){let E=lo[a];E!=s&&(l=!1,I=E==16)}let C=!l&&s==1?[]:null,d=l?i:i+1,B=a;A:for(;;)if(c<o.length&&B==o[c].from){if(I)break A;let E=o[c];if(!l)for(let Q=E.to,u=c+1;;){if(Q==A)break A;if(u<o.length&&o[u].from==Q)Q=o[u++].to;else{if(lo[Q]==s)break A;break}}if(c++,C)C.push(E);else{E.from>a&&r.push(new pg(a,E.from,d));let Q=E.direction==CC!=!(d%2);Bx(t,Q?i+1:i,n,E.inner,E.from,E.to,r),a=E.to}B=E.to}else{if(B==A||(l?lo[B]!=s:lo[B]==s))break;B++}C?dx(t,a,B,i+1,n,C,r):a<B&&r.push(new pg(a,B,d)),a=B}else for(let a=A,c=o.length;a>e;){let l=!0,I=!1;if(!c||a>o[c-1].to){let E=lo[a-1];E!=s&&(l=!1,I=E==16)}let C=!l&&s==1?[]:null,d=l?i:i+1,B=a;A:for(;;)if(c&&B==o[c-1].to){if(I)break A;let E=o[--c];if(!l)for(let Q=E.from,u=c;;){if(Q==e)break A;if(u&&o[u-1].to==Q)Q=o[--u].from;else{if(lo[Q-1]==s)break A;break}}if(C)C.push(E);else{E.to<a&&r.push(new pg(E.to,a,d));let Q=E.direction==CC!=!(d%2);Bx(t,Q?i+1:i,n,E.inner,E.from,E.to,r),a=E.from}B=E.from}else{if(B==e||(l?lo[B-1]!=s:lo[B-1]==s))break;B--}C?dx(t,B,a,i+1,n,C,r):B<a&&r.push(new pg(B,a,d)),a=B}}function Bx(t,e,A,i,n,o,r){let s=e%2?2:1;aRA(t,n,o,i,s),cRA(t,n,o,i,s),lRA(n,o,i,s),dx(t,n,o,e,A,i,r)}function gRA(t,e,A){if(!t)return[new pg(0,0,e==jx?1:0)];if(e==CC&&!A.length&&!sRA.test(t))return rtA(t.length);if(A.length)for(;t.length>lo.length;)lo[lo.length]=256;let i=[],n=e==CC?0:1;return Bx(t,n,n,A,0,t.length,i),i}function rtA(t){return[new pg(0,t,0)]}var stA="";function IRA(t,e,A,i,n){var o;let r=i.head-t.from,s=pg.find(e,r,(o=i.bidiLevel)!==null&&o!==void 0?o:-1,i.assoc),a=e[s],c=a.side(n,A);if(r==c){let C=s+=n?1:-1;if(C<0||C>=e.length)return null;a=e[s=C],r=a.side(!n,A),c=a.side(n,A)}let l=fr(t.text,r,a.forward(n,A));(l<a.from||l>a.to)&&(l=c),stA=t.text.slice(Math.min(r,l),Math.max(r,l));let I=s==(n?e.length-1:0)?null:e[s+(n?1:-1)];return I&&l==c&&I.level+(n?0:1)<a.level?ie.cursor(I.side(!n,A)+t.from,I.forward(n,A)?1:-1,I.level):ie.cursor(l+t.from,a.forward(n,A)?-1:1,a.level)}function CRA(t,e,A){for(let i=e;i<A;i++){let n=ntA(t.charCodeAt(i));if(n==1)return CC;if(n==2||n==4)return jx}return CC}var atA=Te.define(),ctA=Te.define(),ltA=Te.define(),gtA=Te.define(),XL=Te.define(),ItA=Te.define(),CtA=Te.define(),qx=Te.define(),Vx=Te.define(),reA=Te.define({combine:t=>t.some(e=>e)}),dtA=Te.define({combine:t=>t.some(e=>e)}),BtA=Te.define(),N4=class t{constructor(e,A="nearest",i="nearest",n=5,o=5,r=!1){this.range=e,this.y=A,this.x=i,this.yMargin=n,this.xMargin=o,this.isSnapshot=r}map(e){return e.empty?this:new t(this.range.map(e),this.y,this.x,this.yMargin,this.xMargin,this.isSnapshot)}clip(e){return this.range.to<=e.doc.length?this:new t(ie.cursor(e.doc.length),this.y,this.x,this.yMargin,this.xMargin,this.isSnapshot)}},ow=ki.define({map:(t,e)=>t.map(e)}),EtA=ki.define();function Hr(t,e,A){let i=t.facet(gtA);i.length?i[0](e):window.onerror&&window.onerror(String(e),A,void 0,void 0,e)||(A?console.error(A+":",e):console.error(e))}var K0=Te.define({combine:t=>t.length?t[0]:!0}),dRA=0,hE=Te.define({combine(t){return t.filter((e,A)=>{for(let i=0;i<A;i++)if(t[i].plugin==e.plugin)return!1;return!0})}}),Xn=class t{constructor(e,A,i,n,o){this.id=e,this.create=A,this.domEventHandlers=i,this.domEventObservers=n,this.baseExtensions=o(this),this.extension=this.baseExtensions.concat(hE.of({plugin:this,arg:void 0}))}of(e){return this.baseExtensions.concat(hE.of({plugin:this,arg:e}))}static define(e,A){let{eventHandlers:i,eventObservers:n,provide:o,decorations:r}=A||{};return new t(dRA++,e,i,n,s=>{let a=[];return r&&a.push(j4.of(c=>{let l=c.plugin(s);return l?r(l):rt.none})),o&&a.push(o(s)),a})}static fromClass(e,A){return t.define((i,n)=>new e(i,n),A)}},_4=class{constructor(e){this.spec=e,this.mustUpdate=null,this.value=null}get plugin(){return this.spec&&this.spec.plugin}update(e){if(this.value){if(this.mustUpdate){let A=this.mustUpdate;if(this.mustUpdate=null,this.value.update)try{this.value.update(A)}catch(i){if(Hr(A.state,i,"CodeMirror plugin crashed"),this.value.destroy)try{this.value.destroy()}catch{}this.deactivate()}}}else if(this.spec)try{this.value=this.spec.plugin.create(e,this.spec.arg)}catch(A){Hr(e.state,A,"CodeMirror plugin crashed"),this.deactivate()}return this}destroy(e){var A;if(!((A=this.value)===null||A===void 0)&&A.destroy)try{this.value.destroy()}catch(i){Hr(e.state,i,"CodeMirror plugin crashed")}}deactivate(){this.spec=this.value=null}},seA=Te.define(),Ex=Te.define(),j4=Te.define(),htA=Te.define(),Zx=Te.define(),QtA=Te.define();function aeA(t,e){let A=t.state.facet(QtA);if(!A.length)return A;let i=A.map(o=>o instanceof Function?o(t):o),n=[];return Zn.spans(i,e.from,e.to,{point(){},span(o,r,s,a){let c=o-e.from,l=r-e.from,I=n;for(let C=s.length-1;C>=0;C--,a--){let d=s[C].spec.bidiIsolate,B;if(d==null&&(d=CRA(e.text,c,l)),a>0&&I.length&&(B=I[I.length-1]).to==c&&B.direction==d)B.to=l,I=B.inner;else{let E={from:c,to:l,direction:d,inner:[]};I.push(E),I=E.inner}}}}),n}var utA=Te.define();function Wx(t){let e=0,A=0,i=0,n=0;for(let o of t.state.facet(utA)){let r=o(t);r&&(r.left!=null&&(e=Math.max(e,r.left)),r.right!=null&&(A=Math.max(A,r.right)),r.top!=null&&(i=Math.max(i,r.top)),r.bottom!=null&&(n=Math.max(n,r.bottom)))}return{left:e,right:A,top:i,bottom:n}}var M4=Te.define(),wg=class t{constructor(e,A,i,n){this.fromA=e,this.toA=A,this.fromB=i,this.toB=n}join(e){return new t(Math.min(this.fromA,e.fromA),Math.max(this.toA,e.toA),Math.min(this.fromB,e.fromB),Math.max(this.toB,e.toB))}addToSet(e){let A=e.length,i=this;for(;A>0;A--){let n=e[A-1];if(!(n.fromA>i.toA)){if(n.toA<i.fromA)break;i=i.join(n),e.splice(A-1,1)}}return e.splice(A,0,i),e}static extendWithRanges(e,A){if(A.length==0)return e;let i=[];for(let n=0,o=0,r=0,s=0;;n++){let a=n==e.length?null:e[n],c=r-s,l=a?a.fromB:1e9;for(;o<A.length&&A[o]<l;){let I=A[o],C=A[o+1],d=Math.max(s,I),B=Math.min(l,C);if(d<=B&&new t(d+c,B+c,d,B).addToSet(i),C>l)break;o+=2}if(!a)return i;new t(a.fromA,a.toA,a.fromB,a.toB).addToSet(i),r=a.toA,s=a.toB}}},ww=class t{constructor(e,A,i){this.view=e,this.state=A,this.transactions=i,this.flags=0,this.startState=e.state,this.changes=ns.empty(this.startState.doc.length);for(let o of i)this.changes=this.changes.compose(o.changes);let n=[];this.changes.iterChangedRanges((o,r,s,a)=>n.push(new wg(o,r,s,a))),this.changedRanges=n}static create(e,A,i){return new t(e,A,i)}get viewportChanged(){return(this.flags&4)>0}get viewportMoved(){return(this.flags&8)>0}get heightChanged(){return(this.flags&2)>0}get geometryChanged(){return this.docChanged||(this.flags&18)>0}get focusChanged(){return(this.flags&1)>0}get docChanged(){return!this.changes.empty}get selectionSet(){return this.transactions.some(e=>e.selection)}get empty(){return this.flags==0&&this.transactions.length==0}},Dw=class extends mo{get length(){return this.view.state.doc.length}constructor(e){super(),this.view=e,this.decorations=[],this.dynamicDecorationMap=[!1],this.domChanged=null,this.hasComposition=null,this.markedForComposition=new Set,this.editContextFormatting=rt.none,this.lastCompositionAfterCursor=!1,this.minWidth=0,this.minWidthFrom=0,this.minWidthTo=0,this.impreciseAnchor=null,this.impreciseHead=null,this.forceSelection=!1,this.lastUpdate=Date.now(),this.setDOM(e.contentDOM),this.children=[new ss],this.children[0].setParent(this),this.updateDeco(),this.updateInner([new wg(0,0,0,e.state.doc.length)],0,null)}update(e){var A;let i=e.changedRanges;this.minWidth>0&&i.length&&(i.every(({fromA:c,toA:l})=>l<this.minWidthFrom||c>this.minWidthTo)?(this.minWidthFrom=e.changes.mapPos(this.minWidthFrom,1),this.minWidthTo=e.changes.mapPos(this.minWidthTo,1)):this.minWidth=this.minWidthFrom=this.minWidthTo=0),this.updateEditContextFormatting(e);let n=-1;this.view.inputState.composing>=0&&!this.view.observer.editContext&&(!((A=this.domChanged)===null||A===void 0)&&A.newSel?n=this.domChanged.newSel.head:!mRA(e.changes,this.hasComposition)&&!e.selectionSet&&(n=e.state.selection.main.head));let o=n>-1?ERA(this.view,e.changes,n):null;if(this.domChanged=null,this.hasComposition){this.markedForComposition.clear();let{from:c,to:l}=this.hasComposition;i=new wg(c,l,e.changes.mapPos(c,-1),e.changes.mapPos(l,1)).addToSet(i.slice())}this.hasComposition=o?{from:o.range.fromB,to:o.range.toB}:null,(He.ie||He.chrome)&&!o&&e&&e.state.doc.lines!=e.startState.doc.lines&&(this.forceSelection=!0);let r=this.decorations,s=this.updateDeco(),a=uRA(r,s,e.changes);return i=wg.extendWithRanges(i,a),!(this.flags&7)&&i.length==0?!1:(this.updateInner(i,e.startState.doc.length,o),e.transactions.length&&(this.lastUpdate=Date.now()),!0)}updateInner(e,A,i){this.view.viewState.mustMeasureContent=!0,this.updateChildren(e,A,i);let{observer:n}=this.view;n.ignore(()=>{this.dom.style.height=this.view.viewState.contentHeight/this.view.scaleY+"px",this.dom.style.flexBasis=this.minWidth?this.minWidth+"px":"";let r=He.chrome||He.ios?{node:n.selectionRange.focusNode,written:!1}:void 0;this.sync(this.view,r),this.flags&=-8,r&&(r.written||n.selectionRange.focusNode!=r.node)&&(this.forceSelection=!0),this.dom.style.height=""}),this.markedForComposition.forEach(r=>r.flags&=-9);let o=[];if(this.view.viewport.from||this.view.viewport.to<this.view.state.doc.length)for(let r of this.children)r instanceof lC&&r.widget instanceof P4&&o.push(r.dom);n.updateGaps(o)}updateChildren(e,A,i){let n=i?i.range.addToSet(e.slice()):e,o=this.childCursor(A);for(let r=n.length-1;;r--){let s=r>=0?n[r]:null;if(!s)break;let{fromA:a,toA:c,fromB:l,toB:I}=s,C,d,B,E;if(i&&i.range.fromB<I&&i.range.toB>l){let x=F4.build(this.view.state.doc,l,i.range.fromB,this.decorations,this.dynamicDecorationMap),y=F4.build(this.view.state.doc,i.range.toB,I,this.decorations,this.dynamicDecorationMap);d=x.breakAtStart,B=x.openStart,E=y.openEnd;let F=this.compositionView(i);y.breakAtStart?F.breakAfter=1:y.content.length&&F.merge(F.length,F.length,y.content[0],!1,y.openStart,0)&&(F.breakAfter=y.content[0].breakAfter,y.content.shift()),x.content.length&&F.merge(0,0,x.content[x.content.length-1],!0,0,x.openEnd)&&x.content.pop(),C=x.content.concat(F).concat(y.content)}else({content:C,breakAtStart:d,openStart:B,openEnd:E}=F4.build(this.view.state.doc,l,I,this.decorations,this.dynamicDecorationMap));let{i:Q,off:u}=o.findPos(c,1),{i:v,off:L}=o.findPos(a,-1);VeA(this,v,L,Q,u,C,d,B,E)}i&&this.fixCompositionDOM(i)}updateEditContextFormatting(e){this.editContextFormatting=this.editContextFormatting.map(e.changes);for(let A of e.transactions)for(let i of A.effects)i.is(EtA)&&(this.editContextFormatting=i.value)}compositionView(e){let A=new yg(e.text.nodeValue);A.flags|=8;for(let{deco:n}of e.marks)A=new u1(n,[A],A.length);let i=new ss;return i.append(A,0),i}fixCompositionDOM(e){let A=(o,r)=>{r.flags|=8|(r.children.some(a=>a.flags&7)?1:0),this.markedForComposition.add(r);let s=mo.get(o);s&&s!=r&&(s.dom=null),r.setDOM(o)},i=this.childPos(e.range.fromB,1),n=this.children[i.i];A(e.line,n);for(let o=e.marks.length-1;o>=-1;o--)i=n.childPos(i.off,1),n=n.children[i.i],A(o>=0?e.marks[o].node:e.text,n)}updateSelection(e=!1,A=!1){(e||!this.view.observer.selectionRange.focusNode)&&this.view.observer.readSelectionRange();let i=this.view.root.activeElement,n=i==this.dom,o=!n&&!(this.view.state.facet(K0)||this.dom.tabIndex>-1)&&Cw(this.dom,this.view.observer.selectionRange)&&!(i&&this.dom.contains(i));if(!(n||A||o))return;let r=this.forceSelection;this.forceSelection=!1;let s=this.view.state.selection.main,a=this.moveToLine(this.domAtPos(s.anchor)),c=s.empty?a:this.moveToLine(this.domAtPos(s.head));if(He.gecko&&s.empty&&!this.hasComposition&&BRA(a)){let I=document.createTextNode("");this.view.observer.ignore(()=>a.node.insertBefore(I,a.node.childNodes[a.offset]||null)),a=c=new Ts(I,0),r=!0}let l=this.view.observer.selectionRange;(r||!l.focusNode||(!x4(a.node,a.offset,l.anchorNode,l.anchorOffset)||!x4(c.node,c.offset,l.focusNode,l.focusOffset))&&!this.suppressWidgetCursorChange(l,s))&&(this.view.observer.ignore(()=>{He.android&&He.chrome&&this.dom.contains(l.focusNode)&&fRA(l.focusNode,this.dom)&&(this.dom.blur(),this.dom.focus({preventScroll:!0}));let I=Y4(this.view.root);if(I)if(s.empty){if(He.gecko){let C=hRA(a.node,a.offset);if(C&&C!=3){let d=(C==1?jeA:qeA)(a.node,a.offset);d&&(a=new Ts(d.node,d.offset))}}I.collapse(a.node,a.offset),s.bidiLevel!=null&&I.caretBidiLevel!==void 0&&(I.caretBidiLevel=s.bidiLevel)}else if(I.extend){I.collapse(a.node,a.offset);try{I.extend(c.node,c.offset)}catch{}}else{let C=document.createRange();s.anchor>s.head&&([a,c]=[c,a]),C.setEnd(c.node,c.offset),C.setStart(a.node,a.offset),I.removeAllRanges(),I.addRange(C)}o&&this.view.root.activeElement==this.dom&&(this.dom.blur(),i&&i.focus())}),this.view.observer.setSelectionRange(a,c)),this.impreciseAnchor=a.precise?null:new Ts(l.anchorNode,l.anchorOffset),this.impreciseHead=c.precise?null:new Ts(l.focusNode,l.focusOffset)}suppressWidgetCursorChange(e,A){return this.hasComposition&&A.empty&&x4(e.focusNode,e.focusOffset,e.anchorNode,e.anchorOffset)&&this.posFromDOM(e.focusNode,e.focusOffset)==A.head}enforceCursorAssoc(){if(this.hasComposition)return;let{view:e}=this,A=e.state.selection.main,i=Y4(e.root),{anchorNode:n,anchorOffset:o}=e.observer.selectionRange;if(!i||!A.empty||!A.assoc||!i.modify)return;let r=ss.find(this,A.head);if(!r)return;let s=r.posAtStart;if(A.head==s||A.head==s+r.length)return;let a=this.coordsAt(A.head,-1),c=this.coordsAt(A.head,1);if(!a||!c||a.bottom>c.top)return;let l=this.domAtPos(A.head+A.assoc);i.collapse(l.node,l.offset),i.modify("move",A.assoc<0?"forward":"backward","lineboundary"),e.observer.readSelectionRange();let I=e.observer.selectionRange;e.docView.posFromDOM(I.anchorNode,I.anchorOffset)!=A.from&&i.collapse(n,o)}moveToLine(e){let A=this.dom,i;if(e.node!=A)return e;for(let n=e.offset;!i&&n<A.childNodes.length;n++){let o=mo.get(A.childNodes[n]);o instanceof ss&&(i=o.domAtPos(0))}for(let n=e.offset-1;!i&&n>=0;n--){let o=mo.get(A.childNodes[n]);o instanceof ss&&(i=o.domAtPos(o.length))}return i?new Ts(i.node,i.offset,!0):e}nearest(e){for(let A=e;A;){let i=mo.get(A);if(i&&i.rootView==this)return i;A=A.parentNode}return null}posFromDOM(e,A){let i=this.nearest(e);if(!i)throw new RangeError("Trying to find position for a DOM position outside of the document");return i.localPosFromDOM(e,A)+i.posAtStart}domAtPos(e){let{i:A,off:i}=this.childCursor().findPos(e,-1);for(;A<this.children.length-1;){let n=this.children[A];if(i<n.length||n instanceof ss)break;A++,i=0}return this.children[A].domAtPos(i)}coordsAt(e,A){let i=null,n=0;for(let o=this.length,r=this.children.length-1;r>=0;r--){let s=this.children[r],a=o-s.breakAfter,c=a-s.length;if(a<e)break;if(c<=e&&(c<e||s.covers(-1))&&(a>e||s.covers(1))&&(!i||s instanceof ss&&!(i instanceof ss&&A>=0)))i=s,n=c;else if(i&&c==e&&a==e&&s instanceof lC&&Math.abs(A)<2){if(s.deco.startSide<0)break;r&&(i=null)}o=c}return i?i.coordsAt(e-n,A):null}coordsForChar(e){let{i:A,off:i}=this.childPos(e,1),n=this.children[A];if(!(n instanceof ss))return null;for(;n.children.length;){let{i:s,off:a}=n.childPos(i,1);for(;;s++){if(s==n.children.length)return null;if((n=n.children[s]).length)break}i=a}if(!(n instanceof yg))return null;let o=fr(n.text,i);if(o==i)return null;let r=IC(n.dom,i,o).getClientRects();for(let s=0;s<r.length;s++){let a=r[s];if(s==r.length-1||a.top<a.bottom&&a.left<a.right)return a}return null}measureVisibleLineHeights(e){let A=[],{from:i,to:n}=e,o=this.view.contentDOM.clientWidth,r=o>Math.max(this.view.scrollDOM.clientWidth,this.minWidth)+1,s=-1,a=this.view.textDirection==Wn.LTR;for(let c=0,l=0;l<this.children.length;l++){let I=this.children[l],C=c+I.length;if(C>n)break;if(c>=i){let d=I.dom.getBoundingClientRect();if(A.push(d.height),r){let B=I.dom.lastChild,E=B?J4(B):[];if(E.length){let Q=E[E.length-1],u=a?Q.right-d.left:d.right-Q.left;u>s&&(s=u,this.minWidth=o,this.minWidthFrom=c,this.minWidthTo=C)}}}c=C+I.breakAfter}return A}textDirectionAt(e){let{i:A}=this.childPos(e,1);return getComputedStyle(this.children[A].dom).direction=="rtl"?Wn.RTL:Wn.LTR}measureTextSize(){for(let o of this.children)if(o instanceof ss){let r=o.measureTextSize();if(r)return r}let e=document.createElement("div"),A,i,n;return e.className="cm-line",e.style.width="99999px",e.style.position="absolute",e.textContent="abc def ghi jkl mno pqr stu",this.view.observer.ignore(()=>{this.dom.appendChild(e);let o=J4(e.firstChild)[0];A=e.getBoundingClientRect().height,i=o?o.width/27:7,n=o?o.height:A,e.remove()}),{lineHeight:A,charWidth:i,textHeight:n}}childCursor(e=this.length){let A=this.children.length;return A&&(e-=this.children[--A].length),new mw(this.children,e,A)}computeBlockGapDeco(){let e=[],A=this.view.viewState;for(let i=0,n=0;;n++){let o=n==A.viewports.length?null:A.viewports[n],r=o?o.from-1:this.length;if(r>i){let s=(A.lineBlockAt(r).bottom-A.lineBlockAt(i).top)/this.view.scaleY;e.push(rt.replace({widget:new P4(s),block:!0,inclusive:!0,isBlockGap:!0}).range(i,r))}if(!o)break;i=o.to+1}return rt.set(e)}updateDeco(){let e=1,A=this.view.state.facet(j4).map(o=>(this.dynamicDecorationMap[e++]=typeof o=="function")?o(this.view):o),i=!1,n=this.view.state.facet(htA).map((o,r)=>{let s=typeof o=="function";return s&&(i=!0),s?o(this.view):o});for(n.length&&(this.dynamicDecorationMap[e++]=i,A.push(Zn.join(n))),this.decorations=[this.editContextFormatting,...A,this.computeBlockGapDeco(),this.view.viewState.lineGapDeco];e<this.decorations.length;)this.dynamicDecorationMap[e++]=!1;return this.decorations}scrollIntoView(e){if(e.isSnapshot){let c=this.view.viewState.lineBlockAt(e.range.head);this.view.scrollDOM.scrollTop=c.top-e.yMargin,this.view.scrollDOM.scrollLeft=e.xMargin;return}for(let c of this.view.state.facet(BtA))try{if(c(this.view,e.range,e))return!0}catch(l){Hr(this.view.state,l,"scroll handler")}let{range:A}=e,i=this.coordsAt(A.head,A.empty?A.assoc:A.head>A.anchor?-1:1),n;if(!i)return;!A.empty&&(n=this.coordsAt(A.anchor,A.anchor>A.head?-1:1))&&(i={left:Math.min(i.left,n.left),top:Math.min(i.top,n.top),right:Math.max(i.right,n.right),bottom:Math.max(i.bottom,n.bottom)});let o=Wx(this.view),r={left:i.left-o.left,top:i.top-o.top,right:i.right+o.right,bottom:i.bottom+o.bottom},{offsetWidth:s,offsetHeight:a}=this.view.scrollDOM;VSA(this.view.scrollDOM,r,A.head<A.anchor?-1:1,e.x,e.y,Math.max(Math.min(e.xMargin,s),-s),Math.max(Math.min(e.yMargin,a),-a),this.view.textDirection==Wn.LTR)}};function BRA(t){return t.node.nodeType==1&&t.node.firstChild&&(t.offset==0||t.node.childNodes[t.offset-1].contentEditable=="false")&&(t.offset==t.node.childNodes.length||t.node.childNodes[t.offset].contentEditable=="false")}function ftA(t,e){let A=t.observer.selectionRange;if(!A.focusNode)return null;let i=jeA(A.focusNode,A.focusOffset),n=qeA(A.focusNode,A.focusOffset),o=i||n;if(n&&i&&n.node!=i.node){let s=mo.get(n.node);if(!s||s instanceof yg&&s.text!=n.node.nodeValue)o=n;else if(t.docView.lastCompositionAfterCursor){let a=mo.get(i.node);!a||a instanceof yg&&a.text!=i.node.nodeValue||(o=n)}}if(t.docView.lastCompositionAfterCursor=o!=i,!o)return null;let r=e-o.offset;return{from:r,to:r+o.node.nodeValue.length,node:o.node}}function ERA(t,e,A){let i=ftA(t,A);if(!i)return null;let{node:n,from:o,to:r}=i,s=n.nodeValue;if(/[\n\r]/.test(s)||t.state.doc.sliceString(i.from,i.to)!=s)return null;let a=e.invertedDesc,c=new wg(a.mapPos(o),a.mapPos(r),o,r),l=[];for(let I=n.parentNode;;I=I.parentNode){let C=mo.get(I);if(C instanceof u1)l.push({node:I,deco:C.mark});else{if(C instanceof ss||I.nodeName=="DIV"&&I.parentNode==t.contentDOM)return{range:c,text:n,marks:l,line:I};if(I!=t.contentDOM)l.push({node:I,deco:new H4({inclusive:!0,attributes:iRA(I),tagName:I.tagName.toLowerCase()})});else return null}}}function hRA(t,e){return t.nodeType!=1?0:(e&&t.childNodes[e-1].contentEditable=="false"?1:0)|(e<t.childNodes.length&&t.childNodes[e].contentEditable=="false"?2:0)}var QRA=class{constructor(){this.changes=[]}compareRange(e,A){dw(e,A,this.changes)}comparePoint(e,A){dw(e,A,this.changes)}boundChange(e){dw(e,e,this.changes)}};function uRA(t,e,A){let i=new QRA;return Zn.compare(t,e,A,i),i.changes}function fRA(t,e){for(let A=t;A&&A!=e;A=A.assignedSlot||A.parentNode)if(A.nodeType==1&&A.contentEditable=="false")return!0;return!1}function mRA(t,e){let A=!1;return e&&t.iterChangedRanges((i,n)=>{i<e.to&&n>e.from&&(A=!0)}),A}function pRA(t,e,A=1){let i=t.charCategorizer(e),n=t.doc.lineAt(e),o=e-n.from;if(n.length==0)return ie.cursor(e);o==0?A=1:o==n.length&&(A=-1);let r=o,s=o;A<0?r=fr(n.text,o,!1):s=fr(n.text,o);let a=i(n.text.slice(r,s));for(;r>0;){let c=fr(n.text,r,!1);if(i(n.text.slice(c,r))!=a)break;r=c}for(;s<n.length;){let c=fr(n.text,s);if(i(n.text.slice(s,c))!=a)break;s=c}return ie.range(r+n.from,s+n.from)}function wRA(t,e){return e.left>t?e.left-t:Math.max(0,t-e.right)}function DRA(t,e){return e.top>t?e.top-t:Math.max(0,t-e.bottom)}function $L(t,e){return t.top<e.bottom-1&&t.bottom>e.top+1}function ceA(t,e){return e<t.top?{top:e,left:t.left,right:t.right,bottom:t.bottom}:t}function leA(t,e){return e>t.bottom?{top:t.top,left:t.left,right:t.right,bottom:e}:t}function hx(t,e,A){let i,n,o,r,s=!1,a,c,l,I;for(let B=t.firstChild;B;B=B.nextSibling){let E=J4(B);for(let Q=0;Q<E.length;Q++){let u=E[Q];n&&$L(n,u)&&(u=ceA(leA(u,n.bottom),n.top));let v=wRA(e,u),L=DRA(A,u);if(v==0&&L==0)return B.nodeType==3?geA(B,e,A):hx(B,e,A);(!i||r>L||r==L&&o>v)&&(i=B,n=u,o=v,r=L,s=v?e<u.left?Q>0:Q<E.length-1:!0),v==0?A>u.bottom&&(!l||l.bottom<u.bottom)?(a=B,l=u):A<u.top&&(!I||I.top>u.top)&&(c=B,I=u):l&&$L(l,u)?l=leA(l,u.bottom):I&&$L(I,u)&&(I=ceA(I,u.top))}}if(l&&l.bottom>=A?(i=a,n=l):I&&I.top<=A&&(i=c,n=I),!i)return{node:t,offset:0};let C=Math.max(n.left,Math.min(n.right,e));if(i.nodeType==3)return geA(i,C,A);if(s&&i.contentEditable!="false")return hx(i,C,A);let d=Array.prototype.indexOf.call(t.childNodes,i)+(e>=(n.left+n.right)/2?1:0);return{node:t,offset:d}}function geA(t,e,A){let i=t.nodeValue.length,n=-1,o=1e9,r=0;for(let s=0;s<i;s++){let a=IC(t,s,s+1).getClientRects();for(let c=0;c<a.length;c++){let l=a[c];if(l.top==l.bottom)continue;r||(r=e-l.left);let I=(l.top>A?l.top-A:A-l.bottom)-1;if(l.left-1<=e&&l.right+1>=e&&I<o){let C=e>=(l.left+l.right)/2,d=C;if((He.chrome||He.gecko)&&IC(t,s).getBoundingClientRect().left==l.right&&(d=!C),I<=0)return{node:t,offset:s+(d?1:0)};n=s+(d?1:0),o=I}}}return{node:t,offset:n>-1?n:r>0?t.nodeValue.length:0}}function mtA(t,e,A,i=-1){var n,o;let r=t.contentDOM.getBoundingClientRect(),s=r.top+t.viewState.paddingTop,a,{docHeight:c}=t.viewState,{x:l,y:I}=e,C=I-s;if(C<0)return 0;if(C>c)return t.state.doc.length;for(let x=t.viewState.heightOracle.textHeight/2,y=!1;a=t.elementAtHeight(C),a.type!=zs.Text;)for(;C=i>0?a.bottom+x:a.top-x,!(C>=0&&C<=c);){if(y)return A?null:0;y=!0,i=-i}I=s+C;let d=a.from;if(d<t.viewport.from)return t.viewport.from==0?0:A?null:IeA(t,r,a,l,I);if(d>t.viewport.to)return t.viewport.to==t.state.doc.length?t.state.doc.length:A?null:IeA(t,r,a,l,I);let B=t.dom.ownerDocument,E=t.root.elementFromPoint?t.root:B,Q=E.elementFromPoint(l,I);Q&&!t.contentDOM.contains(Q)&&(Q=null),Q||(l=Math.max(r.left+1,Math.min(r.right-1,l)),Q=E.elementFromPoint(l,I),Q&&!t.contentDOM.contains(Q)&&(Q=null));let u,v=-1;if(Q&&((n=t.docView.nearest(Q))===null||n===void 0?void 0:n.isEditable)!=!1){if(B.caretPositionFromPoint){let x=B.caretPositionFromPoint(l,I);x&&({offsetNode:u,offset:v}=x)}else if(B.caretRangeFromPoint){let x=B.caretRangeFromPoint(l,I);x&&({startContainer:u,startOffset:v}=x,(!t.contentDOM.contains(u)||He.safari&&yRA(u,v,l)||He.chrome&&vRA(u,v,l))&&(u=void 0))}u&&(v=Math.min(Dg(u),v))}if(!u||!t.docView.dom.contains(u)){let x=ss.find(t.docView,d);if(!x)return C>a.top+a.height/2?a.to:a.from;({node:u,offset:v}=hx(x.dom,l,I))}let L=t.docView.nearest(u);if(!L)return null;if(L.isWidget&&((o=L.dom)===null||o===void 0?void 0:o.nodeType)==1){let x=L.dom.getBoundingClientRect();return e.y<x.top||e.y<=x.bottom&&e.x<=(x.left+x.right)/2?L.posAtStart:L.posAtEnd}else return L.localPosFromDOM(u,v)+L.posAtStart}function IeA(t,e,A,i,n){let o=Math.round((i-e.left)*t.defaultCharacterWidth);if(t.lineWrapping&&A.height>t.defaultLineHeight*1.5){let s=t.viewState.heightOracle.textHeight,a=Math.floor((n-A.top-(t.defaultLineHeight-s)*.5)/s);o+=a*t.viewState.heightOracle.lineLength}let r=t.state.sliceDoc(A.from,A.to);return A.from+tw(r,o,t.state.tabSize)}function yRA(t,e,A){let i,n=t;if(t.nodeType!=3||e!=(i=t.nodeValue.length))return!1;for(;;){let o=n.nextSibling;if(o){if(o.nodeName=="BR")break;return!1}else{let r=n.parentNode;if(!r||r.nodeName=="DIV")break;n=r}}return IC(t,i-1,i).getBoundingClientRect().right>A}function vRA(t,e,A){if(e!=0)return!1;for(let n=t;;){let o=n.parentNode;if(!o||o.nodeType!=1||o.firstChild!=n)return!1;if(o.classList.contains("cm-line"))break;n=o}let i=t.nodeType==1?t.getBoundingClientRect():IC(t,0,Math.max(t.nodeValue.length,1)).getBoundingClientRect();return A-i.left>5}function Qx(t,e,A){let i=t.lineBlockAt(e);if(Array.isArray(i.type)){let n;for(let o of i.type){if(o.from>e)break;if(!(o.to<e)){if(o.from<e&&o.to>e)return o;(!n||o.type==zs.Text&&(n.type!=o.type||(A<0?o.from<e:o.to>e)))&&(n=o)}}return n||i}return i}function bRA(t,e,A,i){let n=Qx(t,e.head,e.assoc||-1),o=!i||n.type!=zs.Text||!(t.lineWrapping||n.widgetLineBreaks)?null:t.coordsAtPos(e.assoc<0&&e.head>n.from?e.head-1:e.head);if(o){let r=t.dom.getBoundingClientRect(),s=t.textDirectionAt(n.from),a=t.posAtCoords({x:A==(s==Wn.LTR)?r.right-1:r.left+1,y:(o.top+o.bottom)/2});if(a!=null)return ie.cursor(a,A?-1:1)}return ie.cursor(A?n.to:n.from,A?-1:1)}function CeA(t,e,A,i){let n=t.state.doc.lineAt(e.head),o=t.bidiSpans(n),r=t.textDirectionAt(n.from);for(let s=e,a=null;;){let c=IRA(n,o,r,s,A),l=stA;if(!c){if(n.number==(A?t.state.doc.lines:1))return s;l=`
`,n=t.state.doc.line(n.number+(A?1:-1)),o=t.bidiSpans(n),c=t.visualLineSide(n,!A)}if(a){if(!a(l))return s}else{if(!i)return c;a=i(l)}s=c}}function MRA(t,e,A){let i=t.state.charCategorizer(e),n=i(A);return o=>{let r=i(o);return n==Vn.Space&&(n=r),n==r}}function kRA(t,e,A,i){let n=e.head,o=A?1:-1;if(n==(A?t.state.doc.length:0))return ie.cursor(n,e.assoc);let r=e.goalColumn,s,a=t.contentDOM.getBoundingClientRect(),c=t.coordsAtPos(n,e.assoc||-1),l=t.documentTop;if(c)r==null&&(r=c.left-a.left),s=o<0?c.top:c.bottom;else{let d=t.viewState.lineBlockAt(n);r==null&&(r=Math.min(a.right-a.left,t.defaultCharacterWidth*(n-d.from))),s=(o<0?d.top:d.bottom)+l}let I=a.left+r,C=i??t.viewState.heightOracle.textHeight>>1;for(let d=0;;d+=10){let B=s+(C+d)*o,E=mtA(t,{x:I,y:B},!1,o);if(B<a.top||B>a.bottom||(o<0?E<n:E>n)){let Q=t.docView.coordsForChar(E),u=!Q||B<Q.top?-1:1;return ie.cursor(E,u,void 0,r)}}}function Bw(t,e,A){for(;;){let i=0;for(let n of t)n.between(e-1,e+1,(o,r,s)=>{if(e>o&&e<r){let a=i||A||(e-o<r-e?-1:1);e=a<0?o:r,i=a}});if(!i)return e}}function Ax(t,e,A){let i=Bw(t.state.facet(Zx).map(n=>n(t)),A.from,e.head>A.from?-1:1);return i==A.from?A:ie.cursor(i,i<A.from?1:-1)}var S4="\uFFFF",ux=class{constructor(e,A){this.points=e,this.text="",this.lineSeparator=A.facet(Ir.lineSeparator)}append(e){this.text+=e}lineBreak(){this.text+=S4}readRange(e,A){if(!e)return this;let i=e.parentNode;for(let n=e;;){this.findPointBefore(i,n);let o=this.text.length;this.readNode(n);let r=n.nextSibling;if(r==A)break;let s=mo.get(n),a=mo.get(r);(s&&a?s.breakAfter:(s?s.breakAfter:fw(n))||fw(r)&&(n.nodeName!="BR"||n.cmIgnore)&&this.text.length>o)&&this.lineBreak(),n=r}return this.findPointBefore(i,A),this}readTextNode(e){let A=e.nodeValue;for(let i of this.points)i.node==e&&(i.pos=this.text.length+Math.min(i.offset,A.length));for(let i=0,n=this.lineSeparator?null:/\r\n?|\n/g;;){let o=-1,r=1,s;if(this.lineSeparator?(o=A.indexOf(this.lineSeparator,i),r=this.lineSeparator.length):(s=n.exec(A))&&(o=s.index,r=s[0].length),this.append(A.slice(i,o<0?A.length:o)),o<0)break;if(this.lineBreak(),r>1)for(let a of this.points)a.node==e&&a.pos>this.text.length&&(a.pos-=r-1);i=o+r}}readNode(e){if(e.cmIgnore)return;let A=mo.get(e),i=A&&A.overrideDOMText;if(i!=null){this.findPointInside(e,i.length);for(let n=i.iter();!n.next().done;)n.lineBreak?this.lineBreak():this.append(n.value)}else e.nodeType==3?this.readTextNode(e):e.nodeName=="BR"?e.nextSibling&&this.lineBreak():e.nodeType==1&&this.readRange(e.firstChild,null)}findPointBefore(e,A){for(let i of this.points)i.node==e&&e.childNodes[i.offset]==A&&(i.pos=this.text.length)}findPointInside(e,A){for(let i of this.points)(e.nodeType==3?i.node==e:e.contains(i.node))&&(i.pos=this.text.length+(SRA(e,i.node,i.offset)?A:0))}};function SRA(t,e,A){for(;;){if(!e||A<Dg(e))return!1;if(e==t)return!0;A=gC(e)+1,e=e.parentNode}}var yw=class{constructor(e,A){this.node=e,this.offset=A,this.pos=-1}},fx=class{constructor(e,A,i,n){this.typeOver=n,this.bounds=null,this.text="",this.domChanged=A>-1;let{impreciseHead:o,impreciseAnchor:r}=e.docView;if(e.state.readOnly&&A>-1)this.newSel=null;else if(A>-1&&(this.bounds=e.docView.domBoundsAround(A,i,0))){let s=o||r?[]:xRA(e),a=new ux(s,e.state);a.readRange(this.bounds.startDOM,this.bounds.endDOM),this.text=a.text,this.newSel=FRA(s,this.bounds.from)}else{let s=e.observer.selectionRange,a=o&&o.node==s.focusNode&&o.offset==s.focusOffset||!rx(e.contentDOM,s.focusNode)?e.state.selection.main.head:e.docView.posFromDOM(s.focusNode,s.focusOffset),c=r&&r.node==s.anchorNode&&r.offset==s.anchorOffset||!rx(e.contentDOM,s.anchorNode)?e.state.selection.main.anchor:e.docView.posFromDOM(s.anchorNode,s.anchorOffset),l=e.viewport;if((He.ios||He.chrome)&&e.state.selection.main.empty&&a!=c&&(l.from>0||l.to<e.state.doc.length)){let I=Math.min(a,c),C=Math.max(a,c),d=l.from-I,B=l.to-C;(d==0||d==1||I==0)&&(B==0||B==-1||C==e.state.doc.length)&&(a=0,c=e.state.doc.length)}this.newSel=ie.single(c,a)}}};function ptA(t,e){let A,{newSel:i}=e,n=t.state.selection.main,o=t.inputState.lastKeyTime>Date.now()-100?t.inputState.lastKeyCode:-1;if(e.bounds){let{from:r,to:s}=e.bounds,a=n.from,c=null;(o===8||He.android&&e.text.length<s-r)&&(a=n.to,c="end");let l=LRA(t.state.doc.sliceString(r,s,S4),e.text,a-r,c);l&&(He.chrome&&o==13&&l.toB==l.from+2&&e.text.slice(l.from,l.toB)==S4+S4&&l.toB--,A={from:r+l.from,to:r+l.toA,insert:qi.of(e.text.slice(l.from,l.toB).split(S4))})}else i&&(!t.hasFocus&&t.state.facet(K0)||i.main.eq(n))&&(i=null);if(!A&&!i)return!1;if(!A&&e.typeOver&&!n.empty&&i&&i.main.empty?A={from:n.from,to:n.to,insert:t.state.doc.slice(n.from,n.to)}:(He.mac||He.android)&&A&&A.from==A.to&&A.from==n.head-1&&/^\. ?$/.test(A.insert.toString())&&t.contentDOM.getAttribute("autocorrect")=="off"?(i&&A.insert.length==2&&(i=ie.single(i.main.anchor-1,i.main.head-1)),A={from:A.from,to:A.to,insert:qi.of([A.insert.toString().replace("."," ")])}):A&&A.from>=n.from&&A.to<=n.to&&(A.from!=n.from||A.to!=n.to)&&n.to-n.from-(A.to-A.from)<=4?A={from:n.from,to:n.to,insert:t.state.doc.slice(n.from,A.from).append(A.insert).append(t.state.doc.slice(A.to,n.to))}:He.chrome&&A&&A.from==A.to&&A.from==n.head&&A.insert.toString()==`
 `&&t.lineWrapping&&(i&&(i=ie.single(i.main.anchor-1,i.main.head-1)),A={from:n.from,to:n.to,insert:qi.of([" "])}),A)return Xx(t,A,i,o);if(i&&!i.main.eq(n)){let r=!1,s="select";return t.inputState.lastSelectionTime>Date.now()-50&&(t.inputState.lastSelectionOrigin=="select"&&(r=!0),s=t.inputState.lastSelectionOrigin),t.dispatch({selection:i,scrollIntoView:r,userEvent:s}),!0}else return!1}function Xx(t,e,A,i=-1){if(He.ios&&t.inputState.flushIOSKey(e))return!0;let n=t.state.selection.main;if(He.android&&(e.to==n.to&&(e.from==n.from||e.from==n.from-1&&t.state.sliceDoc(e.from,n.from)==" ")&&e.insert.length==1&&e.insert.lines==2&&mE(t.contentDOM,"Enter",13)||(e.from==n.from-1&&e.to==n.to&&e.insert.length==0||i==8&&e.insert.length<e.to-e.from&&e.to>n.head)&&mE(t.contentDOM,"Backspace",8)||e.from==n.from&&e.to==n.to+1&&e.insert.length==0&&mE(t.contentDOM,"Delete",46)))return!0;let o=e.insert.toString();t.inputState.composing>=0&&t.inputState.composing++;let r,s=()=>r||(r=RRA(t,e,A));return t.state.facet(ItA).some(a=>a(t,e.from,e.to,o,s))||t.dispatch(s()),!0}function RRA(t,e,A){let i,n=t.state,o=n.selection.main;if(e.from>=o.from&&e.to<=o.to&&e.to-e.from>=(o.to-o.from)/3&&(!A||A.main.empty&&A.main.from==e.from+e.insert.length)&&t.inputState.composing<0){let s=o.from<e.from?n.sliceDoc(o.from,e.from):"",a=o.to>e.to?n.sliceDoc(e.to,o.to):"";i=n.replaceSelection(t.state.toText(s+e.insert.sliceString(0,void 0,t.state.lineBreak)+a))}else{let s=n.changes(e),a=A&&A.main.to<=s.newLength?A.main:void 0;if(n.selection.ranges.length>1&&t.inputState.composing>=0&&e.to<=o.to&&e.to>=o.to-10){let c=t.state.sliceDoc(e.from,e.to),l,I=A&&ftA(t,A.main.head);if(I){let B=e.insert.length-(e.to-e.from);l={from:I.from,to:I.to-B}}else l=t.state.doc.lineAt(o.head);let C=o.to-e.to,d=o.to-o.from;i=n.changeByRange(B=>{if(B.from==o.from&&B.to==o.to)return{changes:s,range:a||B.map(s)};let E=B.to-C,Q=E-c.length;if(B.to-B.from!=d||t.state.sliceDoc(Q,E)!=c||B.to>=l.from&&B.from<=l.to)return{range:B};let u=n.changes({from:Q,to:E,insert:e.insert}),v=B.to-o.to;return{changes:u,range:a?ie.range(Math.max(0,a.anchor+v),Math.max(0,a.head+v)):B.map(u)}})}else i={changes:s,selection:a&&n.selection.replaceRange(a)}}let r="input.type";return(t.composing||t.inputState.compositionPendingChange&&t.inputState.compositionEndedAt>Date.now()-50)&&(t.inputState.compositionPendingChange=!1,r+=".compose",t.inputState.compositionFirstChange&&(r+=".start",t.inputState.compositionFirstChange=!1)),n.update(i,{userEvent:r,scrollIntoView:!0})}function LRA(t,e,A,i){let n=Math.min(t.length,e.length),o=0;for(;o<n&&t.charCodeAt(o)==e.charCodeAt(o);)o++;if(o==n&&t.length==e.length)return null;let r=t.length,s=e.length;for(;r>0&&s>0&&t.charCodeAt(r-1)==e.charCodeAt(s-1);)r--,s--;if(i=="end"){let a=Math.max(0,o-Math.min(r,s));A-=r+a-o}if(r<o&&t.length<e.length){let a=A<=o&&A>=r?o-A:0;o-=a,s=o+(s-r),r=o}else if(s<o){let a=A<=o&&A>=s?o-A:0;o-=a,r=o+(r-s),s=o}return{from:o,toA:r,toB:s}}function xRA(t){let e=[];if(t.root.activeElement!=t.contentDOM)return e;let{anchorNode:A,anchorOffset:i,focusNode:n,focusOffset:o}=t.observer.selectionRange;return A&&(e.push(new yw(A,i)),(n!=A||o!=i)&&e.push(new yw(n,o))),e}function FRA(t,e){if(t.length==0)return null;let A=t[0].pos,i=t.length==2?t[1].pos:A;return A>-1&&i>-1?ie.single(A+e,i+e):null}var mx=class{setSelectionOrigin(e){this.lastSelectionOrigin=e,this.lastSelectionTime=Date.now()}constructor(e){this.view=e,this.lastKeyCode=0,this.lastKeyTime=0,this.lastTouchTime=0,this.lastFocusTime=0,this.lastScrollTop=0,this.lastScrollLeft=0,this.pendingIOSKey=void 0,this.tabFocusMode=-1,this.lastSelectionOrigin=null,this.lastSelectionTime=0,this.lastContextMenu=0,this.scrollHandlers=[],this.handlers=Object.create(null),this.composing=-1,this.compositionFirstChange=null,this.compositionEndedAt=0,this.compositionPendingKey=!1,this.compositionPendingChange=!1,this.mouseSelection=null,this.draggedContent=null,this.handleEvent=this.handleEvent.bind(this),this.notifiedFocused=e.hasFocus,He.safari&&e.contentDOM.addEventListener("input",()=>null),He.gecko&&VRA(e.contentDOM.ownerDocument)}handleEvent(e){!JRA(this.view,e)||this.ignoreDuringComposition(e)||e.type=="keydown"&&this.keydown(e)||(this.view.updateState!=0?Promise.resolve().then(()=>this.runHandlers(e.type,e)):this.runHandlers(e.type,e))}runHandlers(e,A){let i=this.handlers[e];if(i){for(let n of i.observers)n(this.view,A);for(let n of i.handlers){if(A.defaultPrevented)break;if(n(this.view,A)){A.preventDefault();break}}}}ensureHandlers(e){let A=NRA(e),i=this.handlers,n=this.view.contentDOM;for(let o in A)if(o!="scroll"){let r=!A[o].handlers.length,s=i[o];s&&r!=!s.handlers.length&&(n.removeEventListener(o,this.handleEvent),s=null),s||n.addEventListener(o,this.handleEvent,{passive:r})}for(let o in i)o!="scroll"&&!A[o]&&n.removeEventListener(o,this.handleEvent);this.handlers=A}keydown(e){if(this.lastKeyCode=e.keyCode,this.lastKeyTime=Date.now(),e.keyCode==9&&this.tabFocusMode>-1&&(!this.tabFocusMode||Date.now()<=this.tabFocusMode))return!0;if(this.tabFocusMode>0&&e.keyCode!=27&&DtA.indexOf(e.keyCode)<0&&(this.tabFocusMode=-1),He.android&&He.chrome&&!e.synthetic&&(e.keyCode==13||e.keyCode==8))return this.view.observer.delayAndroidKey(e.key,e.keyCode),!0;let A;return He.ios&&!e.synthetic&&!e.altKey&&!e.metaKey&&((A=wtA.find(i=>i.keyCode==e.keyCode))&&!e.ctrlKey||_RA.indexOf(e.key)>-1&&e.ctrlKey&&!e.shiftKey)?(this.pendingIOSKey=A||e,setTimeout(()=>this.flushIOSKey(),250),!0):(e.keyCode!=229&&this.view.observer.forceFlush(),!1)}flushIOSKey(e){let A=this.pendingIOSKey;return!A||A.key=="Enter"&&e&&e.from<e.to&&/^\S+$/.test(e.insert.toString())?!1:(this.pendingIOSKey=void 0,mE(this.view.contentDOM,A.key,A.keyCode,A instanceof KeyboardEvent?A:void 0))}ignoreDuringComposition(e){return/^key/.test(e.type)?this.composing>0?!0:He.safari&&!He.ios&&this.compositionPendingKey&&Date.now()-this.compositionEndedAt<100?(this.compositionPendingKey=!1,!0):!1:!1}startMouseSelection(e){this.mouseSelection&&this.mouseSelection.destroy(),this.mouseSelection=e}update(e){this.view.observer.update(e),this.mouseSelection&&this.mouseSelection.update(e),this.draggedContent&&e.docChanged&&(this.draggedContent=this.draggedContent.map(e.changes)),e.transactions.length&&(this.lastKeyCode=this.lastSelectionTime=0)}destroy(){this.mouseSelection&&this.mouseSelection.destroy()}};function deA(t,e){return(A,i)=>{try{return e.call(t,i,A)}catch(n){Hr(A.state,n)}}}function NRA(t){let e=Object.create(null);function A(i){return e[i]||(e[i]={observers:[],handlers:[]})}for(let i of t){let n=i.spec,o=n&&n.plugin.domEventHandlers,r=n&&n.plugin.domEventObservers;if(o)for(let s in o){let a=o[s];a&&A(s).handlers.push(deA(i.value,a))}if(r)for(let s in r){let a=r[s];a&&A(s).observers.push(deA(i.value,a))}}for(let i in El)A(i).handlers.push(El[i]);for(let i in Nc)A(i).observers.push(Nc[i]);return e}var wtA=[{key:"Backspace",keyCode:8,inputType:"deleteContentBackward"},{key:"Enter",keyCode:13,inputType:"insertParagraph"},{key:"Enter",keyCode:13,inputType:"insertLineBreak"},{key:"Delete",keyCode:46,inputType:"deleteContentForward"}],_RA="dthko",DtA=[16,17,18,20,91,92,224,225],rw=6;function sw(t){return Math.max(0,t)*.7+8}function GRA(t,e){return Math.max(Math.abs(t.clientX-e.clientX),Math.abs(t.clientY-e.clientY))}var px=class{constructor(e,A,i,n){this.view=e,this.startEvent=A,this.style=i,this.mustSelect=n,this.scrollSpeed={x:0,y:0},this.scrolling=-1,this.lastEvent=A,this.scrollParents=ZSA(e.contentDOM),this.atoms=e.state.facet(Zx).map(r=>r(e));let o=e.contentDOM.ownerDocument;o.addEventListener("mousemove",this.move=this.move.bind(this)),o.addEventListener("mouseup",this.up=this.up.bind(this)),this.extend=A.shiftKey,this.multiple=e.state.facet(Ir.allowMultipleSelections)&&URA(e,A),this.dragging=YRA(e,A)&&btA(A)==1?null:!1}start(e){this.dragging===!1&&this.select(e)}move(e){if(e.buttons==0)return this.destroy();if(this.dragging||this.dragging==null&&GRA(this.startEvent,e)<10)return;this.select(this.lastEvent=e);let A=0,i=0,n=0,o=0,r=this.view.win.innerWidth,s=this.view.win.innerHeight;this.scrollParents.x&&({left:n,right:r}=this.scrollParents.x.getBoundingClientRect()),this.scrollParents.y&&({top:o,bottom:s}=this.scrollParents.y.getBoundingClientRect());let a=Wx(this.view);e.clientX-a.left<=n+rw?A=-sw(n-e.clientX):e.clientX+a.right>=r-rw&&(A=sw(e.clientX-r)),e.clientY-a.top<=o+rw?i=-sw(o-e.clientY):e.clientY+a.bottom>=s-rw&&(i=sw(e.clientY-s)),this.setScrollSpeed(A,i)}up(e){this.dragging==null&&this.select(this.lastEvent),this.dragging||e.preventDefault(),this.destroy()}destroy(){this.setScrollSpeed(0,0);let e=this.view.contentDOM.ownerDocument;e.removeEventListener("mousemove",this.move),e.removeEventListener("mouseup",this.up),this.view.inputState.mouseSelection=this.view.inputState.draggedContent=null}setScrollSpeed(e,A){this.scrollSpeed={x:e,y:A},e||A?this.scrolling<0&&(this.scrolling=setInterval(()=>this.scroll(),50)):this.scrolling>-1&&(clearInterval(this.scrolling),this.scrolling=-1)}scroll(){let{x:e,y:A}=this.scrollSpeed;e&&this.scrollParents.x&&(this.scrollParents.x.scrollLeft+=e,e=0),A&&this.scrollParents.y&&(this.scrollParents.y.scrollTop+=A,A=0),(e||A)&&this.view.win.scrollBy(e,A),this.dragging===!1&&this.select(this.lastEvent)}skipAtoms(e){let A=null;for(let i=0;i<e.ranges.length;i++){let n=e.ranges[i],o=null;if(n.empty){let r=Bw(this.atoms,n.from,0);r!=n.from&&(o=ie.cursor(r,-1))}else{let r=Bw(this.atoms,n.from,-1),s=Bw(this.atoms,n.to,1);(r!=n.from||s!=n.to)&&(o=ie.range(n.from==n.anchor?r:s,n.from==n.head?r:s))}o&&(A||(A=e.ranges.slice()),A[i]=o)}return A?ie.create(A,e.mainIndex):e}select(e){let{view:A}=this,i=this.skipAtoms(this.style.get(e,this.extend,this.multiple));(this.mustSelect||!i.eq(A.state.selection,this.dragging===!1))&&this.view.dispatch({selection:i,userEvent:"select.pointer"}),this.mustSelect=!1}update(e){e.transactions.some(A=>A.isUserEvent("input.type"))?this.destroy():this.style.update(e)&&setTimeout(()=>this.select(this.lastEvent),20)}};function URA(t,e){let A=t.state.facet(atA);return A.length?A[0](e):He.mac?e.metaKey:e.ctrlKey}function KRA(t,e){let A=t.state.facet(ctA);return A.length?A[0](e):He.mac?!e.altKey:!e.ctrlKey}function YRA(t,e){let{main:A}=t.state.selection;if(A.empty)return!1;let i=Y4(t.root);if(!i||i.rangeCount==0)return!0;let n=i.getRangeAt(0).getClientRects();for(let o=0;o<n.length;o++){let r=n[o];if(r.left<=e.clientX&&r.right>=e.clientX&&r.top<=e.clientY&&r.bottom>=e.clientY)return!0}return!1}function JRA(t,e){if(!e.bubbles)return!0;if(e.defaultPrevented)return!1;for(let A=e.target,i;A!=t.contentDOM;A=A.parentNode)if(!A||A.nodeType==11||(i=mo.get(A))&&i.ignoreEvent(e))return!1;return!0}var El=Object.create(null),Nc=Object.create(null),ytA=He.ie&&He.ie_version<15||He.ios&&He.webkit_version<604;function TRA(t){let e=t.dom.parentNode;if(!e)return;let A=e.appendChild(document.createElement("textarea"));A.style.cssText="position: fixed; left: -10000px; top: 10px",A.focus(),setTimeout(()=>{t.focus(),A.remove(),vtA(t,A.value)},50)}function Gw(t,e,A){for(let i of t.facet(e))A=i(A,t);return A}function vtA(t,e){e=Gw(t.state,qx,e);let{state:A}=t,i,n=1,o=A.toText(e),r=o.lines==A.selection.ranges.length;if(wx!=null&&A.selection.ranges.every(a=>a.empty)&&wx==o.toString()){let a=-1;i=A.changeByRange(c=>{let l=A.doc.lineAt(c.from);if(l.from==a)return{range:c};a=l.from;let I=A.toText((r?o.line(n++).text:e)+A.lineBreak);return{changes:{from:l.from,insert:I},range:ie.cursor(c.from+I.length)}})}else r?i=A.changeByRange(a=>{let c=o.line(n++);return{changes:{from:a.from,to:a.to,insert:c.text},range:ie.cursor(a.from+c.length)}}):i=A.replaceSelection(o);t.dispatch(i,{userEvent:"input.paste",scrollIntoView:!0})}Nc.scroll=t=>{t.inputState.lastScrollTop=t.scrollDOM.scrollTop,t.inputState.lastScrollLeft=t.scrollDOM.scrollLeft};El.keydown=(t,e)=>(t.inputState.setSelectionOrigin("select"),e.keyCode==27&&t.inputState.tabFocusMode!=0&&(t.inputState.tabFocusMode=Date.now()+2e3),!1);Nc.touchstart=(t,e)=>{t.inputState.lastTouchTime=Date.now(),t.inputState.setSelectionOrigin("select.pointer")};Nc.touchmove=t=>{t.inputState.setSelectionOrigin("select.pointer")};El.mousedown=(t,e)=>{if(t.observer.flush(),t.inputState.lastTouchTime>Date.now()-2e3)return!1;let A=null;for(let i of t.state.facet(ltA))if(A=i(t,e),A)break;if(!A&&e.button==0&&(A=ORA(t,e)),A){let i=!t.hasFocus;t.inputState.startMouseSelection(new px(t,e,A,i)),i&&t.observer.ignore(()=>{HeA(t.contentDOM);let o=t.root.activeElement;o&&!o.contains(t.contentDOM)&&o.blur()});let n=t.inputState.mouseSelection;if(n)return n.start(e),n.dragging===!1}return!1};function BeA(t,e,A,i){if(i==1)return ie.cursor(e,A);if(i==2)return pRA(t.state,e,A);{let n=ss.find(t.docView,e),o=t.state.doc.lineAt(n?n.posAtEnd:e),r=n?n.posAtStart:o.from,s=n?n.posAtEnd:o.to;return s<t.state.doc.length&&s==o.to&&s++,ie.range(r,s)}}var EeA=(t,e,A)=>e>=A.top&&e<=A.bottom&&t>=A.left&&t<=A.right;function zRA(t,e,A,i){let n=ss.find(t.docView,e);if(!n)return 1;let o=e-n.posAtStart;if(o==0)return 1;if(o==n.length)return-1;let r=n.coordsAt(o,-1);if(r&&EeA(A,i,r))return-1;let s=n.coordsAt(o,1);return s&&EeA(A,i,s)?1:r&&r.bottom>=i?-1:1}function heA(t,e){let A=t.posAtCoords({x:e.clientX,y:e.clientY},!1);return{pos:A,bias:zRA(t,A,e.clientX,e.clientY)}}var HRA=He.ie&&He.ie_version<=11,QeA=null,ueA=0,feA=0;function btA(t){if(!HRA)return t.detail;let e=QeA,A=feA;return QeA=t,feA=Date.now(),ueA=!e||A>Date.now()-400&&Math.abs(e.clientX-t.clientX)<2&&Math.abs(e.clientY-t.clientY)<2?(ueA+1)%3:1}function ORA(t,e){let A=heA(t,e),i=btA(e),n=t.state.selection;return{update(o){o.docChanged&&(A.pos=o.changes.mapPos(A.pos),n=n.map(o.changes))},get(o,r,s){let a=heA(t,o),c,l=BeA(t,a.pos,a.bias,i);if(A.pos!=a.pos&&!r){let I=BeA(t,A.pos,A.bias,i),C=Math.min(I.from,l.from),d=Math.max(I.to,l.to);l=C<l.from?ie.range(C,d):ie.range(d,C)}return r?n.replaceRange(n.main.extend(l.from,l.to)):s&&i==1&&n.ranges.length>1&&(c=PRA(n,a.pos))?c:s?n.addRange(l):ie.create([l])}}}function PRA(t,e){for(let A=0;A<t.ranges.length;A++){let{from:i,to:n}=t.ranges[A];if(i<=e&&n>=e)return ie.create(t.ranges.slice(0,A).concat(t.ranges.slice(A+1)),t.mainIndex==A?0:t.mainIndex-(t.mainIndex>A?1:0))}return null}El.dragstart=(t,e)=>{let{selection:{main:A}}=t.state;if(e.target.draggable){let n=t.docView.nearest(e.target);if(n&&n.isWidget){let o=n.posAtStart,r=o+n.length;(o>=A.to||r<=A.from)&&(A=ie.range(o,r))}}let{inputState:i}=t;return i.mouseSelection&&(i.mouseSelection.dragging=!0),i.draggedContent=A,e.dataTransfer&&(e.dataTransfer.setData("Text",Gw(t.state,Vx,t.state.sliceDoc(A.from,A.to))),e.dataTransfer.effectAllowed="copyMove"),!1};El.dragend=t=>(t.inputState.draggedContent=null,!1);function meA(t,e,A,i){if(A=Gw(t.state,qx,A),!A)return;let n=t.posAtCoords({x:e.clientX,y:e.clientY},!1),{draggedContent:o}=t.inputState,r=i&&o&&KRA(t,e)?{from:o.from,to:o.to}:null,s={from:n,insert:A},a=t.state.changes(r?[r,s]:s);t.focus(),t.dispatch({changes:a,selection:{anchor:a.mapPos(n,-1),head:a.mapPos(n,1)},userEvent:r?"move.drop":"input.drop"}),t.inputState.draggedContent=null}El.drop=(t,e)=>{if(!e.dataTransfer)return!1;if(t.state.readOnly)return!0;let A=e.dataTransfer.files;if(A&&A.length){let i=Array(A.length),n=0,o=()=>{++n==A.length&&meA(t,e,i.filter(r=>r!=null).join(t.state.lineBreak),!1)};for(let r=0;r<A.length;r++){let s=new FileReader;s.onerror=o,s.onload=()=>{/[\x00-\x08\x0e-\x1f]{2}/.test(s.result)||(i[r]=s.result),o()},s.readAsText(A[r])}return!0}else{let i=e.dataTransfer.getData("Text");if(i)return meA(t,e,i,!0),!0}return!1};El.paste=(t,e)=>{if(t.state.readOnly)return!0;t.observer.flush();let A=ytA?null:e.clipboardData;return A?(vtA(t,A.getData("text/plain")||A.getData("text/uri-list")),!0):(TRA(t),!1)};function jRA(t,e){let A=t.dom.parentNode;if(!A)return;let i=A.appendChild(document.createElement("textarea"));i.style.cssText="position: fixed; left: -10000px; top: 10px",i.value=e,i.focus(),i.selectionEnd=e.length,i.selectionStart=0,setTimeout(()=>{i.remove(),t.focus()},50)}function qRA(t){let e=[],A=[],i=!1;for(let n of t.selection.ranges)n.empty||(e.push(t.sliceDoc(n.from,n.to)),A.push(n));if(!e.length){let n=-1;for(let{from:o}of t.selection.ranges){let r=t.doc.lineAt(o);r.number>n&&(e.push(r.text),A.push({from:r.from,to:Math.min(t.doc.length,r.to+1)})),n=r.number}i=!0}return{text:Gw(t,Vx,e.join(t.lineBreak)),ranges:A,linewise:i}}var wx=null;El.copy=El.cut=(t,e)=>{let{text:A,ranges:i,linewise:n}=qRA(t.state);if(!A&&!n)return!1;wx=n?A:null,e.type=="cut"&&!t.state.readOnly&&t.dispatch({changes:i,scrollIntoView:!0,userEvent:"delete.cut"});let o=ytA?null:e.clipboardData;return o?(o.clearData(),o.setData("text/plain",A),!0):(jRA(t,A),!1)};var MtA=wa.define();function ktA(t,e){let A=[];for(let i of t.facet(CtA)){let n=i(t,e);n&&A.push(n)}return A.length?t.update({effects:A,annotations:MtA.of(!0)}):null}function StA(t){setTimeout(()=>{let e=t.hasFocus;if(e!=t.inputState.notifiedFocused){let A=ktA(t.state,e);A?t.dispatch(A):t.update([])}},10)}Nc.focus=t=>{t.inputState.lastFocusTime=Date.now(),!t.scrollDOM.scrollTop&&(t.inputState.lastScrollTop||t.inputState.lastScrollLeft)&&(t.scrollDOM.scrollTop=t.inputState.lastScrollTop,t.scrollDOM.scrollLeft=t.inputState.lastScrollLeft),StA(t)};Nc.blur=t=>{t.observer.clearSelectionRange(),StA(t)};Nc.compositionstart=Nc.compositionupdate=t=>{t.observer.editContext||(t.inputState.compositionFirstChange==null&&(t.inputState.compositionFirstChange=!0),t.inputState.composing<0&&(t.inputState.composing=0))};Nc.compositionend=t=>{t.observer.editContext||(t.inputState.composing=-1,t.inputState.compositionEndedAt=Date.now(),t.inputState.compositionPendingKey=!0,t.inputState.compositionPendingChange=t.observer.pendingRecords().length>0,t.inputState.compositionFirstChange=null,He.chrome&&He.android?t.observer.flushSoon():t.inputState.compositionPendingChange?Promise.resolve().then(()=>t.observer.flush()):setTimeout(()=>{t.inputState.composing<0&&t.docView.hasComposition&&t.update([])},50))};Nc.contextmenu=t=>{t.inputState.lastContextMenu=Date.now()};El.beforeinput=(t,e)=>{var A,i;if(e.inputType=="insertReplacementText"&&t.observer.editContext){let o=(A=e.dataTransfer)===null||A===void 0?void 0:A.getData("text/plain"),r=e.getTargetRanges();if(o&&r.length){let s=r[0],a=t.posAtDOM(s.startContainer,s.startOffset),c=t.posAtDOM(s.endContainer,s.endOffset);return Xx(t,{from:a,to:c,insert:t.state.toText(o)},null),!0}}let n;if(He.chrome&&He.android&&(n=wtA.find(o=>o.inputType==e.inputType))&&(t.observer.delayAndroidKey(n.key,n.keyCode),n.key=="Backspace"||n.key=="Delete")){let o=((i=window.visualViewport)===null||i===void 0?void 0:i.height)||0;setTimeout(()=>{var r;(((r=window.visualViewport)===null||r===void 0?void 0:r.height)||0)>o+10&&t.hasFocus&&(t.contentDOM.blur(),t.focus())},100)}return He.ios&&e.inputType=="deleteContentForward"&&t.observer.flushSoon(),He.safari&&e.inputType=="insertText"&&t.inputState.composing>=0&&setTimeout(()=>Nc.compositionend(t,e),20),!1};var peA=new Set;function VRA(t){peA.has(t)||(peA.add(t),t.addEventListener("copy",()=>{}),t.addEventListener("cut",()=>{}))}var weA=["pre-wrap","normal","pre-line","break-spaces"],pE=!1;function DeA(){pE=!1}var Dx=class{constructor(e){this.lineWrapping=e,this.doc=qi.empty,this.heightSamples={},this.lineHeight=14,this.charWidth=7,this.textHeight=14,this.lineLength=30}heightForGap(e,A){let i=this.doc.lineAt(A).number-this.doc.lineAt(e).number+1;return this.lineWrapping&&(i+=Math.max(0,Math.ceil((A-e-i*this.lineLength*.5)/this.lineLength))),this.lineHeight*i}heightForLine(e){return this.lineWrapping?(1+Math.max(0,Math.ceil((e-this.lineLength)/(this.lineLength-5))))*this.lineHeight:this.lineHeight}setDoc(e){return this.doc=e,this}mustRefreshForWrapping(e){return weA.indexOf(e)>-1!=this.lineWrapping}mustRefreshForHeights(e){let A=!1;for(let i=0;i<e.length;i++){let n=e[i];n<0?i++:this.heightSamples[Math.floor(n*10)]||(A=!0,this.heightSamples[Math.floor(n*10)]=!0)}return A}refresh(e,A,i,n,o,r){let s=weA.indexOf(e)>-1,a=Math.round(A)!=Math.round(this.lineHeight)||this.lineWrapping!=s;if(this.lineWrapping=s,this.lineHeight=A,this.charWidth=i,this.textHeight=n,this.lineLength=o,a){this.heightSamples={};for(let c=0;c<r.length;c++){let l=r[c];l<0?c++:this.heightSamples[Math.floor(l*10)]=!0}}return a}},yx=class{constructor(e,A){this.from=e,this.heights=A,this.index=0}get more(){return this.index<this.heights.length}},mg=class t{constructor(e,A,i,n,o){this.from=e,this.length=A,this.top=i,this.height=n,this._content=o}get type(){return typeof this._content=="number"?zs.Text:Array.isArray(this._content)?this._content:this._content.type}get to(){return this.from+this.length}get bottom(){return this.top+this.height}get widget(){return this._content instanceof f1?this._content.widget:null}get widgetLineBreaks(){return typeof this._content=="number"?this._content:0}join(e){let A=(Array.isArray(this._content)?this._content:[this]).concat(Array.isArray(e._content)?e._content:[e]);return new t(this.from,this.length+e.length,this.top,this.height+e.height,A)}},Lo=function(t){return t[t.ByPos=0]="ByPos",t[t.ByHeight=1]="ByHeight",t[t.ByPosNoHeight=2]="ByPosNoHeight",t}(Lo||(Lo={})),Ew=.001,ic=class t{constructor(e,A,i=2){this.length=e,this.height=A,this.flags=i}get outdated(){return(this.flags&2)>0}set outdated(e){this.flags=(e?2:0)|this.flags&-3}setHeight(e){this.height!=e&&(Math.abs(this.height-e)>Ew&&(pE=!0),this.height=e)}replace(e,A,i){return t.of(i)}decomposeLeft(e,A){A.push(this)}decomposeRight(e,A){A.push(this)}applyChanges(e,A,i,n){let o=this,r=i.doc;for(let s=n.length-1;s>=0;s--){let{fromA:a,toA:c,fromB:l,toB:I}=n[s],C=o.lineAt(a,Lo.ByPosNoHeight,i.setDoc(A),0,0),d=C.to>=c?C:o.lineAt(c,Lo.ByPosNoHeight,i,0,0);for(I+=d.to-c,c=d.to;s>0&&C.from<=n[s-1].toA;)a=n[s-1].fromA,l=n[s-1].fromB,s--,a<C.from&&(C=o.lineAt(a,Lo.ByPosNoHeight,i,0,0));l+=C.from-a,a=C.from;let B=bx.build(i.setDoc(r),e,l,I);o=vw(o,o.replace(a,c,B))}return o.updateHeight(i,0)}static empty(){return new Fc(0,0)}static of(e){if(e.length==1)return e[0];let A=0,i=e.length,n=0,o=0;for(;;)if(A==i)if(n>o*2){let s=e[A-1];s.break?e.splice(--A,1,s.left,null,s.right):e.splice(--A,1,s.left,s.right),i+=1+s.break,n-=s.size}else if(o>n*2){let s=e[i];s.break?e.splice(i,1,s.left,null,s.right):e.splice(i,1,s.left,s.right),i+=2+s.break,o-=s.size}else break;else if(n<o){let s=e[A++];s&&(n+=s.size)}else{let s=e[--i];s&&(o+=s.size)}let r=0;return e[A-1]==null?(r=1,A--):e[A]==null&&(r=1,i++),new vx(t.of(e.slice(0,A)),r,t.of(e.slice(i)))}};function vw(t,e){return t==e?t:(t.constructor!=e.constructor&&(pE=!0),e)}ic.prototype.size=1;var bw=class extends ic{constructor(e,A,i){super(e,A),this.deco=i}blockAt(e,A,i,n){return new mg(n,this.length,i,this.height,this.deco||0)}lineAt(e,A,i,n,o){return this.blockAt(0,i,n,o)}forEachLine(e,A,i,n,o,r){e<=o+this.length&&A>=o&&r(this.blockAt(0,i,n,o))}updateHeight(e,A=0,i=!1,n){return n&&n.from<=A&&n.more&&this.setHeight(n.heights[n.index++]),this.outdated=!1,this}toString(){return`block(${this.length})`}},Fc=class t extends bw{constructor(e,A){super(e,A,null),this.collapsed=0,this.widgetHeight=0,this.breaks=0}blockAt(e,A,i,n){return new mg(n,this.length,i,this.height,this.breaks)}replace(e,A,i){let n=i[0];return i.length==1&&(n instanceof t||n instanceof Q1&&n.flags&4)&&Math.abs(this.length-n.length)<10?(n instanceof Q1?n=new t(n.length,this.height):n.height=this.height,this.outdated||(n.outdated=!1),n):ic.of(i)}updateHeight(e,A=0,i=!1,n){return n&&n.from<=A&&n.more?this.setHeight(n.heights[n.index++]):(i||this.outdated)&&this.setHeight(Math.max(this.widgetHeight,e.heightForLine(this.length-this.collapsed))+this.breaks*e.lineHeight),this.outdated=!1,this}toString(){return`line(${this.length}${this.collapsed?-this.collapsed:""}${this.widgetHeight?":"+this.widgetHeight:""})`}},Q1=class t extends ic{constructor(e){super(e,0)}heightMetrics(e,A){let i=e.doc.lineAt(A).number,n=e.doc.lineAt(A+this.length).number,o=n-i+1,r,s=0;if(e.lineWrapping){let a=Math.min(this.height,e.lineHeight*o);r=a/o,this.length>o+1&&(s=(this.height-a)/(this.length-o-1))}else r=this.height/o;return{firstLine:i,lastLine:n,perLine:r,perChar:s}}blockAt(e,A,i,n){let{firstLine:o,lastLine:r,perLine:s,perChar:a}=this.heightMetrics(A,n);if(A.lineWrapping){let c=n+(e<A.lineHeight?0:Math.round(Math.max(0,Math.min(1,(e-i)/this.height))*this.length)),l=A.doc.lineAt(c),I=s+l.length*a,C=Math.max(i,e-I/2);return new mg(l.from,l.length,C,I,0)}else{let c=Math.max(0,Math.min(r-o,Math.floor((e-i)/s))),{from:l,length:I}=A.doc.line(o+c);return new mg(l,I,i+s*c,s,0)}}lineAt(e,A,i,n,o){if(A==Lo.ByHeight)return this.blockAt(e,i,n,o);if(A==Lo.ByPosNoHeight){let{from:d,to:B}=i.doc.lineAt(e);return new mg(d,B-d,0,0,0)}let{firstLine:r,perLine:s,perChar:a}=this.heightMetrics(i,o),c=i.doc.lineAt(e),l=s+c.length*a,I=c.number-r,C=n+s*I+a*(c.from-o-I);return new mg(c.from,c.length,Math.max(n,Math.min(C,n+this.height-l)),l,0)}forEachLine(e,A,i,n,o,r){e=Math.max(e,o),A=Math.min(A,o+this.length);let{firstLine:s,perLine:a,perChar:c}=this.heightMetrics(i,o);for(let l=e,I=n;l<=A;){let C=i.doc.lineAt(l);if(l==e){let B=C.number-s;I+=a*B+c*(e-o-B)}let d=a+c*C.length;r(new mg(C.from,C.length,I,d,0)),I+=d,l=C.to+1}}replace(e,A,i){let n=this.length-A;if(n>0){let o=i[i.length-1];o instanceof t?i[i.length-1]=new t(o.length+n):i.push(null,new t(n-1))}if(e>0){let o=i[0];o instanceof t?i[0]=new t(e+o.length):i.unshift(new t(e-1),null)}return ic.of(i)}decomposeLeft(e,A){A.push(new t(e-1),null)}decomposeRight(e,A){A.push(null,new t(this.length-e-1))}updateHeight(e,A=0,i=!1,n){let o=A+this.length;if(n&&n.from<=A+this.length&&n.more){let r=[],s=Math.max(A,n.from),a=-1;for(n.from>A&&r.push(new t(n.from-A-1).updateHeight(e,A));s<=o&&n.more;){let l=e.doc.lineAt(s).length;r.length&&r.push(null);let I=n.heights[n.index++];a==-1?a=I:Math.abs(I-a)>=Ew&&(a=-2);let C=new Fc(l,I);C.outdated=!1,r.push(C),s+=l+1}s<=o&&r.push(null,new t(o-s).updateHeight(e,s));let c=ic.of(r);return(a<0||Math.abs(c.height-this.height)>=Ew||Math.abs(a-this.heightMetrics(e,A).perLine)>=Ew)&&(pE=!0),vw(this,c)}else(i||this.outdated)&&(this.setHeight(e.heightForGap(A,A+this.length)),this.outdated=!1);return this}toString(){return`gap(${this.length})`}},vx=class extends ic{constructor(e,A,i){super(e.length+A+i.length,e.height+i.height,A|(e.outdated||i.outdated?2:0)),this.left=e,this.right=i,this.size=e.size+i.size}get break(){return this.flags&1}blockAt(e,A,i,n){let o=i+this.left.height;return e<o?this.left.blockAt(e,A,i,n):this.right.blockAt(e,A,o,n+this.left.length+this.break)}lineAt(e,A,i,n,o){let r=n+this.left.height,s=o+this.left.length+this.break,a=A==Lo.ByHeight?e<r:e<s,c=a?this.left.lineAt(e,A,i,n,o):this.right.lineAt(e,A,i,r,s);if(this.break||(a?c.to<s:c.from>s))return c;let l=A==Lo.ByPosNoHeight?Lo.ByPosNoHeight:Lo.ByPos;return a?c.join(this.right.lineAt(s,l,i,r,s)):this.left.lineAt(s,l,i,n,o).join(c)}forEachLine(e,A,i,n,o,r){let s=n+this.left.height,a=o+this.left.length+this.break;if(this.break)e<a&&this.left.forEachLine(e,A,i,n,o,r),A>=a&&this.right.forEachLine(e,A,i,s,a,r);else{let c=this.lineAt(a,Lo.ByPos,i,n,o);e<c.from&&this.left.forEachLine(e,c.from-1,i,n,o,r),c.to>=e&&c.from<=A&&r(c),A>c.to&&this.right.forEachLine(c.to+1,A,i,s,a,r)}}replace(e,A,i){let n=this.left.length+this.break;if(A<n)return this.balanced(this.left.replace(e,A,i),this.right);if(e>this.left.length)return this.balanced(this.left,this.right.replace(e-n,A-n,i));let o=[];e>0&&this.decomposeLeft(e,o);let r=o.length;for(let s of i)o.push(s);if(e>0&&yeA(o,r-1),A<this.length){let s=o.length;this.decomposeRight(A,o),yeA(o,s)}return ic.of(o)}decomposeLeft(e,A){let i=this.left.length;if(e<=i)return this.left.decomposeLeft(e,A);A.push(this.left),this.break&&(i++,e>=i&&A.push(null)),e>i&&this.right.decomposeLeft(e-i,A)}decomposeRight(e,A){let i=this.left.length,n=i+this.break;if(e>=n)return this.right.decomposeRight(e-n,A);e<i&&this.left.decomposeRight(e,A),this.break&&e<n&&A.push(null),A.push(this.right)}balanced(e,A){return e.size>2*A.size||A.size>2*e.size?ic.of(this.break?[e,null,A]:[e,A]):(this.left=vw(this.left,e),this.right=vw(this.right,A),this.setHeight(e.height+A.height),this.outdated=e.outdated||A.outdated,this.size=e.size+A.size,this.length=e.length+this.break+A.length,this)}updateHeight(e,A=0,i=!1,n){let{left:o,right:r}=this,s=A+o.length+this.break,a=null;return n&&n.from<=A+o.length&&n.more?a=o=o.updateHeight(e,A,i,n):o.updateHeight(e,A,i),n&&n.from<=s+r.length&&n.more?a=r=r.updateHeight(e,s,i,n):r.updateHeight(e,s,i),a?this.balanced(o,r):(this.height=this.left.height+this.right.height,this.outdated=!1,this)}toString(){return this.left+(this.break?" ":"-")+this.right}};function yeA(t,e){let A,i;t[e]==null&&(A=t[e-1])instanceof Q1&&(i=t[e+1])instanceof Q1&&t.splice(e-1,3,new Q1(A.length+1+i.length))}var ZRA=5,bx=class t{constructor(e,A){this.pos=e,this.oracle=A,this.nodes=[],this.lineStart=-1,this.lineEnd=-1,this.covering=null,this.writtenTo=e}get isCovered(){return this.covering&&this.nodes[this.nodes.length-1]==this.covering}span(e,A){if(this.lineStart>-1){let i=Math.min(A,this.lineEnd),n=this.nodes[this.nodes.length-1];n instanceof Fc?n.length+=i-this.pos:(i>this.pos||!this.isCovered)&&this.nodes.push(new Fc(i-this.pos,-1)),this.writtenTo=i,A>i&&(this.nodes.push(null),this.writtenTo++,this.lineStart=-1)}this.pos=A}point(e,A,i){if(e<A||i.heightRelevant){let n=i.widget?i.widget.estimatedHeight:0,o=i.widget?i.widget.lineBreaks:0;n<0&&(n=this.oracle.lineHeight);let r=A-e;i.block?this.addBlock(new bw(r,n,i)):(r||o||n>=ZRA)&&this.addLineDeco(n,o,r)}else A>e&&this.span(e,A);this.lineEnd>-1&&this.lineEnd<this.pos&&(this.lineEnd=this.oracle.doc.lineAt(this.pos).to)}enterLine(){if(this.lineStart>-1)return;let{from:e,to:A}=this.oracle.doc.lineAt(this.pos);this.lineStart=e,this.lineEnd=A,this.writtenTo<e&&((this.writtenTo<e-1||this.nodes[this.nodes.length-1]==null)&&this.nodes.push(this.blankContent(this.writtenTo,e-1)),this.nodes.push(null)),this.pos>e&&this.nodes.push(new Fc(this.pos-e,-1)),this.writtenTo=this.pos}blankContent(e,A){let i=new Q1(A-e);return this.oracle.doc.lineAt(e).to==A&&(i.flags|=4),i}ensureLine(){this.enterLine();let e=this.nodes.length?this.nodes[this.nodes.length-1]:null;if(e instanceof Fc)return e;let A=new Fc(0,-1);return this.nodes.push(A),A}addBlock(e){this.enterLine();let A=e.deco;A&&A.startSide>0&&!this.isCovered&&this.ensureLine(),this.nodes.push(e),this.writtenTo=this.pos=this.pos+e.length,A&&A.endSide>0&&(this.covering=e)}addLineDeco(e,A,i){let n=this.ensureLine();n.length+=i,n.collapsed+=i,n.widgetHeight=Math.max(n.widgetHeight,e),n.breaks+=A,this.writtenTo=this.pos=this.pos+i}finish(e){let A=this.nodes.length==0?null:this.nodes[this.nodes.length-1];this.lineStart>-1&&!(A instanceof Fc)&&!this.isCovered?this.nodes.push(new Fc(0,-1)):(this.writtenTo<this.pos||A==null)&&this.nodes.push(this.blankContent(this.writtenTo,this.pos));let i=e;for(let n of this.nodes)n instanceof Fc&&n.updateHeight(this.oracle,i),i+=n?n.length:1;return this.nodes}static build(e,A,i,n){let o=new t(i,e);return Zn.spans(A,i,n,o,0),o.finish(i)}};function WRA(t,e,A){let i=new Mx;return Zn.compare(t,e,A,i,0),i.changes}var Mx=class{constructor(){this.changes=[]}compareRange(){}comparePoint(e,A,i,n){(e<A||i&&i.heightRelevant||n&&n.heightRelevant)&&dw(e,A,this.changes,5)}};function XRA(t,e){let A=t.getBoundingClientRect(),i=t.ownerDocument,n=i.defaultView||window,o=Math.max(0,A.left),r=Math.min(n.innerWidth,A.right),s=Math.max(0,A.top),a=Math.min(n.innerHeight,A.bottom);for(let c=t.parentNode;c&&c!=i.body;)if(c.nodeType==1){let l=c,I=window.getComputedStyle(l);if((l.scrollHeight>l.clientHeight||l.scrollWidth>l.clientWidth)&&I.overflow!="visible"){let C=l.getBoundingClientRect();o=Math.max(o,C.left),r=Math.min(r,C.right),s=Math.max(s,C.top),a=Math.min(c==t.parentNode?n.innerHeight:a,C.bottom)}c=I.position=="absolute"||I.position=="fixed"?l.offsetParent:l.parentNode}else if(c.nodeType==11)c=c.host;else break;return{left:o-A.left,right:Math.max(o,r)-A.left,top:s-(A.top+e),bottom:Math.max(s,a)-(A.top+e)}}function $RA(t){let e=t.getBoundingClientRect(),A=t.ownerDocument.defaultView||window;return e.left<A.innerWidth&&e.right>0&&e.top<A.innerHeight&&e.bottom>0}function ALA(t,e){let A=t.getBoundingClientRect();return{left:0,right:A.right-A.left,top:e,bottom:A.bottom-(A.top+e)}}var G4=class{constructor(e,A,i,n){this.from=e,this.to=A,this.size=i,this.displaySize=n}static same(e,A){if(e.length!=A.length)return!1;for(let i=0;i<e.length;i++){let n=e[i],o=A[i];if(n.from!=o.from||n.to!=o.to||n.size!=o.size)return!1}return!0}draw(e,A){return rt.replace({widget:new kx(this.displaySize*(A?e.scaleY:e.scaleX),A)}).range(this.from,this.to)}},kx=class extends nc{constructor(e,A){super(),this.size=e,this.vertical=A}eq(e){return e.size==this.size&&e.vertical==this.vertical}toDOM(){let e=document.createElement("div");return this.vertical?e.style.height=this.size+"px":(e.style.width=this.size+"px",e.style.height="2px",e.style.display="inline-block"),e}get estimatedHeight(){return this.vertical?this.size:-1}},Mw=class{constructor(e){this.state=e,this.pixelViewport={left:0,right:window.innerWidth,top:0,bottom:0},this.inView=!0,this.paddingTop=0,this.paddingBottom=0,this.contentDOMWidth=0,this.contentDOMHeight=0,this.editorHeight=0,this.editorWidth=0,this.scrollTop=0,this.scrolledToBottom=!1,this.scaleX=1,this.scaleY=1,this.scrollAnchorPos=0,this.scrollAnchorHeight=-1,this.scaler=veA,this.scrollTarget=null,this.printing=!1,this.mustMeasureContent=!0,this.defaultTextDirection=Wn.LTR,this.visibleRanges=[],this.mustEnforceCursorAssoc=!1;let A=e.facet(Ex).some(i=>typeof i!="function"&&i.class=="cm-lineWrapping");this.heightOracle=new Dx(A),this.stateDeco=e.facet(j4).filter(i=>typeof i!="function"),this.heightMap=ic.empty().applyChanges(this.stateDeco,qi.empty,this.heightOracle.setDoc(e.doc),[new wg(0,0,0,e.doc.length)]);for(let i=0;i<2&&(this.viewport=this.getViewport(0,null),!!this.updateForViewport());i++);this.updateViewportLines(),this.lineGaps=this.ensureLineGaps([]),this.lineGapDeco=rt.set(this.lineGaps.map(i=>i.draw(this,!1))),this.computeVisibleRanges()}updateForViewport(){let e=[this.viewport],{main:A}=this.state.selection;for(let i=0;i<=1;i++){let n=i?A.head:A.anchor;if(!e.some(({from:o,to:r})=>n>=o&&n<=r)){let{from:o,to:r}=this.lineBlockAt(n);e.push(new QE(o,r))}}return this.viewports=e.sort((i,n)=>i.from-n.from),this.updateScaler()}updateScaler(){let e=this.scaler;return this.scaler=this.heightMap.height<=7e6?veA:new Sx(this.heightOracle,this.heightMap,this.viewports),e.eq(this.scaler)?0:2}updateViewportLines(){this.viewportLines=[],this.heightMap.forEachLine(this.viewport.from,this.viewport.to,this.heightOracle.setDoc(this.state.doc),0,0,e=>{this.viewportLines.push(R4(e,this.scaler))})}update(e,A=null){this.state=e.state;let i=this.stateDeco;this.stateDeco=this.state.facet(j4).filter(l=>typeof l!="function");let n=e.changedRanges,o=wg.extendWithRanges(n,WRA(i,this.stateDeco,e?e.changes:ns.empty(this.state.doc.length))),r=this.heightMap.height,s=this.scrolledToBottom?null:this.scrollAnchorAt(this.scrollTop);DeA(),this.heightMap=this.heightMap.applyChanges(this.stateDeco,e.startState.doc,this.heightOracle.setDoc(this.state.doc),o),(this.heightMap.height!=r||pE)&&(e.flags|=2),s?(this.scrollAnchorPos=e.changes.mapPos(s.from,-1),this.scrollAnchorHeight=s.top):(this.scrollAnchorPos=-1,this.scrollAnchorHeight=r);let a=o.length?this.mapViewport(this.viewport,e.changes):this.viewport;(A&&(A.range.head<a.from||A.range.head>a.to)||!this.viewportIsAppropriate(a))&&(a=this.getViewport(0,A));let c=a.from!=this.viewport.from||a.to!=this.viewport.to;this.viewport=a,e.flags|=this.updateForViewport(),(c||!e.changes.empty||e.flags&2)&&this.updateViewportLines(),(this.lineGaps.length||this.viewport.to-this.viewport.from>4e3)&&this.updateLineGaps(this.ensureLineGaps(this.mapLineGaps(this.lineGaps,e.changes))),e.flags|=this.computeVisibleRanges(e.changes),A&&(this.scrollTarget=A),!this.mustEnforceCursorAssoc&&e.selectionSet&&e.view.lineWrapping&&e.state.selection.main.empty&&e.state.selection.main.assoc&&!e.state.facet(dtA)&&(this.mustEnforceCursorAssoc=!0)}measure(e){let A=e.contentDOM,i=window.getComputedStyle(A),n=this.heightOracle,o=i.whiteSpace;this.defaultTextDirection=i.direction=="rtl"?Wn.RTL:Wn.LTR;let r=this.heightOracle.mustRefreshForWrapping(o),s=A.getBoundingClientRect(),a=r||this.mustMeasureContent||this.contentDOMHeight!=s.height;this.contentDOMHeight=s.height,this.mustMeasureContent=!1;let c=0,l=0;if(s.width&&s.height){let{scaleX:x,scaleY:y}=zeA(A,s);(x>.005&&Math.abs(this.scaleX-x)>.005||y>.005&&Math.abs(this.scaleY-y)>.005)&&(this.scaleX=x,this.scaleY=y,c|=16,r=a=!0)}let I=(parseInt(i.paddingTop)||0)*this.scaleY,C=(parseInt(i.paddingBottom)||0)*this.scaleY;(this.paddingTop!=I||this.paddingBottom!=C)&&(this.paddingTop=I,this.paddingBottom=C,c|=18),this.editorWidth!=e.scrollDOM.clientWidth&&(n.lineWrapping&&(a=!0),this.editorWidth=e.scrollDOM.clientWidth,c|=16);let d=e.scrollDOM.scrollTop*this.scaleY;this.scrollTop!=d&&(this.scrollAnchorHeight=-1,this.scrollTop=d),this.scrolledToBottom=PeA(e.scrollDOM);let B=(this.printing?ALA:XRA)(A,this.paddingTop),E=B.top-this.pixelViewport.top,Q=B.bottom-this.pixelViewport.bottom;this.pixelViewport=B;let u=this.pixelViewport.bottom>this.pixelViewport.top&&this.pixelViewport.right>this.pixelViewport.left;if(u!=this.inView&&(this.inView=u,u&&(a=!0)),!this.inView&&!this.scrollTarget&&!$RA(e.dom))return 0;let v=s.width;if((this.contentDOMWidth!=v||this.editorHeight!=e.scrollDOM.clientHeight)&&(this.contentDOMWidth=s.width,this.editorHeight=e.scrollDOM.clientHeight,c|=16),a){let x=e.docView.measureVisibleLineHeights(this.viewport);if(n.mustRefreshForHeights(x)&&(r=!0),r||n.lineWrapping&&Math.abs(v-this.contentDOMWidth)>n.charWidth){let{lineHeight:y,charWidth:F,textHeight:U}=e.docView.measureTextSize();r=y>0&&n.refresh(o,y,F,U,v/F,x),r&&(e.docView.minWidth=0,c|=16)}E>0&&Q>0?l=Math.max(E,Q):E<0&&Q<0&&(l=Math.min(E,Q)),DeA();for(let y of this.viewports){let F=y.from==this.viewport.from?x:e.docView.measureVisibleLineHeights(y);this.heightMap=(r?ic.empty().applyChanges(this.stateDeco,qi.empty,this.heightOracle,[new wg(0,0,0,e.state.doc.length)]):this.heightMap).updateHeight(n,0,r,new yx(y.from,F))}pE&&(c|=2)}let L=!this.viewportIsAppropriate(this.viewport,l)||this.scrollTarget&&(this.scrollTarget.range.head<this.viewport.from||this.scrollTarget.range.head>this.viewport.to);return L&&(c&2&&(c|=this.updateScaler()),this.viewport=this.getViewport(l,this.scrollTarget),c|=this.updateForViewport()),(c&2||L)&&this.updateViewportLines(),(this.lineGaps.length||this.viewport.to-this.viewport.from>4e3)&&this.updateLineGaps(this.ensureLineGaps(r?[]:this.lineGaps,e)),c|=this.computeVisibleRanges(),this.mustEnforceCursorAssoc&&(this.mustEnforceCursorAssoc=!1,e.docView.enforceCursorAssoc()),c}get visibleTop(){return this.scaler.fromDOM(this.pixelViewport.top)}get visibleBottom(){return this.scaler.fromDOM(this.pixelViewport.bottom)}getViewport(e,A){let i=.5-Math.max(-.5,Math.min(.5,e/1e3/2)),n=this.heightMap,o=this.heightOracle,{visibleTop:r,visibleBottom:s}=this,a=new QE(n.lineAt(r-i*1e3,Lo.ByHeight,o,0,0).from,n.lineAt(s+(1-i)*1e3,Lo.ByHeight,o,0,0).to);if(A){let{head:c}=A.range;if(c<a.from||c>a.to){let l=Math.min(this.editorHeight,this.pixelViewport.bottom-this.pixelViewport.top),I=n.lineAt(c,Lo.ByPos,o,0,0),C;A.y=="center"?C=(I.top+I.bottom)/2-l/2:A.y=="start"||A.y=="nearest"&&c<a.from?C=I.top:C=I.bottom-l,a=new QE(n.lineAt(C-1e3/2,Lo.ByHeight,o,0,0).from,n.lineAt(C+l+1e3/2,Lo.ByHeight,o,0,0).to)}}return a}mapViewport(e,A){let i=A.mapPos(e.from,-1),n=A.mapPos(e.to,1);return new QE(this.heightMap.lineAt(i,Lo.ByPos,this.heightOracle,0,0).from,this.heightMap.lineAt(n,Lo.ByPos,this.heightOracle,0,0).to)}viewportIsAppropriate({from:e,to:A},i=0){if(!this.inView)return!0;let{top:n}=this.heightMap.lineAt(e,Lo.ByPos,this.heightOracle,0,0),{bottom:o}=this.heightMap.lineAt(A,Lo.ByPos,this.heightOracle,0,0),{visibleTop:r,visibleBottom:s}=this;return(e==0||n<=r-Math.max(10,Math.min(-i,250)))&&(A==this.state.doc.length||o>=s+Math.max(10,Math.min(i,250)))&&n>r-2*1e3&&o<s+2*1e3}mapLineGaps(e,A){if(!e.length||A.empty)return e;let i=[];for(let n of e)A.touchesRange(n.from,n.to)||i.push(new G4(A.mapPos(n.from),A.mapPos(n.to),n.size,n.displaySize));return i}ensureLineGaps(e,A){let i=this.heightOracle.lineWrapping,n=i?1e4:2e3,o=n>>1,r=n<<1;if(this.defaultTextDirection!=Wn.LTR&&!i)return[];let s=[],a=(l,I,C,d)=>{if(I-l<o)return;let B=this.state.selection.main,E=[B.from];B.empty||E.push(B.to);for(let u of E)if(u>l&&u<I){a(l,u-10,C,d),a(u+10,I,C,d);return}let Q=tLA(e,u=>u.from>=C.from&&u.to<=C.to&&Math.abs(u.from-l)<o&&Math.abs(u.to-I)<o&&!E.some(v=>u.from<v&&u.to>v));if(!Q){if(I<C.to&&A&&i&&A.visibleRanges.some(L=>L.from<=I&&L.to>=I)){let L=A.moveToLineBoundary(ie.cursor(I),!1,!0).head;L>l&&(I=L)}let u=this.gapSize(C,l,I,d),v=i||u<2e6?u:2e6;Q=new G4(l,I,u,v)}s.push(Q)},c=l=>{if(l.length<r||l.type!=zs.Text)return;let I=eLA(l.from,l.to,this.stateDeco);if(I.total<r)return;let C=this.scrollTarget?this.scrollTarget.range.head:null,d,B;if(i){let E=n/this.heightOracle.lineLength*this.heightOracle.lineHeight,Q,u;if(C!=null){let v=cw(I,C),L=((this.visibleBottom-this.visibleTop)/2+E)/l.height;Q=v-L,u=v+L}else Q=(this.visibleTop-l.top-E)/l.height,u=(this.visibleBottom-l.top+E)/l.height;d=aw(I,Q),B=aw(I,u)}else{let E=I.total*this.heightOracle.charWidth,Q=n*this.heightOracle.charWidth,u=0;if(E>2e6)for(let F of e)F.from>=l.from&&F.from<l.to&&F.size!=F.displaySize&&F.from*this.heightOracle.charWidth+u<this.pixelViewport.left&&(u=F.size-F.displaySize);let v=this.pixelViewport.left+u,L=this.pixelViewport.right+u,x,y;if(C!=null){let F=cw(I,C),U=((L-v)/2+Q)/E;x=F-U,y=F+U}else x=(v-Q)/E,y=(L+Q)/E;d=aw(I,x),B=aw(I,y)}d>l.from&&a(l.from,d,l,I),B<l.to&&a(B,l.to,l,I)};for(let l of this.viewportLines)Array.isArray(l.type)?l.type.forEach(c):c(l);return s}gapSize(e,A,i,n){let o=cw(n,i)-cw(n,A);return this.heightOracle.lineWrapping?e.height*o:n.total*this.heightOracle.charWidth*o}updateLineGaps(e){G4.same(e,this.lineGaps)||(this.lineGaps=e,this.lineGapDeco=rt.set(e.map(A=>A.draw(this,this.heightOracle.lineWrapping))))}computeVisibleRanges(e){let A=this.stateDeco;this.lineGaps.length&&(A=A.concat(this.lineGapDeco));let i=[];Zn.spans(A,this.viewport.from,this.viewport.to,{span(o,r){i.push({from:o,to:r})},point(){}},20);let n=0;if(i.length!=this.visibleRanges.length)n=12;else for(let o=0;o<i.length&&!(n&8);o++){let r=this.visibleRanges[o],s=i[o];(r.from!=s.from||r.to!=s.to)&&(n|=4,e&&e.mapPos(r.from,-1)==s.from&&e.mapPos(r.to,1)==s.to||(n|=8))}return this.visibleRanges=i,n}lineBlockAt(e){return e>=this.viewport.from&&e<=this.viewport.to&&this.viewportLines.find(A=>A.from<=e&&A.to>=e)||R4(this.heightMap.lineAt(e,Lo.ByPos,this.heightOracle,0,0),this.scaler)}lineBlockAtHeight(e){return e>=this.viewportLines[0].top&&e<=this.viewportLines[this.viewportLines.length-1].bottom&&this.viewportLines.find(A=>A.top<=e&&A.bottom>=e)||R4(this.heightMap.lineAt(this.scaler.fromDOM(e),Lo.ByHeight,this.heightOracle,0,0),this.scaler)}scrollAnchorAt(e){let A=this.lineBlockAtHeight(e+8);return A.from>=this.viewport.from||this.viewportLines[0].top-e>200?A:this.viewportLines[0]}elementAtHeight(e){return R4(this.heightMap.blockAt(this.scaler.fromDOM(e),this.heightOracle,0,0),this.scaler)}get docHeight(){return this.scaler.toDOM(this.heightMap.height)}get contentHeight(){return this.docHeight+this.paddingTop+this.paddingBottom}},QE=class{constructor(e,A){this.from=e,this.to=A}};function eLA(t,e,A){let i=[],n=t,o=0;return Zn.spans(A,t,e,{span(){},point(r,s){r>n&&(i.push({from:n,to:r}),o+=r-n),n=s}},20),n<e&&(i.push({from:n,to:e}),o+=e-n),{total:o,ranges:i}}function aw({total:t,ranges:e},A){if(A<=0)return e[0].from;if(A>=1)return e[e.length-1].to;let i=Math.floor(t*A);for(let n=0;;n++){let{from:o,to:r}=e[n],s=r-o;if(i<=s)return o+i;i-=s}}function cw(t,e){let A=0;for(let{from:i,to:n}of t.ranges){if(e<=n){A+=e-i;break}A+=n-i}return A/t.total}function tLA(t,e){for(let A of t)if(e(A))return A}var veA={toDOM(t){return t},fromDOM(t){return t},scale:1,eq(t){return t==this}},Sx=class t{constructor(e,A,i){let n=0,o=0,r=0;this.viewports=i.map(({from:s,to:a})=>{let c=A.lineAt(s,Lo.ByPos,e,0,0).top,l=A.lineAt(a,Lo.ByPos,e,0,0).bottom;return n+=l-c,{from:s,to:a,top:c,bottom:l,domTop:0,domBottom:0}}),this.scale=(7e6-n)/(A.height-n);for(let s of this.viewports)s.domTop=r+(s.top-o)*this.scale,r=s.domBottom=s.domTop+(s.bottom-s.top),o=s.bottom}toDOM(e){for(let A=0,i=0,n=0;;A++){let o=A<this.viewports.length?this.viewports[A]:null;if(!o||e<o.top)return n+(e-i)*this.scale;if(e<=o.bottom)return o.domTop+(e-o.top);i=o.bottom,n=o.domBottom}}fromDOM(e){for(let A=0,i=0,n=0;;A++){let o=A<this.viewports.length?this.viewports[A]:null;if(!o||e<o.domTop)return i+(e-n)/this.scale;if(e<=o.domBottom)return o.top+(e-o.domTop);i=o.bottom,n=o.domBottom}}eq(e){return e instanceof t?this.scale==e.scale&&this.viewports.length==e.viewports.length&&this.viewports.every((A,i)=>A.from==e.viewports[i].from&&A.to==e.viewports[i].to):!1}};function R4(t,e){if(e.scale==1)return t;let A=e.toDOM(t.top),i=e.toDOM(t.bottom);return new mg(t.from,t.length,A,i-A,Array.isArray(t._content)?t._content.map(n=>R4(n,e)):t._content)}var lw=Te.define({combine:t=>t.join(" ")}),ex=Te.define({combine:t=>t.indexOf(!0)>-1}),Rx=xc.newName(),RtA=xc.newName(),LtA=xc.newName(),xtA={"&light":"."+RtA,"&dark":"."+LtA};function Lx(t,e,A){return new xc(e,{finish(i){return/&/.test(i)?i.replace(/&\w*/,n=>{if(n=="&")return t;if(!A||!A[n])throw new RangeError(`Unsupported selector: ${n}`);return A[n]}):t+" "+i}})}var iLA=Lx("."+Rx,{"&":{position:"relative !important",boxSizing:"border-box","&.cm-focused":{outline:"1px dotted #212121"},display:"flex !important",flexDirection:"column"},".cm-scroller":{display:"flex !important",alignItems:"flex-start !important",fontFamily:"monospace",lineHeight:1.4,height:"100%",overflowX:"auto",position:"relative",zIndex:0,overflowAnchor:"none"},".cm-content":{margin:0,flexGrow:2,flexShrink:0,display:"block",whiteSpace:"pre",wordWrap:"normal",boxSizing:"border-box",minHeight:"100%",padding:"4px 0",outline:"none","&[contenteditable=true]":{WebkitUserModify:"read-write-plaintext-only"}},".cm-lineWrapping":{whiteSpace_fallback:"pre-wrap",whiteSpace:"break-spaces",wordBreak:"break-word",overflowWrap:"anywhere",flexShrink:1},"&light .cm-content":{caretColor:"black"},"&dark .cm-content":{caretColor:"white"},".cm-line":{display:"block",padding:"0 2px 0 6px"},".cm-layer":{position:"absolute",left:0,top:0,contain:"size style","& > *":{position:"absolute"}},"&light .cm-selectionBackground":{background:"#d9d9d9"},"&dark .cm-selectionBackground":{background:"#222"},"&light.cm-focused > .cm-scroller > .cm-selectionLayer .cm-selectionBackground":{background:"#d7d4f0"},"&dark.cm-focused > .cm-scroller > .cm-selectionLayer .cm-selectionBackground":{background:"#233"},".cm-cursorLayer":{pointerEvents:"none"},"&.cm-focused > .cm-scroller > .cm-cursorLayer":{animation:"steps(1) cm-blink 1.2s infinite"},"@keyframes cm-blink":{"0%":{},"50%":{opacity:0},"100%":{}},"@keyframes cm-blink2":{"0%":{},"50%":{opacity:0},"100%":{}},".cm-cursor, .cm-dropCursor":{borderLeft:"1.2px solid black",marginLeft:"-0.6px",pointerEvents:"none"},".cm-cursor":{display:"none"},"&dark .cm-cursor":{borderLeftColor:"#ddd"},".cm-dropCursor":{position:"absolute"},"&.cm-focused > .cm-scroller > .cm-cursorLayer .cm-cursor":{display:"block"},".cm-iso":{unicodeBidi:"isolate"},".cm-announced":{position:"fixed",top:"-10000px"},"@media print":{".cm-announced":{display:"none"}},"&light .cm-activeLine":{backgroundColor:"#cceeff44"},"&dark .cm-activeLine":{backgroundColor:"#99eeff33"},"&light .cm-specialChar":{color:"red"},"&dark .cm-specialChar":{color:"#f78"},".cm-gutters":{flexShrink:0,display:"flex",height:"100%",boxSizing:"border-box",insetInlineStart:0,zIndex:200},"&light .cm-gutters":{backgroundColor:"#f5f5f5",color:"#6c6c6c",borderRight:"1px solid #ddd"},"&dark .cm-gutters":{backgroundColor:"#333338",color:"#ccc"},".cm-gutter":{display:"flex !important",flexDirection:"column",flexShrink:0,boxSizing:"border-box",minHeight:"100%",overflow:"hidden"},".cm-gutterElement":{boxSizing:"border-box"},".cm-lineNumbers .cm-gutterElement":{padding:"0 3px 0 5px",minWidth:"20px",textAlign:"right",whiteSpace:"nowrap"},"&light .cm-activeLineGutter":{backgroundColor:"#e2f2ff"},"&dark .cm-activeLineGutter":{backgroundColor:"#222227"},".cm-panels":{boxSizing:"border-box",position:"sticky",left:0,right:0,zIndex:300},"&light .cm-panels":{backgroundColor:"#f5f5f5",color:"black"},"&light .cm-panels-top":{borderBottom:"1px solid #ddd"},"&light .cm-panels-bottom":{borderTop:"1px solid #ddd"},"&dark .cm-panels":{backgroundColor:"#333338",color:"white"},".cm-dialog":{padding:"2px 19px 4px 6px",position:"relative","& label":{fontSize:"80%"}},".cm-dialog-close":{position:"absolute",top:"3px",right:"4px",backgroundColor:"inherit",border:"none",font:"inherit",fontSize:"14px",padding:"0"},".cm-tab":{display:"inline-block",overflow:"hidden",verticalAlign:"bottom"},".cm-widgetBuffer":{verticalAlign:"text-top",height:"1em",width:0,display:"inline"},".cm-placeholder":{color:"#888",display:"inline-block",verticalAlign:"top",userSelect:"none"},".cm-highlightSpace":{backgroundImage:"radial-gradient(circle at 50% 55%, #aaa 20%, transparent 5%)",backgroundPosition:"center"},".cm-highlightTab":{backgroundImage:`url('data:image/svg+xml,<svg xmlns="http://www.w3.org/2000/svg" width="200" height="20"><path stroke="%23888" stroke-width="1" fill="none" d="M1 10H196L190 5M190 15L196 10M197 4L197 16"/></svg>')`,backgroundSize:"auto 100%",backgroundPosition:"right 90%",backgroundRepeat:"no-repeat"},".cm-trailingSpace":{backgroundColor:"#ff332255"},".cm-button":{verticalAlign:"middle",color:"inherit",fontSize:"70%",padding:".2em 1em",borderRadius:"1px"},"&light .cm-button":{backgroundImage:"linear-gradient(#eff1f5, #d9d9df)",border:"1px solid #888","&:active":{backgroundImage:"linear-gradient(#b4b4b4, #d0d3d6)"}},"&dark .cm-button":{backgroundImage:"linear-gradient(#393939, #111)",border:"1px solid #888","&:active":{backgroundImage:"linear-gradient(#111, #333)"}},".cm-textfield":{verticalAlign:"middle",color:"inherit",fontSize:"70%",border:"1px solid silver",padding:".2em .5em"},"&light .cm-textfield":{backgroundColor:"white"},"&dark .cm-textfield":{border:"1px solid #555",backgroundColor:"inherit"}},xtA),nLA={childList:!0,characterData:!0,subtree:!0,attributes:!0,characterDataOldValue:!0},tx=He.ie&&He.ie_version<=11,xx=class{constructor(e){this.view=e,this.active=!1,this.editContext=null,this.selectionRange=new sx,this.selectionChanged=!1,this.delayedFlush=-1,this.resizeTimeout=-1,this.queue=[],this.delayedAndroidKey=null,this.flushingAndroidKey=-1,this.lastChange=0,this.scrollTargets=[],this.intersection=null,this.resizeScroll=null,this.intersecting=!1,this.gapIntersection=null,this.gaps=[],this.printQuery=null,this.parentCheck=-1,this.dom=e.contentDOM,this.observer=new MutationObserver(A=>{for(let i of A)this.queue.push(i);(He.ie&&He.ie_version<=11||He.ios&&e.composing)&&A.some(i=>i.type=="childList"&&i.removedNodes.length||i.type=="characterData"&&i.oldValue.length>i.target.nodeValue.length)?this.flushSoon():this.flush()}),window.EditContext&&e.constructor.EDIT_CONTEXT!==!1&&!(He.chrome&&He.chrome_version<126)&&(this.editContext=new Fx(e),e.state.facet(K0)&&(e.contentDOM.editContext=this.editContext.editContext)),tx&&(this.onCharData=A=>{this.queue.push({target:A.target,type:"characterData",oldValue:A.prevValue}),this.flushSoon()}),this.onSelectionChange=this.onSelectionChange.bind(this),this.onResize=this.onResize.bind(this),this.onPrint=this.onPrint.bind(this),this.onScroll=this.onScroll.bind(this),window.matchMedia&&(this.printQuery=window.matchMedia("print")),typeof ResizeObserver=="function"&&(this.resizeScroll=new ResizeObserver(()=>{var A;((A=this.view.docView)===null||A===void 0?void 0:A.lastUpdate)<Date.now()-75&&this.onResize()}),this.resizeScroll.observe(e.scrollDOM)),this.addWindowListeners(this.win=e.win),this.start(),typeof IntersectionObserver=="function"&&(this.intersection=new IntersectionObserver(A=>{this.parentCheck<0&&(this.parentCheck=setTimeout(this.listenForScroll.bind(this),1e3)),A.length>0&&A[A.length-1].intersectionRatio>0!=this.intersecting&&(this.intersecting=!this.intersecting,this.intersecting!=this.view.inView&&this.onScrollChanged(document.createEvent("Event")))},{threshold:[0,.001]}),this.intersection.observe(this.dom),this.gapIntersection=new IntersectionObserver(A=>{A.length>0&&A[A.length-1].intersectionRatio>0&&this.onScrollChanged(document.createEvent("Event"))},{})),this.listenForScroll(),this.readSelectionRange()}onScrollChanged(e){this.view.inputState.runHandlers("scroll",e),this.intersecting&&this.view.measure()}onScroll(e){this.intersecting&&this.flush(!1),this.editContext&&this.view.requestMeasure(this.editContext.measureReq),this.onScrollChanged(e)}onResize(){this.resizeTimeout<0&&(this.resizeTimeout=setTimeout(()=>{this.resizeTimeout=-1,this.view.requestMeasure()},50))}onPrint(e){(e.type=="change"||!e.type)&&!e.matches||(this.view.viewState.printing=!0,this.view.measure(),setTimeout(()=>{this.view.viewState.printing=!1,this.view.requestMeasure()},500))}updateGaps(e){if(this.gapIntersection&&(e.length!=this.gaps.length||this.gaps.some((A,i)=>A!=e[i]))){this.gapIntersection.disconnect();for(let A of e)this.gapIntersection.observe(A);this.gaps=e}}onSelectionChange(e){let A=this.selectionChanged;if(!this.readSelectionRange()||this.delayedAndroidKey)return;let{view:i}=this,n=this.selectionRange;if(i.state.facet(K0)?i.root.activeElement!=this.dom:!Cw(this.dom,n))return;let o=n.anchorNode&&i.docView.nearest(n.anchorNode);if(o&&o.ignoreEvent(e)){A||(this.selectionChanged=!1);return}(He.ie&&He.ie_version<=11||He.android&&He.chrome)&&!i.state.selection.main.empty&&n.focusNode&&x4(n.focusNode,n.focusOffset,n.anchorNode,n.anchorOffset)?this.flushSoon():this.flush(!1)}readSelectionRange(){let{view:e}=this,A=Y4(e.root);if(!A)return!1;let i=He.safari&&e.root.nodeType==11&&e.root.activeElement==this.dom&&oLA(this.view,A)||A;if(!i||this.selectionRange.eq(i))return!1;let n=Cw(this.dom,i);return n&&!this.selectionChanged&&e.inputState.lastFocusTime>Date.now()-200&&e.inputState.lastTouchTime<Date.now()-300&&XSA(this.dom,i)?(this.view.inputState.lastFocusTime=0,e.docView.updateSelection(),!1):(this.selectionRange.setRange(i),n&&(this.selectionChanged=!0),!0)}setSelectionRange(e,A){this.selectionRange.set(e.node,e.offset,A.node,A.offset),this.selectionChanged=!1}clearSelectionRange(){this.selectionRange.set(null,0,null,0)}listenForScroll(){this.parentCheck=-1;let e=0,A=null;for(let i=this.dom;i;)if(i.nodeType==1)!A&&e<this.scrollTargets.length&&this.scrollTargets[e]==i?e++:A||(A=this.scrollTargets.slice(0,e)),A&&A.push(i),i=i.assignedSlot||i.parentNode;else if(i.nodeType==11)i=i.host;else break;if(e<this.scrollTargets.length&&!A&&(A=this.scrollTargets.slice(0,e)),A){for(let i of this.scrollTargets)i.removeEventListener("scroll",this.onScroll);for(let i of this.scrollTargets=A)i.addEventListener("scroll",this.onScroll)}}ignore(e){if(!this.active)return e();try{return this.stop(),e()}finally{this.start(),this.clear()}}start(){this.active||(this.observer.observe(this.dom,nLA),tx&&this.dom.addEventListener("DOMCharacterDataModified",this.onCharData),this.active=!0)}stop(){this.active&&(this.active=!1,this.observer.disconnect(),tx&&this.dom.removeEventListener("DOMCharacterDataModified",this.onCharData))}clear(){this.processRecords(),this.queue.length=0,this.selectionChanged=!1}delayAndroidKey(e,A){var i;if(!this.delayedAndroidKey){let n=()=>{let o=this.delayedAndroidKey;o&&(this.clearDelayedAndroidKey(),this.view.inputState.lastKeyCode=o.keyCode,this.view.inputState.lastKeyTime=Date.now(),!this.flush()&&o.force&&mE(this.dom,o.key,o.keyCode))};this.flushingAndroidKey=this.view.win.requestAnimationFrame(n)}(!this.delayedAndroidKey||e=="Enter")&&(this.delayedAndroidKey={key:e,keyCode:A,force:this.lastChange<Date.now()-50||!!(!((i=this.delayedAndroidKey)===null||i===void 0)&&i.force)})}clearDelayedAndroidKey(){this.win.cancelAnimationFrame(this.flushingAndroidKey),this.delayedAndroidKey=null,this.flushingAndroidKey=-1}flushSoon(){this.delayedFlush<0&&(this.delayedFlush=this.view.win.requestAnimationFrame(()=>{this.delayedFlush=-1,this.flush()}))}forceFlush(){this.delayedFlush>=0&&(this.view.win.cancelAnimationFrame(this.delayedFlush),this.delayedFlush=-1),this.flush()}pendingRecords(){for(let e of this.observer.takeRecords())this.queue.push(e);return this.queue}processRecords(){let e=this.pendingRecords();e.length&&(this.queue=[]);let A=-1,i=-1,n=!1;for(let o of e){let r=this.readMutation(o);r&&(r.typeOver&&(n=!0),A==-1?{from:A,to:i}=r:(A=Math.min(r.from,A),i=Math.max(r.to,i)))}return{from:A,to:i,typeOver:n}}readChange(){let{from:e,to:A,typeOver:i}=this.processRecords(),n=this.selectionChanged&&Cw(this.dom,this.selectionRange);if(e<0&&!n)return null;e>-1&&(this.lastChange=Date.now()),this.view.inputState.lastFocusTime=0,this.selectionChanged=!1;let o=new fx(this.view,e,A,i);return this.view.docView.domChanged={newSel:o.newSel?o.newSel.main:null},o}flush(e=!0){if(this.delayedFlush>=0||this.delayedAndroidKey)return!1;e&&this.readSelectionRange();let A=this.readChange();if(!A)return this.view.requestMeasure(),!1;let i=this.view.state,n=ptA(this.view,A);return this.view.state==i&&(A.domChanged||A.newSel&&!A.newSel.main.eq(this.view.state.selection.main))&&this.view.update([]),n}readMutation(e){let A=this.view.docView.nearest(e.target);if(!A||A.ignoreMutation(e))return null;if(A.markDirty(e.type=="attributes"),e.type=="attributes"&&(A.flags|=4),e.type=="childList"){let i=beA(A,e.previousSibling||e.target.previousSibling,-1),n=beA(A,e.nextSibling||e.target.nextSibling,1);return{from:i?A.posAfter(i):A.posAtStart,to:n?A.posBefore(n):A.posAtEnd,typeOver:!1}}else return e.type=="characterData"?{from:A.posAtStart,to:A.posAtEnd,typeOver:e.target.nodeValue==e.oldValue}:null}setWindow(e){e!=this.win&&(this.removeWindowListeners(this.win),this.win=e,this.addWindowListeners(this.win))}addWindowListeners(e){e.addEventListener("resize",this.onResize),this.printQuery?this.printQuery.addEventListener?this.printQuery.addEventListener("change",this.onPrint):this.printQuery.addListener(this.onPrint):e.addEventListener("beforeprint",this.onPrint),e.addEventListener("scroll",this.onScroll),e.document.addEventListener("selectionchange",this.onSelectionChange)}removeWindowListeners(e){e.removeEventListener("scroll",this.onScroll),e.removeEventListener("resize",this.onResize),this.printQuery?this.printQuery.removeEventListener?this.printQuery.removeEventListener("change",this.onPrint):this.printQuery.removeListener(this.onPrint):e.removeEventListener("beforeprint",this.onPrint),e.document.removeEventListener("selectionchange",this.onSelectionChange)}update(e){this.editContext&&(this.editContext.update(e),e.startState.facet(K0)!=e.state.facet(K0)&&(e.view.contentDOM.editContext=e.state.facet(K0)?this.editContext.editContext:null))}destroy(){var e,A,i;this.stop(),(e=this.intersection)===null||e===void 0||e.disconnect(),(A=this.gapIntersection)===null||A===void 0||A.disconnect(),(i=this.resizeScroll)===null||i===void 0||i.disconnect();for(let n of this.scrollTargets)n.removeEventListener("scroll",this.onScroll);this.removeWindowListeners(this.win),clearTimeout(this.parentCheck),clearTimeout(this.resizeTimeout),this.win.cancelAnimationFrame(this.delayedFlush),this.win.cancelAnimationFrame(this.flushingAndroidKey),this.editContext&&(this.view.contentDOM.editContext=null,this.editContext.destroy())}};function beA(t,e,A){for(;e;){let i=mo.get(e);if(i&&i.parent==t)return i;let n=e.parentNode;e=n!=t.dom?n:A>0?e.nextSibling:e.previousSibling}return null}function MeA(t,e){let A=e.startContainer,i=e.startOffset,n=e.endContainer,o=e.endOffset,r=t.docView.domAtPos(t.state.selection.main.anchor);return x4(r.node,r.offset,n,o)&&([A,i,n,o]=[n,o,A,i]),{anchorNode:A,anchorOffset:i,focusNode:n,focusOffset:o}}function oLA(t,e){if(e.getComposedRanges){let n=e.getComposedRanges(t.root)[0];if(n)return MeA(t,n)}let A=null;function i(n){n.preventDefault(),n.stopImmediatePropagation(),A=n.getTargetRanges()[0]}return t.contentDOM.addEventListener("beforeinput",i,!0),t.dom.ownerDocument.execCommand("indent"),t.contentDOM.removeEventListener("beforeinput",i,!0),A?MeA(t,A):null}var Fx=class{constructor(e){this.from=0,this.to=0,this.pendingContextChange=null,this.handlers=Object.create(null),this.composing=null,this.resetRange(e.state);let A=this.editContext=new window.EditContext({text:e.state.doc.sliceString(this.from,this.to),selectionStart:this.toContextPos(Math.max(this.from,Math.min(this.to,e.state.selection.main.anchor))),selectionEnd:this.toContextPos(e.state.selection.main.head)});this.handlers.textupdate=i=>{let n=e.state.selection.main,{anchor:o,head:r}=n,s=this.toEditorPos(i.updateRangeStart),a=this.toEditorPos(i.updateRangeEnd);e.inputState.composing>=0&&!this.composing&&(this.composing={contextBase:i.updateRangeStart,editorBase:s,drifted:!1});let c={from:s,to:a,insert:qi.of(i.text.split(`
`))};if(c.from==this.from&&o<this.from?c.from=o:c.to==this.to&&o>this.to&&(c.to=o),c.from==c.to&&!c.insert.length){let l=ie.single(this.toEditorPos(i.selectionStart),this.toEditorPos(i.selectionEnd));l.main.eq(n)||e.dispatch({selection:l,userEvent:"select"});return}if((He.mac||He.android)&&c.from==r-1&&/^\. ?$/.test(i.text)&&e.contentDOM.getAttribute("autocorrect")=="off"&&(c={from:s,to:a,insert:qi.of([i.text.replace("."," ")])}),this.pendingContextChange=c,!e.state.readOnly){let l=this.to-this.from+(c.to-c.from+c.insert.length);Xx(e,c,ie.single(this.toEditorPos(i.selectionStart,l),this.toEditorPos(i.selectionEnd,l)))}this.pendingContextChange&&(this.revertPending(e.state),this.setSelection(e.state))},this.handlers.characterboundsupdate=i=>{let n=[],o=null;for(let r=this.toEditorPos(i.rangeStart),s=this.toEditorPos(i.rangeEnd);r<s;r++){let a=e.coordsForChar(r);o=a&&new DOMRect(a.left,a.top,a.right-a.left,a.bottom-a.top)||o||new DOMRect,n.push(o)}A.updateCharacterBounds(i.rangeStart,n)},this.handlers.textformatupdate=i=>{let n=[];for(let o of i.getTextFormats()){let r=o.underlineStyle,s=o.underlineThickness;if(r!="None"&&s!="None"){let a=this.toEditorPos(o.rangeStart),c=this.toEditorPos(o.rangeEnd);if(a<c){let l=`text-decoration: underline ${r=="Dashed"?"dashed ":r=="Squiggle"?"wavy ":""}${s=="Thin"?1:2}px`;n.push(rt.mark({attributes:{style:l}}).range(a,c))}}}e.dispatch({effects:EtA.of(rt.set(n))})},this.handlers.compositionstart=()=>{e.inputState.composing<0&&(e.inputState.composing=0,e.inputState.compositionFirstChange=!0)},this.handlers.compositionend=()=>{if(e.inputState.composing=-1,e.inputState.compositionFirstChange=null,this.composing){let{drifted:i}=this.composing;this.composing=null,i&&this.reset(e.state)}};for(let i in this.handlers)A.addEventListener(i,this.handlers[i]);this.measureReq={read:i=>{this.editContext.updateControlBounds(i.contentDOM.getBoundingClientRect());let n=Y4(i.root);n&&n.rangeCount&&this.editContext.updateSelectionBounds(n.getRangeAt(0).getBoundingClientRect())}}}applyEdits(e){let A=0,i=!1,n=this.pendingContextChange;return e.changes.iterChanges((o,r,s,a,c)=>{if(i)return;let l=c.length-(r-o);if(n&&r>=n.to)if(n.from==o&&n.to==r&&n.insert.eq(c)){n=this.pendingContextChange=null,A+=l,this.to+=l;return}else n=null,this.revertPending(e.state);if(o+=A,r+=A,r<=this.from)this.from+=l,this.to+=l;else if(o<this.to){if(o<this.from||r>this.to||this.to-this.from+c.length>3e4){i=!0;return}this.editContext.updateText(this.toContextPos(o),this.toContextPos(r),c.toString()),this.to+=l}A+=l}),n&&!i&&this.revertPending(e.state),!i}update(e){let A=this.pendingContextChange,i=e.startState.selection.main;this.composing&&(this.composing.drifted||!e.changes.touchesRange(i.from,i.to)&&e.transactions.some(n=>!n.isUserEvent("input.type")&&n.changes.touchesRange(this.from,this.to)))?(this.composing.drifted=!0,this.composing.editorBase=e.changes.mapPos(this.composing.editorBase)):!this.applyEdits(e)||!this.rangeIsValid(e.state)?(this.pendingContextChange=null,this.reset(e.state)):(e.docChanged||e.selectionSet||A)&&this.setSelection(e.state),(e.geometryChanged||e.docChanged||e.selectionSet)&&e.view.requestMeasure(this.measureReq)}resetRange(e){let{head:A}=e.selection.main;this.from=Math.max(0,A-1e4),this.to=Math.min(e.doc.length,A+1e4)}reset(e){this.resetRange(e),this.editContext.updateText(0,this.editContext.text.length,e.doc.sliceString(this.from,this.to)),this.setSelection(e)}revertPending(e){let A=this.pendingContextChange;this.pendingContextChange=null,this.editContext.updateText(this.toContextPos(A.from),this.toContextPos(A.from+A.insert.length),e.doc.sliceString(A.from,A.to))}setSelection(e){let{main:A}=e.selection,i=this.toContextPos(Math.max(this.from,Math.min(this.to,A.anchor))),n=this.toContextPos(A.head);(this.editContext.selectionStart!=i||this.editContext.selectionEnd!=n)&&this.editContext.updateSelection(i,n)}rangeIsValid(e){let{head:A}=e.selection.main;return!(this.from>0&&A-this.from<500||this.to<e.doc.length&&this.to-A<500||this.to-this.from>1e4*3)}toEditorPos(e,A=this.to-this.from){e=Math.min(e,A);let i=this.composing;return i&&i.drifted?i.editorBase+(e-i.contextBase):e+this.from}toContextPos(e){let A=this.composing;return A&&A.drifted?A.contextBase+(e-A.editorBase):e-this.from}destroy(){for(let e in this.handlers)this.editContext.removeEventListener(e,this.handlers[e])}},St=(()=>{class t{get state(){return this.viewState.state}get viewport(){return this.viewState.viewport}get visibleRanges(){return this.viewState.visibleRanges}get inView(){return this.viewState.inView}get composing(){return!!this.inputState&&this.inputState.composing>0}get compositionStarted(){return!!this.inputState&&this.inputState.composing>=0}get root(){return this._root}get win(){return this.dom.ownerDocument.defaultView||window}constructor(A={}){var i;this.plugins=[],this.pluginMap=new Map,this.editorAttrs={},this.contentAttrs={},this.bidiCache=[],this.destroyed=!1,this.updateState=2,this.measureScheduled=-1,this.measureRequests=[],this.contentDOM=document.createElement("div"),this.scrollDOM=document.createElement("div"),this.scrollDOM.tabIndex=-1,this.scrollDOM.className="cm-scroller",this.scrollDOM.appendChild(this.contentDOM),this.announceDOM=document.createElement("div"),this.announceDOM.className="cm-announced",this.announceDOM.setAttribute("aria-live","polite"),this.dom=document.createElement("div"),this.dom.appendChild(this.announceDOM),this.dom.appendChild(this.scrollDOM),A.parent&&A.parent.appendChild(this.dom);let{dispatch:n}=A;this.dispatchTransactions=A.dispatchTransactions||n&&(o=>o.forEach(r=>n(r,this)))||(o=>this.update(o)),this.dispatch=this.dispatch.bind(this),this._root=A.root||WSA(A.parent)||document,this.viewState=new Mw(A.state||Ir.create(A)),A.scrollTo&&A.scrollTo.is(ow)&&(this.viewState.scrollTarget=A.scrollTo.value.clip(this.viewState.state)),this.plugins=this.state.facet(hE).map(o=>new _4(o));for(let o of this.plugins)o.update(this);this.observer=new xx(this),this.inputState=new mx(this),this.inputState.ensureHandlers(this.plugins),this.docView=new Dw(this),this.mountStyles(),this.updateAttrs(),this.updateState=0,this.requestMeasure(),!((i=document.fonts)===null||i===void 0)&&i.ready&&document.fonts.ready.then(()=>this.requestMeasure())}dispatch(...A){let i=A.length==1&&A[0]instanceof Qg?A:A.length==1&&Array.isArray(A[0])?A[0]:[this.state.update(...A)];this.dispatchTransactions(i,this)}update(A){if(this.updateState!=0)throw new Error("Calls to EditorView.update are not allowed while an update is in progress");let i=!1,n=!1,o,r=this.state;for(let d of A){if(d.startState!=r)throw new RangeError("Trying to update state with a transaction that doesn't start from the previous state.");r=d.state}if(this.destroyed){this.viewState.state=r;return}let s=this.hasFocus,a=0,c=null;A.some(d=>d.annotation(MtA))?(this.inputState.notifiedFocused=s,a=1):s!=this.inputState.notifiedFocused&&(this.inputState.notifiedFocused=s,c=ktA(r,s),c||(a=1));let l=this.observer.delayedAndroidKey,I=null;if(l?(this.observer.clearDelayedAndroidKey(),I=this.observer.readChange(),(I&&!this.state.doc.eq(r.doc)||!this.state.selection.eq(r.selection))&&(I=null)):this.observer.clear(),r.facet(Ir.phrases)!=this.state.facet(Ir.phrases))return this.setState(r);o=ww.create(this,r,A),o.flags|=a;let C=this.viewState.scrollTarget;try{this.updateState=2;for(let d of A){if(C&&(C=C.map(d.changes)),d.scrollIntoView){let{main:B}=d.state.selection;C=new N4(B.empty?B:ie.cursor(B.head,B.head>B.anchor?-1:1))}for(let B of d.effects)B.is(ow)&&(C=B.value.clip(this.state))}this.viewState.update(o,C),this.bidiCache=kw.update(this.bidiCache,o.changes),o.empty||(this.updatePlugins(o),this.inputState.update(o)),i=this.docView.update(o),this.state.facet(M4)!=this.styleModules&&this.mountStyles(),n=this.updateAttrs(),this.showAnnouncements(A),this.docView.updateSelection(i,A.some(d=>d.isUserEvent("select.pointer")))}finally{this.updateState=0}if(o.startState.facet(lw)!=o.state.facet(lw)&&(this.viewState.mustMeasureContent=!0),(i||n||C||this.viewState.mustEnforceCursorAssoc||this.viewState.mustMeasureContent)&&this.requestMeasure(),i&&this.docViewUpdate(),!o.empty)for(let d of this.state.facet(XL))try{d(o)}catch(B){Hr(this.state,B,"update listener")}(c||I)&&Promise.resolve().then(()=>{c&&this.state==c.startState&&this.dispatch(c),I&&!ptA(this,I)&&l.force&&mE(this.contentDOM,l.key,l.keyCode)})}setState(A){if(this.updateState!=0)throw new Error("Calls to EditorView.setState are not allowed while an update is in progress");if(this.destroyed){this.viewState.state=A;return}this.updateState=2;let i=this.hasFocus;try{for(let n of this.plugins)n.destroy(this);this.viewState=new Mw(A),this.plugins=A.facet(hE).map(n=>new _4(n)),this.pluginMap.clear();for(let n of this.plugins)n.update(this);this.docView.destroy(),this.docView=new Dw(this),this.inputState.ensureHandlers(this.plugins),this.mountStyles(),this.updateAttrs(),this.bidiCache=[]}finally{this.updateState=0}i&&this.focus(),this.requestMeasure()}updatePlugins(A){let i=A.startState.facet(hE),n=A.state.facet(hE);if(i!=n){let o=[];for(let r of n){let s=i.indexOf(r);if(s<0)o.push(new _4(r));else{let a=this.plugins[s];a.mustUpdate=A,o.push(a)}}for(let r of this.plugins)r.mustUpdate!=A&&r.destroy(this);this.plugins=o,this.pluginMap.clear()}else for(let o of this.plugins)o.mustUpdate=A;for(let o=0;o<this.plugins.length;o++)this.plugins[o].update(this);i!=n&&this.inputState.ensureHandlers(this.plugins)}docViewUpdate(){for(let A of this.plugins){let i=A.value;if(i&&i.docViewUpdate)try{i.docViewUpdate(this)}catch(n){Hr(this.state,n,"doc view update listener")}}}measure(A=!0){if(this.destroyed)return;if(this.measureScheduled>-1&&this.win.cancelAnimationFrame(this.measureScheduled),this.observer.delayedAndroidKey){this.measureScheduled=-1,this.requestMeasure();return}this.measureScheduled=0,A&&this.observer.forceFlush();let i=null,n=this.scrollDOM,o=n.scrollTop*this.scaleY,{scrollAnchorPos:r,scrollAnchorHeight:s}=this.viewState;Math.abs(o-this.viewState.scrollTop)>1&&(s=-1),this.viewState.scrollAnchorHeight=-1;try{for(let a=0;;a++){if(s<0)if(PeA(n))r=-1,s=this.viewState.heightMap.height;else{let B=this.viewState.scrollAnchorAt(o);r=B.from,s=B.top}this.updateState=1;let c=this.viewState.measure(this);if(!c&&!this.measureRequests.length&&this.viewState.scrollTarget==null)break;if(a>5){console.warn(this.measureRequests.length?"Measure loop restarted more than 5 times":"Viewport failed to stabilize");break}let l=[];c&4||([this.measureRequests,l]=[l,this.measureRequests]);let I=l.map(B=>{try{return B.read(this)}catch(E){return Hr(this.state,E),keA}}),C=ww.create(this,this.state,[]),d=!1;C.flags|=c,i?i.flags|=c:i=C,this.updateState=2,C.empty||(this.updatePlugins(C),this.inputState.update(C),this.updateAttrs(),d=this.docView.update(C),d&&this.docViewUpdate());for(let B=0;B<l.length;B++)if(I[B]!=keA)try{let E=l[B];E.write&&E.write(I[B],this)}catch(E){Hr(this.state,E)}if(d&&this.docView.updateSelection(!0),!C.viewportChanged&&this.measureRequests.length==0){if(this.viewState.editorHeight)if(this.viewState.scrollTarget){this.docView.scrollIntoView(this.viewState.scrollTarget),this.viewState.scrollTarget=null,s=-1;continue}else{let E=(r<0?this.viewState.heightMap.height:this.viewState.lineBlockAt(r).top)-s;if(E>1||E<-1){o=o+E,n.scrollTop=o/this.scaleY,s=-1;continue}}break}}}finally{this.updateState=0,this.measureScheduled=-1}if(i&&!i.empty)for(let a of this.state.facet(XL))a(i)}get themeClasses(){return Rx+" "+(this.state.facet(ex)?LtA:RtA)+" "+this.state.facet(lw)}updateAttrs(){let A=SeA(this,seA,{class:"cm-editor"+(this.hasFocus?" cm-focused ":" ")+this.themeClasses}),i={spellcheck:"false",autocorrect:"off",autocapitalize:"off",writingsuggestions:"false",translate:"no",contenteditable:this.state.facet(K0)?"true":"false",class:"cm-content",style:`${He.tabSize}: ${this.state.tabSize}`,role:"textbox","aria-multiline":"true"};this.state.readOnly&&(i["aria-readonly"]="true"),SeA(this,Ex,i);let n=this.observer.ignore(()=>{let o=Ix(this.contentDOM,this.contentAttrs,i),r=Ix(this.dom,this.editorAttrs,A);return o||r});return this.editorAttrs=A,this.contentAttrs=i,n}showAnnouncements(A){let i=!0;for(let n of A)for(let o of n.effects)if(o.is(t.announce)){i&&(this.announceDOM.textContent=""),i=!1;let r=this.announceDOM.appendChild(document.createElement("div"));r.textContent=o.value}}mountStyles(){this.styleModules=this.state.facet(M4);let A=this.state.facet(t.cspNonce);xc.mount(this.root,this.styleModules.concat(iLA).reverse(),A?{nonce:A}:void 0)}readMeasured(){if(this.updateState==2)throw new Error("Reading the editor layout isn't allowed during an update");this.updateState==0&&this.measureScheduled>-1&&this.measure(!1)}requestMeasure(A){if(this.measureScheduled<0&&(this.measureScheduled=this.win.requestAnimationFrame(()=>this.measure())),A){if(this.measureRequests.indexOf(A)>-1)return;if(A.key!=null){for(let i=0;i<this.measureRequests.length;i++)if(this.measureRequests[i].key===A.key){this.measureRequests[i]=A;return}}this.measureRequests.push(A)}}plugin(A){let i=this.pluginMap.get(A);return(i===void 0||i&&i.plugin!=A)&&this.pluginMap.set(A,i=this.plugins.find(n=>n.plugin==A)||null),i&&i.update(this).value}get documentTop(){return this.contentDOM.getBoundingClientRect().top+this.viewState.paddingTop}get documentPadding(){return{top:this.viewState.paddingTop,bottom:this.viewState.paddingBottom}}get scaleX(){return this.viewState.scaleX}get scaleY(){return this.viewState.scaleY}elementAtHeight(A){return this.readMeasured(),this.viewState.elementAtHeight(A)}lineBlockAtHeight(A){return this.readMeasured(),this.viewState.lineBlockAtHeight(A)}get viewportLineBlocks(){return this.viewState.viewportLines}lineBlockAt(A){return this.viewState.lineBlockAt(A)}get contentHeight(){return this.viewState.contentHeight}moveByChar(A,i,n){return Ax(this,A,CeA(this,A,i,n))}moveByGroup(A,i){return Ax(this,A,CeA(this,A,i,n=>MRA(this,A.head,n)))}visualLineSide(A,i){let n=this.bidiSpans(A),o=this.textDirectionAt(A.from),r=n[i?n.length-1:0];return ie.cursor(r.side(i,o)+A.from,r.forward(!i,o)?1:-1)}moveToLineBoundary(A,i,n=!0){return bRA(this,A,i,n)}moveVertically(A,i,n){return Ax(this,A,kRA(this,A,i,n))}domAtPos(A){return this.docView.domAtPos(A)}posAtDOM(A,i=0){return this.docView.posFromDOM(A,i)}posAtCoords(A,i=!0){return this.readMeasured(),mtA(this,A,i)}coordsAtPos(A,i=1){this.readMeasured();let n=this.docView.coordsAt(A,i);if(!n||n.left==n.right)return n;let o=this.state.doc.lineAt(A),r=this.bidiSpans(o),s=r[pg.find(r,A-o.from,-1,i)];return Nw(n,s.dir==Wn.LTR==i>0)}coordsForChar(A){return this.readMeasured(),this.docView.coordsForChar(A)}get defaultCharacterWidth(){return this.viewState.heightOracle.charWidth}get defaultLineHeight(){return this.viewState.heightOracle.lineHeight}get textDirection(){return this.viewState.defaultTextDirection}textDirectionAt(A){return!this.state.facet(reA)||A<this.viewport.from||A>this.viewport.to?this.textDirection:(this.readMeasured(),this.docView.textDirectionAt(A))}get lineWrapping(){return this.viewState.heightOracle.lineWrapping}bidiSpans(A){if(A.length>rLA)return rtA(A.length);let i=this.textDirectionAt(A.from),n;for(let r of this.bidiCache)if(r.from==A.from&&r.dir==i&&(r.fresh||otA(r.isolates,n=aeA(this,A))))return r.order;n||(n=aeA(this,A));let o=gRA(A.text,i,n);return this.bidiCache.push(new kw(A.from,A.to,i,n,!0,o)),o}get hasFocus(){var A;return(this.dom.ownerDocument.hasFocus()||He.safari&&((A=this.inputState)===null||A===void 0?void 0:A.lastContextMenu)>Date.now()-3e4)&&this.root.activeElement==this.contentDOM}focus(){this.observer.ignore(()=>{HeA(this.contentDOM),this.docView.updateSelection()})}setRoot(A){this._root!=A&&(this._root=A,this.observer.setWindow((A.nodeType==9?A:A.ownerDocument).defaultView||window),this.mountStyles())}destroy(){this.root.activeElement==this.contentDOM&&this.contentDOM.blur();for(let A of this.plugins)A.destroy(this);this.plugins=[],this.inputState.destroy(),this.docView.destroy(),this.dom.remove(),this.observer.destroy(),this.measureScheduled>-1&&this.win.cancelAnimationFrame(this.measureScheduled),this.destroyed=!0}static scrollIntoView(A,i={}){return ow.of(new N4(typeof A=="number"?ie.cursor(A):A,i.y,i.x,i.yMargin,i.xMargin))}scrollSnapshot(){let{scrollTop:A,scrollLeft:i}=this.scrollDOM,n=this.viewState.scrollAnchorAt(A);return ow.of(new N4(ie.cursor(n.from),"start","start",n.top-A,i,!0))}setTabFocusMode(A){A==null?this.inputState.tabFocusMode=this.inputState.tabFocusMode<0?0:-1:typeof A=="boolean"?this.inputState.tabFocusMode=A?0:-1:this.inputState.tabFocusMode!=0&&(this.inputState.tabFocusMode=Date.now()+A)}static domEventHandlers(A){return Xn.define(()=>({}),{eventHandlers:A})}static domEventObservers(A){return Xn.define(()=>({}),{eventObservers:A})}static theme(A,i){let n=xc.newName(),o=[lw.of(n),M4.of(Lx(`.${n}`,A))];return i&&i.dark&&o.push(ex.of(!0)),o}static baseTheme(A){return Bl.lowest(M4.of(Lx("."+Rx,A,xtA)))}static findFromDOM(A){var i;let n=A.querySelector(".cm-content"),o=n&&mo.get(n)||mo.get(A);return((i=o?.rootView)===null||i===void 0?void 0:i.view)||null}}return t.styleModule=M4,t.inputHandler=ItA,t.clipboardInputFilter=qx,t.clipboardOutputFilter=Vx,t.scrollHandler=BtA,t.focusChangeEffect=CtA,t.perLineTextDirection=reA,t.exceptionSink=gtA,t.updateListener=XL,t.editable=K0,t.mouseSelectionStyle=ltA,t.dragMovesSelection=ctA,t.clickAddsSelectionRange=atA,t.decorations=j4,t.outerDecorations=htA,t.atomicRanges=Zx,t.bidiIsolatedRanges=QtA,t.scrollMargins=utA,t.darkTheme=ex,t.cspNonce=Te.define({combine:e=>e.length?e[0]:""}),t.contentAttributes=Ex,t.editorAttributes=seA,t.lineWrapping=t.contentAttributes.of({class:"cm-lineWrapping"}),t.announce=ki.define(),t})(),rLA=4096,keA={},kw=class t{constructor(e,A,i,n,o,r){this.from=e,this.to=A,this.dir=i,this.isolates=n,this.fresh=o,this.order=r}static update(e,A){if(A.empty&&!e.some(o=>o.fresh))return e;let i=[],n=e.length?e[e.length-1].dir:Wn.LTR;for(let o=Math.max(0,e.length-10);o<e.length;o++){let r=e[o];r.dir==n&&!A.touchesRange(r.from,r.to)&&i.push(new t(A.mapPos(r.from,1),A.mapPos(r.to,-1),r.dir,r.isolates,!1,r.order))}return i}};function SeA(t,e,A){for(let i=t.state.facet(e),n=i.length-1;n>=0;n--){let o=i[n],r=typeof o=="function"?o(t):o;r&&gx(r,A)}return A}var sLA=He.mac?"mac":He.windows?"win":He.linux?"linux":"key";function aLA(t,e){let A=t.split(/-(?!$)/),i=A[A.length-1];i=="Space"&&(i=" ");let n,o,r,s;for(let a=0;a<A.length-1;++a){let c=A[a];if(/^(cmd|meta|m)$/i.test(c))s=!0;else if(/^a(lt)?$/i.test(c))n=!0;else if(/^(c|ctrl|control)$/i.test(c))o=!0;else if(/^s(hift)?$/i.test(c))r=!0;else if(/^mod$/i.test(c))e=="mac"?s=!0:o=!0;else throw new Error("Unrecognized modifier name: "+c)}return n&&(i="Alt-"+i),o&&(i="Ctrl-"+i),s&&(i="Meta-"+i),r&&(i="Shift-"+i),i}function gw(t,e,A){return e.altKey&&(t="Alt-"+t),e.ctrlKey&&(t="Ctrl-"+t),e.metaKey&&(t="Meta-"+t),A!==!1&&e.shiftKey&&(t="Shift-"+t),t}var cLA=Bl.default(St.domEventHandlers({keydown(t,e){return _tA(FtA(e.state),t,e,"editor")}})),wE=Te.define({enables:cLA}),ReA=new WeakMap;function FtA(t){let e=t.facet(wE),A=ReA.get(e);return A||ReA.set(e,A=gLA(e.reduce((i,n)=>i.concat(n),[]))),A}function NtA(t,e,A){return _tA(FtA(t.state),e,t,A)}var h1=null,lLA=4e3;function gLA(t,e=sLA){let A=Object.create(null),i=Object.create(null),n=(r,s)=>{let a=i[r];if(a==null)i[r]=s;else if(a!=s)throw new Error("Key binding "+r+" is used both as a regular binding and as a multi-stroke prefix")},o=(r,s,a,c,l)=>{var I,C;let d=A[r]||(A[r]=Object.create(null)),B=s.split(/ (?!$)/).map(u=>aLA(u,e));for(let u=1;u<B.length;u++){let v=B.slice(0,u).join(" ");n(v,!0),d[v]||(d[v]={preventDefault:!0,stopPropagation:!1,run:[L=>{let x=h1={view:L,prefix:v,scope:r};return setTimeout(()=>{h1==x&&(h1=null)},lLA),!0}]})}let E=B.join(" ");n(E,!1);let Q=d[E]||(d[E]={preventDefault:!1,stopPropagation:!1,run:((C=(I=d._any)===null||I===void 0?void 0:I.run)===null||C===void 0?void 0:C.slice())||[]});a&&Q.run.push(a),c&&(Q.preventDefault=!0),l&&(Q.stopPropagation=!0)};for(let r of t){let s=r.scope?r.scope.split(" "):["editor"];if(r.any)for(let c of s){let l=A[c]||(A[c]=Object.create(null));l._any||(l._any={preventDefault:!1,stopPropagation:!1,run:[]});let{any:I}=r;for(let C in l)l[C].run.push(d=>I(d,Nx))}let a=r[e]||r.key;if(a)for(let c of s)o(c,a,r.run,r.preventDefault,r.stopPropagation),r.shift&&o(c,"Shift-"+a,r.shift,r.preventDefault,r.stopPropagation)}return A}var Nx=null;function _tA(t,e,A,i){Nx=e;let n=ZAA(e),o=rs(n,0),r=tc(o)==n.length&&n!=" ",s="",a=!1,c=!1,l=!1;h1&&h1.view==A&&h1.scope==i&&(s=h1.prefix+" ",DtA.indexOf(e.keyCode)<0&&(c=!0,h1=null));let I=new Set,C=Q=>{if(Q){for(let u of Q.run)if(!I.has(u)&&(I.add(u),u(A)))return Q.stopPropagation&&(l=!0),!0;Q.preventDefault&&(Q.stopPropagation&&(l=!0),c=!0)}return!1},d=t[i],B,E;return d&&(C(d[s+gw(n,e,!r)])?a=!0:r&&(e.altKey||e.metaKey||e.ctrlKey)&&!(He.windows&&e.ctrlKey&&e.altKey)&&(B=U0[e.keyCode])&&B!=n?(C(d[s+gw(B,e,!0)])||e.shiftKey&&(E=BE[e.keyCode])!=n&&E!=B&&C(d[s+gw(E,e,!1)]))&&(a=!0):r&&e.shiftKey&&C(d[s+gw(n,e,!0)])&&(a=!0),!a&&C(d._any)&&(a=!0)),c&&(a=!0),a&&l&&e.stopPropagation(),Nx=null,a}var q4=class t{constructor(e,A,i,n,o){this.className=e,this.left=A,this.top=i,this.width=n,this.height=o}draw(){let e=document.createElement("div");return e.className=this.className,this.adjust(e),e}update(e,A){return A.className!=this.className?!1:(this.adjust(e),!0)}adjust(e){e.style.left=this.left+"px",e.style.top=this.top+"px",this.width!=null&&(e.style.width=this.width+"px"),e.style.height=this.height+"px"}eq(e){return this.left==e.left&&this.top==e.top&&this.width==e.width&&this.height==e.height&&this.className==e.className}static forRange(e,A,i){if(i.empty){let n=e.coordsAtPos(i.head,i.assoc||1);if(!n)return[];let o=GtA(e);return[new t(A,n.left-o.left,n.top-o.top,null,n.bottom-n.top)]}else return ILA(e,A,i)}};function GtA(t){let e=t.scrollDOM.getBoundingClientRect();return{left:(t.textDirection==Wn.LTR?e.left:e.right-t.scrollDOM.clientWidth*t.scaleX)-t.scrollDOM.scrollLeft*t.scaleX,top:e.top-t.scrollDOM.scrollTop*t.scaleY}}function LeA(t,e,A,i){let n=t.coordsAtPos(e,A*2);if(!n)return i;let o=t.dom.getBoundingClientRect(),r=(n.top+n.bottom)/2,s=t.posAtCoords({x:o.left+1,y:r}),a=t.posAtCoords({x:o.right-1,y:r});return s==null||a==null?i:{from:Math.max(i.from,Math.min(s,a)),to:Math.min(i.to,Math.max(s,a))}}function ILA(t,e,A){if(A.to<=t.viewport.from||A.from>=t.viewport.to)return[];let i=Math.max(A.from,t.viewport.from),n=Math.min(A.to,t.viewport.to),o=t.textDirection==Wn.LTR,r=t.contentDOM,s=r.getBoundingClientRect(),a=GtA(t),c=r.querySelector(".cm-line"),l=c&&window.getComputedStyle(c),I=s.left+(l?parseInt(l.paddingLeft)+Math.min(0,parseInt(l.textIndent)):0),C=s.right-(l?parseInt(l.paddingRight):0),d=Qx(t,i,1),B=Qx(t,n,-1),E=d.type==zs.Text?d:null,Q=B.type==zs.Text?B:null;if(E&&(t.lineWrapping||d.widgetLineBreaks)&&(E=LeA(t,i,1,E)),Q&&(t.lineWrapping||B.widgetLineBreaks)&&(Q=LeA(t,n,-1,Q)),E&&Q&&E.from==Q.from&&E.to==Q.to)return v(L(A.from,A.to,E));{let y=E?L(A.from,null,E):x(d,!1),F=Q?L(null,A.to,Q):x(B,!0),U=[];return(E||d).to<(Q||B).from-(E&&Q?1:0)||d.widgetLineBreaks>1&&y.bottom+t.defaultLineHeight/2<F.top?U.push(u(I,y.bottom,C,F.top)):y.bottom<F.top&&t.elementAtHeight((y.bottom+F.top)/2).type==zs.Text&&(y.bottom=F.top=(y.bottom+F.top)/2),v(y).concat(U).concat(v(F))}function u(y,F,U,T){return new q4(e,y-a.left,F-a.top,U-y,T-F)}function v({top:y,bottom:F,horizontal:U}){let T=[];for(let N=0;N<U.length;N+=2)T.push(u(U[N],y,U[N+1],F));return T}function L(y,F,U){let T=1e9,N=-1e9,K=[];function H(lA,uA,p,V,cA){let aA=t.coordsAtPos(lA,lA==U.to?-2:2),jA=t.coordsAtPos(p,p==U.from?2:-2);!aA||!jA||(T=Math.min(aA.top,jA.top,T),N=Math.max(aA.bottom,jA.bottom,N),cA==Wn.LTR?K.push(o&&uA?I:aA.left,o&&V?C:jA.right):K.push(!o&&V?I:jA.left,!o&&uA?C:aA.right))}let j=y??U.from,IA=F??U.to;for(let lA of t.visibleRanges)if(lA.to>j&&lA.from<IA)for(let uA=Math.max(lA.from,j),p=Math.min(lA.to,IA);;){let V=t.state.doc.lineAt(uA);for(let cA of t.bidiSpans(V)){let aA=cA.from+V.from,jA=cA.to+V.from;if(aA>=p)break;jA>uA&&H(Math.max(aA,uA),y==null&&aA<=j,Math.min(jA,p),F==null&&jA>=IA,cA.dir)}if(uA=V.to+1,uA>=p)break}return K.length==0&&H(j,y==null,IA,F==null,t.textDirection),{top:T,bottom:N,horizontal:K}}function x(y,F){let U=s.top+(F?y.top:y.bottom);return{top:U,bottom:U,horizontal:[]}}}function CLA(t,e){return t.constructor==e.constructor&&t.eq(e)}var _x=class{constructor(e,A){this.view=e,this.layer=A,this.drawn=[],this.scaleX=1,this.scaleY=1,this.measureReq={read:this.measure.bind(this),write:this.draw.bind(this)},this.dom=e.scrollDOM.appendChild(document.createElement("div")),this.dom.classList.add("cm-layer"),A.above&&this.dom.classList.add("cm-layer-above"),A.class&&this.dom.classList.add(A.class),this.scale(),this.dom.setAttribute("aria-hidden","true"),this.setOrder(e.state),e.requestMeasure(this.measureReq),A.mount&&A.mount(this.dom,e)}update(e){e.startState.facet(hw)!=e.state.facet(hw)&&this.setOrder(e.state),(this.layer.update(e,this.dom)||e.geometryChanged)&&(this.scale(),e.view.requestMeasure(this.measureReq))}docViewUpdate(e){this.layer.updateOnDocViewUpdate!==!1&&e.requestMeasure(this.measureReq)}setOrder(e){let A=0,i=e.facet(hw);for(;A<i.length&&i[A]!=this.layer;)A++;this.dom.style.zIndex=String((this.layer.above?150:-1)-A)}measure(){return this.layer.markers(this.view)}scale(){let{scaleX:e,scaleY:A}=this.view;(e!=this.scaleX||A!=this.scaleY)&&(this.scaleX=e,this.scaleY=A,this.dom.style.transform=`scale(${1/e}, ${1/A})`)}draw(e){if(e.length!=this.drawn.length||e.some((A,i)=>!CLA(A,this.drawn[i]))){let A=this.dom.firstChild,i=0;for(let n of e)n.update&&A&&n.constructor&&this.drawn[i].constructor&&n.update(A,this.drawn[i])?(A=A.nextSibling,i++):this.dom.insertBefore(n.draw(),A);for(;A;){let n=A.nextSibling;A.remove(),A=n}this.drawn=e}}destroy(){this.layer.destroy&&this.layer.destroy(this.dom,this.view),this.dom.remove()}},hw=Te.define();function UtA(t){return[Xn.define(e=>new _x(e,t)),hw.of(t)]}var V4=Te.define({combine(t){return zr(t,{cursorBlinkRate:1200,drawRangeCursor:!0},{cursorBlinkRate:(e,A)=>Math.min(e,A),drawRangeCursor:(e,A)=>e||A})}});function KtA(t={}){return[V4.of(t),dLA,BLA,ELA,dtA.of(!0)]}function YtA(t){return t.startState.facet(V4)!=t.state.facet(V4)}var dLA=UtA({above:!0,markers(t){let{state:e}=t,A=e.facet(V4),i=[];for(let n of e.selection.ranges){let o=n==e.selection.main;if(n.empty||A.drawRangeCursor){let r=o?"cm-cursor cm-cursor-primary":"cm-cursor cm-cursor-secondary",s=n.empty?n:ie.cursor(n.head,n.head>n.anchor?-1:1);for(let a of q4.forRange(t,r,s))i.push(a)}}return i},update(t,e){t.transactions.some(i=>i.selection)&&(e.style.animationName=e.style.animationName=="cm-blink"?"cm-blink2":"cm-blink");let A=YtA(t);return A&&xeA(t.state,e),t.docChanged||t.selectionSet||A},mount(t,e){xeA(e.state,t)},class:"cm-cursorLayer"});function xeA(t,e){e.style.animationDuration=t.facet(V4).cursorBlinkRate+"ms"}var BLA=UtA({above:!1,markers(t){return t.state.selection.ranges.map(e=>e.empty?[]:q4.forRange(t,"cm-selectionBackground",e)).reduce((e,A)=>e.concat(A))},update(t,e){return t.docChanged||t.selectionSet||t.viewportChanged||YtA(t)},class:"cm-selectionLayer"}),ELA=Bl.highest(St.theme({".cm-line":{"& ::selection, &::selection":{backgroundColor:"transparent !important"},caretColor:"transparent !important"},".cm-content":{caretColor:"transparent !important","& :focus":{caretColor:"initial !important","&::selection, & ::selection":{backgroundColor:"Highlight !important"}}}})),JtA=ki.define({map(t,e){return t==null?null:e.mapPos(t)}}),L4=To.define({create(){return null},update(t,e){return t!=null&&(t=e.changes.mapPos(t)),e.effects.reduce((A,i)=>i.is(JtA)?i.value:A,t)}}),hLA=Xn.fromClass(class{constructor(t){this.view=t,this.cursor=null,this.measureReq={read:this.readPos.bind(this),write:this.drawCursor.bind(this)}}update(t){var e;let A=t.state.field(L4);A==null?this.cursor!=null&&((e=this.cursor)===null||e===void 0||e.remove(),this.cursor=null):(this.cursor||(this.cursor=this.view.scrollDOM.appendChild(document.createElement("div")),this.cursor.className="cm-dropCursor"),(t.startState.field(L4)!=A||t.docChanged||t.geometryChanged)&&this.view.requestMeasure(this.measureReq))}readPos(){let{view:t}=this,e=t.state.field(L4),A=e!=null&&t.coordsAtPos(e);if(!A)return null;let i=t.scrollDOM.getBoundingClientRect();return{left:A.left-i.left+t.scrollDOM.scrollLeft*t.scaleX,top:A.top-i.top+t.scrollDOM.scrollTop*t.scaleY,height:A.bottom-A.top}}drawCursor(t){if(this.cursor){let{scaleX:e,scaleY:A}=this.view;t?(this.cursor.style.left=t.left/e+"px",this.cursor.style.top=t.top/A+"px",this.cursor.style.height=t.height/A+"px"):this.cursor.style.left="-100000px"}}destroy(){this.cursor&&this.cursor.remove()}setDropPos(t){this.view.state.field(L4)!=t&&this.view.dispatch({effects:JtA.of(t)})}},{eventObservers:{dragover(t){this.setDropPos(this.view.posAtCoords({x:t.clientX,y:t.clientY}))},dragleave(t){(t.target==this.view.contentDOM||!this.view.contentDOM.contains(t.relatedTarget))&&this.setDropPos(null)},dragend(){this.setDropPos(null)},drop(){this.setDropPos(null)}}});function TtA(){return[L4,hLA]}function FeA(t,e,A,i,n){e.lastIndex=0;for(let o=t.iterRange(A,i),r=A,s;!o.next().done;r+=o.value.length)if(!o.lineBreak)for(;s=e.exec(o.value);)n(r+s.index,s)}function QLA(t,e){let A=t.visibleRanges;if(A.length==1&&A[0].from==t.viewport.from&&A[0].to==t.viewport.to)return A;let i=[];for(let{from:n,to:o}of A)n=Math.max(t.state.doc.lineAt(n).from,n-e),o=Math.min(t.state.doc.lineAt(o).to,o+e),i.length&&i[i.length-1].to>=n?i[i.length-1].to=o:i.push({from:n,to:o});return i}var Gx=class{constructor(e){let{regexp:A,decoration:i,decorate:n,boundary:o,maxLength:r=1e3}=e;if(!A.global)throw new RangeError("The regular expression given to MatchDecorator should have its 'g' flag set");if(this.regexp=A,n)this.addMatch=(s,a,c,l)=>n(l,c,c+s[0].length,s,a);else if(typeof i=="function")this.addMatch=(s,a,c,l)=>{let I=i(s,a,c);I&&l(c,c+s[0].length,I)};else if(i)this.addMatch=(s,a,c,l)=>l(c,c+s[0].length,i);else throw new RangeError("Either 'decorate' or 'decoration' should be provided to MatchDecorator");this.boundary=o,this.maxLength=r}createDeco(e){let A=new os,i=A.add.bind(A);for(let{from:n,to:o}of QLA(e,this.maxLength))FeA(e.state.doc,this.regexp,n,o,(r,s)=>this.addMatch(s,e,r,i));return A.finish()}updateDeco(e,A){let i=1e9,n=-1;return e.docChanged&&e.changes.iterChanges((o,r,s,a)=>{a>=e.view.viewport.from&&s<=e.view.viewport.to&&(i=Math.min(s,i),n=Math.max(a,n))}),e.viewportMoved||n-i>1e3?this.createDeco(e.view):n>-1?this.updateRange(e.view,A.map(e.changes),i,n):A}updateRange(e,A,i,n){for(let o of e.visibleRanges){let r=Math.max(o.from,i),s=Math.min(o.to,n);if(s>=r){let a=e.state.doc.lineAt(r),c=a.to<s?e.state.doc.lineAt(s):a,l=Math.max(o.from,a.from),I=Math.min(o.to,c.to);if(this.boundary){for(;r>a.from;r--)if(this.boundary.test(a.text[r-1-a.from])){l=r;break}for(;s<c.to;s++)if(this.boundary.test(c.text[s-c.from])){I=s;break}}let C=[],d,B=(E,Q,u)=>C.push(u.range(E,Q));if(a==c)for(this.regexp.lastIndex=l-a.from;(d=this.regexp.exec(a.text))&&d.index<I-a.from;)this.addMatch(d,e,d.index+a.from,B);else FeA(e.state.doc,this.regexp,l,I,(E,Q)=>this.addMatch(Q,e,E,B));A=A.update({filterFrom:l,filterTo:I,filter:(E,Q)=>E<l||Q>I,add:C})}}return A}},Ux=/x/.unicode!=null?"gu":"g",uLA=new RegExp(`[\0-\b
-\x7F-\x9F\xAD\u061C\u200B\u200E\u200F\u2028\u2029\u202D\u202E\u2066\u2067\u2069\uFEFF\uFFF9-\uFFFC]`,Ux),fLA={0:"null",7:"bell",8:"backspace",10:"newline",11:"vertical tab",13:"carriage return",27:"escape",8203:"zero width space",8204:"zero width non-joiner",8205:"zero width joiner",8206:"left-to-right mark",8207:"right-to-left mark",8232:"line separator",8237:"left-to-right override",8238:"right-to-left override",8294:"left-to-right isolate",8295:"right-to-left isolate",8297:"pop directional isolate",8233:"paragraph separator",65279:"zero width no-break space",65532:"object replacement"},ix=null;function mLA(){var t;if(ix==null&&typeof document<"u"&&document.body){let e=document.body.style;ix=((t=e.tabSize)!==null&&t!==void 0?t:e.MozTabSize)!=null}return ix||!1}var Qw=Te.define({combine(t){let e=zr(t,{render:null,specialChars:uLA,addSpecialChars:null});return(e.replaceTabs=!mLA())&&(e.specialChars=new RegExp("	|"+e.specialChars.source,Ux)),e.addSpecialChars&&(e.specialChars=new RegExp(e.specialChars.source+"|"+e.addSpecialChars.source,Ux)),e}});function ztA(t={}){return[Qw.of(t),pLA()]}var NeA=null;function pLA(){return NeA||(NeA=Xn.fromClass(class{constructor(t){this.view=t,this.decorations=rt.none,this.decorationCache=Object.create(null),this.decorator=this.makeDecorator(t.state.facet(Qw)),this.decorations=this.decorator.createDeco(t)}makeDecorator(t){return new Gx({regexp:t.specialChars,decoration:(e,A,i)=>{let{doc:n}=A.state,o=rs(e[0],0);if(o==9){let r=n.lineAt(i),s=A.state.tabSize,a=G0(r.text,s,i-r.from);return rt.replace({widget:new Yx((s-a%s)*this.view.defaultCharacterWidth/this.view.scaleX)})}return this.decorationCache[o]||(this.decorationCache[o]=rt.replace({widget:new Kx(t,o)}))},boundary:t.replaceTabs?void 0:/[^]/})}update(t){let e=t.state.facet(Qw);t.startState.facet(Qw)!=e?(this.decorator=this.makeDecorator(e),this.decorations=this.decorator.createDeco(t.view)):this.decorations=this.decorator.updateDeco(t,this.decorations)}},{decorations:t=>t.decorations}))}var wLA="\u2022";function DLA(t){return t>=32?wLA:t==10?"\u2424":String.fromCharCode(9216+t)}var Kx=class extends nc{constructor(e,A){super(),this.options=e,this.code=A}eq(e){return e.code==this.code}toDOM(e){let A=DLA(this.code),i=e.state.phrase("Control character")+" "+(fLA[this.code]||"0x"+this.code.toString(16)),n=this.options.render&&this.options.render(this.code,i,A);if(n)return n;let o=document.createElement("span");return o.textContent=A,o.title=i,o.setAttribute("aria-label",i),o.className="cm-specialChar",o}ignoreEvent(){return!1}},Yx=class extends nc{constructor(e){super(),this.width=e}eq(e){return e.width==this.width}toDOM(){let e=document.createElement("span");return e.textContent="	",e.className="cm-tab",e.style.width=this.width+"px",e}ignoreEvent(){return!1}};function HtA(){return vLA}var yLA=rt.line({class:"cm-activeLine"}),vLA=Xn.fromClass(class{constructor(t){this.decorations=this.getDeco(t)}update(t){(t.docChanged||t.selectionSet)&&(this.decorations=this.getDeco(t.view))}getDeco(t){let e=-1,A=[];for(let i of t.state.selection.ranges){let n=t.lineBlockAt(i.head);n.from>e&&(A.push(yLA.range(n.from)),e=n.from)}return rt.set(A)}},{decorations:t=>t.decorations});var Jx=2e3;function bLA(t,e,A){let i=Math.min(e.line,A.line),n=Math.max(e.line,A.line),o=[];if(e.off>Jx||A.off>Jx||e.col<0||A.col<0){let r=Math.min(e.off,A.off),s=Math.max(e.off,A.off);for(let a=i;a<=n;a++){let c=t.doc.line(a);c.length<=s&&o.push(ie.range(c.from+r,c.to+s))}}else{let r=Math.min(e.col,A.col),s=Math.max(e.col,A.col);for(let a=i;a<=n;a++){let c=t.doc.line(a),l=tw(c.text,r,t.tabSize,!0);if(l<0)o.push(ie.cursor(c.to));else{let I=tw(c.text,s,t.tabSize);o.push(ie.range(c.from+l,c.from+I))}}}return o}function MLA(t,e){let A=t.coordsAtPos(t.viewport.from);return A?Math.round(Math.abs((A.left-e)/t.defaultCharacterWidth)):-1}function _eA(t,e){let A=t.posAtCoords({x:e.clientX,y:e.clientY},!1),i=t.state.doc.lineAt(A),n=A-i.from,o=n>Jx?-1:n==i.length?MLA(t,e.clientX):G0(i.text,t.state.tabSize,A-i.from);return{line:i.number,col:o,off:n}}function kLA(t,e){let A=_eA(t,e),i=t.state.selection;return A?{update(n){if(n.docChanged){let o=n.changes.mapPos(n.startState.doc.line(A.line).from),r=n.state.doc.lineAt(o);A={line:r.number,col:A.col,off:Math.min(A.off,r.length)},i=i.map(n.changes)}},get(n,o,r){let s=_eA(t,n);if(!s)return i;let a=bLA(t.state,A,s);return a.length?r?ie.create(a.concat(i.ranges)):ie.create(a):i}}:null}function OtA(t){let e=t?.eventFilter||(A=>A.altKey&&A.button==0);return St.mouseSelectionStyle.of((A,i)=>e(i)?kLA(A,i):null)}var SLA={Alt:[18,t=>!!t.altKey],Control:[17,t=>!!t.ctrlKey],Shift:[16,t=>!!t.shiftKey],Meta:[91,t=>!!t.metaKey]},RLA={style:"cursor: crosshair"};function PtA(t={}){let[e,A]=SLA[t.key||"Alt"],i=Xn.fromClass(class{constructor(n){this.view=n,this.isDown=!1}set(n){this.isDown!=n&&(this.isDown=n,this.view.update([]))}},{eventObservers:{keydown(n){this.set(n.keyCode==e||A(n))},keyup(n){(n.keyCode==e||!A(n))&&this.set(!1)},mousemove(n){this.set(A(n))}}});return[i,St.contentAttributes.of(n=>{var o;return!((o=n.plugin(i))===null||o===void 0)&&o.isDown?RLA:null})]}var k4="-10000px",Sw=class{constructor(e,A,i,n){this.facet=A,this.createTooltipView=i,this.removeTooltipView=n,this.input=e.state.facet(A),this.tooltips=this.input.filter(r=>r);let o=null;this.tooltipViews=this.tooltips.map(r=>o=i(r,o))}update(e,A){var i;let n=e.state.facet(this.facet),o=n.filter(a=>a);if(n===this.input){for(let a of this.tooltipViews)a.update&&a.update(e);return!1}let r=[],s=A?[]:null;for(let a=0;a<o.length;a++){let c=o[a],l=-1;if(c){for(let I=0;I<this.tooltips.length;I++){let C=this.tooltips[I];C&&C.create==c.create&&(l=I)}if(l<0)r[a]=this.createTooltipView(c,a?r[a-1]:null),s&&(s[a]=!!c.above);else{let I=r[a]=this.tooltipViews[l];s&&(s[a]=A[l]),I.update&&I.update(e)}}}for(let a of this.tooltipViews)r.indexOf(a)<0&&(this.removeTooltipView(a),(i=a.destroy)===null||i===void 0||i.call(a));return A&&(s.forEach((a,c)=>A[c]=a),A.length=s.length),this.input=n,this.tooltips=o,this.tooltipViews=r,!0}};function LLA(t){let e=t.dom.ownerDocument.documentElement;return{top:0,left:0,bottom:e.clientHeight,right:e.clientWidth}}var nx=Te.define({combine:t=>{var e,A,i;return{position:He.ios?"absolute":((e=t.find(n=>n.position))===null||e===void 0?void 0:e.position)||"fixed",parent:((A=t.find(n=>n.parent))===null||A===void 0?void 0:A.parent)||null,tooltipSpace:((i=t.find(n=>n.tooltipSpace))===null||i===void 0?void 0:i.tooltipSpace)||LLA}}}),GeA=new WeakMap,$x=Xn.fromClass(class{constructor(t){this.view=t,this.above=[],this.inView=!0,this.madeAbsolute=!1,this.lastTransaction=0,this.measureTimeout=-1;let e=t.state.facet(nx);this.position=e.position,this.parent=e.parent,this.classes=t.themeClasses,this.createContainer(),this.measureReq={read:this.readMeasure.bind(this),write:this.writeMeasure.bind(this),key:this},this.resizeObserver=typeof ResizeObserver=="function"?new ResizeObserver(()=>this.measureSoon()):null,this.manager=new Sw(t,DE,(A,i)=>this.createTooltip(A,i),A=>{this.resizeObserver&&this.resizeObserver.unobserve(A.dom),A.dom.remove()}),this.above=this.manager.tooltips.map(A=>!!A.above),this.intersectionObserver=typeof IntersectionObserver=="function"?new IntersectionObserver(A=>{Date.now()>this.lastTransaction-50&&A.length>0&&A[A.length-1].intersectionRatio<1&&this.measureSoon()},{threshold:[1]}):null,this.observeIntersection(),t.win.addEventListener("resize",this.measureSoon=this.measureSoon.bind(this)),this.maybeMeasure()}createContainer(){this.parent?(this.container=document.createElement("div"),this.container.style.position="relative",this.container.className=this.view.themeClasses,this.parent.appendChild(this.container)):this.container=this.view.dom}observeIntersection(){if(this.intersectionObserver){this.intersectionObserver.disconnect();for(let t of this.manager.tooltipViews)this.intersectionObserver.observe(t.dom)}}measureSoon(){this.measureTimeout<0&&(this.measureTimeout=setTimeout(()=>{this.measureTimeout=-1,this.maybeMeasure()},50))}update(t){t.transactions.length&&(this.lastTransaction=Date.now());let e=this.manager.update(t,this.above);e&&this.observeIntersection();let A=e||t.geometryChanged,i=t.state.facet(nx);if(i.position!=this.position&&!this.madeAbsolute){this.position=i.position;for(let n of this.manager.tooltipViews)n.dom.style.position=this.position;A=!0}if(i.parent!=this.parent){this.parent&&this.container.remove(),this.parent=i.parent,this.createContainer();for(let n of this.manager.tooltipViews)this.container.appendChild(n.dom);A=!0}else this.parent&&this.view.themeClasses!=this.classes&&(this.classes=this.container.className=this.view.themeClasses);A&&this.maybeMeasure()}createTooltip(t,e){let A=t.create(this.view),i=e?e.dom:null;if(A.dom.classList.add("cm-tooltip"),t.arrow&&!A.dom.querySelector(".cm-tooltip > .cm-tooltip-arrow")){let n=document.createElement("div");n.className="cm-tooltip-arrow",A.dom.appendChild(n)}return A.dom.style.position=this.position,A.dom.style.top=k4,A.dom.style.left="0px",this.container.insertBefore(A.dom,i),A.mount&&A.mount(this.view),this.resizeObserver&&this.resizeObserver.observe(A.dom),A}destroy(){var t,e,A;this.view.win.removeEventListener("resize",this.measureSoon);for(let i of this.manager.tooltipViews)i.dom.remove(),(t=i.destroy)===null||t===void 0||t.call(i);this.parent&&this.container.remove(),(e=this.resizeObserver)===null||e===void 0||e.disconnect(),(A=this.intersectionObserver)===null||A===void 0||A.disconnect(),clearTimeout(this.measureTimeout)}readMeasure(){let t=1,e=1,A=!1;if(this.position=="fixed"&&this.manager.tooltipViews.length){let{dom:o}=this.manager.tooltipViews[0];if(He.gecko)A=o.offsetParent!=this.container.ownerDocument.body;else if(o.style.top==k4&&o.style.left=="0px"){let r=o.getBoundingClientRect();A=Math.abs(r.top+1e4)>1||Math.abs(r.left)>1}}if(A||this.position=="absolute")if(this.parent){let o=this.parent.getBoundingClientRect();o.width&&o.height&&(t=o.width/this.parent.offsetWidth,e=o.height/this.parent.offsetHeight)}else({scaleX:t,scaleY:e}=this.view.viewState);let i=this.view.scrollDOM.getBoundingClientRect(),n=Wx(this.view);return{visible:{left:i.left+n.left,top:i.top+n.top,right:i.right-n.right,bottom:i.bottom-n.bottom},parent:this.parent?this.container.getBoundingClientRect():this.view.dom.getBoundingClientRect(),pos:this.manager.tooltips.map((o,r)=>{let s=this.manager.tooltipViews[r];return s.getCoords?s.getCoords(o.pos):this.view.coordsAtPos(o.pos)}),size:this.manager.tooltipViews.map(({dom:o})=>o.getBoundingClientRect()),space:this.view.state.facet(nx).tooltipSpace(this.view),scaleX:t,scaleY:e,makeAbsolute:A}}writeMeasure(t){var e;if(t.makeAbsolute){this.madeAbsolute=!0,this.position="absolute";for(let s of this.manager.tooltipViews)s.dom.style.position="absolute"}let{visible:A,space:i,scaleX:n,scaleY:o}=t,r=[];for(let s=0;s<this.manager.tooltips.length;s++){let a=this.manager.tooltips[s],c=this.manager.tooltipViews[s],{dom:l}=c,I=t.pos[s],C=t.size[s];if(!I||a.clip!==!1&&(I.bottom<=Math.max(A.top,i.top)||I.top>=Math.min(A.bottom,i.bottom)||I.right<Math.max(A.left,i.left)-.1||I.left>Math.min(A.right,i.right)+.1)){l.style.top=k4;continue}let d=a.arrow?c.dom.querySelector(".cm-tooltip-arrow"):null,B=d?7:0,E=C.right-C.left,Q=(e=GeA.get(c))!==null&&e!==void 0?e:C.bottom-C.top,u=c.offset||FLA,v=this.view.textDirection==Wn.LTR,L=C.width>i.right-i.left?v?i.left:i.right-C.width:v?Math.max(i.left,Math.min(I.left-(d?14:0)+u.x,i.right-E)):Math.min(Math.max(i.left,I.left-E+(d?14:0)-u.x),i.right-E),x=this.above[s];!a.strictSide&&(x?I.top-Q-B-u.y<i.top:I.bottom+Q+B+u.y>i.bottom)&&x==i.bottom-I.bottom>I.top-i.top&&(x=this.above[s]=!x);let y=(x?I.top-i.top:i.bottom-I.bottom)-B;if(y<Q&&c.resize!==!1){if(y<this.view.defaultLineHeight){l.style.top=k4;continue}GeA.set(c,Q),l.style.height=(Q=y)/o+"px"}else l.style.height&&(l.style.height="");let F=x?I.top-Q-B-u.y:I.bottom+B+u.y,U=L+E;if(c.overlap!==!0)for(let T of r)T.left<U&&T.right>L&&T.top<F+Q&&T.bottom>F&&(F=x?T.top-Q-2-B:T.bottom+B+2);if(this.position=="absolute"?(l.style.top=(F-t.parent.top)/o+"px",UeA(l,(L-t.parent.left)/n)):(l.style.top=F/o+"px",UeA(l,L/n)),d){let T=I.left+(v?u.x:-u.x)-(L+14-7);d.style.left=T/n+"px"}c.overlap!==!0&&r.push({left:L,top:F,right:U,bottom:F+Q}),l.classList.toggle("cm-tooltip-above",x),l.classList.toggle("cm-tooltip-below",!x),c.positioned&&c.positioned(t.space)}}maybeMeasure(){if(this.manager.tooltips.length&&(this.view.inView&&this.view.requestMeasure(this.measureReq),this.inView!=this.view.inView&&(this.inView=this.view.inView,!this.inView)))for(let t of this.manager.tooltipViews)t.dom.style.top=k4}},{eventObservers:{scroll(){this.maybeMeasure()}}});function UeA(t,e){let A=parseInt(t.style.left,10);(isNaN(A)||Math.abs(e-A)>1)&&(t.style.left=e+"px")}var xLA=St.baseTheme({".cm-tooltip":{zIndex:500,boxSizing:"border-box"},"&light .cm-tooltip":{border:"1px solid #bbb",backgroundColor:"#f5f5f5"},"&light .cm-tooltip-section:not(:first-child)":{borderTop:"1px solid #bbb"},"&dark .cm-tooltip":{backgroundColor:"#333338",color:"white"},".cm-tooltip-arrow":{height:"7px",width:`${7*2}px`,position:"absolute",zIndex:-1,overflow:"hidden","&:before, &:after":{content:"''",position:"absolute",width:0,height:0,borderLeft:"7px solid transparent",borderRight:"7px solid transparent"},".cm-tooltip-above &":{bottom:"-7px","&:before":{borderTop:"7px solid #bbb"},"&:after":{borderTop:"7px solid #f5f5f5",bottom:"1px"}},".cm-tooltip-below &":{top:"-7px","&:before":{borderBottom:"7px solid #bbb"},"&:after":{borderBottom:"7px solid #f5f5f5",top:"1px"}}},"&dark .cm-tooltip .cm-tooltip-arrow":{"&:before":{borderTopColor:"#333338",borderBottomColor:"#333338"},"&:after":{borderTopColor:"transparent",borderBottomColor:"transparent"}}}),FLA={x:0,y:0},DE=Te.define({enables:[$x,xLA]}),Rw=Te.define({combine:t=>t.reduce((e,A)=>e.concat(A),[])}),Lw=class t{static create(e){return new t(e)}constructor(e){this.view=e,this.mounted=!1,this.dom=document.createElement("div"),this.dom.classList.add("cm-tooltip-hover"),this.manager=new Sw(e,Rw,(A,i)=>this.createHostedView(A,i),A=>A.dom.remove())}createHostedView(e,A){let i=e.create(this.view);return i.dom.classList.add("cm-tooltip-section"),this.dom.insertBefore(i.dom,A?A.dom.nextSibling:this.dom.firstChild),this.mounted&&i.mount&&i.mount(this.view),i}mount(e){for(let A of this.manager.tooltipViews)A.mount&&A.mount(e);this.mounted=!0}positioned(e){for(let A of this.manager.tooltipViews)A.positioned&&A.positioned(e)}update(e){this.manager.update(e)}destroy(){var e;for(let A of this.manager.tooltipViews)(e=A.destroy)===null||e===void 0||e.call(A)}passProp(e){let A;for(let i of this.manager.tooltipViews){let n=i[e];if(n!==void 0){if(A===void 0)A=n;else if(A!==n)return}}return A}get offset(){return this.passProp("offset")}get getCoords(){return this.passProp("getCoords")}get overlap(){return this.passProp("overlap")}get resize(){return this.passProp("resize")}},NLA=DE.compute([Rw],t=>{let e=t.facet(Rw);return e.length===0?null:{pos:Math.min(...e.map(A=>A.pos)),end:Math.max(...e.map(A=>{var i;return(i=A.end)!==null&&i!==void 0?i:A.pos})),create:Lw.create,above:e[0].above,arrow:e.some(A=>A.arrow)}}),Tx=class{constructor(e,A,i,n,o){this.view=e,this.source=A,this.field=i,this.setHover=n,this.hoverTime=o,this.hoverTimeout=-1,this.restartTimeout=-1,this.pending=null,this.lastMove={x:0,y:0,target:e.dom,time:0},this.checkHover=this.checkHover.bind(this),e.dom.addEventListener("mouseleave",this.mouseleave=this.mouseleave.bind(this)),e.dom.addEventListener("mousemove",this.mousemove=this.mousemove.bind(this))}update(){this.pending&&(this.pending=null,clearTimeout(this.restartTimeout),this.restartTimeout=setTimeout(()=>this.startHover(),20))}get active(){return this.view.state.field(this.field)}checkHover(){if(this.hoverTimeout=-1,this.active.length)return;let e=Date.now()-this.lastMove.time;e<this.hoverTime?this.hoverTimeout=setTimeout(this.checkHover,this.hoverTime-e):this.startHover()}startHover(){clearTimeout(this.restartTimeout);let{view:e,lastMove:A}=this,i=e.docView.nearest(A.target);if(!i)return;let n,o=1;if(i instanceof T4)n=i.posAtStart;else{if(n=e.posAtCoords(A),n==null)return;let s=e.coordsAtPos(n);if(!s||A.y<s.top||A.y>s.bottom||A.x<s.left-e.defaultCharacterWidth||A.x>s.right+e.defaultCharacterWidth)return;let a=e.bidiSpans(e.state.doc.lineAt(n)).find(l=>l.from<=n&&l.to>=n),c=a&&a.dir==Wn.RTL?-1:1;o=A.x<s.left?-c:c}let r=this.source(e,n,o);if(r?.then){let s=this.pending={pos:n};r.then(a=>{this.pending==s&&(this.pending=null,a&&!(Array.isArray(a)&&!a.length)&&e.dispatch({effects:this.setHover.of(Array.isArray(a)?a:[a])}))},a=>Hr(e.state,a,"hover tooltip"))}else r&&!(Array.isArray(r)&&!r.length)&&e.dispatch({effects:this.setHover.of(Array.isArray(r)?r:[r])})}get tooltip(){let e=this.view.plugin($x),A=e?e.manager.tooltips.findIndex(i=>i.create==Lw.create):-1;return A>-1?e.manager.tooltipViews[A]:null}mousemove(e){var A,i;this.lastMove={x:e.clientX,y:e.clientY,target:e.target,time:Date.now()},this.hoverTimeout<0&&(this.hoverTimeout=setTimeout(this.checkHover,this.hoverTime));let{active:n,tooltip:o}=this;if(n.length&&o&&!_LA(o.dom,e)||this.pending){let{pos:r}=n[0]||this.pending,s=(i=(A=n[0])===null||A===void 0?void 0:A.end)!==null&&i!==void 0?i:r;(r==s?this.view.posAtCoords(this.lastMove)!=r:!GLA(this.view,r,s,e.clientX,e.clientY))&&(this.view.dispatch({effects:this.setHover.of([])}),this.pending=null)}}mouseleave(e){clearTimeout(this.hoverTimeout),this.hoverTimeout=-1;let{active:A}=this;if(A.length){let{tooltip:i}=this;i&&i.dom.contains(e.relatedTarget)?this.watchTooltipLeave(i.dom):this.view.dispatch({effects:this.setHover.of([])})}}watchTooltipLeave(e){let A=i=>{e.removeEventListener("mouseleave",A),this.active.length&&!this.view.dom.contains(i.relatedTarget)&&this.view.dispatch({effects:this.setHover.of([])})};e.addEventListener("mouseleave",A)}destroy(){clearTimeout(this.hoverTimeout),this.view.dom.removeEventListener("mouseleave",this.mouseleave),this.view.dom.removeEventListener("mousemove",this.mousemove)}},Iw=4;function _LA(t,e){let{left:A,right:i,top:n,bottom:o}=t.getBoundingClientRect(),r;if(r=t.querySelector(".cm-tooltip-arrow")){let s=r.getBoundingClientRect();n=Math.min(s.top,n),o=Math.max(s.bottom,o)}return e.clientX>=A-Iw&&e.clientX<=i+Iw&&e.clientY>=n-Iw&&e.clientY<=o+Iw}function GLA(t,e,A,i,n,o){let r=t.scrollDOM.getBoundingClientRect(),s=t.documentTop+t.documentPadding.top+t.contentHeight;if(r.left>i||r.right<i||r.top>n||Math.min(r.bottom,s)<n)return!1;let a=t.posAtCoords({x:i,y:n},!1);return a>=e&&a<=A}function jtA(t,e={}){let A=ki.define(),i=To.define({create(){return[]},update(n,o){if(n.length&&(e.hideOnChange&&(o.docChanged||o.selection)?n=[]:e.hideOn&&(n=n.filter(r=>!e.hideOn(o,r))),o.docChanged)){let r=[];for(let s of n){let a=o.changes.mapPos(s.pos,-1,is.TrackDel);if(a!=null){let c=Object.assign(Object.create(null),s);c.pos=a,c.end!=null&&(c.end=o.changes.mapPos(c.end)),r.push(c)}}n=r}for(let r of o.effects)r.is(A)&&(n=r.value),r.is(ULA)&&(n=[]);return n},provide:n=>Rw.from(n)});return{active:i,extension:[i,Xn.define(n=>new Tx(n,t,i,A,e.hoverTime||300)),NLA]}}function AF(t,e){let A=t.plugin($x);if(!A)return null;let i=A.manager.tooltips.indexOf(e);return i<0?null:A.manager.tooltipViews[i]}var ULA=ki.define();var KeA=Te.define({combine(t){let e,A;for(let i of t)e=e||i.topContainer,A=A||i.bottomContainer;return{topContainer:e,bottomContainer:A}}});function BC(t,e){let A=t.plugin(qtA),i=A?A.specs.indexOf(e):-1;return i>-1?A.panels[i]:null}var qtA=Xn.fromClass(class{constructor(t){this.input=t.state.facet(dC),this.specs=this.input.filter(A=>A),this.panels=this.specs.map(A=>A(t));let e=t.state.facet(KeA);this.top=new uE(t,!0,e.topContainer),this.bottom=new uE(t,!1,e.bottomContainer),this.top.sync(this.panels.filter(A=>A.top)),this.bottom.sync(this.panels.filter(A=>!A.top));for(let A of this.panels)A.dom.classList.add("cm-panel"),A.mount&&A.mount()}update(t){let e=t.state.facet(KeA);this.top.container!=e.topContainer&&(this.top.sync([]),this.top=new uE(t.view,!0,e.topContainer)),this.bottom.container!=e.bottomContainer&&(this.bottom.sync([]),this.bottom=new uE(t.view,!1,e.bottomContainer)),this.top.syncClasses(),this.bottom.syncClasses();let A=t.state.facet(dC);if(A!=this.input){let i=A.filter(a=>a),n=[],o=[],r=[],s=[];for(let a of i){let c=this.specs.indexOf(a),l;c<0?(l=a(t.view),s.push(l)):(l=this.panels[c],l.update&&l.update(t)),n.push(l),(l.top?o:r).push(l)}this.specs=i,this.panels=n,this.top.sync(o),this.bottom.sync(r);for(let a of s)a.dom.classList.add("cm-panel"),a.mount&&a.mount()}else for(let i of this.panels)i.update&&i.update(t)}destroy(){this.top.sync([]),this.bottom.sync([])}},{provide:t=>St.scrollMargins.of(e=>{let A=e.plugin(t);return A&&{top:A.top.scrollMargin(),bottom:A.bottom.scrollMargin()}})}),uE=class{constructor(e,A,i){this.view=e,this.top=A,this.container=i,this.dom=void 0,this.classes="",this.panels=[],this.syncClasses()}sync(e){for(let A of this.panels)A.destroy&&e.indexOf(A)<0&&A.destroy();this.panels=e,this.syncDOM()}syncDOM(){if(this.panels.length==0){this.dom&&(this.dom.remove(),this.dom=void 0);return}if(!this.dom){this.dom=document.createElement("div"),this.dom.className=this.top?"cm-panels cm-panels-top":"cm-panels cm-panels-bottom",this.dom.style[this.top?"top":"bottom"]="0";let A=this.container||this.view.dom;A.insertBefore(this.dom,this.top?A.firstChild:null)}let e=this.dom.firstChild;for(let A of this.panels)if(A.dom.parentNode==this.dom){for(;e!=A.dom;)e=YeA(e);e=e.nextSibling}else this.dom.insertBefore(A.dom,e);for(;e;)e=YeA(e)}scrollMargin(){return!this.dom||this.container?0:Math.max(0,this.top?this.dom.getBoundingClientRect().bottom-Math.max(0,this.view.scrollDOM.getBoundingClientRect().top):Math.min(innerHeight,this.view.scrollDOM.getBoundingClientRect().bottom)-this.dom.getBoundingClientRect().top)}syncClasses(){if(!(!this.container||this.classes==this.view.themeClasses)){for(let e of this.classes.split(" "))e&&this.container.classList.remove(e);for(let e of(this.classes=this.view.themeClasses).split(" "))e&&this.container.classList.add(e)}}};function YeA(t){let e=t.nextSibling;return t.remove(),e}var dC=Te.define({enables:qtA});var ya=class extends dl{compare(e){return this==e||this.constructor==e.constructor&&this.eq(e)}eq(e){return!1}destroy(e){}};ya.prototype.elementClass="";ya.prototype.toDOM=void 0;ya.prototype.mapMode=is.TrackBefore;ya.prototype.startSide=ya.prototype.endSide=-1;ya.prototype.point=!0;var uw=Te.define(),KLA=Te.define(),YLA={class:"",renderEmptyElements:!1,elementStyle:"",markers:()=>Zn.empty,lineMarker:()=>null,widgetMarker:()=>null,lineMarkerChange:null,initialSpacer:null,updateSpacer:null,domEventHandlers:{}},U4=Te.define();function Uw(t){return[VtA(),U4.of(nA(nA({},YLA),t))]}var zx=Te.define({combine:t=>t.some(e=>e)});function VtA(t){let e=[JLA];return t&&t.fixed===!1&&e.push(zx.of(!0)),e}var JLA=Xn.fromClass(class{constructor(t){this.view=t,this.prevViewport=t.viewport,this.dom=document.createElement("div"),this.dom.className="cm-gutters",this.dom.setAttribute("aria-hidden","true"),this.dom.style.minHeight=this.view.contentHeight/this.view.scaleY+"px",this.gutters=t.state.facet(U4).map(e=>new xw(t,e));for(let e of this.gutters)this.dom.appendChild(e.dom);this.fixed=!t.state.facet(zx),this.fixed&&(this.dom.style.position="sticky"),this.syncGutters(!1),t.scrollDOM.insertBefore(this.dom,t.contentDOM)}update(t){if(this.updateGutters(t)){let e=this.prevViewport,A=t.view.viewport,i=Math.min(e.to,A.to)-Math.max(e.from,A.from);this.syncGutters(i<(A.to-A.from)*.8)}t.geometryChanged&&(this.dom.style.minHeight=this.view.contentHeight/this.view.scaleY+"px"),this.view.state.facet(zx)!=!this.fixed&&(this.fixed=!this.fixed,this.dom.style.position=this.fixed?"sticky":""),this.prevViewport=t.view.viewport}syncGutters(t){let e=this.dom.nextSibling;t&&this.dom.remove();let A=Zn.iter(this.view.state.facet(uw),this.view.viewport.from),i=[],n=this.gutters.map(o=>new Ox(o,this.view.viewport,-this.view.documentPadding.top));for(let o of this.view.viewportLineBlocks)if(i.length&&(i=[]),Array.isArray(o.type)){let r=!0;for(let s of o.type)if(s.type==zs.Text&&r){Hx(A,i,s.from);for(let a of n)a.line(this.view,s,i);r=!1}else if(s.widget)for(let a of n)a.widget(this.view,s)}else if(o.type==zs.Text){Hx(A,i,o.from);for(let r of n)r.line(this.view,o,i)}else if(o.widget)for(let r of n)r.widget(this.view,o);for(let o of n)o.finish();t&&this.view.scrollDOM.insertBefore(this.dom,e)}updateGutters(t){let e=t.startState.facet(U4),A=t.state.facet(U4),i=t.docChanged||t.heightChanged||t.viewportChanged||!Zn.eq(t.startState.facet(uw),t.state.facet(uw),t.view.viewport.from,t.view.viewport.to);if(e==A)for(let n of this.gutters)n.update(t)&&(i=!0);else{i=!0;let n=[];for(let o of A){let r=e.indexOf(o);r<0?n.push(new xw(this.view,o)):(this.gutters[r].update(t),n.push(this.gutters[r]))}for(let o of this.gutters)o.dom.remove(),n.indexOf(o)<0&&o.destroy();for(let o of n)this.dom.appendChild(o.dom);this.gutters=n}return i}destroy(){for(let t of this.gutters)t.destroy();this.dom.remove()}},{provide:t=>St.scrollMargins.of(e=>{let A=e.plugin(t);return!A||A.gutters.length==0||!A.fixed?null:e.textDirection==Wn.LTR?{left:A.dom.offsetWidth*e.scaleX}:{right:A.dom.offsetWidth*e.scaleX}})});function JeA(t){return Array.isArray(t)?t:[t]}function Hx(t,e,A){for(;t.value&&t.from<=A;)t.from==A&&e.push(t.value),t.next()}var Ox=class{constructor(e,A,i){this.gutter=e,this.height=i,this.i=0,this.cursor=Zn.iter(e.markers,A.from)}addElement(e,A,i){let{gutter:n}=this,o=(A.top-this.height)/e.scaleY,r=A.height/e.scaleY;if(this.i==n.elements.length){let s=new Fw(e,r,o,i);n.elements.push(s),n.dom.appendChild(s.dom)}else n.elements[this.i].update(e,r,o,i);this.height=A.bottom,this.i++}line(e,A,i){let n=[];Hx(this.cursor,n,A.from),i.length&&(n=n.concat(i));let o=this.gutter.config.lineMarker(e,A,n);o&&n.unshift(o);let r=this.gutter;n.length==0&&!r.config.renderEmptyElements||this.addElement(e,A,n)}widget(e,A){let i=this.gutter.config.widgetMarker(e,A.widget,A),n=i?[i]:null;for(let o of e.state.facet(KLA)){let r=o(e,A.widget,A);r&&(n||(n=[])).push(r)}n&&this.addElement(e,A,n)}finish(){let e=this.gutter;for(;e.elements.length>this.i;){let A=e.elements.pop();e.dom.removeChild(A.dom),A.destroy()}}},xw=class{constructor(e,A){this.view=e,this.config=A,this.elements=[],this.spacer=null,this.dom=document.createElement("div"),this.dom.className="cm-gutter"+(this.config.class?" "+this.config.class:"");for(let i in A.domEventHandlers)this.dom.addEventListener(i,n=>{let o=n.target,r;if(o!=this.dom&&this.dom.contains(o)){for(;o.parentNode!=this.dom;)o=o.parentNode;let a=o.getBoundingClientRect();r=(a.top+a.bottom)/2}else r=n.clientY;let s=e.lineBlockAtHeight(r-e.documentTop);A.domEventHandlers[i](e,s,n)&&n.preventDefault()});this.markers=JeA(A.markers(e)),A.initialSpacer&&(this.spacer=new Fw(e,0,0,[A.initialSpacer(e)]),this.dom.appendChild(this.spacer.dom),this.spacer.dom.style.cssText+="visibility: hidden; pointer-events: none")}update(e){let A=this.markers;if(this.markers=JeA(this.config.markers(e.view)),this.spacer&&this.config.updateSpacer){let n=this.config.updateSpacer(this.spacer.markers[0],e);n!=this.spacer.markers[0]&&this.spacer.update(e.view,0,0,[n])}let i=e.view.viewport;return!Zn.eq(this.markers,A,i.from,i.to)||(this.config.lineMarkerChange?this.config.lineMarkerChange(e):!1)}destroy(){for(let e of this.elements)e.destroy()}},Fw=class{constructor(e,A,i,n){this.height=-1,this.above=0,this.markers=[],this.dom=document.createElement("div"),this.dom.className="cm-gutterElement",this.update(e,A,i,n)}update(e,A,i,n){this.height!=A&&(this.height=A,this.dom.style.height=A+"px"),this.above!=i&&(this.dom.style.marginTop=(this.above=i)?i+"px":""),TLA(this.markers,n)||this.setMarkers(e,n)}setMarkers(e,A){let i="cm-gutterElement",n=this.dom.firstChild;for(let o=0,r=0;;){let s=r,a=o<A.length?A[o++]:null,c=!1;if(a){let l=a.elementClass;l&&(i+=" "+l);for(let I=r;I<this.markers.length;I++)if(this.markers[I].compare(a)){s=I,c=!0;break}}else s=this.markers.length;for(;r<s;){let l=this.markers[r++];if(l.toDOM){l.destroy(n);let I=n.nextSibling;n.remove(),n=I}}if(!a)break;a.toDOM&&(c?n=n.nextSibling:this.dom.insertBefore(a.toDOM(e),n)),c&&r++}this.dom.className=i,this.markers=A}destroy(){this.setMarkers(null,[])}};function TLA(t,e){if(t.length!=e.length)return!1;for(let A=0;A<t.length;A++)if(!t[A].compare(e[A]))return!1;return!0}var zLA=Te.define(),HLA=Te.define(),fE=Te.define({combine(t){return zr(t,{formatNumber:String,domEventHandlers:{}},{domEventHandlers(e,A){let i=Object.assign({},e);for(let n in A){let o=i[n],r=A[n];i[n]=o?(s,a,c)=>o(s,a,c)||r(s,a,c):r}return i}})}}),K4=class extends ya{constructor(e){super(),this.number=e}eq(e){return this.number==e.number}toDOM(){return document.createTextNode(this.number)}};function ox(t,e){return t.state.facet(fE).formatNumber(e,t.state)}var OLA=U4.compute([fE],t=>({class:"cm-lineNumbers",renderEmptyElements:!1,markers(e){return e.state.facet(zLA)},lineMarker(e,A,i){return i.some(n=>n.toDOM)?null:new K4(ox(e,e.state.doc.lineAt(A.from).number))},widgetMarker:(e,A,i)=>{for(let n of e.state.facet(HLA)){let o=n(e,A,i);if(o)return o}return null},lineMarkerChange:e=>e.startState.facet(fE)!=e.state.facet(fE),initialSpacer(e){return new K4(ox(e,TeA(e.state.doc.lines)))},updateSpacer(e,A){let i=ox(A.view,TeA(A.view.state.doc.lines));return i==e.number?e:new K4(i)},domEventHandlers:t.facet(fE).domEventHandlers}));function ZtA(t={}){return[fE.of(t),VtA(),OLA]}function TeA(t){let e=9;for(;e<t;)e=e*10+9;return e}var PLA=new class extends ya{constructor(){super(...arguments),this.elementClass="cm-activeLineGutter"}},jLA=uw.compute(["selection"],t=>{let e=[],A=-1;for(let i of t.selection.ranges){let n=t.doc.lineAt(i.head).from;n>A&&(A=n,e.push(PLA.range(n)))}return Zn.of(e)});function WtA(){return jLA}var qLA=0,Z4=class{constructor(e,A){this.from=e,this.to=A}},si=class{constructor(e={}){this.id=qLA++,this.perNode=!!e.perNode,this.deserialize=e.deserialize||(()=>{throw new Error("This node type doesn't define a deserialize function")})}add(e){if(this.perNode)throw new RangeError("Can't add per-node props to node types");return typeof e!="function"&&(e=ws.match(e)),A=>{let i=e(A);return i===void 0?null:[this,i]}}};si.closedBy=new si({deserialize:t=>t.split(" ")});si.openedBy=new si({deserialize:t=>t.split(" ")});si.group=new si({deserialize:t=>t.split(" ")});si.isolate=new si({deserialize:t=>{if(t&&t!="rtl"&&t!="ltr"&&t!="auto")throw new RangeError("Invalid value for isolate: "+t);return t||"auto"}});si.contextHash=new si({perNode:!0});si.lookAhead=new si({perNode:!0});si.mounted=new si({perNode:!0});var yE=class{constructor(e,A,i){this.tree=e,this.overlay=A,this.parser=i}static get(e){return e&&e.props&&e.props[si.mounted.id]}},VLA=Object.create(null),ws=class t{constructor(e,A,i,n=0){this.name=e,this.props=A,this.id=i,this.flags=n}static define(e){let A=e.props&&e.props.length?Object.create(null):VLA,i=(e.top?1:0)|(e.skipped?2:0)|(e.error?4:0)|(e.name==null?8:0),n=new t(e.name||"",A,e.id,i);if(e.props){for(let o of e.props)if(Array.isArray(o)||(o=o(n)),o){if(o[0].perNode)throw new RangeError("Can't store a per-node prop on a node type");A[o[0].id]=o[1]}}return n}prop(e){return this.props[e.id]}get isTop(){return(this.flags&1)>0}get isSkipped(){return(this.flags&2)>0}get isError(){return(this.flags&4)>0}get isAnonymous(){return(this.flags&8)>0}is(e){if(typeof e=="string"){if(this.name==e)return!0;let A=this.prop(si.group);return A?A.indexOf(e)>-1:!1}return this.id==e}static match(e){let A=Object.create(null);for(let i in e)for(let n of i.split(" "))A[n]=e[i];return i=>{for(let n=i.prop(si.group),o=-1;o<(n?n.length:0);o++){let r=A[o<0?i.name:n[o]];if(r)return r}}}};ws.none=new ws("",Object.create(null),0,8);var W4=class t{constructor(e){this.types=e;for(let A=0;A<e.length;A++)if(e[A].id!=A)throw new RangeError("Node type ids should correspond to array positions when creating a node set")}extend(...e){let A=[];for(let i of this.types){let n=null;for(let o of e){let r=o(i);r&&(n||(n=Object.assign({},i.props)),n[r[0].id]=r[1])}A.push(n?new ws(i.name,n,i.id,i.flags):i)}return new t(A)}},Kw=new WeakMap,XtA=new WeakMap,Fr=function(t){return t[t.ExcludeBuffers=1]="ExcludeBuffers",t[t.IncludeAnonymous=2]="IncludeAnonymous",t[t.IgnoreMounts=4]="IgnoreMounts",t[t.IgnoreOverlays=8]="IgnoreOverlays",t}(Fr||{}),Cr=class t{constructor(e,A,i,n,o){if(this.type=e,this.children=A,this.positions=i,this.length=n,this.props=null,o&&o.length){this.props=Object.create(null);for(let[r,s]of o)this.props[typeof r=="number"?r:r.id]=s}}toString(){let e=yE.get(this);if(e&&!e.overlay)return e.tree.toString();let A="";for(let i of this.children){let n=i.toString();n&&(A&&(A+=","),A+=n)}return this.type.name?(/\W/.test(this.type.name)&&!this.type.isError?JSON.stringify(this.type.name):this.type.name)+(A.length?"("+A+")":""):A}cursor(e=0){return new A3(this.topNode,e)}cursorAt(e,A=0,i=0){let n=Kw.get(this)||this.topNode,o=new A3(n);return o.moveTo(e,A),Kw.set(this,o._tree),o}get topNode(){return new vg(this,0,0,null)}resolve(e,A=0){let i=X4(Kw.get(this)||this.topNode,e,A,!1);return Kw.set(this,i),i}resolveInner(e,A=0){let i=X4(XtA.get(this)||this.topNode,e,A,!0);return XtA.set(this,i),i}resolveStack(e,A=0){return ZLA(this,e,A)}iterate(e){let{enter:A,leave:i,from:n=0,to:o=this.length}=e,r=e.mode||0,s=(r&Fr.IncludeAnonymous)>0;for(let a=this.cursor(r|Fr.IncludeAnonymous);;){let c=!1;if(a.from<=o&&a.to>=n&&(!s&&a.type.isAnonymous||A(a)!==!1)){if(a.firstChild())continue;c=!0}for(;c&&i&&(s||!a.type.isAnonymous)&&i(a),!a.nextSibling();){if(!a.parent())return;c=!0}}}prop(e){return e.perNode?this.props?this.props[e.id]:void 0:this.type.prop(e)}get propValues(){let e=[];if(this.props)for(let A in this.props)e.push([+A,this.props[A]]);return e}balance(e={}){return this.children.length<=8?this:sF(ws.none,this.children,this.positions,0,this.children.length,0,this.length,(A,i,n)=>new t(this.type,A,i,n,this.propValues),e.makeTree||((A,i,n)=>new t(ws.none,A,i,n)))}static build(e){return WLA(e)}};Cr.empty=new Cr(ws.none,[],[],0);var eF=class t{constructor(e,A){this.buffer=e,this.index=A}get id(){return this.buffer[this.index-4]}get start(){return this.buffer[this.index-3]}get end(){return this.buffer[this.index-2]}get size(){return this.buffer[this.index-1]}get pos(){return this.index}next(){this.index-=4}fork(){return new t(this.buffer,this.index)}},m1=class t{constructor(e,A,i){this.buffer=e,this.length=A,this.set=i}get type(){return ws.none}toString(){let e=[];for(let A=0;A<this.buffer.length;)e.push(this.childString(A)),A=this.buffer[A+3];return e.join(",")}childString(e){let A=this.buffer[e],i=this.buffer[e+3],n=this.set.types[A],o=n.name;if(/\W/.test(o)&&!n.isError&&(o=JSON.stringify(o)),e+=4,i==e)return o;let r=[];for(;e<i;)r.push(this.childString(e)),e=this.buffer[e+3];return o+"("+r.join(",")+")"}findChild(e,A,i,n,o){let{buffer:r}=this,s=-1;for(let a=e;a!=A&&!(eiA(o,n,r[a+1],r[a+2])&&(s=a,i>0));a=r[a+3]);return s}slice(e,A,i){let n=this.buffer,o=new Uint16Array(A-e),r=0;for(let s=e,a=0;s<A;){o[a++]=n[s++],o[a++]=n[s++]-i;let c=o[a++]=n[s++]-i;o[a++]=n[s++]-e,r=Math.max(r,c)}return new t(o,r,this.set)}};function eiA(t,e,A,i){switch(t){case-2:return A<e;case-1:return i>=e&&A<e;case 0:return A<e&&i>e;case 1:return A<=e&&i>e;case 2:return i>e;case 4:return!0}}function X4(t,e,A,i){for(var n;t.from==t.to||(A<1?t.from>=e:t.from>e)||(A>-1?t.to<=e:t.to<e);){let r=!i&&t instanceof vg&&t.index<0?null:t.parent;if(!r)return t;t=r}let o=i?0:Fr.IgnoreOverlays;if(i)for(let r=t,s=r.parent;s;r=s,s=r.parent)r instanceof vg&&r.index<0&&((n=s.enter(e,A,o))===null||n===void 0?void 0:n.from)!=r.from&&(t=s);for(;;){let r=t.enter(e,A,o);if(!r)return t;t=r}}var Jw=class{cursor(e=0){return new A3(this,e)}getChild(e,A=null,i=null){let n=$tA(this,e,A,i);return n.length?n[0]:null}getChildren(e,A=null,i=null){return $tA(this,e,A,i)}resolve(e,A=0){return X4(this,e,A,!1)}resolveInner(e,A=0){return X4(this,e,A,!0)}matchContext(e){return tF(this.parent,e)}enterUnfinishedNodesBefore(e){let A=this.childBefore(e),i=this;for(;A;){let n=A.lastChild;if(!n||n.to!=A.to)break;n.type.isError&&n.from==n.to?(i=A,A=n.prevSibling):A=n}return i}get node(){return this}get next(){return this.parent}},vg=class t extends Jw{constructor(e,A,i,n){super(),this._tree=e,this.from=A,this.index=i,this._parent=n}get type(){return this._tree.type}get name(){return this._tree.type.name}get to(){return this.from+this._tree.length}nextChild(e,A,i,n,o=0){for(let r=this;;){for(let{children:s,positions:a}=r._tree,c=A>0?s.length:-1;e!=c;e+=A){let l=s[e],I=a[e]+r.from;if(eiA(n,i,I,I+l.length)){if(l instanceof m1){if(o&Fr.ExcludeBuffers)continue;let C=l.findChild(0,l.buffer.length,A,i-I,n);if(C>-1)return new $4(new iF(r,l,e,I),null,C)}else if(o&Fr.IncludeAnonymous||!l.type.isAnonymous||rF(l)){let C;if(!(o&Fr.IgnoreMounts)&&(C=yE.get(l))&&!C.overlay)return new t(C.tree,I,e,r);let d=new t(l,I,e,r);return o&Fr.IncludeAnonymous||!d.type.isAnonymous?d:d.nextChild(A<0?l.children.length-1:0,A,i,n)}}}if(o&Fr.IncludeAnonymous||!r.type.isAnonymous||(r.index>=0?e=r.index+A:e=A<0?-1:r._parent._tree.children.length,r=r._parent,!r))return null}}get firstChild(){return this.nextChild(0,1,0,4)}get lastChild(){return this.nextChild(this._tree.children.length-1,-1,0,4)}childAfter(e){return this.nextChild(0,1,e,2)}childBefore(e){return this.nextChild(this._tree.children.length-1,-1,e,-2)}enter(e,A,i=0){let n;if(!(i&Fr.IgnoreOverlays)&&(n=yE.get(this._tree))&&n.overlay){let o=e-this.from;for(let{from:r,to:s}of n.overlay)if((A>0?r<=o:r<o)&&(A<0?s>=o:s>o))return new t(n.tree,n.overlay[0].from+this.from,-1,this)}return this.nextChild(0,1,e,A,i)}nextSignificantParent(){let e=this;for(;e.type.isAnonymous&&e._parent;)e=e._parent;return e}get parent(){return this._parent?this._parent.nextSignificantParent():null}get nextSibling(){return this._parent&&this.index>=0?this._parent.nextChild(this.index+1,1,0,4):null}get prevSibling(){return this._parent&&this.index>=0?this._parent.nextChild(this.index-1,-1,0,4):null}get tree(){return this._tree}toTree(){return this._tree}toString(){return this._tree.toString()}};function $tA(t,e,A,i){let n=t.cursor(),o=[];if(!n.firstChild())return o;if(A!=null){for(let r=!1;!r;)if(r=n.type.is(A),!n.nextSibling())return o}for(;;){if(i!=null&&n.type.is(i))return o;if(n.type.is(e)&&o.push(n.node),!n.nextSibling())return i==null?o:[]}}function tF(t,e,A=e.length-1){for(let i=t;A>=0;i=i.parent){if(!i)return!1;if(!i.type.isAnonymous){if(e[A]&&e[A]!=i.name)return!1;A--}}return!0}var iF=class{constructor(e,A,i,n){this.parent=e,this.buffer=A,this.index=i,this.start=n}},$4=class t extends Jw{get name(){return this.type.name}get from(){return this.context.start+this.context.buffer.buffer[this.index+1]}get to(){return this.context.start+this.context.buffer.buffer[this.index+2]}constructor(e,A,i){super(),this.context=e,this._parent=A,this.index=i,this.type=e.buffer.set.types[e.buffer.buffer[i]]}child(e,A,i){let{buffer:n}=this.context,o=n.findChild(this.index+4,n.buffer[this.index+3],e,A-this.context.start,i);return o<0?null:new t(this.context,this,o)}get firstChild(){return this.child(1,0,4)}get lastChild(){return this.child(-1,0,4)}childAfter(e){return this.child(1,e,2)}childBefore(e){return this.child(-1,e,-2)}enter(e,A,i=0){if(i&Fr.ExcludeBuffers)return null;let{buffer:n}=this.context,o=n.findChild(this.index+4,n.buffer[this.index+3],A>0?1:-1,e-this.context.start,A);return o<0?null:new t(this.context,this,o)}get parent(){return this._parent||this.context.parent.nextSignificantParent()}externalSibling(e){return this._parent?null:this.context.parent.nextChild(this.context.index+e,e,0,4)}get nextSibling(){let{buffer:e}=this.context,A=e.buffer[this.index+3];return A<(this._parent?e.buffer[this._parent.index+3]:e.buffer.length)?new t(this.context,this._parent,A):this.externalSibling(1)}get prevSibling(){let{buffer:e}=this.context,A=this._parent?this._parent.index+4:0;return this.index==A?this.externalSibling(-1):new t(this.context,this._parent,e.findChild(A,this.index,-1,0,4))}get tree(){return null}toTree(){let e=[],A=[],{buffer:i}=this.context,n=this.index+4,o=i.buffer[this.index+3];if(o>n){let r=i.buffer[this.index+1];e.push(i.slice(n,o,r)),A.push(0)}return new Cr(this.type,e,A,this.to-this.from)}toString(){return this.context.buffer.childString(this.index)}};function tiA(t){if(!t.length)return null;let e=0,A=t[0];for(let o=1;o<t.length;o++){let r=t[o];(r.from>A.from||r.to<A.to)&&(A=r,e=o)}let i=A instanceof vg&&A.index<0?null:A.parent,n=t.slice();return i?n[e]=i:n.splice(e,1),new nF(n,A)}var nF=class{constructor(e,A){this.heads=e,this.node=A}get next(){return tiA(this.heads)}};function ZLA(t,e,A){let i=t.resolveInner(e,A),n=null;for(let o=i instanceof vg?i:i.context.parent;o;o=o.parent)if(o.index<0){let r=o.parent;(n||(n=[i])).push(r.resolve(e,A)),o=r}else{let r=yE.get(o.tree);if(r&&r.overlay&&r.overlay[0].from<=e&&r.overlay[r.overlay.length-1].to>=e){let s=new vg(r.tree,r.overlay[0].from+o.from,-1,o);(n||(n=[i])).push(X4(s,e,A,!1))}}return n?tiA(n):i}var A3=class{get name(){return this.type.name}constructor(e,A=0){if(this.mode=A,this.buffer=null,this.stack=[],this.index=0,this.bufferNode=null,e instanceof vg)this.yieldNode(e);else{this._tree=e.context.parent,this.buffer=e.context;for(let i=e._parent;i;i=i._parent)this.stack.unshift(i.index);this.bufferNode=e,this.yieldBuf(e.index)}}yieldNode(e){return e?(this._tree=e,this.type=e.type,this.from=e.from,this.to=e.to,!0):!1}yieldBuf(e,A){this.index=e;let{start:i,buffer:n}=this.buffer;return this.type=A||n.set.types[n.buffer[e]],this.from=i+n.buffer[e+1],this.to=i+n.buffer[e+2],!0}yield(e){return e?e instanceof vg?(this.buffer=null,this.yieldNode(e)):(this.buffer=e.context,this.yieldBuf(e.index,e.type)):!1}toString(){return this.buffer?this.buffer.buffer.childString(this.index):this._tree.toString()}enterChild(e,A,i){if(!this.buffer)return this.yield(this._tree.nextChild(e<0?this._tree._tree.children.length-1:0,e,A,i,this.mode));let{buffer:n}=this.buffer,o=n.findChild(this.index+4,n.buffer[this.index+3],e,A-this.buffer.start,i);return o<0?!1:(this.stack.push(this.index),this.yieldBuf(o))}firstChild(){return this.enterChild(1,0,4)}lastChild(){return this.enterChild(-1,0,4)}childAfter(e){return this.enterChild(1,e,2)}childBefore(e){return this.enterChild(-1,e,-2)}enter(e,A,i=this.mode){return this.buffer?i&Fr.ExcludeBuffers?!1:this.enterChild(1,e,A):this.yield(this._tree.enter(e,A,i))}parent(){if(!this.buffer)return this.yieldNode(this.mode&Fr.IncludeAnonymous?this._tree._parent:this._tree.parent);if(this.stack.length)return this.yieldBuf(this.stack.pop());let e=this.mode&Fr.IncludeAnonymous?this.buffer.parent:this.buffer.parent.nextSignificantParent();return this.buffer=null,this.yieldNode(e)}sibling(e){if(!this.buffer)return this._tree._parent?this.yield(this._tree.index<0?null:this._tree._parent.nextChild(this._tree.index+e,e,0,4,this.mode)):!1;let{buffer:A}=this.buffer,i=this.stack.length-1;if(e<0){let n=i<0?0:this.stack[i]+4;if(this.index!=n)return this.yieldBuf(A.findChild(n,this.index,-1,0,4))}else{let n=A.buffer[this.index+3];if(n<(i<0?A.buffer.length:A.buffer[this.stack[i]+3]))return this.yieldBuf(n)}return i<0?this.yield(this.buffer.parent.nextChild(this.buffer.index+e,e,0,4,this.mode)):!1}nextSibling(){return this.sibling(1)}prevSibling(){return this.sibling(-1)}atLastNode(e){let A,i,{buffer:n}=this;if(n){if(e>0){if(this.index<n.buffer.buffer.length)return!1}else for(let o=0;o<this.index;o++)if(n.buffer.buffer[o+3]<this.index)return!1;({index:A,parent:i}=n)}else({index:A,_parent:i}=this._tree);for(;i;{index:A,_parent:i}=i)if(A>-1)for(let o=A+e,r=e<0?-1:i._tree.children.length;o!=r;o+=e){let s=i._tree.children[o];if(this.mode&Fr.IncludeAnonymous||s instanceof m1||!s.type.isAnonymous||rF(s))return!1}return!0}move(e,A){if(A&&this.enterChild(e,0,4))return!0;for(;;){if(this.sibling(e))return!0;if(this.atLastNode(e)||!this.parent())return!1}}next(e=!0){return this.move(1,e)}prev(e=!0){return this.move(-1,e)}moveTo(e,A=0){for(;(this.from==this.to||(A<1?this.from>=e:this.from>e)||(A>-1?this.to<=e:this.to<e))&&this.parent(););for(;this.enterChild(1,e,A););return this}get node(){if(!this.buffer)return this._tree;let e=this.bufferNode,A=null,i=0;if(e&&e.context==this.buffer)A:for(let n=this.index,o=this.stack.length;o>=0;){for(let r=e;r;r=r._parent)if(r.index==n){if(n==this.index)return r;A=r,i=o+1;break A}n=this.stack[--o]}for(let n=i;n<this.stack.length;n++)A=new $4(this.buffer,A,this.stack[n]);return this.bufferNode=new $4(this.buffer,A,this.index)}get tree(){return this.buffer?null:this._tree._tree}iterate(e,A){for(let i=0;;){let n=!1;if(this.type.isAnonymous||e(this)!==!1){if(this.firstChild()){i++;continue}this.type.isAnonymous||(n=!0)}for(;;){if(n&&A&&A(this),n=this.type.isAnonymous,!i)return;if(this.nextSibling())break;this.parent(),i--,n=!0}}}matchContext(e){if(!this.buffer)return tF(this.node.parent,e);let{buffer:A}=this.buffer,{types:i}=A.set;for(let n=e.length-1,o=this.stack.length-1;n>=0;o--){if(o<0)return tF(this._tree,e,n);let r=i[A.buffer[this.stack[o]]];if(!r.isAnonymous){if(e[n]&&e[n]!=r.name)return!1;n--}}return!0}};function rF(t){return t.children.some(e=>e instanceof m1||!e.type.isAnonymous||rF(e))}function WLA(t){var e;let{buffer:A,nodeSet:i,maxBufferLength:n=1024,reused:o=[],minRepeatType:r=i.types.length}=t,s=Array.isArray(A)?new eF(A,A.length):A,a=i.types,c=0,l=0;function I(y,F,U,T,N,K){let{id:H,start:j,end:IA,size:lA}=s,uA=l,p=c;for(;lA<0;)if(s.next(),lA==-1){let VA=o[H];U.push(VA),T.push(j-y);return}else if(lA==-3){c=H;return}else if(lA==-4){l=H;return}else throw new RangeError(`Unrecognized record size: ${lA}`);let V=a[H],cA,aA,jA=j-y;if(IA-j<=n&&(aA=Q(s.pos-F,N))){let VA=new Uint16Array(aA.size-aA.skip),ce=s.pos-aA.size,EA=VA.length;for(;s.pos>ce;)EA=u(aA.start,VA,EA);cA=new m1(VA,IA-aA.start,i),jA=aA.start-y}else{let VA=s.pos-lA;s.next();let ce=[],EA=[],sA=H>=r?H:-1,TA=0,Ke=IA;for(;s.pos>VA;)sA>=0&&s.id==sA&&s.size>=0?(s.end<=Ke-n&&(B(ce,EA,j,TA,s.end,Ke,sA,uA,p),TA=ce.length,Ke=s.end),s.next()):K>2500?C(j,VA,ce,EA):I(j,VA,ce,EA,sA,K+1);if(sA>=0&&TA>0&&TA<ce.length&&B(ce,EA,j,TA,j,Ke,sA,uA,p),ce.reverse(),EA.reverse(),sA>-1&&TA>0){let Re=d(V,p);cA=sF(V,ce,EA,0,ce.length,0,IA-j,Re,Re)}else cA=E(V,ce,EA,IA-j,uA-IA,p)}U.push(cA),T.push(jA)}function C(y,F,U,T){let N=[],K=0,H=-1;for(;s.pos>F;){let{id:j,start:IA,end:lA,size:uA}=s;if(uA>4)s.next();else{if(H>-1&&IA<H)break;H<0&&(H=lA-n),N.push(j,IA,lA),K++,s.next()}}if(K){let j=new Uint16Array(K*4),IA=N[N.length-2];for(let lA=N.length-3,uA=0;lA>=0;lA-=3)j[uA++]=N[lA],j[uA++]=N[lA+1]-IA,j[uA++]=N[lA+2]-IA,j[uA++]=uA;U.push(new m1(j,N[2]-IA,i)),T.push(IA-y)}}function d(y,F){return(U,T,N)=>{let K=0,H=U.length-1,j,IA;if(H>=0&&(j=U[H])instanceof Cr){if(!H&&j.type==y&&j.length==N)return j;(IA=j.prop(si.lookAhead))&&(K=T[H]+j.length+IA)}return E(y,U,T,N,K,F)}}function B(y,F,U,T,N,K,H,j,IA){let lA=[],uA=[];for(;y.length>T;)lA.push(y.pop()),uA.push(F.pop()+U-N);y.push(E(i.types[H],lA,uA,K-N,j-K,IA)),F.push(N-U)}function E(y,F,U,T,N,K,H){if(K){let j=[si.contextHash,K];H=H?[j].concat(H):[j]}if(N>25){let j=[si.lookAhead,N];H=H?[j].concat(H):[j]}return new Cr(y,F,U,T,H)}function Q(y,F){let U=s.fork(),T=0,N=0,K=0,H=U.end-n,j={size:0,start:0,skip:0};A:for(let IA=U.pos-y;U.pos>IA;){let lA=U.size;if(U.id==F&&lA>=0){j.size=T,j.start=N,j.skip=K,K+=4,T+=4,U.next();continue}let uA=U.pos-lA;if(lA<0||uA<IA||U.start<H)break;let p=U.id>=r?4:0,V=U.start;for(U.next();U.pos>uA;){if(U.size<0)if(U.size==-3)p+=4;else break A;else U.id>=r&&(p+=4);U.next()}N=V,T+=lA,K+=p}return(F<0||T==y)&&(j.size=T,j.start=N,j.skip=K),j.size>4?j:void 0}function u(y,F,U){let{id:T,start:N,end:K,size:H}=s;if(s.next(),H>=0&&T<r){let j=U;if(H>4){let IA=s.pos-(H-4);for(;s.pos>IA;)U=u(y,F,U)}F[--U]=j,F[--U]=K-y,F[--U]=N-y,F[--U]=T}else H==-3?c=T:H==-4&&(l=T);return U}let v=[],L=[];for(;s.pos>0;)I(t.start||0,t.bufferStart||0,v,L,-1,0);let x=(e=t.length)!==null&&e!==void 0?e:v.length?L[0]+v[0].length:0;return new Cr(a[t.topID],v.reverse(),L.reverse(),x)}var AiA=new WeakMap;function Yw(t,e){if(!t.isAnonymous||e instanceof m1||e.type!=t)return 1;let A=AiA.get(e);if(A==null){A=1;for(let i of e.children){if(i.type!=t||!(i instanceof Cr)){A=1;break}A+=Yw(t,i)}AiA.set(e,A)}return A}function sF(t,e,A,i,n,o,r,s,a){let c=0;for(let B=i;B<n;B++)c+=Yw(t,e[B]);let l=Math.ceil(c*1.5/8),I=[],C=[];function d(B,E,Q,u,v){for(let L=Q;L<u;){let x=L,y=E[L],F=Yw(t,B[L]);for(L++;L<u;L++){let U=Yw(t,B[L]);if(F+U>=l)break;F+=U}if(L==x+1){if(F>l){let U=B[x];d(U.children,U.positions,0,U.children.length,E[x]+v);continue}I.push(B[x])}else{let U=E[L-1]+B[L-1].length-y;I.push(sF(t,B,E,x,L,y,U,null,a))}C.push(y+v-o)}}return d(e,A,i,n,0),(s||a)(I,C,r)}var EC=class t{constructor(e,A,i,n,o=!1,r=!1){this.from=e,this.to=A,this.tree=i,this.offset=n,this.open=(o?1:0)|(r?2:0)}get openStart(){return(this.open&1)>0}get openEnd(){return(this.open&2)>0}static addTree(e,A=[],i=!1){let n=[new t(0,e.length,e,0,!1,i)];for(let o of A)o.to>e.length&&n.push(o);return n}static applyChanges(e,A,i=128){if(!A.length)return e;let n=[],o=1,r=e.length?e[0]:null;for(let s=0,a=0,c=0;;s++){let l=s<A.length?A[s]:null,I=l?l.fromA:1e9;if(I-a>=i)for(;r&&r.from<I;){let C=r;if(a>=C.from||I<=C.to||c){let d=Math.max(C.from,a)-c,B=Math.min(C.to,I)-c;C=d>=B?null:new t(d,B,C.tree,C.offset+c,s>0,!!l)}if(C&&n.push(C),r.to>I)break;r=o<e.length?e[o++]:null}if(!l)break;a=l.toA,c=l.toA-l.toB}return n}},vE=class{startParse(e,A,i){return typeof e=="string"&&(e=new oF(e)),i=i?i.length?i.map(n=>new Z4(n.from,n.to)):[new Z4(0,0)]:[new Z4(0,e.length)],this.createParse(e,A||[],i)}parse(e,A,i){let n=this.startParse(e,A,i);for(;;){let o=n.advance();if(o)return o}}},oF=class{constructor(e){this.string=e}get length(){return this.string.length}chunk(e){return this.string.slice(e)}get lineChunks(){return!1}read(e,A){return this.string.slice(e,A)}};var bme=new si({perNode:!0});var XLA=0,hl=class t{constructor(e,A,i,n){this.name=e,this.set=A,this.base=i,this.modified=n,this.id=XLA++}toString(){let{name:e}=this;for(let A of this.modified)A.name&&(e=`${A.name}(${e})`);return e}static define(e,A){let i=typeof e=="string"?e:"?";if(e instanceof t&&(A=e),A?.base)throw new Error("Can not derive from a modified tag");let n=new t(i,[],null,[]);if(n.set.push(n),A)for(let o of A.set)n.set.push(o);return n}static defineModifier(e){let A=new Ow(e);return i=>i.modified.indexOf(A)>-1?i:Ow.get(i.base||i,i.modified.concat(A).sort((n,o)=>n.id-o.id))}},$LA=0,Ow=class t{constructor(e){this.name=e,this.instances=[],this.id=$LA++}static get(e,A){if(!A.length)return e;let i=A[0].instances.find(s=>s.base==e&&AxA(A,s.modified));if(i)return i;let n=[],o=new hl(e.name,n,e,A);for(let s of A)s.instances.push(o);let r=exA(A);for(let s of e.set)if(!s.modified.length)for(let a of r)n.push(t.get(s,a));return o}};function AxA(t,e){return t.length==e.length&&t.every((A,i)=>A==e[i])}function exA(t){let e=[[]];for(let A=0;A<t.length;A++)for(let i=0,n=e.length;i<n;i++)e.push(e[i].concat(t[A]));return e.sort((A,i)=>i.length-A.length)}function Pw(t){let e=Object.create(null);for(let A in t){let i=t[A];Array.isArray(i)||(i=[i]);for(let n of A.split(" "))if(n){let o=[],r=2,s=n;for(let I=0;;){if(s=="..."&&I>0&&I+3==n.length){r=1;break}let C=/^"(?:[^"\\]|\\.)*?"|[^\/!]+/.exec(s);if(!C)throw new RangeError("Invalid path: "+n);if(o.push(C[0]=="*"?"":C[0][0]=='"'?JSON.parse(C[0]):C[0]),I+=C[0].length,I==n.length)break;let d=n[I++];if(I==n.length&&d=="!"){r=0;break}if(d!="/")throw new RangeError("Invalid path: "+n);s=n.slice(I)}let a=o.length-1,c=o[a];if(!c)throw new RangeError("Invalid path: "+n);let l=new bE(i,r,a>0?o.slice(0,a):null);e[c]=l.sort(e[c])}}return oiA.add(e)}var oiA=new si,bE=class{constructor(e,A,i,n){this.tags=e,this.mode=A,this.context=i,this.next=n}get opaque(){return this.mode==0}get inherit(){return this.mode==1}sort(e){return!e||e.depth<this.depth?(this.next=e,this):(e.next=this.sort(e.next),e)}get depth(){return this.context?this.context.length:0}};bE.empty=new bE([],2,null);function gF(t,e){let A=Object.create(null);for(let o of t)if(!Array.isArray(o.tag))A[o.tag.id]=o.class;else for(let r of o.tag)A[r.id]=o.class;let{scope:i,all:n=null}=e||{};return{style:o=>{let r=n;for(let s of o)for(let a of s.set){let c=A[a.id];if(c){r=r?r+" "+c:c;break}}return r},scope:i}}function txA(t,e){let A=null;for(let i of t){let n=i.style(e);n&&(A=A?A+" "+n:n)}return A}function riA(t,e,A,i=0,n=t.length){let o=new cF(i,Array.isArray(e)?e:[e],A);o.highlightRange(t.cursor(),i,n,"",o.highlighters),o.flush(n)}var cF=class{constructor(e,A,i){this.at=e,this.highlighters=A,this.span=i,this.class=""}startSpan(e,A){A!=this.class&&(this.flush(e),e>this.at&&(this.at=e),this.class=A)}flush(e){e>this.at&&this.class&&this.span(this.at,e,this.class)}highlightRange(e,A,i,n,o){let{type:r,from:s,to:a}=e;if(s>=i||a<=A)return;r.isTop&&(o=this.highlighters.filter(d=>!d.scope||d.scope(r)));let c=n,l=ixA(e)||bE.empty,I=txA(o,l.tags);if(I&&(c&&(c+=" "),c+=I,l.mode==1&&(n+=(n?" ":"")+I)),this.startSpan(Math.max(A,s),c),l.opaque)return;let C=e.tree&&e.tree.prop(si.mounted);if(C&&C.overlay){let d=e.node.enter(C.overlay[0].from+s,1),B=this.highlighters.filter(Q=>!Q.scope||Q.scope(C.tree.type)),E=e.firstChild();for(let Q=0,u=s;;Q++){let v=Q<C.overlay.length?C.overlay[Q]:null,L=v?v.from+s:a,x=Math.max(A,u),y=Math.min(i,L);if(x<y&&E)for(;e.from<y&&(this.highlightRange(e,x,y,n,o),this.startSpan(Math.min(y,e.to),c),!(e.to>=L||!e.nextSibling())););if(!v||L>i)break;u=v.to+s,u>A&&(this.highlightRange(d.cursor(),Math.max(A,v.from+s),Math.min(i,u),"",B),this.startSpan(Math.min(i,u),c))}E&&e.parent()}else if(e.firstChild()){C&&(n="");do if(!(e.to<=A)){if(e.from>=i)break;this.highlightRange(e,A,i,n,o),this.startSpan(Math.min(i,e.to),c)}while(e.nextSibling());e.parent()}}};function ixA(t){let e=t.type.prop(oiA);for(;e&&e.context&&!t.matchContext(e.context);)e=e.next;return e||null}var Ue=hl.define,Tw=Ue(),p1=Ue(),iiA=Ue(p1),niA=Ue(p1),w1=Ue(),zw=Ue(w1),aF=Ue(w1),kg=Ue(),hC=Ue(kg),bg=Ue(),Mg=Ue(),lF=Ue(),e3=Ue(lF),Hw=Ue(),we={comment:Tw,lineComment:Ue(Tw),blockComment:Ue(Tw),docComment:Ue(Tw),name:p1,variableName:Ue(p1),typeName:iiA,tagName:Ue(iiA),propertyName:niA,attributeName:Ue(niA),className:Ue(p1),labelName:Ue(p1),namespace:Ue(p1),macroName:Ue(p1),literal:w1,string:zw,docString:Ue(zw),character:Ue(zw),attributeValue:Ue(zw),number:aF,integer:Ue(aF),float:Ue(aF),bool:Ue(w1),regexp:Ue(w1),escape:Ue(w1),color:Ue(w1),url:Ue(w1),keyword:bg,self:Ue(bg),null:Ue(bg),atom:Ue(bg),unit:Ue(bg),modifier:Ue(bg),operatorKeyword:Ue(bg),controlKeyword:Ue(bg),definitionKeyword:Ue(bg),moduleKeyword:Ue(bg),operator:Mg,derefOperator:Ue(Mg),arithmeticOperator:Ue(Mg),logicOperator:Ue(Mg),bitwiseOperator:Ue(Mg),compareOperator:Ue(Mg),updateOperator:Ue(Mg),definitionOperator:Ue(Mg),typeOperator:Ue(Mg),controlOperator:Ue(Mg),punctuation:lF,separator:Ue(lF),bracket:e3,angleBracket:Ue(e3),squareBracket:Ue(e3),paren:Ue(e3),brace:Ue(e3),content:kg,heading:hC,heading1:Ue(hC),heading2:Ue(hC),heading3:Ue(hC),heading4:Ue(hC),heading5:Ue(hC),heading6:Ue(hC),contentSeparator:Ue(kg),list:Ue(kg),quote:Ue(kg),emphasis:Ue(kg),strong:Ue(kg),link:Ue(kg),monospace:Ue(kg),strikethrough:Ue(kg),inserted:Ue(),deleted:Ue(),changed:Ue(),invalid:Ue(),meta:Hw,documentMeta:Ue(Hw),annotation:Ue(Hw),processingInstruction:Ue(Hw),definition:hl.defineModifier("definition"),constant:hl.defineModifier("constant"),function:hl.defineModifier("function"),standard:hl.defineModifier("standard"),local:hl.defineModifier("local"),special:hl.defineModifier("special")};for(let t in we){let e=we[t];e instanceof hl&&(e.name=t)}var Sme=gF([{tag:we.link,class:"tok-link"},{tag:we.heading,class:"tok-heading"},{tag:we.emphasis,class:"tok-emphasis"},{tag:we.strong,class:"tok-strong"},{tag:we.keyword,class:"tok-keyword"},{tag:we.atom,class:"tok-atom"},{tag:we.bool,class:"tok-bool"},{tag:we.url,class:"tok-url"},{tag:we.labelName,class:"tok-labelName"},{tag:we.inserted,class:"tok-inserted"},{tag:we.deleted,class:"tok-deleted"},{tag:we.literal,class:"tok-literal"},{tag:we.string,class:"tok-string"},{tag:we.number,class:"tok-number"},{tag:[we.regexp,we.escape,we.special(we.string)],class:"tok-string2"},{tag:we.variableName,class:"tok-variableName"},{tag:we.local(we.variableName),class:"tok-variableName tok-local"},{tag:we.definition(we.variableName),class:"tok-variableName tok-definition"},{tag:we.special(we.variableName),class:"tok-variableName2"},{tag:we.definition(we.propertyName),class:"tok-propertyName tok-definition"},{tag:we.typeName,class:"tok-typeName"},{tag:we.namespace,class:"tok-namespace"},{tag:we.className,class:"tok-className"},{tag:we.macroName,class:"tok-macroName"},{tag:we.propertyName,class:"tok-propertyName"},{tag:we.operator,class:"tok-operator"},{tag:we.comment,class:"tok-comment"},{tag:we.meta,class:"tok-meta"},{tag:we.invalid,class:"tok-invalid"},{tag:we.punctuation,class:"tok-punctuation"}]);var IF,ME=new si;function nxA(t){return Te.define({combine:t?e=>e.concat(t):void 0})}var oxA=new si,Sg=(()=>{class t{constructor(A,i,n=[],o=""){this.data=A,this.name=o,Ir.prototype.hasOwnProperty("tree")||Object.defineProperty(Ir.prototype,"tree",{get(){return Or(this)}}),this.parser=i,this.extension=[D1.of(this),Ir.languageData.of((r,s,a)=>{let c=siA(r,s,a),l=c.type.prop(ME);if(!l)return[];let I=r.facet(l),C=c.type.prop(oxA);if(C){let d=c.resolve(s-c.from,a);for(let B of C)if(B.test(d,r)){let E=r.facet(B.facet);return B.type=="replace"?E:E.concat(I)}}return I})].concat(n)}isActiveAt(A,i,n=-1){return siA(A,i,n).type.prop(ME)==this.data}findRegions(A){let i=A.facet(D1);if(i?.data==this.data)return[{from:0,to:A.doc.length}];if(!i||!i.allowsNesting)return[];let n=[],o=(r,s)=>{if(r.prop(ME)==this.data){n.push({from:s,to:s+r.length});return}let a=r.prop(si.mounted);if(a){if(a.tree.prop(ME)==this.data){if(a.overlay)for(let c of a.overlay)n.push({from:c.from+s,to:c.to+s});else n.push({from:s,to:s+r.length});return}else if(a.overlay){let c=n.length;if(o(a.tree,a.overlay[0].from+s),n.length>c)return}}for(let c=0;c<r.children.length;c++){let l=r.children[c];l instanceof Cr&&o(l,r.positions[c]+s)}};return o(Or(A),0),n}get allowsNesting(){return!0}}return t.setState=ki.define(),t})();function siA(t,e,A){let i=t.facet(D1),n=Or(t).topNode;if(!i||i.allowsNesting)for(let o=n;o;o=o.enter(e,A,Fr.ExcludeBuffers))o.type.isTop&&(n=o);return n}var jw=class t extends Sg{constructor(e,A,i){super(e,A,[],i),this.parser=A}static define(e){let A=nxA(e.languageData);return new t(A,e.parser.configure({props:[ME.add(i=>i.isTop?A:void 0)]}),e.name)}configure(e,A){return new t(this.data,this.parser.configure(e),A||this.name)}get allowsNesting(){return this.parser.hasWrappers()}};function Or(t){let e=t.field(Sg.state,!1);return e?e.tree:Cr.empty}var EF=class{constructor(e){this.doc=e,this.cursorPos=0,this.string="",this.cursor=e.iter()}get length(){return this.doc.length}syncTo(e){return this.string=this.cursor.next(e-this.cursorPos).value,this.cursorPos=e+this.string.length,this.cursorPos-this.string.length}chunk(e){return this.syncTo(e),this.string}get lineChunks(){return!0}read(e,A){let i=this.cursorPos-this.string.length;return e<i||A>=this.cursorPos?this.doc.sliceString(e,A):this.string.slice(e-i,A-i)}},t3=null,hF=class t{constructor(e,A,i=[],n,o,r,s,a){this.parser=e,this.state=A,this.fragments=i,this.tree=n,this.treeLen=o,this.viewport=r,this.skipped=s,this.scheduleOn=a,this.parse=null,this.tempSkipped=[]}static create(e,A,i){return new t(e,A,[],Cr.empty,0,i,[],null)}startParse(){return this.parser.startParse(new EF(this.state.doc),this.fragments)}work(e,A){return A!=null&&A>=this.state.doc.length&&(A=void 0),this.tree!=Cr.empty&&this.isDone(A??this.state.doc.length)?(this.takeTree(),!0):this.withContext(()=>{var i;if(typeof e=="number"){let n=Date.now()+e;e=()=>Date.now()>n}for(this.parse||(this.parse=this.startParse()),A!=null&&(this.parse.stoppedAt==null||this.parse.stoppedAt>A)&&A<this.state.doc.length&&this.parse.stopAt(A);;){let n=this.parse.advance();if(n)if(this.fragments=this.withoutTempSkipped(EC.addTree(n,this.fragments,this.parse.stoppedAt!=null)),this.treeLen=(i=this.parse.stoppedAt)!==null&&i!==void 0?i:this.state.doc.length,this.tree=n,this.parse=null,this.treeLen<(A??this.state.doc.length))this.parse=this.startParse();else return!0;if(e())return!1}})}takeTree(){let e,A;this.parse&&(e=this.parse.parsedPos)>=this.treeLen&&((this.parse.stoppedAt==null||this.parse.stoppedAt>e)&&this.parse.stopAt(e),this.withContext(()=>{for(;!(A=this.parse.advance()););}),this.treeLen=e,this.tree=A,this.fragments=this.withoutTempSkipped(EC.addTree(this.tree,this.fragments,!0)),this.parse=null)}withContext(e){let A=t3;t3=this;try{return e()}finally{t3=A}}withoutTempSkipped(e){for(let A;A=this.tempSkipped.pop();)e=aiA(e,A.from,A.to);return e}changes(e,A){let{fragments:i,tree:n,treeLen:o,viewport:r,skipped:s}=this;if(this.takeTree(),!e.empty){let a=[];if(e.iterChangedRanges((c,l,I,C)=>a.push({fromA:c,toA:l,fromB:I,toB:C})),i=EC.applyChanges(i,a),n=Cr.empty,o=0,r={from:e.mapPos(r.from,-1),to:e.mapPos(r.to,1)},this.skipped.length){s=[];for(let c of this.skipped){let l=e.mapPos(c.from,1),I=e.mapPos(c.to,-1);l<I&&s.push({from:l,to:I})}}}return new t(this.parser,A,i,n,o,r,s,this.scheduleOn)}updateViewport(e){if(this.viewport.from==e.from&&this.viewport.to==e.to)return!1;this.viewport=e;let A=this.skipped.length;for(let i=0;i<this.skipped.length;i++){let{from:n,to:o}=this.skipped[i];n<e.to&&o>e.from&&(this.fragments=aiA(this.fragments,n,o),this.skipped.splice(i--,1))}return this.skipped.length>=A?!1:(this.reset(),!0)}reset(){this.parse&&(this.takeTree(),this.parse=null)}skipUntilInView(e,A){this.skipped.push({from:e,to:A})}static getSkippingParser(e){return new class extends vE{createParse(A,i,n){let o=n[0].from,r=n[n.length-1].to;return{parsedPos:o,advance(){let a=t3;if(a){for(let c of n)a.tempSkipped.push(c);e&&(a.scheduleOn=a.scheduleOn?Promise.all([a.scheduleOn,e]):e)}return this.parsedPos=r,new Cr(ws.none,[],[],r-o)},stoppedAt:null,stopAt(){}}}}}isDone(e){e=Math.min(e,this.state.doc.length);let A=this.fragments;return this.treeLen>=e&&A.length&&A[0].from==0&&A[0].to>=e}static get(){return t3}};function aiA(t,e,A){return EC.applyChanges(t,[{fromA:e,toA:A,fromB:e,toB:A}])}var n3=class t{constructor(e){this.context=e,this.tree=e.tree}apply(e){if(!e.docChanged&&this.tree==this.context.tree)return this;let A=this.context.changes(e.changes,e.state),i=this.context.treeLen==e.startState.doc.length?void 0:Math.max(e.changes.mapPos(this.context.treeLen),A.viewport.to);return A.work(20,i)||A.takeTree(),new t(A)}static init(e){let A=Math.min(3e3,e.doc.length),i=hF.create(e.facet(D1).parser,e,{from:0,to:A});return i.work(20,A)||i.takeTree(),new t(i)}};Sg.state=To.define({create:n3.init,update(t,e){for(let A of e.effects)if(A.is(Sg.setState))return A.value;return e.startState.facet(D1)!=e.state.facet(D1)?n3.init(e.state):t.apply(e)}});var CiA=t=>{let e=setTimeout(()=>t(),500);return()=>clearTimeout(e)};typeof requestIdleCallback<"u"&&(CiA=t=>{let e=-1,A=setTimeout(()=>{e=requestIdleCallback(t,{timeout:400})},100);return()=>e<0?clearTimeout(A):cancelIdleCallback(e)});var CF=typeof navigator<"u"&&(!((IF=navigator.scheduling)===null||IF===void 0)&&IF.isInputPending)?()=>navigator.scheduling.isInputPending():null,rxA=Xn.fromClass(class{constructor(e){this.view=e,this.working=null,this.workScheduled=0,this.chunkEnd=-1,this.chunkBudget=-1,this.work=this.work.bind(this),this.scheduleWork()}update(e){let A=this.view.state.field(Sg.state).context;(A.updateViewport(e.view.viewport)||this.view.viewport.to>A.treeLen)&&this.scheduleWork(),(e.docChanged||e.selectionSet)&&(this.view.hasFocus&&(this.chunkBudget+=50),this.scheduleWork()),this.checkAsyncSchedule(A)}scheduleWork(){if(this.working)return;let{state:e}=this.view,A=e.field(Sg.state);(A.tree!=A.context.tree||!A.context.isDone(e.doc.length))&&(this.working=CiA(this.work))}work(e){this.working=null;let A=Date.now();if(this.chunkEnd<A&&(this.chunkEnd<0||this.view.hasFocus)&&(this.chunkEnd=A+3e4,this.chunkBudget=3e3),this.chunkBudget<=0)return;let{state:i,viewport:{to:n}}=this.view,o=i.field(Sg.state);if(o.tree==o.context.tree&&o.context.isDone(n+1e5))return;let r=Date.now()+Math.min(this.chunkBudget,100,e&&!CF?Math.max(25,e.timeRemaining()-5):1e9),s=o.context.treeLen<n&&i.doc.length>n+1e3,a=o.context.work(()=>CF&&CF()||Date.now()>r,n+(s?0:1e5));this.chunkBudget-=Date.now()-A,(a||this.chunkBudget<=0)&&(o.context.takeTree(),this.view.dispatch({effects:Sg.setState.of(new n3(o.context))})),this.chunkBudget>0&&!(a&&!s)&&this.scheduleWork(),this.checkAsyncSchedule(o.context)}checkAsyncSchedule(e){e.scheduleOn&&(this.workScheduled++,e.scheduleOn.then(()=>this.scheduleWork()).catch(A=>Hr(this.view.state,A)).then(()=>this.workScheduled--),e.scheduleOn=null)}destroy(){this.working&&this.working()}isWorking(){return!!(this.working||this.workScheduled>0)}},{eventHandlers:{focus(){this.scheduleWork()}}}),D1=Te.define({combine(t){return t.length?t[0]:null},enables:t=>[Sg.state,rxA,St.contentAttributes.compute([t],e=>{let A=e.facet(t);return A&&A.name?{"data-language":A.name}:{}})]}),qw=class{constructor(e,A=[]){this.language=e,this.support=A,this.extension=[e,A]}};var sxA=Te.define(),fC=Te.define({combine:t=>{if(!t.length)return"  ";let e=t[0];if(!e||/\S/.test(e)||Array.from(e).some(A=>A!=e[0]))throw new Error("Invalid indent unit: "+JSON.stringify(t[0]));return e}});function ul(t){let e=t.facet(fC);return e.charCodeAt(0)==9?t.tabSize*e.length:e.length}function SE(t,e){let A="",i=t.tabSize,n=t.facet(fC)[0];if(n=="	"){for(;e>=i;)A+="	",e-=i;n=" "}for(let o=0;o<e;o++)A+=n;return A}function Ww(t,e){t instanceof Ir&&(t=new QC(t));for(let i of t.state.facet(sxA)){let n=i(t,e);if(n!==void 0)return n}let A=Or(t.state);return A.length>=e?axA(t,A,e):null}var QC=class{constructor(e,A={}){this.state=e,this.options=A,this.unit=ul(e)}lineAt(e,A=1){let i=this.state.doc.lineAt(e),{simulateBreak:n,simulateDoubleBreak:o}=this.options;return n!=null&&n>=i.from&&n<=i.to?o&&n==e?{text:"",from:e}:(A<0?n<e:n<=e)?{text:i.text.slice(n-i.from),from:n}:{text:i.text.slice(0,n-i.from),from:i.from}:i}textAfterPos(e,A=1){if(this.options.simulateDoubleBreak&&e==this.options.simulateBreak)return"";let{text:i,from:n}=this.lineAt(e,A);return i.slice(e-n,Math.min(i.length,e+100-n))}column(e,A=1){let{text:i,from:n}=this.lineAt(e,A),o=this.countColumn(i,e-n),r=this.options.overrideIndentation?this.options.overrideIndentation(n):-1;return r>-1&&(o+=r-this.countColumn(i,i.search(/\S|$/))),o}countColumn(e,A=e.length){return G0(e,this.state.tabSize,A)}lineIndent(e,A=1){let{text:i,from:n}=this.lineAt(e,A),o=this.options.overrideIndentation;if(o){let r=o(n);if(r>-1)return r}return this.countColumn(i,i.search(/\S|$/))}get simulatedBreak(){return this.options.simulateBreak||null}},DF=new si;function axA(t,e,A){let i=e.resolveStack(A),n=e.resolveInner(A,-1).resolve(A,0).enterUnfinishedNodesBefore(A);if(n!=i.node){let o=[];for(let r=n;r&&!(r.from<i.node.from||r.to>i.node.to||r.from==i.node.from&&r.type==i.node.type);r=r.parent)o.push(r);for(let r=o.length-1;r>=0;r--)i={node:o[r],next:i}}return diA(i,t,A)}function diA(t,e,A){for(let i=t;i;i=i.next){let n=lxA(i.node);if(n)return n(QF.create(e,A,i))}return 0}function cxA(t){return t.pos==t.options.simulateBreak&&t.options.simulateDoubleBreak}function lxA(t){let e=t.type.prop(DF);if(e)return e;let A=t.firstChild,i;if(A&&(i=A.type.prop(si.closedBy))){let n=t.lastChild,o=n&&i.indexOf(n.name)>-1;return r=>dxA(r,!0,1,void 0,o&&!cxA(r)?n.from:void 0)}return t.parent==null?gxA:null}function gxA(){return 0}var QF=class t extends QC{constructor(e,A,i){super(e.state,e.options),this.base=e,this.pos=A,this.context=i}get node(){return this.context.node}static create(e,A,i){return new t(e,A,i)}get textAfter(){return this.textAfterPos(this.pos)}get baseIndent(){return this.baseIndentFor(this.node)}baseIndentFor(e){let A=this.state.doc.lineAt(e.from);for(;;){let i=e.resolve(A.from);for(;i.parent&&i.parent.from==i.from;)i=i.parent;if(IxA(i,e))break;A=this.state.doc.lineAt(i.from)}return this.lineIndent(A.from)}continue(){return diA(this.context.next,this.base,this.pos)}};function IxA(t,e){for(let A=e;A;A=A.parent)if(t==A)return!0;return!1}function CxA(t){let e=t.node,A=e.childAfter(e.from),i=e.lastChild;if(!A)return null;let n=t.options.simulateBreak,o=t.state.doc.lineAt(A.from),r=n==null||n<=o.from?o.to:Math.min(o.to,n);for(let s=A.to;;){let a=e.childAfter(s);if(!a||a==i)return null;if(!a.type.isSkipped){if(a.from>=r)return null;let c=/^ */.exec(o.text.slice(A.to-o.from))[0].length;return{from:A.from,to:A.to+c}}s=a.to}}function dxA(t,e,A,i,n){let o=t.textAfter,r=o.match(/^\s*/)[0].length,s=i&&o.slice(r,r+i.length)==i||n==t.pos+r,a=e?CxA(t):null;return a?s?t.column(a.from):t.column(a.to):t.baseIndent+(s?0:t.unit*A)}function yF({except:t,units:e=1}={}){return A=>{let i=t&&t.test(A.textAfter);return A.baseIndent+(i?0:e*A.unit)}}var BxA=200;function BiA(){return Ir.transactionFilter.of(t=>{if(!t.docChanged||!t.isUserEvent("input.type")&&!t.isUserEvent("input.complete"))return t;let e=t.startState.languageDataAt("indentOnInput",t.startState.selection.main.head);if(!e.length)return t;let A=t.newDoc,{head:i}=t.newSelection.main,n=A.lineAt(i);if(i>n.from+BxA)return t;let o=A.sliceString(n.from,i);if(!e.some(c=>c.test(o)))return t;let{state:r}=t,s=-1,a=[];for(let{head:c}of r.selection.ranges){let l=r.doc.lineAt(c);if(l.from==s)continue;s=l.from;let I=Ww(r,l.from);if(I==null)continue;let C=/^\s*/.exec(l.text)[0],d=SE(r,I);C!=d&&a.push({from:l.from,to:l.from+C.length,insert:d})}return a.length?[t,{changes:a,sequential:!0}]:t})}var ExA=Te.define(),vF=new si;function EiA(t){let e=t.firstChild,A=t.lastChild;return e&&e.to<A.from?{from:e.to,to:A.type.isError?t.to:A.from}:null}function hxA(t,e,A){let i=Or(t);if(i.length<A)return null;let n=i.resolveStack(A,1),o=null;for(let r=n;r;r=r.next){let s=r.node;if(s.to<=A||s.from>A)continue;if(o&&s.from<e)break;let a=s.type.prop(vF);if(a&&(s.to<i.length-50||i.length==t.doc.length||!QxA(s))){let c=a(s,t);c&&c.from<=A&&c.from>=e&&c.to>A&&(o=c)}}return o}function QxA(t){let e=t.lastChild;return e&&e.to==t.to&&e.type.isError}function Vw(t,e,A){for(let i of t.facet(ExA)){let n=i(t,e,A);if(n)return n}return hxA(t,e,A)}function hiA(t,e){let A=e.mapPos(t.from,1),i=e.mapPos(t.to,-1);return A>=i?void 0:{from:A,to:i}}var Xw=ki.define({map:hiA}),o3=ki.define({map:hiA});function QiA(t){let e=[];for(let{head:A}of t.state.selection.ranges)e.some(i=>i.from<=A&&i.to>=A)||e.push(t.lineBlockAt(A));return e}var uC=To.define({create(){return rt.none},update(t,e){t=t.map(e.changes);for(let A of e.effects)if(A.is(Xw)&&!uxA(t,A.value.from,A.value.to)){let{preparePlaceholder:i}=e.state.facet(bF),n=i?rt.replace({widget:new uF(i(e.state,A.value))}):ciA;t=t.update({add:[n.range(A.value.from,A.value.to)]})}else A.is(o3)&&(t=t.update({filter:(i,n)=>A.value.from!=i||A.value.to!=n,filterFrom:A.value.from,filterTo:A.value.to}));if(e.selection){let A=!1,{head:i}=e.selection.main;t.between(i,i,(n,o)=>{n<i&&o>i&&(A=!0)}),A&&(t=t.update({filterFrom:i,filterTo:i,filter:(n,o)=>o<=i||n>=i}))}return t},provide:t=>St.decorations.from(t),toJSON(t,e){let A=[];return t.between(0,e.doc.length,(i,n)=>{A.push(i,n)}),A},fromJSON(t){if(!Array.isArray(t)||t.length%2)throw new RangeError("Invalid JSON for fold state");let e=[];for(let A=0;A<t.length;){let i=t[A++],n=t[A++];if(typeof i!="number"||typeof n!="number")throw new RangeError("Invalid JSON for fold state");e.push(ciA.range(i,n))}return rt.set(e,!0)}});function Zw(t,e,A){var i;let n=null;return(i=t.field(uC,!1))===null||i===void 0||i.between(e,A,(o,r)=>{(!n||n.from>o)&&(n={from:o,to:r})}),n}function uxA(t,e,A){let i=!1;return t.between(e,e,(n,o)=>{n==e&&o==A&&(i=!0)}),i}function uiA(t,e){return t.field(uC,!1)?e:e.concat(ki.appendConfig.of(piA()))}var fxA=t=>{for(let e of QiA(t)){let A=Vw(t.state,e.from,e.to);if(A)return t.dispatch({effects:uiA(t.state,[Xw.of(A),fiA(t,A)])}),!0}return!1},mxA=t=>{if(!t.state.field(uC,!1))return!1;let e=[];for(let A of QiA(t)){let i=Zw(t.state,A.from,A.to);i&&e.push(o3.of(i),fiA(t,i,!1))}return e.length&&t.dispatch({effects:e}),e.length>0};function fiA(t,e,A=!0){let i=t.state.doc.lineAt(e.from).number,n=t.state.doc.lineAt(e.to).number;return St.announce.of(`${t.state.phrase(A?"Folded lines":"Unfolded lines")} ${i} ${t.state.phrase("to")} ${n}.`)}var pxA=t=>{let{state:e}=t,A=[];for(let i=0;i<e.doc.length;){let n=t.lineBlockAt(i),o=Vw(e,n.from,n.to);o&&A.push(Xw.of(o)),i=(o?t.lineBlockAt(o.to):n).to+1}return A.length&&t.dispatch({effects:uiA(t.state,A)}),!!A.length},wxA=t=>{let e=t.state.field(uC,!1);if(!e||!e.size)return!1;let A=[];return e.between(0,t.state.doc.length,(i,n)=>{A.push(o3.of({from:i,to:n}))}),t.dispatch({effects:A}),!0};var miA=[{key:"Ctrl-Shift-[",mac:"Cmd-Alt-[",run:fxA},{key:"Ctrl-Shift-]",mac:"Cmd-Alt-]",run:mxA},{key:"Ctrl-Alt-[",run:pxA},{key:"Ctrl-Alt-]",run:wxA}],DxA={placeholderDOM:null,preparePlaceholder:null,placeholderText:"\u2026"},bF=Te.define({combine(t){return zr(t,DxA)}});function piA(t){let e=[uC,vxA];return t&&e.push(bF.of(t)),e}function wiA(t,e){let{state:A}=t,i=A.facet(bF),n=r=>{let s=t.lineBlockAt(t.posAtDOM(r.target)),a=Zw(t.state,s.from,s.to);a&&t.dispatch({effects:o3.of(a)}),r.preventDefault()};if(i.placeholderDOM)return i.placeholderDOM(t,n,e);let o=document.createElement("span");return o.textContent=i.placeholderText,o.setAttribute("aria-label",A.phrase("folded code")),o.title=A.phrase("unfold"),o.className="cm-foldPlaceholder",o.onclick=n,o}var ciA=rt.replace({widget:new class extends nc{toDOM(t){return wiA(t,null)}}}),uF=class extends nc{constructor(e){super(),this.value=e}eq(e){return this.value==e.value}toDOM(e){return wiA(e,this.value)}},yxA={openText:"\u2304",closedText:"\u203A",markerDOM:null,domEventHandlers:{},foldingChanged:()=>!1},i3=class extends ya{constructor(e,A){super(),this.config=e,this.open=A}eq(e){return this.config==e.config&&this.open==e.open}toDOM(e){if(this.config.markerDOM)return this.config.markerDOM(this.open);let A=document.createElement("span");return A.textContent=this.open?this.config.openText:this.config.closedText,A.title=e.state.phrase(this.open?"Fold line":"Unfold line"),A}};function DiA(t={}){let e=nA(nA({},yxA),t),A=new i3(e,!0),i=new i3(e,!1),n=Xn.fromClass(class{constructor(r){this.from=r.viewport.from,this.markers=this.buildMarkers(r)}update(r){(r.docChanged||r.viewportChanged||r.startState.facet(D1)!=r.state.facet(D1)||r.startState.field(uC,!1)!=r.state.field(uC,!1)||Or(r.startState)!=Or(r.state)||e.foldingChanged(r))&&(this.markers=this.buildMarkers(r.view))}buildMarkers(r){let s=new os;for(let a of r.viewportLineBlocks){let c=Zw(r.state,a.from,a.to)?i:Vw(r.state,a.from,a.to)?A:null;c&&s.add(a.from,a.from,c)}return s.finish()}}),{domEventHandlers:o}=e;return[n,Uw({class:"cm-foldGutter",markers(r){var s;return((s=r.plugin(n))===null||s===void 0?void 0:s.markers)||Zn.empty},initialSpacer(){return new i3(e,!1)},domEventHandlers:Ne(nA({},o),{click:(r,s,a)=>{if(o.click&&o.click(r,s,a))return!0;let c=Zw(r.state,s.from,s.to);if(c)return r.dispatch({effects:o3.of(c)}),!0;let l=Vw(r.state,s.from,s.to);return l?(r.dispatch({effects:Xw.of(l)}),!0):!1}})}),piA()]}var vxA=St.baseTheme({".cm-foldPlaceholder":{backgroundColor:"#eee",border:"1px solid #ddd",color:"#888",borderRadius:".2em",margin:"0 1px",padding:"0 1px",cursor:"pointer"},".cm-foldGutter span":{padding:"0 1px",cursor:"pointer"}}),kE=class t{constructor(e,A){this.specs=e;let i;function n(s){let a=xc.newName();return(i||(i=Object.create(null)))["."+a]=s,a}let o=typeof A.all=="string"?A.all:A.all?n(A.all):void 0,r=A.scope;this.scope=r instanceof Sg?s=>s.prop(ME)==r.data:r?s=>s==r:void 0,this.style=gF(e.map(s=>({tag:s.tag,class:s.class||n(Object.assign({},s,{tag:null}))})),{all:o}).style,this.module=i?new xc(i):null,this.themeType=A.themeType}static define(e,A){return new t(e,A||{})}},fF=Te.define(),yiA=Te.define({combine(t){return t.length?[t[0]]:null}});function dF(t){let e=t.facet(fF);return e.length?e:t.facet(yiA)}function MF(t,e){let A=[bxA],i;return t instanceof kE&&(t.module&&A.push(St.styleModule.of(t.module)),i=t.themeType),e?.fallback?A.push(yiA.of(t)):i?A.push(fF.computeN([St.darkTheme],n=>n.facet(St.darkTheme)==(i=="dark")?[t]:[])):A.push(fF.of(t)),A}var mF=class{constructor(e){this.markCache=Object.create(null),this.tree=Or(e.state),this.decorations=this.buildDeco(e,dF(e.state)),this.decoratedTo=e.viewport.to}update(e){let A=Or(e.state),i=dF(e.state),n=i!=dF(e.startState),{viewport:o}=e.view,r=e.changes.mapPos(this.decoratedTo,1);A.length<o.to&&!n&&A.type==this.tree.type&&r>=o.to?(this.decorations=this.decorations.map(e.changes),this.decoratedTo=r):(A!=this.tree||e.viewportChanged||n)&&(this.tree=A,this.decorations=this.buildDeco(e.view,i),this.decoratedTo=o.to)}buildDeco(e,A){if(!A||!this.tree.length)return rt.none;let i=new os;for(let{from:n,to:o}of e.visibleRanges)riA(this.tree,A,(r,s,a)=>{i.add(r,s,this.markCache[a]||(this.markCache[a]=rt.mark({class:a})))},n,o);return i.finish()}},bxA=Bl.high(Xn.fromClass(mF,{decorations:t=>t.decorations})),viA=kE.define([{tag:we.meta,color:"#404740"},{tag:we.link,textDecoration:"underline"},{tag:we.heading,textDecoration:"underline",fontWeight:"bold"},{tag:we.emphasis,fontStyle:"italic"},{tag:we.strong,fontWeight:"bold"},{tag:we.strikethrough,textDecoration:"line-through"},{tag:we.keyword,color:"#708"},{tag:[we.atom,we.bool,we.url,we.contentSeparator,we.labelName],color:"#219"},{tag:[we.literal,we.inserted],color:"#164"},{tag:[we.string,we.deleted],color:"#a11"},{tag:[we.regexp,we.escape,we.special(we.string)],color:"#e40"},{tag:we.definition(we.variableName),color:"#00f"},{tag:we.local(we.variableName),color:"#30a"},{tag:[we.typeName,we.namespace],color:"#085"},{tag:we.className,color:"#167"},{tag:[we.special(we.variableName),we.macroName],color:"#256"},{tag:we.definition(we.propertyName),color:"#00c"},{tag:we.comment,color:"#940"},{tag:we.invalid,color:"#f00"}]),MxA=St.baseTheme({"&.cm-focused .cm-matchingBracket":{backgroundColor:"#328c8252"},"&.cm-focused .cm-nonmatchingBracket":{backgroundColor:"#bb555544"}}),biA=1e4,MiA="()[]{}",kiA=Te.define({combine(t){return zr(t,{afterCursor:!0,brackets:MiA,maxScanDistance:biA,renderMatch:RxA})}}),kxA=rt.mark({class:"cm-matchingBracket"}),SxA=rt.mark({class:"cm-nonmatchingBracket"});function RxA(t){let e=[],A=t.matched?kxA:SxA;return e.push(A.range(t.start.from,t.start.to)),t.end&&e.push(A.range(t.end.from,t.end.to)),e}var LxA=To.define({create(){return rt.none},update(t,e){if(!e.docChanged&&!e.selection)return t;let A=[],i=e.state.facet(kiA);for(let n of e.state.selection.ranges){if(!n.empty)continue;let o=Ql(e.state,n.head,-1,i)||n.head>0&&Ql(e.state,n.head-1,1,i)||i.afterCursor&&(Ql(e.state,n.head,1,i)||n.head<e.state.doc.length&&Ql(e.state,n.head+1,-1,i));o&&(A=A.concat(i.renderMatch(o,e.state)))}return rt.set(A,!0)},provide:t=>St.decorations.from(t)}),xxA=[LxA,MxA];function SiA(t={}){return[kiA.of(t),xxA]}var FxA=new si;function pF(t,e,A){let i=t.prop(e<0?si.openedBy:si.closedBy);if(i)return i;if(t.name.length==1){let n=A.indexOf(t.name);if(n>-1&&n%2==(e<0?1:0))return[A[n+e]]}return null}function wF(t){let e=t.type.prop(FxA);return e?e(t.node):t}function Ql(t,e,A,i={}){let n=i.maxScanDistance||biA,o=i.brackets||MiA,r=Or(t),s=r.resolveInner(e,A);for(let a=s;a;a=a.parent){let c=pF(a.type,A,o);if(c&&a.from<a.to){let l=wF(a);if(l&&(A>0?e>=l.from&&e<l.to:e>l.from&&e<=l.to))return NxA(t,e,A,a,l,c,o)}}return _xA(t,e,A,r,s.type,n,o)}function NxA(t,e,A,i,n,o,r){let s=i.parent,a={from:n.from,to:n.to},c=0,l=s?.cursor();if(l&&(A<0?l.childBefore(i.from):l.childAfter(i.to)))do if(A<0?l.to<=i.from:l.from>=i.to){if(c==0&&o.indexOf(l.type.name)>-1&&l.from<l.to){let I=wF(l);return{start:a,end:I?{from:I.from,to:I.to}:void 0,matched:!0}}else if(pF(l.type,A,r))c++;else if(pF(l.type,-A,r)){if(c==0){let I=wF(l);return{start:a,end:I&&I.from<I.to?{from:I.from,to:I.to}:void 0,matched:!1}}c--}}while(A<0?l.prevSibling():l.nextSibling());return{start:a,matched:!1}}function _xA(t,e,A,i,n,o,r){let s=A<0?t.sliceDoc(e-1,e):t.sliceDoc(e,e+1),a=r.indexOf(s);if(a<0||a%2==0!=A>0)return null;let c={from:A<0?e-1:e,to:A>0?e+1:e},l=t.doc.iterRange(e,A>0?t.doc.length:0),I=0;for(let C=0;!l.next().done&&C<=o;){let d=l.value;A<0&&(C+=d.length);let B=e+C*A;for(let E=A>0?0:d.length-1,Q=A>0?d.length:-1;E!=Q;E+=A){let u=r.indexOf(d[E]);if(!(u<0||i.resolveInner(B+E,1).type!=n))if(u%2==0==A>0)I++;else{if(I==1)return{start:c,end:{from:B+E,to:B+E+1},matched:u>>1==a>>1};I--}}A>0&&(C+=d.length)}return l.done?{start:c,matched:!1}:null}var GxA=Object.create(null),liA=[ws.none];var giA=[],IiA=Object.create(null),UxA=Object.create(null);for(let[t,e]of[["variable","variableName"],["variable-2","variableName.special"],["string-2","string.special"],["def","variableName.definition"],["tag","tagName"],["attribute","attributeName"],["type","typeName"],["builtin","variableName.standard"],["qualifier","modifier"],["error","invalid"],["header","heading"],["property","propertyName"]])UxA[t]=KxA(GxA,e);function BF(t,e){giA.indexOf(t)>-1||(giA.push(t),console.warn(e))}function KxA(t,e){let A=[];for(let s of e.split(" ")){let a=[];for(let c of s.split(".")){let l=t[c]||we[c];l?typeof l=="function"?a.length?a=a.map(l):BF(c,`Modifier ${c} used at start of tag`):a.length?BF(c,`Tag ${c} used as modifier`):a=Array.isArray(l)?l:[l]:BF(c,`Unknown highlighting tag ${c}`)}for(let c of a)A.push(c)}if(!A.length)return 0;let i=e.replace(/ /g,"_"),n=i+" "+A.map(s=>s.id),o=IiA[n];if(o)return o.id;let r=IiA[n]=ws.define({id:liA.length,name:i,props:[Pw({[i]:A})]});return liA.push(r),r.id}var Ume={rtl:rt.mark({class:"cm-iso",inclusive:!0,attributes:{dir:"rtl"},bidiIsolate:Wn.RTL}),ltr:rt.mark({class:"cm-iso",inclusive:!0,attributes:{dir:"ltr"},bidiIsolate:Wn.LTR}),auto:rt.mark({class:"cm-iso",inclusive:!0,attributes:{dir:"auto"},bidiIsolate:null})};var YxA=t=>{let{state:e}=t,A=e.doc.lineAt(e.selection.main.from),i=LF(t.state,A.from);return i.line?JxA(t):i.block?zxA(t):!1};function RF(t,e){return({state:A,dispatch:i})=>{if(A.readOnly)return!1;let n=t(e,A);return n?(i(A.update(n)),!0):!1}}var JxA=RF(PxA,0);var TxA=RF(KiA,0);var zxA=RF((t,e)=>KiA(t,e,OxA(e)),0);function LF(t,e){let A=t.languageDataAt("commentTokens",e,1);return A.length?A[0]:{}}var r3=50;function HxA(t,{open:e,close:A},i,n){let o=t.sliceDoc(i-r3,i),r=t.sliceDoc(n,n+r3),s=/\s*$/.exec(o)[0].length,a=/^\s*/.exec(r)[0].length,c=o.length-s;if(o.slice(c-e.length,c)==e&&r.slice(a,a+A.length)==A)return{open:{pos:i-s,margin:s&&1},close:{pos:n+a,margin:a&&1}};let l,I;n-i<=2*r3?l=I=t.sliceDoc(i,n):(l=t.sliceDoc(i,i+r3),I=t.sliceDoc(n-r3,n));let C=/^\s*/.exec(l)[0].length,d=/\s*$/.exec(I)[0].length,B=I.length-d-A.length;return l.slice(C,C+e.length)==e&&I.slice(B,B+A.length)==A?{open:{pos:i+C+e.length,margin:/\s/.test(l.charAt(C+e.length))?1:0},close:{pos:n-d-A.length,margin:/\s/.test(I.charAt(B-1))?1:0}}:null}function OxA(t){let e=[];for(let A of t.selection.ranges){let i=t.doc.lineAt(A.from),n=A.to<=i.to?i:t.doc.lineAt(A.to);n.from>i.from&&n.from==A.to&&(n=A.to==i.to+1?i:t.doc.lineAt(A.to-1));let o=e.length-1;o>=0&&e[o].to>i.from?e[o].to=n.to:e.push({from:i.from+/^\s*/.exec(i.text)[0].length,to:n.to})}return e}function KiA(t,e,A=e.selection.ranges){let i=A.map(o=>LF(e,o.from).block);if(!i.every(o=>o))return null;let n=A.map((o,r)=>HxA(e,i[r],o.from,o.to));if(t!=2&&!n.every(o=>o))return{changes:e.changes(A.map((o,r)=>n[r]?[]:[{from:o.from,insert:i[r].open+" "},{from:o.to,insert:" "+i[r].close}]))};if(t!=1&&n.some(o=>o)){let o=[];for(let r=0,s;r<n.length;r++)if(s=n[r]){let a=i[r],{open:c,close:l}=s;o.push({from:c.pos-a.open.length,to:c.pos+c.margin},{from:l.pos-l.margin,to:l.pos+a.close.length})}return{changes:o}}return null}function PxA(t,e,A=e.selection.ranges){let i=[],n=-1;for(let{from:o,to:r}of A){let s=i.length,a=1e9,c=LF(e,o).line;if(c){for(let l=o;l<=r;){let I=e.doc.lineAt(l);if(I.from>n&&(o==r||r>I.from)){n=I.from;let C=/^\s*/.exec(I.text)[0].length,d=C==I.length,B=I.text.slice(C,C+c.length)==c?C:-1;C<I.text.length&&C<a&&(a=C),i.push({line:I,comment:B,token:c,indent:C,empty:d,single:!1})}l=I.to+1}if(a<1e9)for(let l=s;l<i.length;l++)i[l].indent<i[l].line.text.length&&(i[l].indent=a);i.length==s+1&&(i[s].single=!0)}}if(t!=2&&i.some(o=>o.comment<0&&(!o.empty||o.single))){let o=[];for(let{line:s,token:a,indent:c,empty:l,single:I}of i)(I||!l)&&o.push({from:s.from+c,insert:a+" "});let r=e.changes(o);return{changes:r,selection:e.selection.map(r,1)}}else if(t!=1&&i.some(o=>o.comment>=0)){let o=[];for(let{line:r,comment:s,token:a}of i)if(s>=0){let c=r.from+s,l=c+a.length;r.text[l-r.from]==" "&&l++,o.push({from:c,to:l})}return{changes:o}}return null}function RE(t,e){return ie.create(t.ranges.map(e),t.mainIndex)}function Rg(t,e){return t.update({selection:e,scrollIntoView:!0,userEvent:"select"})}function fl({state:t,dispatch:e},A){let i=RE(t.selection,A);return i.eq(t.selection,!0)?!1:(e(Rg(t,i)),!0)}function AD(t,e){return ie.cursor(e?t.to:t.from)}function YiA(t,e){return fl(t,A=>A.empty?t.moveByChar(A,e):AD(A,e))}function Ds(t){return t.textDirectionAt(t.state.selection.main.head)==Wn.LTR}var JiA=t=>YiA(t,!Ds(t)),TiA=t=>YiA(t,Ds(t));function ziA(t,e){return fl(t,A=>A.empty?t.moveByGroup(A,e):AD(A,e))}var jxA=t=>ziA(t,!Ds(t)),qxA=t=>ziA(t,Ds(t));var qme=typeof Intl<"u"&&Intl.Segmenter?new Intl.Segmenter(void 0,{granularity:"word"}):null;function VxA(t,e,A){if(e.type.prop(A))return!0;let i=e.to-e.from;return i&&(i>2||/[^\s,.;:]/.test(t.sliceDoc(e.from,e.to)))||e.firstChild}function eD(t,e,A){let i=Or(t).resolveInner(e.head),n=A?si.closedBy:si.openedBy;for(let a=e.head;;){let c=A?i.childAfter(a):i.childBefore(a);if(!c)break;VxA(t,c,n)?i=c:a=A?c.to:c.from}let o=i.type.prop(n),r,s;return o&&(r=A?Ql(t,i.from,1):Ql(t,i.to,-1))&&r.matched?s=A?r.end.to:r.end.from:s=A?i.to:i.from,ie.cursor(s,A?-1:1)}var ZxA=t=>fl(t,e=>eD(t.state,e,!Ds(t))),WxA=t=>fl(t,e=>eD(t.state,e,Ds(t)));function HiA(t,e){return fl(t,A=>{if(!A.empty)return AD(A,e);let i=t.moveVertically(A,e);return i.head!=A.head?i:t.moveToLineBoundary(A,e)})}var OiA=t=>HiA(t,!1),PiA=t=>HiA(t,!0);function jiA(t){let e=t.scrollDOM.clientHeight<t.scrollDOM.scrollHeight-2,A=0,i=0,n;if(e){for(let o of t.state.facet(St.scrollMargins)){let r=o(t);r?.top&&(A=Math.max(r?.top,A)),r?.bottom&&(i=Math.max(r?.bottom,i))}n=t.scrollDOM.clientHeight-A-i}else n=(t.dom.ownerDocument.defaultView||window).innerHeight;return{marginTop:A,marginBottom:i,selfScroll:e,height:Math.max(t.defaultLineHeight,n-5)}}function qiA(t,e){let A=jiA(t),{state:i}=t,n=RE(i.selection,r=>r.empty?t.moveVertically(r,e,A.height):AD(r,e));if(n.eq(i.selection))return!1;let o;if(A.selfScroll){let r=t.coordsAtPos(i.selection.main.head),s=t.scrollDOM.getBoundingClientRect(),a=s.top+A.marginTop,c=s.bottom-A.marginBottom;r&&r.top>a&&r.bottom<c&&(o=St.scrollIntoView(n.main.head,{y:"start",yMargin:r.top-a}))}return t.dispatch(Rg(i,n),{effects:o}),!0}var RiA=t=>qiA(t,!1),kF=t=>qiA(t,!0);function y1(t,e,A){let i=t.lineBlockAt(e.head),n=t.moveToLineBoundary(e,A);if(n.head==e.head&&n.head!=(A?i.to:i.from)&&(n=t.moveToLineBoundary(e,A,!1)),!A&&n.head==i.from&&i.length){let o=/^\s*/.exec(t.state.sliceDoc(i.from,Math.min(i.from+100,i.to)))[0].length;o&&e.head!=i.from+o&&(n=ie.cursor(i.from+o))}return n}var XxA=t=>fl(t,e=>y1(t,e,!0)),$xA=t=>fl(t,e=>y1(t,e,!1)),AFA=t=>fl(t,e=>y1(t,e,!Ds(t))),eFA=t=>fl(t,e=>y1(t,e,Ds(t))),tFA=t=>fl(t,e=>ie.cursor(t.lineBlockAt(e.head).from,1)),iFA=t=>fl(t,e=>ie.cursor(t.lineBlockAt(e.head).to,-1));function nFA(t,e,A){let i=!1,n=RE(t.selection,o=>{let r=Ql(t,o.head,-1)||Ql(t,o.head,1)||o.head>0&&Ql(t,o.head-1,1)||o.head<t.doc.length&&Ql(t,o.head+1,-1);if(!r||!r.end)return o;i=!0;let s=r.start.from==o.head?r.end.to:r.end.from;return A?ie.range(o.anchor,s):ie.cursor(s)});return i?(e(Rg(t,n)),!0):!1}var oFA=({state:t,dispatch:e})=>nFA(t,e,!1);function _c(t,e){let A=RE(t.state.selection,i=>{let n=e(i);return ie.range(i.anchor,n.head,n.goalColumn,n.bidiLevel||void 0)});return A.eq(t.state.selection)?!1:(t.dispatch(Rg(t.state,A)),!0)}function ViA(t,e){return _c(t,A=>t.moveByChar(A,e))}var ZiA=t=>ViA(t,!Ds(t)),WiA=t=>ViA(t,Ds(t));function XiA(t,e){return _c(t,A=>t.moveByGroup(A,e))}var rFA=t=>XiA(t,!Ds(t)),sFA=t=>XiA(t,Ds(t));var aFA=t=>_c(t,e=>eD(t.state,e,!Ds(t))),cFA=t=>_c(t,e=>eD(t.state,e,Ds(t)));function $iA(t,e){return _c(t,A=>t.moveVertically(A,e))}var AnA=t=>$iA(t,!1),enA=t=>$iA(t,!0);function tnA(t,e){return _c(t,A=>t.moveVertically(A,e,jiA(t).height))}var LiA=t=>tnA(t,!1),xiA=t=>tnA(t,!0),lFA=t=>_c(t,e=>y1(t,e,!0)),gFA=t=>_c(t,e=>y1(t,e,!1)),IFA=t=>_c(t,e=>y1(t,e,!Ds(t))),CFA=t=>_c(t,e=>y1(t,e,Ds(t))),dFA=t=>_c(t,e=>ie.cursor(t.lineBlockAt(e.head).from)),BFA=t=>_c(t,e=>ie.cursor(t.lineBlockAt(e.head).to)),FiA=({state:t,dispatch:e})=>(e(Rg(t,{anchor:0})),!0),NiA=({state:t,dispatch:e})=>(e(Rg(t,{anchor:t.doc.length})),!0),_iA=({state:t,dispatch:e})=>(e(Rg(t,{anchor:t.selection.main.anchor,head:0})),!0),GiA=({state:t,dispatch:e})=>(e(Rg(t,{anchor:t.selection.main.anchor,head:t.doc.length})),!0),EFA=({state:t,dispatch:e})=>(e(t.update({selection:{anchor:0,head:t.doc.length},userEvent:"select"})),!0),hFA=({state:t,dispatch:e})=>{let A=tD(t).map(({from:i,to:n})=>ie.range(i,Math.min(n+1,t.doc.length)));return e(t.update({selection:ie.create(A),userEvent:"select"})),!0},QFA=({state:t,dispatch:e})=>{let A=RE(t.selection,i=>{let n=Or(t),o=n.resolveStack(i.from,1);if(i.empty){let r=n.resolveStack(i.from,-1);r.node.from>=o.node.from&&r.node.to<=o.node.to&&(o=r)}for(let r=o;r;r=r.next){let{node:s}=r;if((s.from<i.from&&s.to>=i.to||s.to>i.to&&s.from<=i.from)&&r.next)return ie.range(s.to,s.from)}return i});return A.eq(t.selection)?!1:(e(Rg(t,A)),!0)},uFA=({state:t,dispatch:e})=>{let A=t.selection,i=null;return A.ranges.length>1?i=ie.create([A.main]):A.main.empty||(i=ie.create([ie.cursor(A.main.head)])),i?(e(Rg(t,i)),!0):!1};function s3(t,e){if(t.state.readOnly)return!1;let A="delete.selection",{state:i}=t,n=i.changeByRange(o=>{let{from:r,to:s}=o;if(r==s){let a=e(o);a<r?(A="delete.backward",a=$w(t,a,!1)):a>r&&(A="delete.forward",a=$w(t,a,!0)),r=Math.min(r,a),s=Math.max(s,a)}else r=$w(t,r,!1),s=$w(t,s,!0);return r==s?{range:o}:{changes:{from:r,to:s},range:ie.cursor(r,r<o.head?-1:1)}});return n.changes.empty?!1:(t.dispatch(i.update(n,{scrollIntoView:!0,userEvent:A,effects:A=="delete.selection"?St.announce.of(i.phrase("Selection deleted")):void 0})),!0)}function $w(t,e,A){if(t instanceof St)for(let i of t.state.facet(St.atomicRanges).map(n=>n(t)))i.between(e,e,(n,o)=>{n<e&&o>e&&(e=A?o:n)});return e}var inA=(t,e,A)=>s3(t,i=>{let n=i.from,{state:o}=t,r=o.doc.lineAt(n),s,a;if(A&&!e&&n>r.from&&n<r.from+200&&!/[^ \t]/.test(s=r.text.slice(0,n-r.from))){if(s[s.length-1]=="	")return n-1;let c=G0(s,o.tabSize),l=c%ul(o)||ul(o);for(let I=0;I<l&&s[s.length-1-I]==" ";I++)n--;a=n}else a=fr(r.text,n-r.from,e,e)+r.from,a==n&&r.number!=(e?o.doc.lines:1)?a+=e?1:-1:!e&&/[\ufe00-\ufe0f]/.test(r.text.slice(a-r.from,n-r.from))&&(a=fr(r.text,a-r.from,!1,!1)+r.from);return a}),SF=t=>inA(t,!1,!0);var nnA=t=>inA(t,!0,!1),onA=(t,e)=>s3(t,A=>{let i=A.head,{state:n}=t,o=n.doc.lineAt(i),r=n.charCategorizer(i);for(let s=null;;){if(i==(e?o.to:o.from)){i==A.head&&o.number!=(e?n.doc.lines:1)&&(i+=e?1:-1);break}let a=fr(o.text,i-o.from,e)+o.from,c=o.text.slice(Math.min(i,a)-o.from,Math.max(i,a)-o.from),l=r(c);if(s!=null&&l!=s)break;(c!=" "||i!=A.head)&&(s=l),i=a}return i}),rnA=t=>onA(t,!1),fFA=t=>onA(t,!0),mFA=t=>s3(t,e=>{let A=t.lineBlockAt(e.head).to;return e.head<A?A:Math.min(t.state.doc.length,e.head+1)});var pFA=t=>s3(t,e=>{let A=t.moveToLineBoundary(e,!1).head;return e.head>A?A:Math.max(0,e.head-1)}),wFA=t=>s3(t,e=>{let A=t.moveToLineBoundary(e,!0).head;return e.head<A?A:Math.min(t.state.doc.length,e.head+1)});var DFA=({state:t,dispatch:e})=>{if(t.readOnly)return!1;let A=t.changeByRange(i=>({changes:{from:i.from,to:i.to,insert:qi.of(["",""])},range:ie.cursor(i.from)}));return e(t.update(A,{scrollIntoView:!0,userEvent:"input"})),!0},yFA=({state:t,dispatch:e})=>{if(t.readOnly)return!1;let A=t.changeByRange(i=>{if(!i.empty||i.from==0||i.from==t.doc.length)return{range:i};let n=i.from,o=t.doc.lineAt(n),r=n==o.from?n-1:fr(o.text,n-o.from,!1)+o.from,s=n==o.to?n+1:fr(o.text,n-o.from,!0)+o.from;return{changes:{from:r,to:s,insert:t.doc.slice(n,s).append(t.doc.slice(r,n))},range:ie.cursor(s)}});return A.changes.empty?!1:(e(t.update(A,{scrollIntoView:!0,userEvent:"move.character"})),!0)};function tD(t){let e=[],A=-1;for(let i of t.selection.ranges){let n=t.doc.lineAt(i.from),o=t.doc.lineAt(i.to);if(!i.empty&&i.to==o.from&&(o=t.doc.lineAt(i.to-1)),A>=n.number){let r=e[e.length-1];r.to=o.to,r.ranges.push(i)}else e.push({from:n.from,to:o.to,ranges:[i]});A=o.number+1}return e}function snA(t,e,A){if(t.readOnly)return!1;let i=[],n=[];for(let o of tD(t)){if(A?o.to==t.doc.length:o.from==0)continue;let r=t.doc.lineAt(A?o.to+1:o.from-1),s=r.length+1;if(A){i.push({from:o.to,to:r.to},{from:o.from,insert:r.text+t.lineBreak});for(let a of o.ranges)n.push(ie.range(Math.min(t.doc.length,a.anchor+s),Math.min(t.doc.length,a.head+s)))}else{i.push({from:r.from,to:o.from},{from:o.to,insert:t.lineBreak+r.text});for(let a of o.ranges)n.push(ie.range(a.anchor-s,a.head-s))}}return i.length?(e(t.update({changes:i,scrollIntoView:!0,selection:ie.create(n,t.selection.mainIndex),userEvent:"move.line"})),!0):!1}var vFA=({state:t,dispatch:e})=>snA(t,e,!1),bFA=({state:t,dispatch:e})=>snA(t,e,!0);function anA(t,e,A){if(t.readOnly)return!1;let i=[];for(let n of tD(t))A?i.push({from:n.from,insert:t.doc.slice(n.from,n.to)+t.lineBreak}):i.push({from:n.to,insert:t.lineBreak+t.doc.slice(n.from,n.to)});return e(t.update({changes:i,scrollIntoView:!0,userEvent:"input.copyline"})),!0}var MFA=({state:t,dispatch:e})=>anA(t,e,!1),kFA=({state:t,dispatch:e})=>anA(t,e,!0),SFA=t=>{if(t.state.readOnly)return!1;let{state:e}=t,A=e.changes(tD(e).map(({from:n,to:o})=>(n>0?n--:o<e.doc.length&&o++,{from:n,to:o}))),i=RE(e.selection,n=>{let o;if(t.lineWrapping){let r=t.lineBlockAt(n.head),s=t.coordsAtPos(n.head,n.assoc||1);s&&(o=r.bottom+t.documentTop-s.bottom+t.defaultLineHeight/2)}return t.moveVertically(n,!0,o)}).map(A);return t.dispatch({changes:A,selection:i,scrollIntoView:!0,userEvent:"delete.line"}),!0};function RFA(t,e){if(/\(\)|\[\]|\{\}/.test(t.sliceDoc(e-1,e+1)))return{from:e,to:e};let A=Or(t).resolveInner(e),i=A.childBefore(e),n=A.childAfter(e),o;return i&&n&&i.to<=e&&n.from>=e&&(o=i.type.prop(si.closedBy))&&o.indexOf(n.name)>-1&&t.doc.lineAt(i.to).from==t.doc.lineAt(n.from).from&&!/\S/.test(t.sliceDoc(i.to,n.from))?{from:i.to,to:n.from}:null}var UiA=cnA(!1),LFA=cnA(!0);function cnA(t){return({state:e,dispatch:A})=>{if(e.readOnly)return!1;let i=e.changeByRange(n=>{let{from:o,to:r}=n,s=e.doc.lineAt(o),a=!t&&o==r&&RFA(e,o);t&&(o=r=(r<=s.to?s:e.doc.lineAt(r)).to);let c=new QC(e,{simulateBreak:o,simulateDoubleBreak:!!a}),l=Ww(c,o);for(l==null&&(l=G0(/^\s*/.exec(e.doc.lineAt(o).text)[0],e.tabSize));r<s.to&&/\s/.test(s.text[r-s.from]);)r++;a?{from:o,to:r}=a:o>s.from&&o<s.from+100&&!/\S/.test(s.text.slice(0,o))&&(o=s.from);let I=["",SE(e,l)];return a&&I.push(SE(e,c.lineIndent(s.from,-1))),{changes:{from:o,to:r,insert:qi.of(I)},range:ie.cursor(o+1+I[1].length)}});return A(e.update(i,{scrollIntoView:!0,userEvent:"input"})),!0}}function xF(t,e){let A=-1;return t.changeByRange(i=>{let n=[];for(let r=i.from;r<=i.to;){let s=t.doc.lineAt(r);s.number>A&&(i.empty||i.to>s.from)&&(e(s,n,i),A=s.number),r=s.to+1}let o=t.changes(n);return{changes:n,range:ie.range(o.mapPos(i.anchor,1),o.mapPos(i.head,1))}})}var xFA=({state:t,dispatch:e})=>{if(t.readOnly)return!1;let A=Object.create(null),i=new QC(t,{overrideIndentation:o=>{let r=A[o];return r??-1}}),n=xF(t,(o,r,s)=>{let a=Ww(i,o.from);if(a==null)return;/\S/.test(o.text)||(a=0);let c=/^\s*/.exec(o.text)[0],l=SE(t,a);(c!=l||s.from<o.from+c.length)&&(A[o.from]=a,r.push({from:o.from,to:o.from+c.length,insert:l}))});return n.changes.empty||e(t.update(n,{userEvent:"indent"})),!0},lnA=({state:t,dispatch:e})=>t.readOnly?!1:(e(t.update(xF(t,(A,i)=>{i.push({from:A.from,insert:t.facet(fC)})}),{userEvent:"input.indent"})),!0),gnA=({state:t,dispatch:e})=>t.readOnly?!1:(e(t.update(xF(t,(A,i)=>{let n=/^\s*/.exec(A.text)[0];if(!n)return;let o=G0(n,t.tabSize),r=0,s=SE(t,Math.max(0,o-ul(t)));for(;r<n.length&&r<s.length&&n.charCodeAt(r)==s.charCodeAt(r);)r++;i.push({from:A.from+r,to:A.from+n.length,insert:s.slice(r)})}),{userEvent:"delete.dedent"})),!0),FFA=t=>(t.setTabFocusMode(),!0);var NFA=[{key:"Ctrl-b",run:JiA,shift:ZiA,preventDefault:!0},{key:"Ctrl-f",run:TiA,shift:WiA},{key:"Ctrl-p",run:OiA,shift:AnA},{key:"Ctrl-n",run:PiA,shift:enA},{key:"Ctrl-a",run:tFA,shift:dFA},{key:"Ctrl-e",run:iFA,shift:BFA},{key:"Ctrl-d",run:nnA},{key:"Ctrl-h",run:SF},{key:"Ctrl-k",run:mFA},{key:"Ctrl-Alt-h",run:rnA},{key:"Ctrl-o",run:DFA},{key:"Ctrl-t",run:yFA},{key:"Ctrl-v",run:kF}],_FA=[{key:"ArrowLeft",run:JiA,shift:ZiA,preventDefault:!0},{key:"Mod-ArrowLeft",mac:"Alt-ArrowLeft",run:jxA,shift:rFA,preventDefault:!0},{mac:"Cmd-ArrowLeft",run:AFA,shift:IFA,preventDefault:!0},{key:"ArrowRight",run:TiA,shift:WiA,preventDefault:!0},{key:"Mod-ArrowRight",mac:"Alt-ArrowRight",run:qxA,shift:sFA,preventDefault:!0},{mac:"Cmd-ArrowRight",run:eFA,shift:CFA,preventDefault:!0},{key:"ArrowUp",run:OiA,shift:AnA,preventDefault:!0},{mac:"Cmd-ArrowUp",run:FiA,shift:_iA},{mac:"Ctrl-ArrowUp",run:RiA,shift:LiA},{key:"ArrowDown",run:PiA,shift:enA,preventDefault:!0},{mac:"Cmd-ArrowDown",run:NiA,shift:GiA},{mac:"Ctrl-ArrowDown",run:kF,shift:xiA},{key:"PageUp",run:RiA,shift:LiA},{key:"PageDown",run:kF,shift:xiA},{key:"Home",run:$xA,shift:gFA,preventDefault:!0},{key:"Mod-Home",run:FiA,shift:_iA},{key:"End",run:XxA,shift:lFA,preventDefault:!0},{key:"Mod-End",run:NiA,shift:GiA},{key:"Enter",run:UiA,shift:UiA},{key:"Mod-a",run:EFA},{key:"Backspace",run:SF,shift:SF},{key:"Delete",run:nnA},{key:"Mod-Backspace",mac:"Alt-Backspace",run:rnA},{key:"Mod-Delete",mac:"Alt-Delete",run:fFA},{mac:"Mod-Backspace",run:pFA},{mac:"Mod-Delete",run:wFA}].concat(NFA.map(t=>({mac:t.key,run:t.run,shift:t.shift}))),InA=[{key:"Alt-ArrowLeft",mac:"Ctrl-ArrowLeft",run:ZxA,shift:aFA},{key:"Alt-ArrowRight",mac:"Ctrl-ArrowRight",run:WxA,shift:cFA},{key:"Alt-ArrowUp",run:vFA},{key:"Shift-Alt-ArrowUp",run:MFA},{key:"Alt-ArrowDown",run:bFA},{key:"Shift-Alt-ArrowDown",run:kFA},{key:"Escape",run:uFA},{key:"Mod-Enter",run:LFA},{key:"Alt-l",mac:"Ctrl-l",run:hFA},{key:"Mod-i",run:QFA,preventDefault:!0},{key:"Mod-[",run:gnA},{key:"Mod-]",run:lnA},{key:"Mod-Alt-\\",run:xFA},{key:"Shift-Mod-k",run:SFA},{key:"Shift-Mod-\\",run:oFA},{key:"Mod-/",run:YxA},{key:"Alt-A",run:TxA},{key:"Ctrl-m",mac:"Shift-Alt-m",run:FFA}].concat(_FA),CnA={key:"Tab",run:lnA,shift:gnA};var oD=class{constructor(e,A,i){this.from=e,this.to=A,this.diagnostic=i}},mC=class t{constructor(e,A,i){this.diagnostics=e,this.panel=A,this.selected=i}static init(e,A,i){let n=i.facet(Lg).markerFilter;n&&(e=n(e,i));let o=e.slice().sort((l,I)=>l.from-I.from||l.to-I.to),r=new os,s=[],a=0;for(let l=0;;){let I=l==o.length?null:o[l];if(!I&&!s.length)break;let C,d;for(s.length?(C=a,d=s.reduce((E,Q)=>Math.min(E,Q.to),I&&I.from>C?I.from:1e8)):(C=I.from,d=I.to,s.push(I),l++);l<o.length;){let E=o[l];if(E.from==C&&(E.to>E.from||E.to==C))s.push(E),l++,d=Math.min(E.to,d);else{d=Math.min(E.from,d);break}}let B=wnA(s);if(s.some(E=>E.from==E.to||E.from==E.to-1&&i.doc.lineAt(E.from).to==E.from))r.add(C,C,rt.widget({widget:new FF(B),diagnostics:s.slice()}));else{let E=s.reduce((Q,u)=>u.markClass?Q+" "+u.markClass:Q,"");r.add(C,d,rt.mark({class:"cm-lintRange cm-lintRange-"+B+E,diagnostics:s.slice(),inclusiveEnd:s.some(Q=>Q.to>d)}))}a=d;for(let E=0;E<s.length;E++)s[E].to<=a&&s.splice(E--,1)}let c=r.finish();return new t(c,A,LE(c))}};function LE(t,e=null,A=0){let i=null;return t.between(A,1e9,(n,o,{spec:r})=>{if(!(e&&r.diagnostics.indexOf(e)<0))if(!i)i=new oD(n,o,e||r.diagnostics[0]);else{if(r.diagnostics.indexOf(i.diagnostic)<0)return!1;i=new oD(i.from,o,i.diagnostic)}}),i}function BnA(t,e){let A=e.pos,i=e.end||A,n=t.state.facet(Lg).hideOn(t,A,i);if(n!=null)return n;let o=t.startState.doc.lineAt(e.pos);return!!(t.effects.some(r=>r.is(aD))||t.changes.touchesRange(o.from,Math.max(o.to,i)))}function EnA(t,e){return t.field(oc,!1)?e:e.concat(ki.appendConfig.of(ynA))}function GFA(t,e){return{effects:EnA(t,[aD.of(e)])}}var aD=ki.define(),_F=ki.define(),hnA=ki.define(),oc=To.define({create(){return new mC(rt.none,null,null)},update(t,e){if(e.docChanged&&t.diagnostics.size){let A=t.diagnostics.map(e.changes),i=null,n=t.panel;if(t.selected){let o=e.changes.mapPos(t.selected.from,1);i=LE(A,t.selected.diagnostic,o)||LE(A,null,o)}!A.size&&n&&e.state.facet(Lg).autoPanel&&(n=null),t=new mC(A,n,i)}for(let A of e.effects)if(A.is(aD)){let i=e.state.facet(Lg).autoPanel?A.value.length?a3.open:null:t.panel;t=mC.init(A.value,i,e.state)}else A.is(_F)?t=new mC(t.diagnostics,A.value?a3.open:null,t.selected):A.is(hnA)&&(t=new mC(t.diagnostics,t.panel,A.value));return t},provide:t=>[dC.from(t,e=>e.panel),St.decorations.from(t,e=>e.diagnostics)]});var UFA=rt.mark({class:"cm-lintRange cm-lintRange-active"});function KFA(t,e,A){let{diagnostics:i}=t.state.field(oc),n,o=-1,r=-1;i.between(e-(A<0?1:0),e+(A>0?1:0),(a,c,{spec:l})=>{if(e>=a&&e<=c&&(a==c||(e>a||A>0)&&(e<c||A<0)))return n=l.diagnostics,o=a,r=c,!1});let s=t.state.facet(Lg).tooltipFilter;return n&&s&&(n=s(n,t.state)),n?{pos:o,end:r,above:t.state.doc.lineAt(o).to<r,create(){return{dom:QnA(t,n)}}}:null}function QnA(t,e){return kn("ul",{class:"cm-tooltip-lint"},e.map(A=>pnA(t,A,!1)))}var YFA=t=>{let e=t.state.field(oc,!1);(!e||!e.panel)&&t.dispatch({effects:EnA(t.state,[_F.of(!0)])});let A=BC(t,a3.open);return A&&A.dom.querySelector(".cm-panel-lint ul").focus(),!0},dnA=t=>{let e=t.state.field(oc,!1);return!e||!e.panel?!1:(t.dispatch({effects:_F.of(!1)}),!0)},JFA=t=>{let e=t.state.field(oc,!1);if(!e)return!1;let A=t.state.selection.main,i=e.diagnostics.iter(A.to+1);return!i.value&&(i=e.diagnostics.iter(0),!i.value||i.from==A.from&&i.to==A.to)?!1:(t.dispatch({selection:{anchor:i.from,head:i.to},scrollIntoView:!0}),!0)};var unA=[{key:"Mod-Shift-m",run:YFA,preventDefault:!0},{key:"F8",run:JFA}],TFA=Xn.fromClass(class{constructor(t){this.view=t,this.timeout=-1,this.set=!0;let{delay:e}=t.state.facet(Lg);this.lintTime=Date.now()+e,this.run=this.run.bind(this),this.timeout=setTimeout(this.run,e)}run(){clearTimeout(this.timeout);let t=Date.now();if(t<this.lintTime-10)this.timeout=setTimeout(this.run,this.lintTime-t);else{this.set=!1;let{state:e}=this.view,{sources:A}=e.facet(Lg);A.length&&zFA(A.map(i=>Promise.resolve(i(this.view))),i=>{this.view.state.doc==e.doc&&this.view.dispatch(GFA(this.view.state,i.reduce((n,o)=>n.concat(o))))},i=>{Hr(this.view.state,i)})}}update(t){let e=t.state.facet(Lg);(t.docChanged||e!=t.startState.facet(Lg)||e.needsRefresh&&e.needsRefresh(t))&&(this.lintTime=Date.now()+e.delay,this.set||(this.set=!0,this.timeout=setTimeout(this.run,e.delay)))}force(){this.set&&(this.lintTime=Date.now(),this.run())}destroy(){clearTimeout(this.timeout)}});function zFA(t,e,A){let i=[],n=-1;for(let o of t)o.then(r=>{i.push(r),clearTimeout(n),i.length==t.length?e(i):n=setTimeout(()=>e(i),200)},A)}var Lg=Te.define({combine(t){return Object.assign({sources:t.map(e=>e.source).filter(e=>e!=null)},zr(t.map(e=>e.config),{delay:750,markerFilter:null,tooltipFilter:null,needsRefresh:null,hideOn:()=>null},{needsRefresh:(e,A)=>e?A?i=>e(i)||A(i):e:A}))}});function fnA(t,e={}){return[Lg.of({source:t,config:e}),TFA,ynA]}function mnA(t){let e=[];if(t)A:for(let{name:A}of t){for(let i=0;i<A.length;i++){let n=A[i];if(/[a-zA-Z]/.test(n)&&!e.some(o=>o.toLowerCase()==n.toLowerCase())){e.push(n);continue A}}e.push("")}return e}function pnA(t,e,A){var i;let n=A?mnA(e.actions):[];return kn("li",{class:"cm-diagnostic cm-diagnostic-"+e.severity},kn("span",{class:"cm-diagnosticText"},e.renderMessage?e.renderMessage(t):e.message),(i=e.actions)===null||i===void 0?void 0:i.map((o,r)=>{let s=!1,a=C=>{if(C.preventDefault(),s)return;s=!0;let d=LE(t.state.field(oc).diagnostics,e);d&&o.apply(t,d.from,d.to)},{name:c}=o,l=n[r]?c.indexOf(n[r]):-1,I=l<0?c:[c.slice(0,l),kn("u",c.slice(l,l+1)),c.slice(l+1)];return kn("button",{type:"button",class:"cm-diagnosticAction",onclick:a,onmousedown:a,"aria-label":` Action: ${c}${l<0?"":` (access key "${n[r]})"`}.`},I)}),e.source&&kn("div",{class:"cm-diagnosticSource"},e.source))}var FF=class extends nc{constructor(e){super(),this.sev=e}eq(e){return e.sev==this.sev}toDOM(){return kn("span",{class:"cm-lintPoint cm-lintPoint-"+this.sev})}},rD=class{constructor(e,A){this.diagnostic=A,this.id="item_"+Math.floor(Math.random()*4294967295).toString(16),this.dom=pnA(e,A,!0),this.dom.id=this.id,this.dom.setAttribute("role","option")}},a3=class t{constructor(e){this.view=e,this.items=[];let A=n=>{if(n.keyCode==27)dnA(this.view),this.view.focus();else if(n.keyCode==38||n.keyCode==33)this.moveSelection((this.selectedIndex-1+this.items.length)%this.items.length);else if(n.keyCode==40||n.keyCode==34)this.moveSelection((this.selectedIndex+1)%this.items.length);else if(n.keyCode==36)this.moveSelection(0);else if(n.keyCode==35)this.moveSelection(this.items.length-1);else if(n.keyCode==13)this.view.focus();else if(n.keyCode>=65&&n.keyCode<=90&&this.selectedIndex>=0){let{diagnostic:o}=this.items[this.selectedIndex],r=mnA(o.actions);for(let s=0;s<r.length;s++)if(r[s].toUpperCase().charCodeAt(0)==n.keyCode){let a=LE(this.view.state.field(oc).diagnostics,o);a&&o.actions[s].apply(e,a.from,a.to)}}else return;n.preventDefault()},i=n=>{for(let o=0;o<this.items.length;o++)this.items[o].dom.contains(n.target)&&this.moveSelection(o)};this.list=kn("ul",{tabIndex:0,role:"listbox","aria-label":this.view.state.phrase("Diagnostics"),onkeydown:A,onclick:i}),this.dom=kn("div",{class:"cm-panel-lint"},this.list,kn("button",{type:"button",name:"close","aria-label":this.view.state.phrase("close"),onclick:()=>dnA(this.view)},"\xD7")),this.update()}get selectedIndex(){let e=this.view.state.field(oc).selected;if(!e)return-1;for(let A=0;A<this.items.length;A++)if(this.items[A].diagnostic==e.diagnostic)return A;return-1}update(){let{diagnostics:e,selected:A}=this.view.state.field(oc),i=0,n=!1,o=null,r=new Set;for(e.between(0,this.view.state.doc.length,(s,a,{spec:c})=>{for(let l of c.diagnostics){if(r.has(l))continue;r.add(l);let I=-1,C;for(let d=i;d<this.items.length;d++)if(this.items[d].diagnostic==l){I=d;break}I<0?(C=new rD(this.view,l),this.items.splice(i,0,C),n=!0):(C=this.items[I],I>i&&(this.items.splice(i,I-i),n=!0)),A&&C.diagnostic==A.diagnostic?C.dom.hasAttribute("aria-selected")||(C.dom.setAttribute("aria-selected","true"),o=C):C.dom.hasAttribute("aria-selected")&&C.dom.removeAttribute("aria-selected"),i++}});i<this.items.length&&!(this.items.length==1&&this.items[0].diagnostic.from<0);)n=!0,this.items.pop();this.items.length==0&&(this.items.push(new rD(this.view,{from:-1,to:-1,severity:"info",message:this.view.state.phrase("No diagnostics")})),n=!0),o?(this.list.setAttribute("aria-activedescendant",o.id),this.view.requestMeasure({key:this,read:()=>({sel:o.dom.getBoundingClientRect(),panel:this.list.getBoundingClientRect()}),write:({sel:s,panel:a})=>{let c=a.height/this.list.offsetHeight;s.top<a.top?this.list.scrollTop-=(a.top-s.top)/c:s.bottom>a.bottom&&(this.list.scrollTop+=(s.bottom-a.bottom)/c)}})):this.selectedIndex<0&&this.list.removeAttribute("aria-activedescendant"),n&&this.sync()}sync(){let e=this.list.firstChild;function A(){let i=e;e=i.nextSibling,i.remove()}for(let i of this.items)if(i.dom.parentNode==this.list){for(;e!=i.dom;)A();e=i.dom.nextSibling}else this.list.insertBefore(i.dom,e);for(;e;)A()}moveSelection(e){if(this.selectedIndex<0)return;let A=this.view.state.field(oc),i=LE(A.diagnostics,this.items[e].diagnostic);i&&this.view.dispatch({selection:{anchor:i.from,head:i.to},scrollIntoView:!0,effects:hnA.of(i)})}static open(e){return new t(e)}};function nD(t,e='viewBox="0 0 40 40"'){return`url('data:image/svg+xml,<svg xmlns="http://www.w3.org/2000/svg" ${e}>${encodeURIComponent(t)}</svg>')`}function iD(t){return nD(`<path d="m0 2.5 l2 -1.5 l1 0 l2 1.5 l1 0" stroke="${t}" fill="none" stroke-width=".7"/>`,'width="6" height="3"')}var HFA=St.baseTheme({".cm-diagnostic":{padding:"3px 6px 3px 8px",marginLeft:"-1px",display:"block",whiteSpace:"pre-wrap"},".cm-diagnostic-error":{borderLeft:"5px solid #d11"},".cm-diagnostic-warning":{borderLeft:"5px solid orange"},".cm-diagnostic-info":{borderLeft:"5px solid #999"},".cm-diagnostic-hint":{borderLeft:"5px solid #66d"},".cm-diagnosticAction":{font:"inherit",border:"none",padding:"2px 4px",backgroundColor:"#444",color:"white",borderRadius:"3px",marginLeft:"8px",cursor:"pointer"},".cm-diagnosticSource":{fontSize:"70%",opacity:.7},".cm-lintRange":{backgroundPosition:"left bottom",backgroundRepeat:"repeat-x",paddingBottom:"0.7px"},".cm-lintRange-error":{backgroundImage:iD("#d11")},".cm-lintRange-warning":{backgroundImage:iD("orange")},".cm-lintRange-info":{backgroundImage:iD("#999")},".cm-lintRange-hint":{backgroundImage:iD("#66d")},".cm-lintRange-active":{backgroundColor:"#ffdd9980"},".cm-tooltip-lint":{padding:0,margin:0},".cm-lintPoint":{position:"relative","&:after":{content:'""',position:"absolute",bottom:0,left:"-2px",borderLeft:"3px solid transparent",borderRight:"3px solid transparent",borderBottom:"4px solid #d11"}},".cm-lintPoint-warning":{"&:after":{borderBottomColor:"orange"}},".cm-lintPoint-info":{"&:after":{borderBottomColor:"#999"}},".cm-lintPoint-hint":{"&:after":{borderBottomColor:"#66d"}},".cm-panel.cm-panel-lint":{position:"relative","& ul":{maxHeight:"100px",overflowY:"auto","& [aria-selected]":{backgroundColor:"#ddd","& u":{textDecoration:"underline"}},"&:focus [aria-selected]":{background_fallback:"#bdf",backgroundColor:"Highlight",color_fallback:"white",color:"HighlightText"},"& u":{textDecoration:"none"},padding:0,margin:0},"& [name=close]":{position:"absolute",top:"0",right:"2px",background:"inherit",border:"none",font:"inherit",padding:0,margin:0}}});function OFA(t){return t=="error"?4:t=="warning"?3:t=="info"?2:1}function wnA(t){let e="hint",A=1;for(let i of t){let n=OFA(i.severity);n>A&&(A=n,e=i.severity)}return e}var sD=class extends ya{constructor(e){super(),this.diagnostics=e,this.severity=wnA(e)}toDOM(e){let A=document.createElement("div");A.className="cm-lint-marker cm-lint-marker-"+this.severity;let i=this.diagnostics,n=e.state.facet(cD).tooltipFilter;return n&&(i=n(i,e.state)),i.length&&(A.onmouseover=()=>jFA(e,A,i)),A}};function PFA(t,e){let A=i=>{let n=e.getBoundingClientRect();if(!(i.clientX>n.left-10&&i.clientX<n.right+10&&i.clientY>n.top-10&&i.clientY<n.bottom+10)){for(let o=i.target;o;o=o.parentNode)if(o.nodeType==1&&o.classList.contains("cm-tooltip-lint"))return;window.removeEventListener("mousemove",A),t.state.field(DnA)&&t.dispatch({effects:GF.of(null)})}};window.addEventListener("mousemove",A)}function jFA(t,e,A){function i(){let r=t.elementAtHeight(e.getBoundingClientRect().top+5-t.documentTop);t.coordsAtPos(r.from)&&t.dispatch({effects:GF.of({pos:r.from,above:!1,clip:!1,create(){return{dom:QnA(t,A),getCoords:()=>e.getBoundingClientRect()}}})}),e.onmouseout=e.onmousemove=null,PFA(t,e)}let{hoverTime:n}=t.state.facet(cD),o=setTimeout(i,n);e.onmouseout=()=>{clearTimeout(o),e.onmouseout=e.onmousemove=null},e.onmousemove=()=>{clearTimeout(o),o=setTimeout(i,n)}}function qFA(t,e){let A=Object.create(null);for(let n of e){let o=t.lineAt(n.from);(A[o.from]||(A[o.from]=[])).push(n)}let i=[];for(let n in A)i.push(new sD(A[n]).range(+n));return Zn.of(i,!0)}var VFA=Uw({class:"cm-gutter-lint",markers:t=>t.state.field(NF),widgetMarker:(t,e,A)=>{let i=[];return t.state.field(NF).between(A.from,A.to,(n,o,r)=>{n>A.from&&n<A.to&&i.push(...r.diagnostics)}),i.length?new sD(i):null}}),NF=To.define({create(){return Zn.empty},update(t,e){t=t.map(e.changes);let A=e.state.facet(cD).markerFilter;for(let i of e.effects)if(i.is(aD)){let n=i.value;A&&(n=A(n||[],e.state)),t=qFA(e.state.doc,n.slice(0))}return t}}),GF=ki.define(),DnA=To.define({create(){return null},update(t,e){return t&&e.docChanged&&(t=BnA(e,t)?null:Object.assign(Object.assign({},t),{pos:e.changes.mapPos(t.pos)})),e.effects.reduce((A,i)=>i.is(GF)?i.value:A,t)},provide:t=>DE.from(t)}),ZFA=St.baseTheme({".cm-gutter-lint":{width:"1.4em","& .cm-gutterElement":{padding:".2em"}},".cm-lint-marker":{width:"1em",height:"1em"},".cm-lint-marker-info":{content:nD('<path fill="#aaf" stroke="#77e" stroke-width="6" stroke-linejoin="round" d="M5 5L35 5L35 35L5 35Z"/>')},".cm-lint-marker-warning":{content:nD('<path fill="#fe8" stroke="#fd7" stroke-width="6" stroke-linejoin="round" d="M20 6L37 35L3 35Z"/>')},".cm-lint-marker-error":{content:nD('<circle cx="20" cy="20" r="15" fill="#f87" stroke="#f43" stroke-width="6"/>')}}),ynA=[oc,St.decorations.compute([oc],t=>{let{selected:e,panel:A}=t.field(oc);return!e||!A||e.from==e.to?rt.none:rt.set([UFA.range(e.from,e.to)])}),jtA(KFA,{hideOn:BnA}),HFA],cD=Te.define({combine(t){return zr(t,{hoverTime:300,markerFilter:null,tooltipFilter:null})}});function vnA(t={}){return[cD.of(t),NF,VFA,ZFA,DnA]}var KF=class t{constructor(e,A,i,n,o,r,s,a,c,l=0,I){this.p=e,this.stack=A,this.state=i,this.reducePos=n,this.pos=o,this.score=r,this.buffer=s,this.bufferBase=a,this.curContext=c,this.lookAhead=l,this.parent=I}toString(){return`[${this.stack.filter((e,A)=>A%3==0).concat(this.state)}]@${this.pos}${this.score?"!"+this.score:""}`}static start(e,A,i=0){let n=e.parser.context;return new t(e,[],A,i,i,0,[],0,n?new lD(n,n.start):null,0,null)}get context(){return this.curContext?this.curContext.context:null}pushState(e,A){this.stack.push(this.state,A,this.bufferBase+this.buffer.length),this.state=e}reduce(e){var A;let i=e>>19,n=e&65535,{parser:o}=this.p,r=this.reducePos<this.pos-25;r&&this.setLookAhead(this.pos);let s=o.dynamicPrecedence(n);if(s&&(this.score+=s),i==0){this.pushState(o.getGoto(this.state,n,!0),this.reducePos),n<o.minRepeatTerm&&this.storeNode(n,this.reducePos,this.reducePos,r?8:4,!0),this.reduceContext(n,this.reducePos);return}let a=this.stack.length-(i-1)*3-(e&262144?6:0),c=a?this.stack[a-2]:this.p.ranges[0].from,l=this.reducePos-c;l>=2e3&&!(!((A=this.p.parser.nodeSet.types[n])===null||A===void 0)&&A.isAnonymous)&&(c==this.p.lastBigReductionStart?(this.p.bigReductionCount++,this.p.lastBigReductionSize=l):this.p.lastBigReductionSize<l&&(this.p.bigReductionCount=1,this.p.lastBigReductionStart=c,this.p.lastBigReductionSize=l));let I=a?this.stack[a-1]:0,C=this.bufferBase+this.buffer.length-I;if(n<o.minRepeatTerm||e&131072){let d=o.stateFlag(this.state,1)?this.pos:this.reducePos;this.storeNode(n,c,d,C+4,!0)}if(e&262144)this.state=this.stack[a];else{let d=this.stack[a-3];this.state=o.getGoto(d,n,!0)}for(;this.stack.length>a;)this.stack.pop();this.reduceContext(n,c)}storeNode(e,A,i,n=4,o=!1){if(e==0&&(!this.stack.length||this.stack[this.stack.length-1]<this.buffer.length+this.bufferBase)){let r=this,s=this.buffer.length;if(s==0&&r.parent&&(s=r.bufferBase-r.parent.bufferBase,r=r.parent),s>0&&r.buffer[s-4]==0&&r.buffer[s-1]>-1){if(A==i)return;if(r.buffer[s-2]>=A){r.buffer[s-2]=i;return}}}if(!o||this.pos==i)this.buffer.push(e,A,i,n);else{let r=this.buffer.length;if(r>0&&this.buffer[r-4]!=0){let s=!1;for(let a=r;a>0&&this.buffer[a-2]>i;a-=4)if(this.buffer[a-1]>=0){s=!0;break}if(s)for(;r>0&&this.buffer[r-2]>i;)this.buffer[r]=this.buffer[r-4],this.buffer[r+1]=this.buffer[r-3],this.buffer[r+2]=this.buffer[r-2],this.buffer[r+3]=this.buffer[r-1],r-=4,n>4&&(n-=4)}this.buffer[r]=e,this.buffer[r+1]=A,this.buffer[r+2]=i,this.buffer[r+3]=n}}shift(e,A,i,n){if(e&131072)this.pushState(e&65535,this.pos);else if((e&262144)==0){let o=e,{parser:r}=this.p;(n>this.pos||A<=r.maxNode)&&(this.pos=n,r.stateFlag(o,1)||(this.reducePos=n)),this.pushState(o,i),this.shiftContext(A,i),A<=r.maxNode&&this.buffer.push(A,i,n,4)}else this.pos=n,this.shiftContext(A,i),A<=this.p.parser.maxNode&&this.buffer.push(A,i,n,4)}apply(e,A,i,n){e&65536?this.reduce(e):this.shift(e,A,i,n)}useNode(e,A){let i=this.p.reused.length-1;(i<0||this.p.reused[i]!=e)&&(this.p.reused.push(e),i++);let n=this.pos;this.reducePos=this.pos=n+e.length,this.pushState(A,n),this.buffer.push(i,n,this.reducePos,-1),this.curContext&&this.updateContext(this.curContext.tracker.reuse(this.curContext.context,e,this,this.p.stream.reset(this.pos-e.length)))}split(){let e=this,A=e.buffer.length;for(;A>0&&e.buffer[A-2]>e.reducePos;)A-=4;let i=e.buffer.slice(A),n=e.bufferBase+A;for(;e&&n==e.bufferBase;)e=e.parent;return new t(this.p,this.stack.slice(),this.state,this.reducePos,this.pos,this.score,i,n,this.curContext,this.lookAhead,e)}recoverByDelete(e,A){let i=e<=this.p.parser.maxNode;i&&this.storeNode(e,this.pos,A,4),this.storeNode(0,this.pos,A,i?8:4),this.pos=this.reducePos=A,this.score-=190}canShift(e){for(let A=new YF(this);;){let i=this.p.parser.stateSlot(A.state,4)||this.p.parser.hasAction(A.state,e);if(i==0)return!1;if((i&65536)==0)return!0;A.reduce(i)}}recoverByInsert(e){if(this.stack.length>=300)return[];let A=this.p.parser.nextStates(this.state);if(A.length>8||this.stack.length>=120){let n=[];for(let o=0,r;o<A.length;o+=2)(r=A[o+1])!=this.state&&this.p.parser.hasAction(r,e)&&n.push(A[o],r);if(this.stack.length<120)for(let o=0;n.length<8&&o<A.length;o+=2){let r=A[o+1];n.some((s,a)=>a&1&&s==r)||n.push(A[o],r)}A=n}let i=[];for(let n=0;n<A.length&&i.length<4;n+=2){let o=A[n+1];if(o==this.state)continue;let r=this.split();r.pushState(o,this.pos),r.storeNode(0,r.pos,r.pos,4,!0),r.shiftContext(A[n],this.pos),r.reducePos=this.pos,r.score-=200,i.push(r)}return i}forceReduce(){let{parser:e}=this.p,A=e.stateSlot(this.state,5);if((A&65536)==0)return!1;if(!e.validAction(this.state,A)){let i=A>>19,n=A&65535,o=this.stack.length-i*3;if(o<0||e.getGoto(this.stack[o],n,!1)<0){let r=this.findForcedReduction();if(r==null)return!1;A=r}this.storeNode(0,this.pos,this.pos,4,!0),this.score-=100}return this.reducePos=this.pos,this.reduce(A),!0}findForcedReduction(){let{parser:e}=this.p,A=[],i=(n,o)=>{if(!A.includes(n))return A.push(n),e.allActions(n,r=>{if(!(r&393216))if(r&65536){let s=(r>>19)-o;if(s>1){let a=r&65535,c=this.stack.length-s*3;if(c>=0&&e.getGoto(this.stack[c],a,!1)>=0)return s<<19|65536|a}}else{let s=i(r,o+1);if(s!=null)return s}})};return i(this.state,0)}forceAll(){for(;!this.p.parser.stateFlag(this.state,2);)if(!this.forceReduce()){this.storeNode(0,this.pos,this.pos,4,!0);break}return this}get deadEnd(){if(this.stack.length!=3)return!1;let{parser:e}=this.p;return e.data[e.stateSlot(this.state,1)]==65535&&!e.stateSlot(this.state,4)}restart(){this.storeNode(0,this.pos,this.pos,4,!0),this.state=this.stack[0],this.stack.length=0}sameState(e){if(this.state!=e.state||this.stack.length!=e.stack.length)return!1;for(let A=0;A<this.stack.length;A+=3)if(this.stack[A]!=e.stack[A])return!1;return!0}get parser(){return this.p.parser}dialectEnabled(e){return this.p.parser.dialect.flags[e]}shiftContext(e,A){this.curContext&&this.updateContext(this.curContext.tracker.shift(this.curContext.context,e,this,this.p.stream.reset(A)))}reduceContext(e,A){this.curContext&&this.updateContext(this.curContext.tracker.reduce(this.curContext.context,e,this,this.p.stream.reset(A)))}emitContext(){let e=this.buffer.length-1;(e<0||this.buffer[e]!=-3)&&this.buffer.push(this.curContext.hash,this.pos,this.pos,-3)}emitLookAhead(){let e=this.buffer.length-1;(e<0||this.buffer[e]!=-4)&&this.buffer.push(this.lookAhead,this.pos,this.pos,-4)}updateContext(e){if(e!=this.curContext.context){let A=new lD(this.curContext.tracker,e);A.hash!=this.curContext.hash&&this.emitContext(),this.curContext=A}}setLookAhead(e){e>this.lookAhead&&(this.emitLookAhead(),this.lookAhead=e)}close(){this.curContext&&this.curContext.tracker.strict&&this.emitContext(),this.lookAhead>0&&this.emitLookAhead()}},lD=class{constructor(e,A){this.tracker=e,this.context=A,this.hash=e.strict?e.hash(A):0}},YF=class{constructor(e){this.start=e,this.state=e.state,this.stack=e.stack,this.base=this.stack.length}reduce(e){let A=e&65535,i=e>>19;i==0?(this.stack==this.start.stack&&(this.stack=this.stack.slice()),this.stack.push(this.state,0,0),this.base+=3):this.base-=(i-1)*3;let n=this.start.p.parser.getGoto(this.stack[this.base-3],A,!0);this.state=n}},JF=class t{constructor(e,A,i){this.stack=e,this.pos=A,this.index=i,this.buffer=e.buffer,this.index==0&&this.maybeNext()}static create(e,A=e.bufferBase+e.buffer.length){return new t(e,A,A-e.bufferBase)}maybeNext(){let e=this.stack.parent;e!=null&&(this.index=this.stack.bufferBase-e.bufferBase,this.stack=e,this.buffer=e.buffer)}get id(){return this.buffer[this.index-4]}get start(){return this.buffer[this.index-3]}get end(){return this.buffer[this.index-2]}get size(){return this.buffer[this.index-1]}next(){this.index-=4,this.pos-=4,this.index==0&&this.maybeNext()}fork(){return new t(this.stack,this.pos,this.index)}};function c3(t,e=Uint16Array){if(typeof t!="string")return t;let A=null;for(let i=0,n=0;i<t.length;){let o=0;for(;;){let r=t.charCodeAt(i++),s=!1;if(r==126){o=65535;break}r>=92&&r--,r>=34&&r--;let a=r-32;if(a>=46&&(a-=46,s=!0),o+=a,s)break;o*=46}A?A[n++]=o:A=new e(o)}return A}var xE=class{constructor(){this.start=-1,this.value=-1,this.end=-1,this.extended=-1,this.lookAhead=0,this.mask=0,this.context=0}},bnA=new xE,TF=class{constructor(e,A){this.input=e,this.ranges=A,this.chunk="",this.chunkOff=0,this.chunk2="",this.chunk2Pos=0,this.next=-1,this.token=bnA,this.rangeIndex=0,this.pos=this.chunkPos=A[0].from,this.range=A[0],this.end=A[A.length-1].to,this.readNext()}resolveOffset(e,A){let i=this.range,n=this.rangeIndex,o=this.pos+e;for(;o<i.from;){if(!n)return null;let r=this.ranges[--n];o-=i.from-r.to,i=r}for(;A<0?o>i.to:o>=i.to;){if(n==this.ranges.length-1)return null;let r=this.ranges[++n];o+=r.from-i.to,i=r}return o}clipPos(e){if(e>=this.range.from&&e<this.range.to)return e;for(let A of this.ranges)if(A.to>e)return Math.max(e,A.from);return this.end}peek(e){let A=this.chunkOff+e,i,n;if(A>=0&&A<this.chunk.length)i=this.pos+e,n=this.chunk.charCodeAt(A);else{let o=this.resolveOffset(e,1);if(o==null)return-1;if(i=o,i>=this.chunk2Pos&&i<this.chunk2Pos+this.chunk2.length)n=this.chunk2.charCodeAt(i-this.chunk2Pos);else{let r=this.rangeIndex,s=this.range;for(;s.to<=i;)s=this.ranges[++r];this.chunk2=this.input.chunk(this.chunk2Pos=i),i+this.chunk2.length>s.to&&(this.chunk2=this.chunk2.slice(0,s.to-i)),n=this.chunk2.charCodeAt(0)}}return i>=this.token.lookAhead&&(this.token.lookAhead=i+1),n}acceptToken(e,A=0){let i=A?this.resolveOffset(A,-1):this.pos;if(i==null||i<this.token.start)throw new RangeError("Token end out of bounds");this.token.value=e,this.token.end=i}acceptTokenTo(e,A){this.token.value=e,this.token.end=A}getChunk(){if(this.pos>=this.chunk2Pos&&this.pos<this.chunk2Pos+this.chunk2.length){let{chunk:e,chunkPos:A}=this;this.chunk=this.chunk2,this.chunkPos=this.chunk2Pos,this.chunk2=e,this.chunk2Pos=A,this.chunkOff=this.pos-this.chunkPos}else{this.chunk2=this.chunk,this.chunk2Pos=this.chunkPos;let e=this.input.chunk(this.pos),A=this.pos+e.length;this.chunk=A>this.range.to?e.slice(0,this.range.to-this.pos):e,this.chunkPos=this.pos,this.chunkOff=0}}readNext(){return this.chunkOff>=this.chunk.length&&(this.getChunk(),this.chunkOff==this.chunk.length)?this.next=-1:this.next=this.chunk.charCodeAt(this.chunkOff)}advance(e=1){for(this.chunkOff+=e;this.pos+e>=this.range.to;){if(this.rangeIndex==this.ranges.length-1)return this.setDone();e-=this.range.to-this.pos,this.range=this.ranges[++this.rangeIndex],this.pos=this.range.from}return this.pos+=e,this.pos>=this.token.lookAhead&&(this.token.lookAhead=this.pos+1),this.readNext()}setDone(){return this.pos=this.chunkPos=this.end,this.range=this.ranges[this.rangeIndex=this.ranges.length-1],this.chunk="",this.next=-1}reset(e,A){if(A?(this.token=A,A.start=e,A.lookAhead=e+1,A.value=A.extended=-1):this.token=bnA,this.pos!=e){if(this.pos=e,e==this.end)return this.setDone(),this;for(;e<this.range.from;)this.range=this.ranges[--this.rangeIndex];for(;e>=this.range.to;)this.range=this.ranges[++this.rangeIndex];e>=this.chunkPos&&e<this.chunkPos+this.chunk.length?this.chunkOff=e-this.chunkPos:(this.chunk="",this.chunkOff=0),this.readNext()}return this}read(e,A){if(e>=this.chunkPos&&A<=this.chunkPos+this.chunk.length)return this.chunk.slice(e-this.chunkPos,A-this.chunkPos);if(e>=this.chunk2Pos&&A<=this.chunk2Pos+this.chunk2.length)return this.chunk2.slice(e-this.chunk2Pos,A-this.chunk2Pos);if(e>=this.range.from&&A<=this.range.to)return this.input.read(e,A);let i="";for(let n of this.ranges){if(n.from>=A)break;n.to>e&&(i+=this.input.read(Math.max(n.from,e),Math.min(n.to,A)))}return i}},v1=class{constructor(e,A){this.data=e,this.id=A}token(e,A){let{parser:i}=A.p;LnA(this.data,e,A,this.id,i.data,i.tokenPrecTable)}};v1.prototype.contextual=v1.prototype.fallback=v1.prototype.extend=!1;var zF=class{constructor(e,A,i){this.precTable=A,this.elseToken=i,this.data=typeof e=="string"?c3(e):e}token(e,A){let i=e.pos,n=0;for(;;){let o=e.next<0,r=e.resolveOffset(1,1);if(LnA(this.data,e,A,0,this.data,this.precTable),e.token.value>-1)break;if(this.elseToken==null)return;if(o||n++,r==null)break;e.reset(r,e.token)}n&&(e.reset(i,e.token),e.acceptToken(this.elseToken,n))}};zF.prototype.contextual=v1.prototype.fallback=v1.prototype.extend=!1;function LnA(t,e,A,i,n,o){let r=0,s=1<<i,{dialect:a}=A.p.parser;A:for(;(s&t[r])!=0;){let c=t[r+1];for(let d=r+3;d<c;d+=2)if((t[d+1]&s)>0){let B=t[d];if(a.allows(B)&&(e.token.value==-1||e.token.value==B||XFA(B,e.token.value,n,o))){e.acceptToken(B);break}}let l=e.next,I=0,C=t[r+2];if(e.next<0&&C>I&&t[c+C*3-3]==65535){r=t[c+C*3-1];continue A}for(;I<C;){let d=I+C>>1,B=c+d+(d<<1),E=t[B],Q=t[B+1]||65536;if(l<E)C=d;else if(l>=Q)I=d+1;else{r=t[B+2],e.advance();continue A}}break}}function MnA(t,e,A){for(let i=e,n;(n=t[i])!=65535;i++)if(n==A)return i-e;return-1}function XFA(t,e,A,i){let n=MnA(A,i,e);return n<0||MnA(A,i,t)<n}var rc=typeof process<"u"&&process.env&&/\bparse\b/.test(process.env.LOG),UF=null;function knA(t,e,A){let i=t.cursor(Fr.IncludeAnonymous);for(i.moveTo(e);;)if(!(A<0?i.childBefore(e):i.childAfter(e)))for(;;){if((A<0?i.to<e:i.from>e)&&!i.type.isError)return A<0?Math.max(0,Math.min(i.to-1,e-25)):Math.min(t.length,Math.max(i.from+1,e+25));if(A<0?i.prevSibling():i.nextSibling())break;if(!i.parent())return A<0?0:t.length}}var HF=class{constructor(e,A){this.fragments=e,this.nodeSet=A,this.i=0,this.fragment=null,this.safeFrom=-1,this.safeTo=-1,this.trees=[],this.start=[],this.index=[],this.nextFragment()}nextFragment(){let e=this.fragment=this.i==this.fragments.length?null:this.fragments[this.i++];if(e){for(this.safeFrom=e.openStart?knA(e.tree,e.from+e.offset,1)-e.offset:e.from,this.safeTo=e.openEnd?knA(e.tree,e.to+e.offset,-1)-e.offset:e.to;this.trees.length;)this.trees.pop(),this.start.pop(),this.index.pop();this.trees.push(e.tree),this.start.push(-e.offset),this.index.push(0),this.nextStart=this.safeFrom}else this.nextStart=1e9}nodeAt(e){if(e<this.nextStart)return null;for(;this.fragment&&this.safeTo<=e;)this.nextFragment();if(!this.fragment)return null;for(;;){let A=this.trees.length-1;if(A<0)return this.nextFragment(),null;let i=this.trees[A],n=this.index[A];if(n==i.children.length){this.trees.pop(),this.start.pop(),this.index.pop();continue}let o=i.children[n],r=this.start[A]+i.positions[n];if(r>e)return this.nextStart=r,null;if(o instanceof Cr){if(r==e){if(r<this.safeFrom)return null;let s=r+o.length;if(s<=this.safeTo){let a=o.prop(si.lookAhead);if(!a||s+a<this.fragment.to)return o}}this.index[A]++,r+o.length>=Math.max(this.safeFrom,e)&&(this.trees.push(o),this.start.push(r),this.index.push(0))}else this.index[A]++,this.nextStart=r+o.length}}},OF=class{constructor(e,A){this.stream=A,this.tokens=[],this.mainToken=null,this.actions=[],this.tokens=e.tokenizers.map(i=>new xE)}getActions(e){let A=0,i=null,{parser:n}=e.p,{tokenizers:o}=n,r=n.stateSlot(e.state,3),s=e.curContext?e.curContext.hash:0,a=0;for(let c=0;c<o.length;c++){if((1<<c&r)==0)continue;let l=o[c],I=this.tokens[c];if(!(i&&!l.fallback)&&((l.contextual||I.start!=e.pos||I.mask!=r||I.context!=s)&&(this.updateCachedToken(I,l,e),I.mask=r,I.context=s),I.lookAhead>I.end+25&&(a=Math.max(I.lookAhead,a)),I.value!=0)){let C=A;if(I.extended>-1&&(A=this.addActions(e,I.extended,I.end,A)),A=this.addActions(e,I.value,I.end,A),!l.extend&&(i=I,A>C))break}}for(;this.actions.length>A;)this.actions.pop();return a&&e.setLookAhead(a),!i&&e.pos==this.stream.end&&(i=new xE,i.value=e.p.parser.eofTerm,i.start=i.end=e.pos,A=this.addActions(e,i.value,i.end,A)),this.mainToken=i,this.actions}getMainToken(e){if(this.mainToken)return this.mainToken;let A=new xE,{pos:i,p:n}=e;return A.start=i,A.end=Math.min(i+1,n.stream.end),A.value=i==n.stream.end?n.parser.eofTerm:0,A}updateCachedToken(e,A,i){let n=this.stream.clipPos(i.pos);if(A.token(this.stream.reset(n,e),i),e.value>-1){let{parser:o}=i.p;for(let r=0;r<o.specialized.length;r++)if(o.specialized[r]==e.value){let s=o.specializers[r](this.stream.read(e.start,e.end),i);if(s>=0&&i.p.parser.dialect.allows(s>>1)){(s&1)==0?e.value=s>>1:e.extended=s>>1;break}}}else e.value=0,e.end=this.stream.clipPos(n+1)}putAction(e,A,i,n){for(let o=0;o<n;o+=3)if(this.actions[o]==e)return n;return this.actions[n++]=e,this.actions[n++]=A,this.actions[n++]=i,n}addActions(e,A,i,n){let{state:o}=e,{parser:r}=e.p,{data:s}=r;for(let a=0;a<2;a++)for(let c=r.stateSlot(o,a?2:1);;c+=3){if(s[c]==65535)if(s[c+1]==1)c=Y0(s,c+2);else{n==0&&s[c+1]==2&&(n=this.putAction(Y0(s,c+2),A,i,n));break}s[c]==A&&(n=this.putAction(Y0(s,c+1),A,i,n))}return n}},PF=class{constructor(e,A,i,n){this.parser=e,this.input=A,this.ranges=n,this.recovering=0,this.nextStackID=9812,this.minStackPos=0,this.reused=[],this.stoppedAt=null,this.lastBigReductionStart=-1,this.lastBigReductionSize=0,this.bigReductionCount=0,this.stream=new TF(A,n),this.tokens=new OF(e,this.stream),this.topTerm=e.top[1];let{from:o}=n[0];this.stacks=[KF.start(this,e.top[0],o)],this.fragments=i.length&&this.stream.end-o>e.bufferLength*4?new HF(i,e.nodeSet):null}get parsedPos(){return this.minStackPos}advance(){let e=this.stacks,A=this.minStackPos,i=this.stacks=[],n,o;if(this.bigReductionCount>300&&e.length==1){let[r]=e;for(;r.forceReduce()&&r.stack.length&&r.stack[r.stack.length-2]>=this.lastBigReductionStart;);this.bigReductionCount=this.lastBigReductionSize=0}for(let r=0;r<e.length;r++){let s=e[r];for(;;){if(this.tokens.mainToken=null,s.pos>A)i.push(s);else{if(this.advanceStack(s,i,e))continue;{n||(n=[],o=[]),n.push(s);let a=this.tokens.getMainToken(s);o.push(a.value,a.end)}}break}}if(!i.length){let r=n&&$FA(n);if(r)return rc&&console.log("Finish with "+this.stackID(r)),this.stackToTree(r);if(this.parser.strict)throw rc&&n&&console.log("Stuck with token "+(this.tokens.mainToken?this.parser.getName(this.tokens.mainToken.value):"none")),new SyntaxError("No parse at "+A);this.recovering||(this.recovering=5)}if(this.recovering&&n){let r=this.stoppedAt!=null&&n[0].pos>this.stoppedAt?n[0]:this.runRecovery(n,o,i);if(r)return rc&&console.log("Force-finish "+this.stackID(r)),this.stackToTree(r.forceAll())}if(this.recovering){let r=this.recovering==1?1:this.recovering*3;if(i.length>r)for(i.sort((s,a)=>a.score-s.score);i.length>r;)i.pop();i.some(s=>s.reducePos>A)&&this.recovering--}else if(i.length>1){A:for(let r=0;r<i.length-1;r++){let s=i[r];for(let a=r+1;a<i.length;a++){let c=i[a];if(s.sameState(c)||s.buffer.length>500&&c.buffer.length>500)if((s.score-c.score||s.buffer.length-c.buffer.length)>0)i.splice(a--,1);else{i.splice(r--,1);continue A}}}i.length>12&&i.splice(12,i.length-12)}this.minStackPos=i[0].pos;for(let r=1;r<i.length;r++)i[r].pos<this.minStackPos&&(this.minStackPos=i[r].pos);return null}stopAt(e){if(this.stoppedAt!=null&&this.stoppedAt<e)throw new RangeError("Can't move stoppedAt forward");this.stoppedAt=e}advanceStack(e,A,i){let n=e.pos,{parser:o}=this,r=rc?this.stackID(e)+" -> ":"";if(this.stoppedAt!=null&&n>this.stoppedAt)return e.forceReduce()?e:null;if(this.fragments){let c=e.curContext&&e.curContext.tracker.strict,l=c?e.curContext.hash:0;for(let I=this.fragments.nodeAt(n);I;){let C=this.parser.nodeSet.types[I.type.id]==I.type?o.getGoto(e.state,I.type.id):-1;if(C>-1&&I.length&&(!c||(I.prop(si.contextHash)||0)==l))return e.useNode(I,C),rc&&console.log(r+this.stackID(e)+` (via reuse of ${o.getName(I.type.id)})`),!0;if(!(I instanceof Cr)||I.children.length==0||I.positions[0]>0)break;let d=I.children[0];if(d instanceof Cr&&I.positions[0]==0)I=d;else break}}let s=o.stateSlot(e.state,4);if(s>0)return e.reduce(s),rc&&console.log(r+this.stackID(e)+` (via always-reduce ${o.getName(s&65535)})`),!0;if(e.stack.length>=8400)for(;e.stack.length>6e3&&e.forceReduce(););let a=this.tokens.getActions(e);for(let c=0;c<a.length;){let l=a[c++],I=a[c++],C=a[c++],d=c==a.length||!i,B=d?e:e.split(),E=this.tokens.mainToken;if(B.apply(l,I,E?E.start:B.pos,C),rc&&console.log(r+this.stackID(B)+` (via ${(l&65536)==0?"shift":`reduce of ${o.getName(l&65535)}`} for ${o.getName(I)} @ ${n}${B==e?"":", split"})`),d)return!0;B.pos>n?A.push(B):i.push(B)}return!1}advanceFully(e,A){let i=e.pos;for(;;){if(!this.advanceStack(e,null,null))return!1;if(e.pos>i)return SnA(e,A),!0}}runRecovery(e,A,i){let n=null,o=!1;for(let r=0;r<e.length;r++){let s=e[r],a=A[r<<1],c=A[(r<<1)+1],l=rc?this.stackID(s)+" -> ":"";if(s.deadEnd&&(o||(o=!0,s.restart(),rc&&console.log(l+this.stackID(s)+" (restarted)"),this.advanceFully(s,i))))continue;let I=s.split(),C=l;for(let d=0;I.forceReduce()&&d<10&&(rc&&console.log(C+this.stackID(I)+" (via force-reduce)"),!this.advanceFully(I,i));d++)rc&&(C=this.stackID(I)+" -> ");for(let d of s.recoverByInsert(a))rc&&console.log(l+this.stackID(d)+" (via recover-insert)"),this.advanceFully(d,i);this.stream.end>s.pos?(c==s.pos&&(c++,a=0),s.recoverByDelete(a,c),rc&&console.log(l+this.stackID(s)+` (via recover-delete ${this.parser.getName(a)})`),SnA(s,i)):(!n||n.score<s.score)&&(n=s)}return n}stackToTree(e){return e.close(),Cr.build({buffer:JF.create(e),nodeSet:this.parser.nodeSet,topID:this.topTerm,maxBufferLength:this.parser.bufferLength,reused:this.reused,start:this.ranges[0].from,length:e.pos-this.ranges[0].from,minRepeatType:this.parser.minRepeatTerm})}stackID(e){let A=(UF||(UF=new WeakMap)).get(e);return A||UF.set(e,A=String.fromCodePoint(this.nextStackID++)),A+e}};function SnA(t,e){for(let A=0;A<e.length;A++){let i=e[A];if(i.pos==t.pos&&i.sameState(t)){e[A].score<t.score&&(e[A]=t);return}}e.push(t)}var jF=class{constructor(e,A,i){this.source=e,this.flags=A,this.disabled=i}allows(e){return!this.disabled||this.disabled[e]==0}};var gD=class t extends vE{constructor(e){if(super(),this.wrappers=[],e.version!=14)throw new RangeError(`Parser version (${e.version}) doesn't match runtime version (14)`);let A=e.nodeNames.split(" ");this.minRepeatTerm=A.length;for(let s=0;s<e.repeatNodeCount;s++)A.push("");let i=Object.keys(e.topRules).map(s=>e.topRules[s][1]),n=[];for(let s=0;s<A.length;s++)n.push([]);function o(s,a,c){n[s].push([a,a.deserialize(String(c))])}if(e.nodeProps)for(let s of e.nodeProps){let a=s[0];typeof a=="string"&&(a=si[a]);for(let c=1;c<s.length;){let l=s[c++];if(l>=0)o(l,a,s[c++]);else{let I=s[c+-l];for(let C=-l;C>0;C--)o(s[c++],a,I);c++}}}this.nodeSet=new W4(A.map((s,a)=>ws.define({name:a>=this.minRepeatTerm?void 0:s,id:a,props:n[a],top:i.indexOf(a)>-1,error:a==0,skipped:e.skippedNodes&&e.skippedNodes.indexOf(a)>-1}))),e.propSources&&(this.nodeSet=this.nodeSet.extend(...e.propSources)),this.strict=!1,this.bufferLength=1024;let r=c3(e.tokenData);this.context=e.context,this.specializerSpecs=e.specialized||[],this.specialized=new Uint16Array(this.specializerSpecs.length);for(let s=0;s<this.specializerSpecs.length;s++)this.specialized[s]=this.specializerSpecs[s].term;this.specializers=this.specializerSpecs.map(RnA),this.states=c3(e.states,Uint32Array),this.data=c3(e.stateData),this.goto=c3(e.goto),this.maxTerm=e.maxTerm,this.tokenizers=e.tokenizers.map(s=>typeof s=="number"?new v1(r,s):s),this.topRules=e.topRules,this.dialects=e.dialects||{},this.dynamicPrecedences=e.dynamicPrecedences||null,this.tokenPrecTable=e.tokenPrec,this.termNames=e.termNames||null,this.maxNode=this.nodeSet.types.length-1,this.dialect=this.parseDialect(),this.top=this.topRules[Object.keys(this.topRules)[0]]}createParse(e,A,i){let n=new PF(this,e,A,i);for(let o of this.wrappers)n=o(n,e,A,i);return n}getGoto(e,A,i=!1){let n=this.goto;if(A>=n[0])return-1;for(let o=n[A+1];;){let r=n[o++],s=r&1,a=n[o++];if(s&&i)return a;for(let c=o+(r>>1);o<c;o++)if(n[o]==e)return a;if(s)return-1}}hasAction(e,A){let i=this.data;for(let n=0;n<2;n++)for(let o=this.stateSlot(e,n?2:1),r;;o+=3){if((r=i[o])==65535)if(i[o+1]==1)r=i[o=Y0(i,o+2)];else{if(i[o+1]==2)return Y0(i,o+2);break}if(r==A||r==0)return Y0(i,o+1)}return 0}stateSlot(e,A){return this.states[e*6+A]}stateFlag(e,A){return(this.stateSlot(e,0)&A)>0}validAction(e,A){return!!this.allActions(e,i=>i==A?!0:null)}allActions(e,A){let i=this.stateSlot(e,4),n=i?A(i):void 0;for(let o=this.stateSlot(e,1);n==null;o+=3){if(this.data[o]==65535)if(this.data[o+1]==1)o=Y0(this.data,o+2);else break;n=A(Y0(this.data,o+1))}return n}nextStates(e){let A=[];for(let i=this.stateSlot(e,1);;i+=3){if(this.data[i]==65535)if(this.data[i+1]==1)i=Y0(this.data,i+2);else break;if((this.data[i+2]&1)==0){let n=this.data[i+1];A.some((o,r)=>r&1&&o==n)||A.push(this.data[i],n)}}return A}configure(e){let A=Object.assign(Object.create(t.prototype),this);if(e.props&&(A.nodeSet=this.nodeSet.extend(...e.props)),e.top){let i=this.topRules[e.top];if(!i)throw new RangeError(`Invalid top rule name ${e.top}`);A.top=i}return e.tokenizers&&(A.tokenizers=this.tokenizers.map(i=>{let n=e.tokenizers.find(o=>o.from==i);return n?n.to:i})),e.specializers&&(A.specializers=this.specializers.slice(),A.specializerSpecs=this.specializerSpecs.map((i,n)=>{let o=e.specializers.find(s=>s.from==i.external);if(!o)return i;let r=Object.assign(Object.assign({},i),{external:o.to});return A.specializers[n]=RnA(r),r})),e.contextTracker&&(A.context=e.contextTracker),e.dialect&&(A.dialect=this.parseDialect(e.dialect)),e.strict!=null&&(A.strict=e.strict),e.wrap&&(A.wrappers=A.wrappers.concat(e.wrap)),e.bufferLength!=null&&(A.bufferLength=e.bufferLength),A}hasWrappers(){return this.wrappers.length>0}getName(e){return this.termNames?this.termNames[e]:String(e<=this.maxNode&&this.nodeSet.types[e].name||e)}get eofTerm(){return this.maxNode+1}get topNode(){return this.nodeSet.types[this.top[1]]}dynamicPrecedence(e){let A=this.dynamicPrecedences;return A==null?0:A[e]||0}parseDialect(e){let A=Object.keys(this.dialects),i=A.map(()=>!1);if(e)for(let o of e.split(" ")){let r=A.indexOf(o);r>=0&&(i[r]=!0)}let n=null;for(let o=0;o<A.length;o++)if(!i[o])for(let r=this.dialects[A[o]],s;(s=this.data[r++])!=65535;)(n||(n=new Uint8Array(this.maxTerm+1)))[s]=1;return new jF(e,i,n)}static deserialize(e){return new t(e)}};function Y0(t,e){return t[e]|t[e+1]<<16}function $FA(t){let e=null;for(let A of t){let i=A.p.stoppedAt;(A.pos==A.p.stream.end||i!=null&&A.pos>i)&&A.p.parser.stateFlag(A.state,2)&&(!e||e.score<A.score)&&(e=A)}return e}function RnA(t){if(t.external){let e=t.extend?1:0;return(A,i)=>t.external(A,i)<<1|e}return t.get}var ANA=Pw({String:we.string,Number:we.number,"True False":we.bool,PropertyName:we.propertyName,Null:we.null,", :":we.separator,"[ ]":we.squareBracket,"{ }":we.brace}),xnA=gD.deserialize({version:14,states:"$bOVQPOOOOQO'#Cb'#CbOnQPO'#CeOvQPO'#ClOOQO'#Cr'#CrQOQPOOOOQO'#Cg'#CgO}QPO'#CfO!SQPO'#CtOOQO,59P,59PO![QPO,59PO!aQPO'#CuOOQO,59W,59WO!iQPO,59WOVQPO,59QOqQPO'#CmO!nQPO,59`OOQO1G.k1G.kOVQPO'#CnO!vQPO,59aOOQO1G.r1G.rOOQO1G.l1G.lOOQO,59X,59XOOQO-E6k-E6kOOQO,59Y,59YOOQO-E6l-E6l",stateData:"#O~OeOS~OQSORSOSSOTSOWQO_ROgPO~OVXOgUO~O^[O~PVO[^O~O]_OVhX~OVaO~O]bO^iX~O^dO~O]_OVha~O]bO^ia~O",goto:"!kjPPPPPPkPPkqwPPPPk{!RPPP!XP!e!hXSOR^bQWQRf_TVQ_Q`WRg`QcZRicQTOQZRQe^RhbRYQR]R",nodeNames:"\u26A0 JsonText True False Null Number String } { Object Property PropertyName : , ] [ Array",maxTerm:25,nodeProps:[["isolate",-2,6,11,""],["openedBy",7,"{",14,"["],["closedBy",8,"}",15,"]"]],propSources:[ANA],skippedNodes:[0],repeatNodeCount:2,tokenData:"(|~RaXY!WYZ!W]^!Wpq!Wrs!]|}$u}!O$z!Q!R%T!R![&c![!]&t!}#O&y#P#Q'O#Y#Z'T#b#c'r#h#i(Z#o#p(r#q#r(w~!]Oe~~!`Wpq!]qr!]rs!xs#O!]#O#P!}#P;'S!];'S;=`$o<%lO!]~!}Og~~#QXrs!]!P!Q!]#O#P!]#U#V!]#Y#Z!]#b#c!]#f#g!]#h#i!]#i#j#m~#pR!Q![#y!c!i#y#T#Z#y~#|R!Q![$V!c!i$V#T#Z$V~$YR!Q![$c!c!i$c#T#Z$c~$fR!Q![!]!c!i!]#T#Z!]~$rP;=`<%l!]~$zO]~~$}Q!Q!R%T!R![&c~%YRT~!O!P%c!g!h%w#X#Y%w~%fP!Q![%i~%nRT~!Q![%i!g!h%w#X#Y%w~%zR{|&T}!O&T!Q![&Z~&WP!Q![&Z~&`PT~!Q![&Z~&hST~!O!P%c!Q![&c!g!h%w#X#Y%w~&yO[~~'OO_~~'TO^~~'WP#T#U'Z~'^P#`#a'a~'dP#g#h'g~'jP#X#Y'm~'rOR~~'uP#i#j'x~'{P#`#a(O~(RP#`#a(U~(ZOS~~(^P#f#g(a~(dP#i#j(g~(jP#X#Y(m~(rOQ~~(wOW~~(|OV~",tokenizers:[0],topRules:{JsonText:[0,1]},tokenPrec:0});var eNA=jw.define({name:"json",parser:xnA.configure({props:[DF.add({Object:yF({except:/^\s*\}/}),Array:yF({except:/^\s*\]/})}),vF.add({"Object Array":EiA})]}),languageData:{closeBrackets:{brackets:["[","{",'"']},indentOnInput:/^\s*[\}\]]$/}});function FnA(){return new qw(eNA)}var NnA=typeof String.prototype.normalize=="function"?t=>t.normalize("NFKD"):t=>t,M1=class{constructor(e,A,i=0,n=e.length,o,r){this.test=r,this.value={from:0,to:0},this.done=!1,this.matches=[],this.buffer="",this.bufferPos=0,this.iter=e.iterRange(i,n),this.bufferStart=i,this.normalize=o?s=>o(NnA(s)):NnA,this.query=this.normalize(A)}peek(){if(this.bufferPos==this.buffer.length){if(this.bufferStart+=this.buffer.length,this.iter.next(),this.iter.done)return-1;this.bufferPos=0,this.buffer=this.iter.value}return rs(this.buffer,this.bufferPos)}next(){for(;this.matches.length;)this.matches.pop();return this.nextOverlapping()}nextOverlapping(){for(;;){let e=this.peek();if(e<0)return this.done=!0,this;let A=b4(e),i=this.bufferStart+this.bufferPos;this.bufferPos+=tc(e);let n=this.normalize(A);if(n.length)for(let o=0,r=i;;o++){let s=n.charCodeAt(o),a=this.match(s,r,this.bufferPos+this.bufferStart);if(o==n.length-1){if(a)return this.value=a,this;break}r==i&&o<A.length&&A.charCodeAt(o)==s&&r++}}}match(e,A,i){let n=null;for(let o=0;o<this.matches.length;o+=2){let r=this.matches[o],s=!1;this.query.charCodeAt(r)==e&&(r==this.query.length-1?n={from:this.matches[o+1],to:i}:(this.matches[o]++,s=!0)),s||(this.matches.splice(o,2),o-=2)}return this.query.charCodeAt(0)==e&&(this.query.length==1?n={from:A,to:i}:this.matches.push(1,A)),n&&this.test&&!this.test(n.from,n.to,this.buffer,this.bufferStart)&&(n=null),n}};typeof Symbol<"u"&&(M1.prototype[Symbol.iterator]=function(){return this});var KnA={from:-1,to:-1,match:/.*/.exec("")},eN="gm"+(/x/.unicode==null?"":"u"),dD=class{constructor(e,A,i,n=0,o=e.length){if(this.text=e,this.to=o,this.curLine="",this.done=!1,this.value=KnA,/\\[sWDnr]|\n|\r|\[\^/.test(A))return new ED(e,A,i,n,o);this.re=new RegExp(A,eN+(i?.ignoreCase?"i":"")),this.test=i?.test,this.iter=e.iter();let r=e.lineAt(n);this.curLineStart=r.from,this.matchPos=hD(e,n),this.getLine(this.curLineStart)}getLine(e){this.iter.next(e),this.iter.lineBreak?this.curLine="":(this.curLine=this.iter.value,this.curLineStart+this.curLine.length>this.to&&(this.curLine=this.curLine.slice(0,this.to-this.curLineStart)),this.iter.next())}nextLine(){this.curLineStart=this.curLineStart+this.curLine.length+1,this.curLineStart>this.to?this.curLine="":this.getLine(0)}next(){for(let e=this.matchPos-this.curLineStart;;){this.re.lastIndex=e;let A=this.matchPos<=this.to&&this.re.exec(this.curLine);if(A){let i=this.curLineStart+A.index,n=i+A[0].length;if(this.matchPos=hD(this.text,n+(i==n?1:0)),i==this.curLineStart+this.curLine.length&&this.nextLine(),(i<n||i>this.value.to)&&(!this.test||this.test(i,n,A)))return this.value={from:i,to:n,match:A},this;e=this.matchPos-this.curLineStart}else if(this.curLineStart+this.curLine.length<this.to)this.nextLine(),e=0;else return this.done=!0,this}}},qF=new WeakMap,BD=class t{constructor(e,A){this.from=e,this.text=A}get to(){return this.from+this.text.length}static get(e,A,i){let n=qF.get(e);if(!n||n.from>=i||n.to<=A){let s=new t(A,e.sliceString(A,i));return qF.set(e,s),s}if(n.from==A&&n.to==i)return n;let{text:o,from:r}=n;return r>A&&(o=e.sliceString(A,r)+o,r=A),n.to<i&&(o+=e.sliceString(n.to,i)),qF.set(e,new t(r,o)),new t(A,o.slice(A-r,i-r))}},ED=class{constructor(e,A,i,n,o){this.text=e,this.to=o,this.done=!1,this.value=KnA,this.matchPos=hD(e,n),this.re=new RegExp(A,eN+(i?.ignoreCase?"i":"")),this.test=i?.test,this.flat=BD.get(e,n,this.chunkEnd(n+5e3))}chunkEnd(e){return e>=this.to?this.to:this.text.lineAt(e).to}next(){for(;;){let e=this.re.lastIndex=this.matchPos-this.flat.from,A=this.re.exec(this.flat.text);if(A&&!A[0]&&A.index==e&&(this.re.lastIndex=e+1,A=this.re.exec(this.flat.text)),A){let i=this.flat.from+A.index,n=i+A[0].length;if((this.flat.to>=this.to||A.index+A[0].length<=this.flat.text.length-10)&&(!this.test||this.test(i,n,A)))return this.value={from:i,to:n,match:A},this.matchPos=hD(this.text,n+(i==n?1:0)),this}if(this.flat.to==this.to)return this.done=!0,this;this.flat=BD.get(this.text,this.flat.from,this.chunkEnd(this.flat.from+this.flat.text.length*2))}}};typeof Symbol<"u"&&(dD.prototype[Symbol.iterator]=ED.prototype[Symbol.iterator]=function(){return this});function tNA(t){try{return new RegExp(t,eN),!0}catch{return!1}}function hD(t,e){if(e>=t.length)return e;let A=t.lineAt(e),i;for(;e<A.to&&(i=A.text.charCodeAt(e-A.from))>=56320&&i<57344;)e++;return e}function VF(t){let e=String(t.state.doc.lineAt(t.state.selection.main.head).number),A=kn("input",{class:"cm-textfield",name:"line",value:e}),i=kn("form",{class:"cm-gotoLine",onkeydown:o=>{o.keyCode==27?(o.preventDefault(),t.dispatch({effects:l3.of(!1)}),t.focus()):o.keyCode==13&&(o.preventDefault(),n())},onsubmit:o=>{o.preventDefault(),n()}},kn("label",t.state.phrase("Go to line"),": ",A)," ",kn("button",{class:"cm-button",type:"submit"},t.state.phrase("go")),kn("button",{name:"close",onclick:()=>{t.dispatch({effects:l3.of(!1)}),t.focus()},"aria-label":t.state.phrase("close"),type:"button"},["\xD7"]));function n(){let o=/^([+-])?(\d+)?(:\d+)?(%)?$/.exec(A.value);if(!o)return;let{state:r}=t,s=r.doc.lineAt(r.selection.main.head),[,a,c,l,I]=o,C=l?+l.slice(1):0,d=c?+c:s.number;if(c&&I){let Q=d/100;a&&(Q=Q*(a=="-"?-1:1)+s.number/r.doc.lines),d=Math.round(r.doc.lines*Q)}else c&&a&&(d=d*(a=="-"?-1:1)+s.number);let B=r.doc.line(Math.max(1,Math.min(r.doc.lines,d))),E=ie.cursor(B.from+Math.max(0,Math.min(C,B.length)));t.dispatch({effects:[l3.of(!1),St.scrollIntoView(E.from,{y:"center"})],selection:E}),t.focus()}return{dom:i}}var l3=ki.define(),_nA=To.define({create(){return!0},update(t,e){for(let A of e.effects)A.is(l3)&&(t=A.value);return t},provide:t=>dC.from(t,e=>e?VF:null)}),iNA=t=>{let e=BC(t,VF);if(!e){let A=[l3.of(!0)];t.state.field(_nA,!1)==null&&A.push(ki.appendConfig.of([_nA,nNA])),t.dispatch({effects:A}),e=BC(t,VF)}return e&&e.dom.querySelector("input").select(),!0},nNA=St.baseTheme({".cm-panel.cm-gotoLine":{padding:"2px 6px 4px",position:"relative","& label":{fontSize:"80%"},"& [name=close]":{position:"absolute",top:"0",bottom:"0",right:"4px",backgroundColor:"inherit",border:"none",font:"inherit",padding:"0"}}}),oNA={highlightWordAroundCursor:!1,minSelectionLength:1,maxMatches:100,wholeWords:!1},YnA=Te.define({combine(t){return zr(t,oNA,{highlightWordAroundCursor:(e,A)=>e||A,minSelectionLength:Math.min,maxMatches:Math.min})}});function JnA(t){let e=[lNA,cNA];return t&&e.push(YnA.of(t)),e}var rNA=rt.mark({class:"cm-selectionMatch"}),sNA=rt.mark({class:"cm-selectionMatch cm-selectionMatch-main"});function GnA(t,e,A,i){return(A==0||t(e.sliceDoc(A-1,A))!=Vn.Word)&&(i==e.doc.length||t(e.sliceDoc(i,i+1))!=Vn.Word)}function aNA(t,e,A,i){return t(e.sliceDoc(A,A+1))==Vn.Word&&t(e.sliceDoc(i-1,i))==Vn.Word}var cNA=Xn.fromClass(class{constructor(t){this.decorations=this.getDeco(t)}update(t){(t.selectionSet||t.docChanged||t.viewportChanged)&&(this.decorations=this.getDeco(t.view))}getDeco(t){let e=t.state.facet(YnA),{state:A}=t,i=A.selection;if(i.ranges.length>1)return rt.none;let n=i.main,o,r=null;if(n.empty){if(!e.highlightWordAroundCursor)return rt.none;let a=A.wordAt(n.head);if(!a)return rt.none;r=A.charCategorizer(n.head),o=A.sliceDoc(a.from,a.to)}else{let a=n.to-n.from;if(a<e.minSelectionLength||a>200)return rt.none;if(e.wholeWords){if(o=A.sliceDoc(n.from,n.to),r=A.charCategorizer(n.head),!(GnA(r,A,n.from,n.to)&&aNA(r,A,n.from,n.to)))return rt.none}else if(o=A.sliceDoc(n.from,n.to),!o)return rt.none}let s=[];for(let a of t.visibleRanges){let c=new M1(A.doc,o,a.from,a.to);for(;!c.next().done;){let{from:l,to:I}=c.value;if((!r||GnA(r,A,l,I))&&(n.empty&&l<=n.from&&I>=n.to?s.push(sNA.range(l,I)):(l>=n.to||I<=n.from)&&s.push(rNA.range(l,I)),s.length>e.maxMatches))return rt.none}}return rt.set(s)}},{decorations:t=>t.decorations}),lNA=St.baseTheme({".cm-selectionMatch":{backgroundColor:"#99ff7780"},".cm-searchMatch .cm-selectionMatch":{backgroundColor:"transparent"}}),gNA=({state:t,dispatch:e})=>{let{selection:A}=t,i=ie.create(A.ranges.map(n=>t.wordAt(n.head)||ie.cursor(n.head)),A.mainIndex);return i.eq(A)?!1:(e(t.update({selection:i})),!0)};function INA(t,e){let{main:A,ranges:i}=t.selection,n=t.wordAt(A.head),o=n&&n.from==A.from&&n.to==A.to;for(let r=!1,s=new M1(t.doc,e,i[i.length-1].to);;)if(s.next(),s.done){if(r)return null;s=new M1(t.doc,e,0,Math.max(0,i[i.length-1].from-1)),r=!0}else{if(r&&i.some(a=>a.from==s.value.from))continue;if(o){let a=t.wordAt(s.value.from);if(!a||a.from!=s.value.from||a.to!=s.value.to)continue}return s.value}}var CNA=({state:t,dispatch:e})=>{let{ranges:A}=t.selection;if(A.some(o=>o.from===o.to))return gNA({state:t,dispatch:e});let i=t.sliceDoc(A[0].from,A[0].to);if(t.selection.ranges.some(o=>t.sliceDoc(o.from,o.to)!=i))return!1;let n=INA(t,i);return n?(e(t.update({selection:t.selection.addRange(ie.range(n.from,n.to),!1),effects:St.scrollIntoView(n.to)})),!0):!1},pC=Te.define({combine(t){return zr(t,{top:!1,caseSensitive:!1,literal:!1,regexp:!1,wholeWord:!1,createPanel:e=>new $F(e),scrollToMatch:e=>St.scrollIntoView(e)})}});function TnA(t){return t?[pC.of(t),AN]:AN}var QD=class{constructor(e){this.search=e.search,this.caseSensitive=!!e.caseSensitive,this.literal=!!e.literal,this.regexp=!!e.regexp,this.replace=e.replace||"",this.valid=!!this.search&&(!this.regexp||tNA(this.search)),this.unquoted=this.unquote(this.search),this.wholeWord=!!e.wholeWord}unquote(e){return this.literal?e:e.replace(/\\([nrt\\])/g,(A,i)=>i=="n"?`
`:i=="r"?"\r":i=="t"?"	":"\\")}eq(e){return this.search==e.search&&this.replace==e.replace&&this.caseSensitive==e.caseSensitive&&this.regexp==e.regexp&&this.wholeWord==e.wholeWord}create(){return this.regexp?new WF(this):new ZF(this)}getCursor(e,A=0,i){let n=e.doc?e:Ir.create({doc:e});return i==null&&(i=n.doc.length),this.regexp?NE(this,n,A,i):FE(this,n,A,i)}},uD=class{constructor(e){this.spec=e}};function FE(t,e,A,i){return new M1(e.doc,t.unquoted,A,i,t.caseSensitive?void 0:n=>n.toLowerCase(),t.wholeWord?dNA(e.doc,e.charCategorizer(e.selection.main.head)):void 0)}function dNA(t,e){return(A,i,n,o)=>((o>A||o+n.length<i)&&(o=Math.max(0,A-2),n=t.sliceString(o,Math.min(t.length,i+2))),(e(fD(n,A-o))!=Vn.Word||e(mD(n,A-o))!=Vn.Word)&&(e(mD(n,i-o))!=Vn.Word||e(fD(n,i-o))!=Vn.Word))}var ZF=class extends uD{constructor(e){super(e)}nextMatch(e,A,i){let n=FE(this.spec,e,i,e.doc.length).nextOverlapping();if(n.done){let o=Math.min(e.doc.length,A+this.spec.unquoted.length);n=FE(this.spec,e,0,o).nextOverlapping()}return n.done||n.value.from==A&&n.value.to==i?null:n.value}prevMatchInRange(e,A,i){for(let n=i;;){let o=Math.max(A,n-1e4-this.spec.unquoted.length),r=FE(this.spec,e,o,n),s=null;for(;!r.nextOverlapping().done;)s=r.value;if(s)return s;if(o==A)return null;n-=1e4}}prevMatch(e,A,i){let n=this.prevMatchInRange(e,0,A);return n||(n=this.prevMatchInRange(e,Math.max(0,i-this.spec.unquoted.length),e.doc.length)),n&&(n.from!=A||n.to!=i)?n:null}getReplacement(e){return this.spec.unquote(this.spec.replace)}matchAll(e,A){let i=FE(this.spec,e,0,e.doc.length),n=[];for(;!i.next().done;){if(n.length>=A)return null;n.push(i.value)}return n}highlight(e,A,i,n){let o=FE(this.spec,e,Math.max(0,A-this.spec.unquoted.length),Math.min(i+this.spec.unquoted.length,e.doc.length));for(;!o.next().done;)n(o.value.from,o.value.to)}};function NE(t,e,A,i){return new dD(e.doc,t.search,{ignoreCase:!t.caseSensitive,test:t.wholeWord?BNA(e.charCategorizer(e.selection.main.head)):void 0},A,i)}function fD(t,e){return t.slice(fr(t,e,!1),e)}function mD(t,e){return t.slice(e,fr(t,e))}function BNA(t){return(e,A,i)=>!i[0].length||(t(fD(i.input,i.index))!=Vn.Word||t(mD(i.input,i.index))!=Vn.Word)&&(t(mD(i.input,i.index+i[0].length))!=Vn.Word||t(fD(i.input,i.index+i[0].length))!=Vn.Word)}var WF=class extends uD{nextMatch(e,A,i){let n=NE(this.spec,e,i,e.doc.length).next();return n.done&&(n=NE(this.spec,e,0,A).next()),n.done?null:n.value}prevMatchInRange(e,A,i){for(let n=1;;n++){let o=Math.max(A,i-n*1e4),r=NE(this.spec,e,o,i),s=null;for(;!r.next().done;)s=r.value;if(s&&(o==A||s.from>o+10))return s;if(o==A)return null}}prevMatch(e,A,i){return this.prevMatchInRange(e,0,A)||this.prevMatchInRange(e,i,e.doc.length)}getReplacement(e){return this.spec.unquote(this.spec.replace).replace(/\$([$&]|\d+)/g,(A,i)=>{if(i=="&")return e.match[0];if(i=="$")return"$";for(let n=i.length;n>0;n--){let o=+i.slice(0,n);if(o>0&&o<e.match.length)return e.match[o]+i.slice(n)}return A})}matchAll(e,A){let i=NE(this.spec,e,0,e.doc.length),n=[];for(;!i.next().done;){if(n.length>=A)return null;n.push(i.value)}return n}highlight(e,A,i,n){let o=NE(this.spec,e,Math.max(0,A-250),Math.min(i+250,e.doc.length));for(;!o.next().done;)n(o.value.from,o.value.to)}},I3=ki.define(),tN=ki.define(),b1=To.define({create(t){return new g3(XF(t).create(),null)},update(t,e){for(let A of e.effects)A.is(I3)?t=new g3(A.value.create(),t.panel):A.is(tN)&&(t=new g3(t.query,A.value?iN:null));return t},provide:t=>dC.from(t,e=>e.panel)});var g3=class{constructor(e,A){this.query=e,this.panel=A}},ENA=rt.mark({class:"cm-searchMatch"}),hNA=rt.mark({class:"cm-searchMatch cm-searchMatch-selected"}),QNA=Xn.fromClass(class{constructor(t){this.view=t,this.decorations=this.highlight(t.state.field(b1))}update(t){let e=t.state.field(b1);(e!=t.startState.field(b1)||t.docChanged||t.selectionSet||t.viewportChanged)&&(this.decorations=this.highlight(e))}highlight({query:t,panel:e}){if(!e||!t.spec.valid)return rt.none;let{view:A}=this,i=new os;for(let n=0,o=A.visibleRanges,r=o.length;n<r;n++){let{from:s,to:a}=o[n];for(;n<r-1&&a>o[n+1].from-2*250;)a=o[++n].to;t.highlight(A.state,s,a,(c,l)=>{let I=A.state.selection.ranges.some(C=>C.from==c&&C.to==l);i.add(c,l,I?hNA:ENA)})}return i.finish()}},{decorations:t=>t.decorations});function C3(t){return e=>{let A=e.state.field(b1,!1);return A&&A.query.spec.valid?t(e,A):DD(e)}}var pD=C3((t,{query:e})=>{let{to:A}=t.state.selection.main,i=e.nextMatch(t.state,A,A);if(!i)return!1;let n=ie.single(i.from,i.to),o=t.state.facet(pC);return t.dispatch({selection:n,effects:[nN(t,i),o.scrollToMatch(n.main,t)],userEvent:"select.search"}),HnA(t),!0}),wD=C3((t,{query:e})=>{let{state:A}=t,{from:i}=A.selection.main,n=e.prevMatch(A,i,i);if(!n)return!1;let o=ie.single(n.from,n.to),r=t.state.facet(pC);return t.dispatch({selection:o,effects:[nN(t,n),r.scrollToMatch(o.main,t)],userEvent:"select.search"}),HnA(t),!0}),uNA=C3((t,{query:e})=>{let A=e.matchAll(t.state,1e3);return!A||!A.length?!1:(t.dispatch({selection:ie.create(A.map(i=>ie.range(i.from,i.to))),userEvent:"select.search.matches"}),!0)}),fNA=({state:t,dispatch:e})=>{let A=t.selection;if(A.ranges.length>1||A.main.empty)return!1;let{from:i,to:n}=A.main,o=[],r=0;for(let s=new M1(t.doc,t.sliceDoc(i,n));!s.next().done;){if(o.length>1e3)return!1;s.value.from==i&&(r=o.length),o.push(ie.range(s.value.from,s.value.to))}return e(t.update({selection:ie.create(o,r),userEvent:"select.search.matches"})),!0},UnA=C3((t,{query:e})=>{let{state:A}=t,{from:i,to:n}=A.selection.main;if(A.readOnly)return!1;let o=e.nextMatch(A,i,i);if(!o)return!1;let r=o,s=[],a,c,l=[];r.from==i&&r.to==n&&(c=A.toText(e.getReplacement(r)),s.push({from:r.from,to:r.to,insert:c}),r=e.nextMatch(A,r.from,r.to),l.push(St.announce.of(A.phrase("replaced match on line $",A.doc.lineAt(i).number)+".")));let I=t.state.changes(s);return r&&(a=ie.single(r.from,r.to).map(I),l.push(nN(t,r)),l.push(A.facet(pC).scrollToMatch(a.main,t))),t.dispatch({changes:I,selection:a,effects:l,userEvent:"input.replace"}),!0}),mNA=C3((t,{query:e})=>{if(t.state.readOnly)return!1;let A=e.matchAll(t.state,1e9).map(n=>{let{from:o,to:r}=n;return{from:o,to:r,insert:e.getReplacement(n)}});if(!A.length)return!1;let i=t.state.phrase("replaced $ matches",A.length)+".";return t.dispatch({changes:A,effects:St.announce.of(i),userEvent:"input.replace.all"}),!0});function iN(t){return t.state.facet(pC).createPanel(t)}function XF(t,e){var A,i,n,o,r;let s=t.selection.main,a=s.empty||s.to>s.from+100?"":t.sliceDoc(s.from,s.to);if(e&&!a)return e;let c=t.facet(pC);return new QD({search:((A=e?.literal)!==null&&A!==void 0?A:c.literal)?a:a.replace(/\n/g,"\\n"),caseSensitive:(i=e?.caseSensitive)!==null&&i!==void 0?i:c.caseSensitive,literal:(n=e?.literal)!==null&&n!==void 0?n:c.literal,regexp:(o=e?.regexp)!==null&&o!==void 0?o:c.regexp,wholeWord:(r=e?.wholeWord)!==null&&r!==void 0?r:c.wholeWord})}function znA(t){let e=BC(t,iN);return e&&e.dom.querySelector("[main-field]")}function HnA(t){let e=znA(t);e&&e==t.root.activeElement&&e.select()}var DD=t=>{let e=t.state.field(b1,!1);if(e&&e.panel){let A=znA(t);if(A&&A!=t.root.activeElement){let i=XF(t.state,e.query.spec);i.valid&&t.dispatch({effects:I3.of(i)}),A.focus(),A.select()}}else t.dispatch({effects:[tN.of(!0),e?I3.of(XF(t.state,e.query.spec)):ki.appendConfig.of(AN)]});return!0},yD=t=>{let e=t.state.field(b1,!1);if(!e||!e.panel)return!1;let A=BC(t,iN);return A&&A.dom.contains(t.root.activeElement)&&t.focus(),t.dispatch({effects:tN.of(!1)}),!0},OnA=[{key:"Mod-f",run:DD,scope:"editor search-panel"},{key:"F3",run:pD,shift:wD,scope:"editor search-panel",preventDefault:!0},{key:"Mod-g",run:pD,shift:wD,scope:"editor search-panel",preventDefault:!0},{key:"Escape",run:yD,scope:"editor search-panel"},{key:"Mod-Shift-l",run:fNA},{key:"Mod-Alt-g",run:iNA},{key:"Mod-d",run:CNA,preventDefault:!0}],$F=class{constructor(e){this.view=e;let A=this.query=e.state.field(b1).query.spec;this.commit=this.commit.bind(this),this.searchField=kn("input",{value:A.search,placeholder:sc(e,"Find"),"aria-label":sc(e,"Find"),class:"cm-textfield",name:"search",form:"","main-field":"true",onchange:this.commit,onkeyup:this.commit}),this.replaceField=kn("input",{value:A.replace,placeholder:sc(e,"Replace"),"aria-label":sc(e,"Replace"),class:"cm-textfield",name:"replace",form:"",onchange:this.commit,onkeyup:this.commit}),this.caseField=kn("input",{type:"checkbox",name:"case",form:"",checked:A.caseSensitive,onchange:this.commit}),this.reField=kn("input",{type:"checkbox",name:"re",form:"",checked:A.regexp,onchange:this.commit}),this.wordField=kn("input",{type:"checkbox",name:"word",form:"",checked:A.wholeWord,onchange:this.commit});function i(n,o,r){return kn("button",{class:"cm-button",name:n,onclick:o,type:"button"},r)}this.dom=kn("div",{onkeydown:n=>this.keydown(n),class:"cm-search"},[this.searchField,i("next",()=>pD(e),[sc(e,"next")]),i("prev",()=>wD(e),[sc(e,"previous")]),i("select",()=>uNA(e),[sc(e,"all")]),kn("label",null,[this.caseField,sc(e,"match case")]),kn("label",null,[this.reField,sc(e,"regexp")]),kn("label",null,[this.wordField,sc(e,"by word")]),...e.state.readOnly?[]:[kn("br"),this.replaceField,i("replace",()=>UnA(e),[sc(e,"replace")]),i("replaceAll",()=>mNA(e),[sc(e,"replace all")])],kn("button",{name:"close",onclick:()=>yD(e),"aria-label":sc(e,"close"),type:"button"},["\xD7"])])}commit(){let e=new QD({search:this.searchField.value,caseSensitive:this.caseField.checked,regexp:this.reField.checked,wholeWord:this.wordField.checked,replace:this.replaceField.value});e.eq(this.query)||(this.query=e,this.view.dispatch({effects:I3.of(e)}))}keydown(e){NtA(this.view,e,"search-panel")?e.preventDefault():e.keyCode==13&&e.target==this.searchField?(e.preventDefault(),(e.shiftKey?wD:pD)(this.view)):e.keyCode==13&&e.target==this.replaceField&&(e.preventDefault(),UnA(this.view))}update(e){for(let A of e.transactions)for(let i of A.effects)i.is(I3)&&!i.value.eq(this.query)&&this.setQuery(i.value)}setQuery(e){this.query=e,this.searchField.value=e.search,this.replaceField.value=e.replace,this.caseField.checked=e.caseSensitive,this.reField.checked=e.regexp,this.wordField.checked=e.wholeWord}mount(){this.searchField.select()}get pos(){return 80}get top(){return this.view.state.facet(pC).top}};function sc(t,e){return t.state.phrase(e)}var ID=30,CD=/[\s\.,:;?!]/;function nN(t,{from:e,to:A}){let i=t.state.doc.lineAt(e),n=t.state.doc.lineAt(A).to,o=Math.max(i.from,e-ID),r=Math.min(n,A+ID),s=t.state.sliceDoc(o,r);if(o!=i.from){for(let a=0;a<ID;a++)if(!CD.test(s[a+1])&&CD.test(s[a])){s=s.slice(a);break}}if(r!=n){for(let a=s.length-1;a>s.length-ID;a--)if(!CD.test(s[a-1])&&CD.test(s[a])){s=s.slice(0,a);break}}return St.announce.of(`${t.state.phrase("current match")}. ${s} ${t.state.phrase("on line")} ${i.number}.`)}var pNA=St.baseTheme({".cm-panel.cm-search":{padding:"2px 6px 4px",position:"relative","& [name=close]":{position:"absolute",top:"0",right:"4px",backgroundColor:"inherit",border:"none",font:"inherit",padding:0,margin:0},"& input, & button, & label":{margin:".2em .6em .2em 0"},"& input[type=checkbox]":{marginRight:".2em"},"& label":{fontSize:"80%",whiteSpace:"pre"}},"&light .cm-searchMatch":{backgroundColor:"#ffff0054"},"&dark .cm-searchMatch":{backgroundColor:"#00ffff8a"},"&light .cm-searchMatch-selected":{backgroundColor:"#ff6a0054"},"&dark .cm-searchMatch-selected":{backgroundColor:"#ff00ff8a"}}),AN=[b1,Bl.low(QNA),pNA];var bD=class{constructor(e,A,i,n){this.state=e,this.pos=A,this.explicit=i,this.view=n,this.abortListeners=[],this.abortOnDocChange=!1}tokenBefore(e){let A=Or(this.state).resolveInner(this.pos,-1);for(;A&&e.indexOf(A.name)<0;)A=A.parent;return A?{from:A.from,to:this.pos,text:this.state.sliceDoc(A.from,this.pos),type:A.type}:null}matchBefore(e){let A=this.state.doc.lineAt(this.pos),i=Math.max(A.from,this.pos-250),n=A.text.slice(i-A.from,this.pos-A.from),o=n.search(AoA(e,!1));return o<0?null:{from:i+o,to:this.pos,text:n.slice(o)}}get aborted(){return this.abortListeners==null}addEventListener(e,A,i){e=="abort"&&this.abortListeners&&(this.abortListeners.push(A),i&&i.onDocChange&&(this.abortOnDocChange=!0))}};function PnA(t){let e=Object.keys(t).join(""),A=/\w/.test(e);return A&&(e=e.replace(/\w/g,"")),`[${A?"\\w":""}${e.replace(/[^\w\s]/g,"\\$&")}]`}function wNA(t){let e=Object.create(null),A=Object.create(null);for(let{label:n}of t){e[n[0]]=!0;for(let o=1;o<n.length;o++)A[n[o]]=!0}let i=PnA(e)+PnA(A)+"*$";return[new RegExp("^"+i),new RegExp(i)]}function DNA(t){let e=t.map(n=>typeof n=="string"?{label:n}:n),[A,i]=e.every(n=>/^\w+$/.test(n.label))?[/\w*$/,/\w+$/]:wNA(e);return n=>{let o=n.matchBefore(i);return o||n.explicit?{from:o?o.from:n.pos,options:e,validFor:A}:null}}var MD=class{constructor(e,A,i,n){this.completion=e,this.source=A,this.match=i,this.score=n}};function DC(t){return t.selection.main.from}function AoA(t,e){var A;let{source:i}=t,n=e&&i[0]!="^",o=i[i.length-1]!="$";return!n&&!o?t:new RegExp(`${n?"^":""}(?:${i})${o?"$":""}`,(A=t.flags)!==null&&A!==void 0?A:t.ignoreCase?"i":"")}var eoA=wa.define();function yNA(t,e,A,i){let{main:n}=t.selection,o=A-n.from,r=i-n.from;return Object.assign(Object.assign({},t.changeByRange(s=>{if(s!=n&&A!=i&&t.sliceDoc(s.from+o,s.from+r)!=t.sliceDoc(A,i))return{range:s};let a=t.toText(e);return{changes:{from:s.from+o,to:i==n.from?s.to:s.from+r,insert:a},range:ie.cursor(s.from+o+a.length)}})),{scrollIntoView:!0,userEvent:"input.complete"})}var jnA=new WeakMap;function vNA(t){if(!Array.isArray(t))return t;let e=jnA.get(t);return e||jnA.set(t,e=DNA(t)),e}var kD=ki.define(),d3=ki.define(),sN=class{constructor(e){this.pattern=e,this.chars=[],this.folded=[],this.any=[],this.precise=[],this.byWord=[],this.score=0,this.matched=[];for(let A=0;A<e.length;){let i=rs(e,A),n=tc(i);this.chars.push(i);let o=e.slice(A,A+n),r=o.toUpperCase();this.folded.push(rs(r==o?o.toLowerCase():r,0)),A+=n}this.astral=e.length!=this.chars.length}ret(e,A){return this.score=e,this.matched=A,this}match(e){if(this.pattern.length==0)return this.ret(-100,[]);if(e.length<this.pattern.length)return null;let{chars:A,folded:i,any:n,precise:o,byWord:r}=this;if(A.length==1){let v=rs(e,0),L=tc(v),x=L==e.length?0:-100;if(v!=A[0])if(v==i[0])x+=-200;else return null;return this.ret(x,[0,L])}let s=e.indexOf(this.pattern);if(s==0)return this.ret(e.length==this.pattern.length?0:-100,[0,this.pattern.length]);let a=A.length,c=0;if(s<0){for(let v=0,L=Math.min(e.length,200);v<L&&c<a;){let x=rs(e,v);(x==A[c]||x==i[c])&&(n[c++]=v),v+=tc(x)}if(c<a)return null}let l=0,I=0,C=!1,d=0,B=-1,E=-1,Q=/[a-z]/.test(e),u=!0;for(let v=0,L=Math.min(e.length,200),x=0;v<L&&I<a;){let y=rs(e,v);s<0&&(l<a&&y==A[l]&&(o[l++]=v),d<a&&(y==A[d]||y==i[d]?(d==0&&(B=v),E=v+1,d++):d=0));let F,U=y<255?y>=48&&y<=57||y>=97&&y<=122?2:y>=65&&y<=90?1:0:(F=b4(y))!=F.toLowerCase()?1:F!=F.toUpperCase()?2:0;(!v||U==1&&Q||x==0&&U!=0)&&(A[I]==y||i[I]==y&&(C=!0)?r[I++]=v:r.length&&(u=!1)),x=U,v+=tc(y)}return I==a&&r[0]==0&&u?this.result(-100+(C?-200:0),r,e):d==a&&B==0?this.ret(-200-e.length+(E==e.length?0:-100),[0,E]):s>-1?this.ret(-700-e.length,[s,s+this.pattern.length]):d==a?this.ret(-900-e.length,[B,E]):I==a?this.result(-100+(C?-200:0)+-700+(u?0:-1100),r,e):A.length==2?null:this.result((n[0]?-700:0)+-200+-1100,n,e)}result(e,A,i){let n=[],o=0;for(let r of A){let s=r+(this.astral?tc(rs(i,r)):1);o&&n[o-1]==r?n[o-1]=s:(n[o++]=r,n[o++]=s)}return this.ret(e-i.length,n)}},aN=class{constructor(e){this.pattern=e,this.matched=[],this.score=0,this.folded=e.toLowerCase()}match(e){if(e.length<this.pattern.length)return null;let A=e.slice(0,this.pattern.length),i=A==this.pattern?0:A.toLowerCase()==this.folded?-200:null;return i==null?null:(this.matched=[0,A.length],this.score=i+(e.length==this.pattern.length?0:-100),this)}},Pr=Te.define({combine(t){return zr(t,{activateOnTyping:!0,activateOnCompletion:()=>!1,activateOnTypingDelay:100,selectOnOpen:!0,override:null,closeOnBlur:!0,maxRenderedOptions:100,defaultKeymap:!0,tooltipClass:()=>"",optionClass:()=>"",aboveCursor:!1,icons:!0,addToOptions:[],positionInfo:bNA,filterStrict:!1,compareCompletions:(e,A)=>e.label.localeCompare(A.label),interactionDelay:75,updateSyncTime:100},{defaultKeymap:(e,A)=>e&&A,closeOnBlur:(e,A)=>e&&A,icons:(e,A)=>e&&A,tooltipClass:(e,A)=>i=>qnA(e(i),A(i)),optionClass:(e,A)=>i=>qnA(e(i),A(i)),addToOptions:(e,A)=>e.concat(A),filterStrict:(e,A)=>e||A})}});function qnA(t,e){return t?e?t+" "+e:t:e}function bNA(t,e,A,i,n,o){let r=t.textDirection==Wn.RTL,s=r,a=!1,c="top",l,I,C=e.left-n.left,d=n.right-e.right,B=i.right-i.left,E=i.bottom-i.top;if(s&&C<Math.min(B,d)?s=!1:!s&&d<Math.min(B,C)&&(s=!0),B<=(s?C:d))l=Math.max(n.top,Math.min(A.top,n.bottom-E))-e.top,I=Math.min(400,s?C:d);else{a=!0,I=Math.min(400,(r?e.right:n.right-e.left)-30);let v=n.bottom-e.bottom;v>=E||v>e.top?l=A.bottom-e.top:(c="bottom",l=e.bottom-A.top)}let Q=(e.bottom-e.top)/o.offsetHeight,u=(e.right-e.left)/o.offsetWidth;return{style:`${c}: ${l/Q}px; max-width: ${I/u}px`,class:"cm-completionInfo-"+(a?r?"left-narrow":"right-narrow":s?"left":"right")}}function MNA(t){let e=t.addToOptions.slice();return t.icons&&e.push({render(A){let i=document.createElement("div");return i.classList.add("cm-completionIcon"),A.type&&i.classList.add(...A.type.split(/\s+/g).map(n=>"cm-completionIcon-"+n)),i.setAttribute("aria-hidden","true"),i},position:20}),e.push({render(A,i,n,o){let r=document.createElement("span");r.className="cm-completionLabel";let s=A.displayLabel||A.label,a=0;for(let c=0;c<o.length;){let l=o[c++],I=o[c++];l>a&&r.appendChild(document.createTextNode(s.slice(a,l)));let C=r.appendChild(document.createElement("span"));C.appendChild(document.createTextNode(s.slice(l,I))),C.className="cm-completionMatchedText",a=I}return a<s.length&&r.appendChild(document.createTextNode(s.slice(a))),r},position:50},{render(A){if(!A.detail)return null;let i=document.createElement("span");return i.className="cm-completionDetail",i.textContent=A.detail,i},position:80}),e.sort((A,i)=>A.position-i.position).map(A=>A.render)}function oN(t,e,A){if(t<=A)return{from:0,to:t};if(e<0&&(e=0),e<=t>>1){let n=Math.floor(e/A);return{from:n*A,to:(n+1)*A}}let i=Math.floor((t-e)/A);return{from:t-(i+1)*A,to:t-i*A}}var cN=class{constructor(e,A,i){this.view=e,this.stateField=A,this.applyCompletion=i,this.info=null,this.infoDestroy=null,this.placeInfoReq={read:()=>this.measureInfo(),write:a=>this.placeInfo(a),key:this},this.space=null,this.currentClass="";let n=e.state.field(A),{options:o,selected:r}=n.open,s=e.state.facet(Pr);this.optionContent=MNA(s),this.optionClass=s.optionClass,this.tooltipClass=s.tooltipClass,this.range=oN(o.length,r,s.maxRenderedOptions),this.dom=document.createElement("div"),this.dom.className="cm-tooltip-autocomplete",this.updateTooltipClass(e.state),this.dom.addEventListener("mousedown",a=>{let{options:c}=e.state.field(A).open;for(let l=a.target,I;l&&l!=this.dom;l=l.parentNode)if(l.nodeName=="LI"&&(I=/-(\d+)$/.exec(l.id))&&+I[1]<c.length){this.applyCompletion(e,c[+I[1]]),a.preventDefault();return}}),this.dom.addEventListener("focusout",a=>{let c=e.state.field(this.stateField,!1);c&&c.tooltip&&e.state.facet(Pr).closeOnBlur&&a.relatedTarget!=e.contentDOM&&e.dispatch({effects:d3.of(null)})}),this.showOptions(o,n.id)}mount(){this.updateSel()}showOptions(e,A){this.list&&this.list.remove(),this.list=this.dom.appendChild(this.createListBox(e,A,this.range)),this.list.addEventListener("scroll",()=>{this.info&&this.view.requestMeasure(this.placeInfoReq)})}update(e){var A;let i=e.state.field(this.stateField),n=e.startState.field(this.stateField);if(this.updateTooltipClass(e.state),i!=n){let{options:o,selected:r,disabled:s}=i.open;(!n.open||n.open.options!=o)&&(this.range=oN(o.length,r,e.state.facet(Pr).maxRenderedOptions),this.showOptions(o,i.id)),this.updateSel(),s!=((A=n.open)===null||A===void 0?void 0:A.disabled)&&this.dom.classList.toggle("cm-tooltip-autocomplete-disabled",!!s)}}updateTooltipClass(e){let A=this.tooltipClass(e);if(A!=this.currentClass){for(let i of this.currentClass.split(" "))i&&this.dom.classList.remove(i);for(let i of A.split(" "))i&&this.dom.classList.add(i);this.currentClass=A}}positioned(e){this.space=e,this.info&&this.view.requestMeasure(this.placeInfoReq)}updateSel(){let e=this.view.state.field(this.stateField),A=e.open;if((A.selected>-1&&A.selected<this.range.from||A.selected>=this.range.to)&&(this.range=oN(A.options.length,A.selected,this.view.state.facet(Pr).maxRenderedOptions),this.showOptions(A.options,e.id)),this.updateSelectedOption(A.selected)){this.destroyInfo();let{completion:i}=A.options[A.selected],{info:n}=i;if(!n)return;let o=typeof n=="string"?document.createTextNode(n):n(i);if(!o)return;"then"in o?o.then(r=>{r&&this.view.state.field(this.stateField,!1)==e&&this.addInfoPane(r,i)}).catch(r=>Hr(this.view.state,r,"completion info")):this.addInfoPane(o,i)}}addInfoPane(e,A){this.destroyInfo();let i=this.info=document.createElement("div");if(i.className="cm-tooltip cm-completionInfo",e.nodeType!=null)i.appendChild(e),this.infoDestroy=null;else{let{dom:n,destroy:o}=e;i.appendChild(n),this.infoDestroy=o||null}this.dom.appendChild(i),this.view.requestMeasure(this.placeInfoReq)}updateSelectedOption(e){let A=null;for(let i=this.list.firstChild,n=this.range.from;i;i=i.nextSibling,n++)i.nodeName!="LI"||!i.id?n--:n==e?i.hasAttribute("aria-selected")||(i.setAttribute("aria-selected","true"),A=i):i.hasAttribute("aria-selected")&&i.removeAttribute("aria-selected");return A&&SNA(this.list,A),A}measureInfo(){let e=this.dom.querySelector("[aria-selected]");if(!e||!this.info)return null;let A=this.dom.getBoundingClientRect(),i=this.info.getBoundingClientRect(),n=e.getBoundingClientRect(),o=this.space;if(!o){let r=this.dom.ownerDocument.documentElement;o={left:0,top:0,right:r.clientWidth,bottom:r.clientHeight}}return n.top>Math.min(o.bottom,A.bottom)-10||n.bottom<Math.max(o.top,A.top)+10?null:this.view.state.facet(Pr).positionInfo(this.view,A,n,i,o,this.dom)}placeInfo(e){this.info&&(e?(e.style&&(this.info.style.cssText=e.style),this.info.className="cm-tooltip cm-completionInfo "+(e.class||"")):this.info.style.cssText="top: -1e6px")}createListBox(e,A,i){let n=document.createElement("ul");n.id=A,n.setAttribute("role","listbox"),n.setAttribute("aria-expanded","true"),n.setAttribute("aria-label",this.view.state.phrase("Completions")),n.addEventListener("mousedown",r=>{r.target==n&&r.preventDefault()});let o=null;for(let r=i.from;r<i.to;r++){let{completion:s,match:a}=e[r],{section:c}=s;if(c){let C=typeof c=="string"?c:c.name;if(C!=o&&(r>i.from||i.from==0))if(o=C,typeof c!="string"&&c.header)n.appendChild(c.header(c));else{let d=n.appendChild(document.createElement("completion-section"));d.textContent=C}}let l=n.appendChild(document.createElement("li"));l.id=A+"-"+r,l.setAttribute("role","option");let I=this.optionClass(s);I&&(l.className=I);for(let C of this.optionContent){let d=C(s,this.view.state,this.view,a);d&&l.appendChild(d)}}return i.from&&n.classList.add("cm-completionListIncompleteTop"),i.to<e.length&&n.classList.add("cm-completionListIncompleteBottom"),n}destroyInfo(){this.info&&(this.infoDestroy&&this.infoDestroy(),this.info.remove(),this.info=null)}destroy(){this.destroyInfo()}};function kNA(t,e){return A=>new cN(A,t,e)}function SNA(t,e){let A=t.getBoundingClientRect(),i=e.getBoundingClientRect(),n=A.height/t.offsetHeight;i.top<A.top?t.scrollTop-=(A.top-i.top)/n:i.bottom>A.bottom&&(t.scrollTop+=(i.bottom-A.bottom)/n)}function VnA(t){return(t.boost||0)*100+(t.apply?10:0)+(t.info?5:0)+(t.type?1:0)}function RNA(t,e){let A=[],i=null,n=c=>{A.push(c);let{section:l}=c.completion;if(l){i||(i=[]);let I=typeof l=="string"?l:l.name;i.some(C=>C.name==I)||i.push(typeof l=="string"?{name:I}:l)}},o=e.facet(Pr);for(let c of t)if(c.hasResult()){let l=c.result.getMatch;if(c.result.filter===!1)for(let I of c.result.options)n(new MD(I,c.source,l?l(I):[],1e9-A.length));else{let I=e.sliceDoc(c.from,c.to),C,d=o.filterStrict?new aN(I):new sN(I);for(let B of c.result.options)if(C=d.match(B.label)){let E=B.displayLabel?l?l(B,C.matched):[]:C.matched;n(new MD(B,c.source,E,C.score+(B.boost||0)))}}}if(i){let c=Object.create(null),l=0,I=(C,d)=>{var B,E;return((B=C.rank)!==null&&B!==void 0?B:1e9)-((E=d.rank)!==null&&E!==void 0?E:1e9)||(C.name<d.name?-1:1)};for(let C of i.sort(I))l-=1e5,c[C.name]=l;for(let C of A){let{section:d}=C.completion;d&&(C.score+=c[typeof d=="string"?d:d.name])}}let r=[],s=null,a=o.compareCompletions;for(let c of A.sort((l,I)=>I.score-l.score||a(l.completion,I.completion))){let l=c.completion;!s||s.label!=l.label||s.detail!=l.detail||s.type!=null&&l.type!=null&&s.type!=l.type||s.apply!=l.apply||s.boost!=l.boost?r.push(c):VnA(c.completion)>VnA(s)&&(r[r.length-1]=c),s=c.completion}return r}var lN=class t{constructor(e,A,i,n,o,r){this.options=e,this.attrs=A,this.tooltip=i,this.timestamp=n,this.selected=o,this.disabled=r}setSelected(e,A){return e==this.selected||e>=this.options.length?this:new t(this.options,ZnA(A,e),this.tooltip,this.timestamp,e,this.disabled)}static build(e,A,i,n,o,r){if(n&&!r&&e.some(c=>c.isPending))return n.setDisabled();let s=RNA(e,A);if(!s.length)return n&&e.some(c=>c.isPending)?n.setDisabled():null;let a=A.facet(Pr).selectOnOpen?0:-1;if(n&&n.selected!=a&&n.selected!=-1){let c=n.options[n.selected].completion;for(let l=0;l<s.length;l++)if(s[l].completion==c){a=l;break}}return new t(s,ZnA(i,a),{pos:e.reduce((c,l)=>l.hasResult()?Math.min(c,l.from):c,1e8),create:GNA,above:o.aboveCursor},n?n.timestamp:Date.now(),a,!1)}map(e){return new t(this.options,this.attrs,Object.assign(Object.assign({},this.tooltip),{pos:e.mapPos(this.tooltip.pos)}),this.timestamp,this.selected,this.disabled)}setDisabled(){return new t(this.options,this.attrs,this.tooltip,this.timestamp,this.selected,!0)}},gN=class t{constructor(e,A,i){this.active=e,this.id=A,this.open=i}static start(){return new t(NNA,"cm-ac-"+Math.floor(Math.random()*2e6).toString(36),null)}update(e){let{state:A}=e,i=A.facet(Pr),o=(i.override||A.languageDataAt("autocomplete",DC(A)).map(vNA)).map(a=>(this.active.find(l=>l.source==a)||new J0(a,this.active.some(l=>l.state!=0)?1:0)).update(e,i));o.length==this.active.length&&o.every((a,c)=>a==this.active[c])&&(o=this.active);let r=this.open,s=e.effects.some(a=>a.is(CN));r&&e.docChanged&&(r=r.map(e.changes)),e.selection||o.some(a=>a.hasResult()&&e.changes.touchesRange(a.from,a.to))||!LNA(o,this.active)||s?r=lN.build(o,A,this.id,r,i,s):r&&r.disabled&&!o.some(a=>a.isPending)&&(r=null),!r&&o.every(a=>!a.isPending)&&o.some(a=>a.hasResult())&&(o=o.map(a=>a.hasResult()?new J0(a.source,0):a));for(let a of e.effects)a.is(ioA)&&(r=r&&r.setSelected(a.value,this.id));return o==this.active&&r==this.open?this:new t(o,this.id,r)}get tooltip(){return this.open?this.open.tooltip:null}get attrs(){return this.open?this.open.attrs:this.active.length?xNA:FNA}};function LNA(t,e){if(t==e)return!0;for(let A=0,i=0;;){for(;A<t.length&&!t[A].hasResult();)A++;for(;i<e.length&&!e[i].hasResult();)i++;let n=A==t.length,o=i==e.length;if(n||o)return n==o;if(t[A++].result!=e[i++].result)return!1}}var xNA={"aria-autocomplete":"list"},FNA={};function ZnA(t,e){let A={"aria-autocomplete":"list","aria-haspopup":"listbox","aria-controls":t};return e>-1&&(A["aria-activedescendant"]=t+"-"+e),A}var NNA=[];function toA(t,e){if(t.isUserEvent("input.complete")){let i=t.annotation(eoA);if(i&&e.activateOnCompletion(i))return 12}let A=t.isUserEvent("input.type");return A&&e.activateOnTyping?5:A?1:t.isUserEvent("delete.backward")?2:t.selection?8:t.docChanged?16:0}var J0=class t{constructor(e,A,i=!1){this.source=e,this.state=A,this.explicit=i}hasResult(){return!1}get isPending(){return this.state==1}update(e,A){let i=toA(e,A),n=this;(i&8||i&16&&this.touches(e))&&(n=new t(n.source,0)),i&4&&n.state==0&&(n=new t(this.source,1)),n=n.updateFor(e,i);for(let o of e.effects)if(o.is(kD))n=new t(n.source,1,o.value);else if(o.is(d3))n=new t(n.source,0);else if(o.is(CN))for(let r of o.value)r.source==n.source&&(n=r);return n}updateFor(e,A){return this.map(e.changes)}map(e){return this}touches(e){return e.changes.touchesRange(DC(e.state))}},SD=class t extends J0{constructor(e,A,i,n,o,r){super(e,3,A),this.limit=i,this.result=n,this.from=o,this.to=r}hasResult(){return!0}updateFor(e,A){var i;if(!(A&3))return this.map(e.changes);let n=this.result;n.map&&!e.changes.empty&&(n=n.map(n,e.changes));let o=e.changes.mapPos(this.from),r=e.changes.mapPos(this.to,1),s=DC(e.state);if(s>r||!n||A&2&&(DC(e.startState)==this.from||s<this.limit))return new J0(this.source,A&4?1:0);let a=e.changes.mapPos(this.limit);return _NA(n.validFor,e.state,o,r)?new t(this.source,this.explicit,a,n,o,r):n.update&&(n=n.update(n,o,r,new bD(e.state,s,!1)))?new t(this.source,this.explicit,a,n,n.from,(i=n.to)!==null&&i!==void 0?i:DC(e.state)):new J0(this.source,1,this.explicit)}map(e){return e.empty?this:(this.result.map?this.result.map(this.result,e):this.result)?new t(this.source,this.explicit,e.mapPos(this.limit),this.result,e.mapPos(this.from),e.mapPos(this.to,1)):new J0(this.source,0)}touches(e){return e.changes.touchesRange(this.from,this.to)}};function _NA(t,e,A,i){if(!t)return!1;let n=e.sliceDoc(A,i);return typeof t=="function"?t(n,A,i,e):AoA(t,!0).test(n)}var CN=ki.define({map(t,e){return t.map(A=>A.map(e))}}),ioA=ki.define(),va=To.define({create(){return gN.start()},update(t,e){return t.update(e)},provide:t=>[DE.from(t,e=>e.tooltip),St.contentAttributes.from(t,e=>e.attrs)]});function dN(t,e){let A=e.completion.apply||e.completion.label,i=t.state.field(va).active.find(n=>n.source==e.source);return i instanceof SD?(typeof A=="string"?t.dispatch(Object.assign(Object.assign({},yNA(t.state,A,i.from,i.to)),{annotations:eoA.of(e.completion)})):A(t,e.completion,i.from,i.to),!0):!1}var GNA=kNA(va,dN);function vD(t,e="option"){return A=>{let i=A.state.field(va,!1);if(!i||!i.open||i.open.disabled||Date.now()-i.open.timestamp<A.state.facet(Pr).interactionDelay)return!1;let n=1,o;e=="page"&&(o=AF(A,i.open.tooltip))&&(n=Math.max(2,Math.floor(o.dom.offsetHeight/o.dom.querySelector("li").offsetHeight)-1));let{length:r}=i.open.options,s=i.open.selected>-1?i.open.selected+n*(t?1:-1):t?0:r-1;return s<0?s=e=="page"?0:r-1:s>=r&&(s=e=="page"?r-1:0),A.dispatch({effects:ioA.of(s)}),!0}}var UNA=t=>{let e=t.state.field(va,!1);return t.state.readOnly||!e||!e.open||e.open.selected<0||e.open.disabled||Date.now()-e.open.timestamp<t.state.facet(Pr).interactionDelay?!1:dN(t,e.open.options[e.open.selected])},WnA=t=>t.state.field(va,!1)?(t.dispatch({effects:kD.of(!0)}),!0):!1,KNA=t=>{let e=t.state.field(va,!1);return!e||!e.active.some(A=>A.state!=0)?!1:(t.dispatch({effects:d3.of(null)}),!0)},IN=class{constructor(e,A){this.active=e,this.context=A,this.time=Date.now(),this.updates=[],this.done=void 0}},YNA=50,JNA=1e3,TNA=Xn.fromClass(class{constructor(t){this.view=t,this.debounceUpdate=-1,this.running=[],this.debounceAccept=-1,this.pendingStart=!1,this.composing=0;for(let e of t.state.field(va).active)e.isPending&&this.startQuery(e)}update(t){let e=t.state.field(va),A=t.state.facet(Pr);if(!t.selectionSet&&!t.docChanged&&t.startState.field(va)==e)return;let i=t.transactions.some(o=>{let r=toA(o,A);return r&8||(o.selection||o.docChanged)&&!(r&3)});for(let o=0;o<this.running.length;o++){let r=this.running[o];if(i||r.context.abortOnDocChange&&t.docChanged||r.updates.length+t.transactions.length>YNA&&Date.now()-r.time>JNA){for(let s of r.context.abortListeners)try{s()}catch(a){Hr(this.view.state,a)}r.context.abortListeners=null,this.running.splice(o--,1)}else r.updates.push(...t.transactions)}this.debounceUpdate>-1&&clearTimeout(this.debounceUpdate),t.transactions.some(o=>o.effects.some(r=>r.is(kD)))&&(this.pendingStart=!0);let n=this.pendingStart?50:A.activateOnTypingDelay;if(this.debounceUpdate=e.active.some(o=>o.isPending&&!this.running.some(r=>r.active.source==o.source))?setTimeout(()=>this.startUpdate(),n):-1,this.composing!=0)for(let o of t.transactions)o.isUserEvent("input.type")?this.composing=2:this.composing==2&&o.selection&&(this.composing=3)}startUpdate(){this.debounceUpdate=-1,this.pendingStart=!1;let{state:t}=this.view,e=t.field(va);for(let A of e.active)A.isPending&&!this.running.some(i=>i.active.source==A.source)&&this.startQuery(A);this.running.length&&e.open&&e.open.disabled&&(this.debounceAccept=setTimeout(()=>this.accept(),this.view.state.facet(Pr).updateSyncTime))}startQuery(t){let{state:e}=this.view,A=DC(e),i=new bD(e,A,t.explicit,this.view),n=new IN(t,i);this.running.push(n),Promise.resolve(t.source(i)).then(o=>{n.context.aborted||(n.done=o||null,this.scheduleAccept())},o=>{this.view.dispatch({effects:d3.of(null)}),Hr(this.view.state,o)})}scheduleAccept(){this.running.every(t=>t.done!==void 0)?this.accept():this.debounceAccept<0&&(this.debounceAccept=setTimeout(()=>this.accept(),this.view.state.facet(Pr).updateSyncTime))}accept(){var t;this.debounceAccept>-1&&clearTimeout(this.debounceAccept),this.debounceAccept=-1;let e=[],A=this.view.state.facet(Pr),i=this.view.state.field(va);for(let n=0;n<this.running.length;n++){let o=this.running[n];if(o.done===void 0)continue;if(this.running.splice(n--,1),o.done){let s=DC(o.updates.length?o.updates[0].startState:this.view.state),a=Math.min(s,o.done.from+(o.active.explicit?0:1)),c=new SD(o.active.source,o.active.explicit,a,o.done,o.done.from,(t=o.done.to)!==null&&t!==void 0?t:s);for(let l of o.updates)c=c.update(l,A);if(c.hasResult()){e.push(c);continue}}let r=i.active.find(s=>s.source==o.active.source);if(r&&r.isPending)if(o.done==null){let s=new J0(o.active.source,0);for(let a of o.updates)s=s.update(a,A);s.isPending||e.push(s)}else this.startQuery(r)}(e.length||i.open&&i.open.disabled)&&this.view.dispatch({effects:CN.of(e)})}},{eventHandlers:{blur(t){let e=this.view.state.field(va,!1);if(e&&e.tooltip&&this.view.state.facet(Pr).closeOnBlur){let A=e.open&&AF(this.view,e.open.tooltip);(!A||!A.dom.contains(t.relatedTarget))&&setTimeout(()=>this.view.dispatch({effects:d3.of(null)}),10)}},compositionstart(){this.composing=1},compositionend(){this.composing==3&&setTimeout(()=>this.view.dispatch({effects:kD.of(!1)}),20),this.composing=0}}}),zNA=typeof navigator=="object"&&/Win/.test(navigator.platform),HNA=Bl.highest(St.domEventHandlers({keydown(t,e){let A=e.state.field(va,!1);if(!A||!A.open||A.open.disabled||A.open.selected<0||t.key.length>1||t.ctrlKey&&!(zNA&&t.altKey)||t.metaKey)return!1;let i=A.open.options[A.open.selected],n=A.active.find(r=>r.source==i.source),o=i.completion.commitCharacters||n.result.commitCharacters;return o&&o.indexOf(t.key)>-1&&dN(e,i),!1}})),ONA=St.baseTheme({".cm-tooltip.cm-tooltip-autocomplete":{"& > ul":{fontFamily:"monospace",whiteSpace:"nowrap",overflow:"hidden auto",maxWidth_fallback:"700px",maxWidth:"min(700px, 95vw)",minWidth:"250px",maxHeight:"10em",height:"100%",listStyle:"none",margin:0,padding:0,"& > li, & > completion-section":{padding:"1px 3px",lineHeight:1.2},"& > li":{overflowX:"hidden",textOverflow:"ellipsis",cursor:"pointer"},"& > completion-section":{display:"list-item",borderBottom:"1px solid silver",paddingLeft:"0.5em",opacity:.7}}},"&light .cm-tooltip-autocomplete ul li[aria-selected]":{background:"#17c",color:"white"},"&light .cm-tooltip-autocomplete-disabled ul li[aria-selected]":{background:"#777"},"&dark .cm-tooltip-autocomplete ul li[aria-selected]":{background:"#347",color:"white"},"&dark .cm-tooltip-autocomplete-disabled ul li[aria-selected]":{background:"#444"},".cm-completionListIncompleteTop:before, .cm-completionListIncompleteBottom:after":{content:'"\xB7\xB7\xB7"',opacity:.5,display:"block",textAlign:"center"},".cm-tooltip.cm-completionInfo":{position:"absolute",padding:"3px 9px",width:"max-content",maxWidth:"400px",boxSizing:"border-box",whiteSpace:"pre-line"},".cm-completionInfo.cm-completionInfo-left":{right:"100%"},".cm-completionInfo.cm-completionInfo-right":{left:"100%"},".cm-completionInfo.cm-completionInfo-left-narrow":{right:"30px"},".cm-completionInfo.cm-completionInfo-right-narrow":{left:"30px"},"&light .cm-snippetField":{backgroundColor:"#00000022"},"&dark .cm-snippetField":{backgroundColor:"#ffffff22"},".cm-snippetFieldPosition":{verticalAlign:"text-top",width:0,height:"1.15em",display:"inline-block",margin:"0 -0.7px -.7em",borderLeft:"1.4px dotted #888"},".cm-completionMatchedText":{textDecoration:"underline"},".cm-completionDetail":{marginLeft:"0.5em",fontStyle:"italic"},".cm-completionIcon":{fontSize:"90%",width:".8em",display:"inline-block",textAlign:"center",paddingRight:".6em",opacity:"0.6",boxSizing:"content-box"},".cm-completionIcon-function, .cm-completionIcon-method":{"&:after":{content:"'\u0192'"}},".cm-completionIcon-class":{"&:after":{content:"'\u25CB'"}},".cm-completionIcon-interface":{"&:after":{content:"'\u25CC'"}},".cm-completionIcon-variable":{"&:after":{content:"'\u{1D465}'"}},".cm-completionIcon-constant":{"&:after":{content:"'\u{1D436}'"}},".cm-completionIcon-type":{"&:after":{content:"'\u{1D461}'"}},".cm-completionIcon-enum":{"&:after":{content:"'\u222A'"}},".cm-completionIcon-property":{"&:after":{content:"'\u25A1'"}},".cm-completionIcon-keyword":{"&:after":{content:"'\u{1F511}\uFE0E'"}},".cm-completionIcon-namespace":{"&:after":{content:"'\u25A2'"}},".cm-completionIcon-text":{"&:after":{content:"'abc'",fontSize:"50%",verticalAlign:"middle"}}});var B3={brackets:["(","[","{","'",'"'],before:")]}:;>",stringPrefixes:[]},wC=ki.define({map(t,e){let A=e.mapPos(t,-1,is.TrackAfter);return A??void 0}}),BN=new class extends dl{};BN.startSide=1;BN.endSide=-1;var noA=To.define({create(){return Zn.empty},update(t,e){if(t=t.map(e.changes),e.selection){let A=e.state.doc.lineAt(e.selection.main.head);t=t.update({filter:i=>i>=A.from&&i<=A.to})}for(let A of e.effects)A.is(wC)&&(t=t.update({add:[BN.range(A.value,A.value+1)]}));return t}});function ooA(){return[jNA,noA]}var rN="()[]{}<>\xAB\xBB\xBB\xAB\uFF3B\uFF3D\uFF5B\uFF5D";function roA(t){for(let e=0;e<rN.length;e+=2)if(rN.charCodeAt(e)==t)return rN.charAt(e+1);return b4(t<128?t:t+1)}function soA(t,e){return t.languageDataAt("closeBrackets",e)[0]||B3}var PNA=typeof navigator=="object"&&/Android\b/.test(navigator.userAgent),jNA=St.inputHandler.of((t,e,A,i)=>{if((PNA?t.composing:t.compositionStarted)||t.state.readOnly)return!1;let n=t.state.selection.main;if(i.length>2||i.length==2&&tc(rs(i,0))==1||e!=n.from||A!=n.to)return!1;let o=VNA(t.state,i);return o?(t.dispatch(o),!0):!1}),qNA=({state:t,dispatch:e})=>{if(t.readOnly)return!1;let i=soA(t,t.selection.main.head).brackets||B3.brackets,n=null,o=t.changeByRange(r=>{if(r.empty){let s=ZNA(t.doc,r.head);for(let a of i)if(a==s&&RD(t.doc,r.head)==roA(rs(a,0)))return{changes:{from:r.head-a.length,to:r.head+a.length},range:ie.cursor(r.head-a.length)}}return{range:n=r}});return n||e(t.update(o,{scrollIntoView:!0,userEvent:"delete.backward"})),!n},aoA=[{key:"Backspace",run:qNA}];function VNA(t,e){let A=soA(t,t.selection.main.head),i=A.brackets||B3.brackets;for(let n of i){let o=roA(rs(n,0));if(e==n)return o==n?$NA(t,n,i.indexOf(n+n+n)>-1,A):WNA(t,n,o,A.before||B3.before);if(e==o&&coA(t,t.selection.main.from))return XNA(t,n,o)}return null}function coA(t,e){let A=!1;return t.field(noA).between(0,t.doc.length,i=>{i==e&&(A=!0)}),A}function RD(t,e){let A=t.sliceString(e,e+2);return A.slice(0,tc(rs(A,0)))}function ZNA(t,e){let A=t.sliceString(e-2,e);return tc(rs(A,0))==A.length?A:A.slice(1)}function WNA(t,e,A,i){let n=null,o=t.changeByRange(r=>{if(!r.empty)return{changes:[{insert:e,from:r.from},{insert:A,from:r.to}],effects:wC.of(r.to+e.length),range:ie.range(r.anchor+e.length,r.head+e.length)};let s=RD(t.doc,r.head);return!s||/\s/.test(s)||i.indexOf(s)>-1?{changes:{insert:e+A,from:r.head},effects:wC.of(r.head+e.length),range:ie.cursor(r.head+e.length)}:{range:n=r}});return n?null:t.update(o,{scrollIntoView:!0,userEvent:"input.type"})}function XNA(t,e,A){let i=null,n=t.changeByRange(o=>o.empty&&RD(t.doc,o.head)==A?{changes:{from:o.head,to:o.head+A.length,insert:A},range:ie.cursor(o.head+A.length)}:i={range:o});return i?null:t.update(n,{scrollIntoView:!0,userEvent:"input.type"})}function $NA(t,e,A,i){let n=i.stringPrefixes||B3.stringPrefixes,o=null,r=t.changeByRange(s=>{if(!s.empty)return{changes:[{insert:e,from:s.from},{insert:e,from:s.to}],effects:wC.of(s.to+e.length),range:ie.range(s.anchor+e.length,s.head+e.length)};let a=s.head,c=RD(t.doc,a),l;if(c==e){if(XnA(t,a))return{changes:{insert:e+e,from:a},effects:wC.of(a+e.length),range:ie.cursor(a+e.length)};if(coA(t,a)){let C=A&&t.sliceDoc(a,a+e.length*3)==e+e+e?e+e+e:e;return{changes:{from:a,to:a+C.length,insert:C},range:ie.cursor(a+C.length)}}}else{if(A&&t.sliceDoc(a-2*e.length,a)==e+e&&(l=$nA(t,a-2*e.length,n))>-1&&XnA(t,l))return{changes:{insert:e+e+e+e,from:a},effects:wC.of(a+e.length),range:ie.cursor(a+e.length)};if(t.charCategorizer(a)(c)!=Vn.Word&&$nA(t,a,n)>-1&&!A_A(t,a,e,n))return{changes:{insert:e+e,from:a},effects:wC.of(a+e.length),range:ie.cursor(a+e.length)}}return{range:o=s}});return o?null:t.update(r,{scrollIntoView:!0,userEvent:"input.type"})}function XnA(t,e){let A=Or(t).resolveInner(e+1);return A.parent&&A.from==e}function A_A(t,e,A,i){let n=Or(t).resolveInner(e,-1),o=i.reduce((r,s)=>Math.max(r,s.length),0);for(let r=0;r<5;r++){let s=t.sliceDoc(n.from,Math.min(n.to,n.from+A.length+o)),a=s.indexOf(A);if(!a||a>-1&&i.indexOf(s.slice(0,a))>-1){let l=n.firstChild;for(;l&&l.from==n.from&&l.to-l.from>A.length+a;){if(t.sliceDoc(l.to-A.length,l.to)==A)return!1;l=l.firstChild}return!0}let c=n.to==e&&n.parent;if(!c)break;n=c}return!1}function $nA(t,e,A){let i=t.charCategorizer(e);if(i(t.sliceDoc(e-1,e))!=Vn.Word)return e;for(let n of A){let o=e-n.length;if(t.sliceDoc(o,e)==n&&i(t.sliceDoc(o-1,o))!=Vn.Word)return o}return-1}function loA(t={}){return[HNA,va,Pr.of(t),TNA,e_A,ONA]}var EN=[{key:"Ctrl-Space",run:WnA},{mac:"Alt-`",run:WnA},{key:"Escape",run:KNA},{key:"ArrowDown",run:vD(!0)},{key:"ArrowUp",run:vD(!1)},{key:"PageDown",run:vD(!0,"page")},{key:"PageUp",run:vD(!1,"page")},{key:"Enter",run:UNA}],e_A=Bl.highest(wE.computeN([Pr],t=>t.facet(Pr).defaultKeymap?[EN]:[]));function t_A(t,e=t.state){let A=new Set;for(let{from:i,to:n}of t.visibleRanges){let o=i;for(;o<=n;){let r=e.doc.lineAt(o);A.has(r)||A.add(r),o=r.to+1}}return A}function hN(t){let e=t.selection.main.head;return t.doc.lineAt(e)}function goA(t,e){let A=0;A:for(let i=0;i<t.length;i++)switch(t[i]){case" ":case"\xA0":{A+=1;continue A}case"	":{A+=e-A%e;continue A}case"\r":continue A;default:break A}return A}var xD=Te.define({combine(t){return zr(t,{highlightActiveBlock:!0,hideFirstIndent:!1,markerType:"fullScope",thickness:1})}}),QN=class{constructor(e,A,i,n){this.lines=e,this.state=A,this.map=new Map,this.unitWidth=i,this.markerType=n;for(let o of this.lines)this.add(o);this.state.facet(xD).highlightActiveBlock&&this.findAndSetActiveLines()}has(e){return this.map.has(typeof e=="number"?e:e.number)}get(e){let A=this.map.get(typeof e=="number"?e:e.number);if(!A)throw new Error("Line not found in indentation map");return A}set(e,A,i){let n=!e.text.trim().length,o={line:e,col:A,level:i,empty:n};return this.map.set(o.line.number,o),o}add(e){if(this.has(e))return this.get(e);if(!e.length||!e.text.trim().length){if(e.number===1)return this.set(e,0,0);if(e.number===this.state.doc.lines){let r=this.closestNonEmpty(e,-1);return this.set(e,0,r.level)}let n=this.closestNonEmpty(e,-1),o=this.closestNonEmpty(e,1);return n.level>=o.level&&this.markerType!=="codeOnly"?this.set(e,0,n.level):n.empty&&n.level===0&&o.level!==0?this.set(e,0,0):o.level>n.level?this.set(e,0,n.level+1):this.set(e,0,o.level)}let A=goA(e.text,this.state.tabSize),i=Math.floor(A/this.unitWidth);return this.set(e,A,i)}closestNonEmpty(e,A){let i=e.number+A;for(;A===-1?i>=1:i<=this.state.doc.lines;){if(this.has(i)){let r=this.get(i);if(!r.empty)return r}let o=this.state.doc.line(i);if(o.text.trim().length){let r=goA(o.text,this.state.tabSize),s=Math.floor(r/this.unitWidth);return this.set(o,r,s)}i+=A}let n=this.state.doc.line(A===-1?1:this.state.doc.lines);return this.set(n,0,0)}findAndSetActiveLines(){let e=hN(this.state);if(!this.has(e))return;let A=this.get(e);if(this.has(A.line.number+1)){let o=this.get(A.line.number+1);o.level>A.level&&(A=o)}if(this.has(A.line.number-1)){let o=this.get(A.line.number-1);o.level>A.level&&(A=o)}if(A.level===0)return;A.active=A.level;let i,n;for(i=A.line.number;i>1;i--){if(!this.has(i-1))continue;let o=this.get(i-1);if(o.level<A.level)break;o.active=A.level}for(n=A.line.number;n<this.state.doc.lines;n++){if(!this.has(n+1))continue;let o=this.get(n+1);if(o.level<A.level)break;o.active=A.level}}};function i_A(t){let e={light:"#F0F1F2",dark:"#2B3245",activeLight:"#E4E5E6",activeDark:"#3C445C"},A=e;return t&&(A=Object.assign(Object.assign({},e),t)),St.baseTheme({"&light":{"--indent-marker-bg-color":A.light,"--indent-marker-active-bg-color":A.activeLight},"&dark":{"--indent-marker-bg-color":A.dark,"--indent-marker-active-bg-color":A.activeDark},".cm-line":{position:"relative"},".cm-indent-markers::before":{content:'""',position:"absolute",top:0,left:"2px",right:0,bottom:0,background:"var(--indent-markers)",pointerEvents:"none",zIndex:"-1"}})}function LD(t,e,A,i,n){return`${`repeating-linear-gradient(to right, var(${t}) 0 ${e}px, transparent ${e}px ${A}ch)`} ${i*A}.5ch/calc(${A*n}ch - 1px) no-repeat`}function n_A(t,e,A,i,n){let{level:o,active:r}=t;if(n=n??i,A&&o===0)return[];let s=A?1:0,a=[];if(r!==void 0){let c=r-s-1;c>0&&a.push(LD("--indent-marker-bg-color",i,e,s,c)),a.push(LD("--indent-marker-active-bg-color",n,e,r-1,1)),r!==o&&a.push(LD("--indent-marker-bg-color",i,e,r,o-r))}else a.push(LD("--indent-marker-bg-color",i,e,s,o-s));return a.join(",")}var uN=class{constructor(e){this.view=e,this.unitWidth=ul(e.state),this.currentLineNumber=hN(e.state).number,this.generate(e.state)}update(e){let A=ul(e.state),i=A!==this.unitWidth;i&&(this.unitWidth=A);let n=hN(e.state).number,o=n!==this.currentLineNumber;this.currentLineNumber=n;let r=e.state.facet(xD).highlightActiveBlock&&o;(e.docChanged||e.viewportChanged||i||r)&&this.generate(e.state)}generate(e){let A=new os,i=t_A(this.view,e),{hideFirstIndent:n,markerType:o,thickness:r,activeThickness:s}=e.facet(xD),a=new QN(i,e,this.unitWidth,o);for(let c of i){let l=a.get(c.number);if(!l?.level)continue;let I=n_A(l,this.unitWidth,n,r,s);A.add(c.from,c.from,rt.line({class:"cm-indent-markers",attributes:{style:`--indent-markers: ${I}`}}))}this.decorations=A.finish()}};function IoA(t={}){return[xD.of(t),i_A(t.colors),Xn.fromClass(uN,{decorations:e=>e.decorations})]}var o_A=["mainAxis","crossAxis","fallbackPlacements","fallbackStrategy","fallbackAxisSideDirection","flipAlignment"],r_A=["mainAxis","crossAxis","limiter"];function frA(t,e){if(t==null)return{};var A,i,n=function(r,s){if(r==null)return{};var a={};for(var c in r)if({}.hasOwnProperty.call(r,c)){if(s.indexOf(c)!==-1)continue;a[c]=r[c]}return a}(t,e);if(Object.getOwnPropertySymbols){var o=Object.getOwnPropertySymbols(t);for(i=0;i<o.length;i++)A=o[i],e.indexOf(A)===-1&&{}.propertyIsEnumerable.call(t,A)&&(n[A]=t[A])}return n}function CoA(t,e){var A=Object.keys(t);if(Object.getOwnPropertySymbols){var i=Object.getOwnPropertySymbols(t);e&&(i=i.filter(function(n){return Object.getOwnPropertyDescriptor(t,n).enumerable})),A.push.apply(A,i)}return A}function Be(t){for(var e=1;e<arguments.length;e++){var A=arguments[e]!=null?arguments[e]:{};e%2?CoA(Object(A),!0).forEach(function(i){s_A(t,i,A[i])}):Object.getOwnPropertyDescriptors?Object.defineProperties(t,Object.getOwnPropertyDescriptors(A)):CoA(Object(A)).forEach(function(i){Object.defineProperty(t,i,Object.getOwnPropertyDescriptor(A,i))})}return t}function s_A(t,e,A){return(e=function(i){var n=function(o,r){if(typeof o!="object"||!o)return o;var s=o[Symbol.toPrimitive];if(s!==void 0){var a=s.call(o,r||"default");if(typeof a!="object")return a;throw new TypeError("@@toPrimitive must return a primitive value.")}return(r==="string"?String:Number)(o)}(i,"string");return typeof n=="symbol"?n:n+""}(e))in t?Object.defineProperty(t,e,{value:A,enumerable:!0,configurable:!0,writable:!0}):t[e]=A,t}function doA(t,e,A,i,n,o,r){try{var s=t[o](r),a=s.value}catch(c){return void A(c)}s.done?e(a):Promise.resolve(a).then(i,n)}function yt(t){return function(){var e=this,A=arguments;return new Promise(function(i,n){var o=t.apply(e,A);function r(a){doA(o,i,n,r,s,"next",a)}function s(a){doA(o,i,n,r,s,"throw",a)}r(void 0)})}}var BoA,fN,EoA,mN;typeof window<"u"&&((fN=(BoA=(mN=(EoA=window).__svelte)!==null&&mN!==void 0?mN:EoA.__svelte={}).v)!==null&&fN!==void 0?fN:BoA.v=new Set).add("5");var ih=!1;ih=!0;var Hs=Symbol(),l_A=!1,Y3=Array.isArray,g_A=Array.prototype.indexOf,VN=Array.from,I_A=Object.defineProperty,j0=Object.getOwnPropertyDescriptor,prA=Object.getOwnPropertyDescriptors,C_A=Object.prototype,d_A=Array.prototype,k_=Object.getPrototypeOf,hoA=Object.isExtensible;function E3(t){return typeof t=="function"}var QoA=()=>{};function B_A(t){return t()}function WD(t){for(var e=0;e<t.length;e++)t[e]()}var hy=32,wrA=64,ZN=128,yl=256,WN=512,ka=1024,FC=2048,TC=4096,_1=8192,S_=16384,J3=65536,E_A=1<<17,h_A=1<<20,XN=1<<21,G1=Symbol("$state"),DrA=Symbol("legacy props"),Q_A=Symbol("");function yrA(t){return t===this.v}function R_(t,e){return t!=t?e==e:t!==e||t!==null&&typeof t=="object"||typeof t=="function"}function u_A(t,e){return t!==e}function L_(t){return!R_(t,this.v)}function T3(t){throw new Error("https://svelte.dev/e/lifecycle_outside_component")}var Bn=null;function uoA(t){Bn=t}function H1(t){return vrA().get(t)}function st(t){var e=Bn={p:Bn,c:null,d:!1,e:null,m:!1,s:t,x:null,l:null};ih&&!(arguments.length>1&&arguments[1]!==void 0&&arguments[1])&&(Bn.l={s:null,u:null,r1:[],r2:NC(!1)}),x_(()=>{e.d=!0})}function at(t){var e=Bn;if(e!==null){t!==void 0&&(e.x=t);var A=e.e;if(A!==null){var i=eo,n=Io;e.e=null;try{for(var o=0;o<A.length;o++){var r=A[o];J1(r.effect),Ug(r.reaction),Nr(r.fn)}}finally{J1(i),Ug(n)}}Bn=e.p,e.m=!0}return t||{}}function nh(){return!ih||Bn!==null&&Bn.l===null}function vrA(t){var e,A;return Bn===null&&T3(),(A=(e=Bn).c)!==null&&A!==void 0?A:e.c=new Map(function(i){for(var n=i.p;n!==null;){var o=n.c;if(o!==null)return o;n=n.p}return null}(Bn)||void 0)}function vC(t){if(typeof t!="object"||t===null||G1 in t)return t;var e=k_(t);if(e!==C_A&&e!==d_A)return t;var A=new Map,i=Y3(t),n=T0(0),o=Io,r=s=>{var a=Io;Ug(o);var c=s();return Ug(a),c};return i&&A.set("length",T0(t.length)),new Proxy(t,{defineProperty(s,a,c){"value"in c&&c.configurable!==!1&&c.enumerable!==!1&&c.writable!==!1||function(){throw new Error("https://svelte.dev/e/state_descriptors_fixed")}();var l=A.get(a);return l===void 0?(l=r(()=>T0(c.value)),A.set(a,l)):b(l,r(()=>vC(c.value))),!0},deleteProperty(s,a){var c=A.get(a);if(c===void 0)a in s&&(A.set(a,r(()=>T0(Hs))),pN(n));else{if(i&&typeof a=="string"){var l=A.get("length"),I=Number(a);Number.isInteger(I)&&I<l.v&&b(l,I)}b(c,Hs),pN(n)}return!0},get(s,a,c){var l;if(a===G1)return t;var I=A.get(a),C=a in s;if(I===void 0&&(!C||(l=j0(s,a))!==null&&l!==void 0&&l.writable)&&(I=r(()=>T0(vC(C?s[a]:Hs))),A.set(a,I)),I!==void 0){var d=g(I);return d===Hs?void 0:d}return Reflect.get(s,a,c)},getOwnPropertyDescriptor(s,a){var c=Reflect.getOwnPropertyDescriptor(s,a);if(c&&"value"in c){var l=A.get(a);l&&(c.value=g(l))}else if(c===void 0){var I=A.get(a),C=I?.v;if(I!==void 0&&C!==Hs)return{enumerable:!0,configurable:!0,value:C,writable:!0}}return c},has(s,a){var c;if(a===G1)return!0;var l=A.get(a),I=l!==void 0&&l.v!==Hs||Reflect.has(s,a);return(l!==void 0||eo!==null&&(!I||(c=j0(s,a))!==null&&c!==void 0&&c.writable))&&(l===void 0&&(l=r(()=>T0(I?vC(s[a]):Hs)),A.set(a,l)),g(l)===Hs)?!1:I},set(s,a,c,l){var I,C=A.get(a),d=a in s;if(i&&a==="length")for(var B=c;B<C.v;B+=1){var E=A.get(B+"");E!==void 0?b(E,Hs):B in s&&(E=r(()=>T0(Hs)),A.set(B+"",E))}C===void 0?(!d||(I=j0(s,a))!==null&&I!==void 0&&I.writable)&&(b(C=r(()=>T0(void 0)),r(()=>vC(c))),A.set(a,C)):(d=C.v!==Hs,b(C,r(()=>vC(c))));var Q=Reflect.getOwnPropertyDescriptor(s,a);if(Q!=null&&Q.set&&Q.set.call(l,c),!d){if(i&&typeof a=="string"){var u=A.get("length"),v=Number(a);Number.isInteger(v)&&v>=u.v&&b(u,v+1)}pN(n)}return!0},ownKeys(s){g(n);var a=Reflect.ownKeys(s).filter(I=>{var C=A.get(I);return C===void 0||C.v!==Hs});for(var[c,l]of A)l.v===Hs||c in s||a.push(c);return a},setPrototypeOf(){(function(){throw new Error("https://svelte.dev/e/state_prototype_fixed")})()}})}function pN(t){var e=arguments.length>1&&arguments[1]!==void 0?arguments[1]:1;b(t,t.v+e)}function ZE(t){var e=2050,A=Io!==null&&2&Io.f?Io:null;return eo===null||A!==null&&(A.f&yl)!==0?e|=yl:eo.f|=h_A,{ctx:Bn,deps:null,effects:null,equals:yrA,f:e,fn:t,reactions:null,rv:0,v:null,wv:0,parent:A??eo}}function ba(t){var e=ZE(t);return TrA(e),e}function PA(t){var e=ZE(t);return e.equals=L_,e}function brA(t){var e=t.effects;if(e!==null){t.effects=null;for(var A=0;A<e.length;A+=1)Gg(e[A])}}function MrA(t){var e,A=eo;J1(function(i){for(var n=i.parent;n!==null;){if(!(2&n.f))return n;n=n.parent}return null}(t));try{brA(t),e=PrA(t)}finally{J1(A)}return e}function krA(t){var e=MrA(t);Jc(t,!x1&&(t.f&yl)===0||t.deps===null?ka:TC),t.equals(e)||(t.v=e,t.wv=HrA())}var v3=new Map;function NC(t,e){return{f:0,v:t,reactions:null,equals:yrA,rv:0,wv:0}}function T0(t,e){var A=NC(t);return TrA(A),A}function X(t){var e,A,i=arguments.length>1&&arguments[1]!==void 0&&arguments[1],n=NC(t);return i||(n.equals=L_),ih&&Bn!==null&&Bn.l!==null&&((A=(e=Bn.l).s)!==null&&A!==void 0?A:e.s=[]).push(n),n}function lc(t,e){return b(t,Kg(()=>g(t))),e}function b(t,e){var A,i=arguments.length>2&&arguments[2]!==void 0&&arguments[2];return Io!==null&&!xg&&nh()&&18&Io.f&&((A=V0)===null||A===void 0||!A.includes(t))&&function(){throw new Error("https://svelte.dev/e/state_unsafe_mutation")}(),$N(t,i?vC(e):e)}function $N(t,e){if(!t.equals(e)){var A=t.v;z3?v3.set(t,e):v3.set(t,A),t.v=e,2&t.f&&((t.f&FC)!==0&&MrA(t),Jc(t,(t.f&yl)===0?ka:TC)),t.wv=HrA(),SrA(t,FC),!nh()||eo===null||(eo.f&ka)===0||96&eo.f||(Gc===null?function(i){Gc=i}([t]):Gc.push(t))}return e}function foA(t){var e=arguments.length>1&&arguments[1]!==void 0?arguments[1]:1,A=g(t),i=e===1?A++:A--;return b(t,A),i}function SrA(t,e){var A=t.reactions;if(A!==null)for(var i=nh(),n=A.length,o=0;o<n;o++){var r=A[o],s=r.f;(s&FC)===0&&(i||r!==eo)&&(Jc(r,e),1280&s&&(2&s?SrA(r,TC):wy(r)))}}var q0,RrA,LrA,xrA;function Qy(){var t=arguments.length>0&&arguments[0]!==void 0?arguments[0]:"";return document.createTextNode(t)}function gc(t){return LrA.call(t)}function uy(t){return xrA.call(t)}function $(t,e){return gc(t)}function Bt(t,e){var A=gc(t);return A instanceof Comment&&A.data===""?uy(A):A}function gA(t){for(var e=arguments.length>1&&arguments[1]!==void 0?arguments[1]:1,A=t;e--;)A=uy(A);return A}function FrA(t){eo===null&&Io===null&&function(){throw new Error("https://svelte.dev/e/effect_orphan")}(),Io!==null&&(Io.f&yl)!==0&&eo===null&&function(){throw new Error("https://svelte.dev/e/effect_in_unowned_derived")}(),z3&&function(){throw new Error("https://svelte.dev/e/effect_in_teardown")}()}function oh(t,e,A){var i=!(arguments.length>3&&arguments[3]!==void 0)||arguments[3],n=eo,o={ctx:Bn,deps:null,nodes_start:null,nodes_end:null,f:t|FC,first:null,fn:e,last:null,next:null,parent:n,prev:null,teardown:null,transitions:null,wv:0};if(A)try{py(o),o.f|=32768}catch(a){throw Gg(o),a}else e!==null&&wy(o);if(!(A&&o.deps===null&&o.first===null&&o.nodes_start===null&&o.teardown===null&&!(1048704&o.f))&&i&&(n!==null&&function(a,c){var l=c.last;l===null?c.last=c.first=a:(l.next=a,a.prev=l,c.last=a)}(o,n),Io!==null&&2&Io.f)){var r,s=Io;((r=s.effects)!==null&&r!==void 0?r:s.effects=[]).push(o)}return o}function x_(t){var e=oh(8,null,!1);return Jc(e,ka),e.teardown=t,e}function A_(t){if(FrA(),!(eo!==null&&(eo.f&hy)!==0&&Bn!==null&&!Bn.m))return Nr(t);var e,A=Bn;((e=A.e)!==null&&e!==void 0?e:A.e=[]).push({fn:t,effect:eo,reaction:Io})}function Nr(t){return oh(4,t,!1)}function fA(t,e){var A=Bn,i={effect:null,ran:!1};A.l.r1.push(i),i.effect=rh(()=>{t(),i.ran||(i.ran=!0,b(A.l.r2,!0),Kg(e))})}function nn(){var t=Bn;rh(()=>{if(g(t.l.r2)){for(var e of t.l.r1){var A=e.effect;(A.f&ka)!==0&&Jc(A,TC),sh(A)&&py(A),e.ran=!1}t.l.r2.v=!1}})}function rh(t){return oh(8,t,!0)}function Ee(t){var e=arguments.length>2&&arguments[2]!==void 0?arguments[2]:ZE,A=(arguments.length>1&&arguments[1]!==void 0?arguments[1]:[]).map(e);return zC(()=>t(...A.map(g)))}function zC(t){return oh(24|(arguments.length>1&&arguments[1]!==void 0?arguments[1]:0),t,!0)}function $0(t){return oh(40,t,!0,!(arguments.length>1&&arguments[1]!==void 0)||arguments[1])}function NrA(t){var e=t.teardown;if(e!==null){var A=z3,i=Io;moA(!0),Ug(null);try{e.call(null)}finally{moA(A),Ug(i)}}}function _rA(t){var e=arguments.length>1&&arguments[1]!==void 0&&arguments[1],A=t.first;for(t.first=t.last=null;A!==null;){var i=A.next;(A.f&wrA)!==0?A.parent=null:Gg(A,e),A=i}}function Gg(t){var e=!(arguments.length>1&&arguments[1]!==void 0)||arguments[1],A=!1;(e||524288&t.f)&&t.nodes_start!==null&&(GrA(t.nodes_start,t.nodes_end),A=!0),_rA(t,e&&!A),ty(t,0),Jc(t,S_);var i=t.transitions;if(i!==null)for(var n of i)n.stop();NrA(t);var o=t.parent;o!==null&&o.first!==null&&UrA(t),t.next=t.prev=t.teardown=t.ctx=t.deps=t.fn=t.nodes_start=t.nodes_end=null}function GrA(t,e){for(;t!==null;){var A=t===e?null:uy(t);t.remove(),t=A}}function UrA(t){var e=t.parent,A=t.prev,i=t.next;A!==null&&(A.next=i),i!==null&&(i.prev=A),e!==null&&(e.first===t&&(e.first=i),e.last===t&&(e.last=A))}function WE(t,e){var A=[];F_(t,A,!0),KrA(A,()=>{Gg(t),e&&e()})}function KrA(t,e){var A=t.length;if(A>0){var i=()=>--A||e();for(var n of t)n.out(i)}else e()}function F_(t,e,A){if((t.f&_1)===0){if(t.f^=_1,t.transitions!==null)for(var i of t.transitions)(i.is_global||A)&&e.push(i);for(var n=t.first;n!==null;){var o=n.next;F_(n,e,((n.f&J3)!==0||(n.f&hy)!==0)&&A),n=o}}}function XD(t){YrA(t,!0)}function YrA(t,e){if((t.f&_1)!==0){t.f^=_1,(t.f&ka)===0&&(t.f^=ka),sh(t)&&(Jc(t,FC),wy(t));for(var A=t.first;A!==null;){var i=A.next;YrA(A,((A.f&J3)!==0||(A.f&hy)!==0)&&e),A=i}if(t.transitions!==null)for(var n of t.transitions)(n.is_global||e)&&n.in()}}var b3=[],wN=[];function JrA(){var t=b3;b3=[],WD(t)}function fy(t){b3.length===0&&queueMicrotask(JrA),b3.push(t)}function f_A(){var t;b3.length>0&&JrA(),wN.length>0&&(t=wN,wN=[],WD(t))}var FD=!1,$D=!1,Ay=null,MC=!1,z3=!1;function moA(t){z3=t}var D3=[],Io=null,xg=!1;function Ug(t){Io=t}var eo=null;function J1(t){eo=t}var V0=null;function TrA(t){Io!==null&&Io.f&XN&&(V0===null?V0=[t]:V0.push(t))}var Os=null,ac=0,Gc=null,zrA=1,ey=0,x1=!1,e_=null;function HrA(){return++zrA}function sh(t){var e=t.f;if((e&FC)!==0)return!0;if((e&TC)!==0){var A=t.deps,i=(e&yl)!==0;if(A!==null){var n,o,r=(e&WN)!==0,s=i&&eo!==null&&!x1,a=A.length;if(r||s){var c=t,l=c.parent;for(n=0;n<a;n++){var I,C,d;o=A[n],(r||(I=o)===null||I===void 0||(I=I.reactions)===null||I===void 0||!I.includes(c))&&((d=(C=o).reactions)!==null&&d!==void 0?d:C.reactions=[]).push(c)}r&&(c.f^=WN),s&&l!==null&&(l.f&yl)===0&&(c.f^=yl)}for(n=0;n<a;n++)if(sh(o=A[n])&&krA(o),o.wv>t.wv)return!0}i&&(eo===null||x1)||Jc(t,ka)}return!1}function poA(t){return(t.f&S_)===0&&(t.parent===null||(t.parent.f&ZN)===0)}function my(t,e,A,i){if(FD){if(A===null&&(FD=!1),poA(e))throw t}else if(A!==null&&(FD=!0),function(n,o){for(var r=o;r!==null;){if((r.f&ZN)!==0)try{return void r.fn(n)}catch{r.f^=ZN}r=r.parent}throw FD=!1,n}(t,e),poA(e))throw t}function OrA(t,e){var A=!(arguments.length>2&&arguments[2]!==void 0)||arguments[2],i=t.reactions;if(i!==null)for(var n=0;n<i.length;n++){var o,r=i[n];(o=V0)!==null&&o!==void 0&&o.includes(t)||(2&r.f?OrA(r,e,!1):e===r&&(A?Jc(r,FC):(r.f&ka)!==0&&Jc(r,TC),wy(r)))}}function PrA(t){var e=Os,A=ac,i=Gc,n=Io,o=x1,r=V0,s=Bn,a=xg,c=t.f;Os=null,ac=0,Gc=null,x1=(c&yl)!==0&&(xg||!MC||Io===null),Io=96&c?null:t,V0=null,uoA(t.ctx),xg=!1,ey++,t.f|=XN;try{var l=(0,t.fn)(),I=t.deps;if(Os!==null){var C;if(ty(t,ac),I!==null&&ac>0)for(I.length=ac+Os.length,C=0;C<Os.length;C++)I[ac+C]=Os[C];else t.deps=I=Os;if(!x1)for(C=ac;C<I.length;C++){var d,B;((B=(d=I[C]).reactions)!==null&&B!==void 0?B:d.reactions=[]).push(t)}}else I!==null&&ac<I.length&&(ty(t,ac),I.length=ac);if(nh()&&Gc!==null&&!xg&&I!==null&&!(6146&t.f))for(C=0;C<Gc.length;C++)OrA(Gc[C],t);return n!==null&&n!==t&&(ey++,Gc!==null&&(i===null?i=Gc:i.push(...Gc))),l}finally{Os=e,ac=A,Gc=i,Io=n,x1=o,V0=r,uoA(s),xg=a,t.f^=XN}}function m_A(t,e){var A=e.reactions;if(A!==null){var i=g_A.call(A,t);if(i!==-1){var n=A.length-1;n===0?A=e.reactions=null:(A[i]=A[n],A.pop())}}A===null&&2&e.f&&(Os===null||!Os.includes(e))&&(Jc(e,TC),768&e.f||(e.f^=WN),brA(e),ty(e,0))}function ty(t,e){var A=t.deps;if(A!==null)for(var i=e;i<A.length;i++)m_A(t,A[i])}function py(t){var e=t.f;if((e&S_)===0){Jc(t,ka);var A=eo,i=Bn,n=MC;eo=t,MC=!0;try{16&e?function(r){for(var s=r.first;s!==null;){var a=s.next;(s.f&hy)===0&&Gg(s),s=a}}(t):_rA(t),NrA(t);var o=PrA(t);t.teardown=typeof o=="function"?o:null,t.wv=zrA,t.deps}catch(r){my(r,t,A,i||t.ctx)}finally{MC=n,eo=A}}}function p_A(){try{(function(){throw new Error("https://svelte.dev/e/effect_update_depth_exceeded")})()}catch(t){if(Ay===null)throw t;my(t,Ay,null)}}function jrA(){var t=MC;try{var e=0;for(MC=!0;D3.length>0;){e++>1e3&&p_A();var A=D3,i=A.length;D3=[];for(var n=0;n<i;n++)w_A(D_A(A[n]));v3.clear()}}finally{$D=!1,MC=t,Ay=null}}function w_A(t){var e=t.length;if(e!==0)for(var A=0;A<e;A++){var i=t[A];if(!(24576&i.f))try{sh(i)&&(py(i),i.deps===null&&i.first===null&&i.nodes_start===null&&(i.teardown===null?UrA(i):i.fn=null))}catch(n){my(n,i,null,i.ctx)}}}function wy(t){$D||($D=!0,queueMicrotask(jrA));for(var e=Ay=t;e.parent!==null;){var A=(e=e.parent).f;if(96&A){if((A&ka)===0)return;e.f^=ka}}D3.push(e)}function D_A(t){for(var e=[],A=t;A!==null;){var i=A.f,n=!!(96&i);if(!(n&&(i&ka)!==0)&&(i&_1)===0){if(4&i)e.push(A);else if(n)A.f^=ka;else try{sh(A)&&py(A)}catch(s){my(s,A,null,A.ctx)}var o=A.first;if(o!==null){A=o;continue}}var r=A.parent;for(A=A.next;A===null&&r!==null;)A=r.next,r=r.parent}return e}function go(t){for(;;){if(f_A(),D3.length===0)return;$D=!0,jrA()}}function qrA(){return(qrA=yt(function*(){yield Promise.resolve(),go()})).apply(this,arguments)}function g(t){var e,A=!!(2&t.f);if(e_!==null&&e_.add(t),Io===null||xg){if(A&&t.deps===null&&t.effects===null){var i=t,n=i.parent;n!==null&&(n.f&yl)===0&&(i.f^=yl)}}else if((e=V0)===null||e===void 0||!e.includes(t)){var o=Io.deps;t.rv<ey&&(t.rv=ey,Os===null&&o!==null&&o[ac]===t?ac++:Os===null?Os=[t]:x1&&Os.includes(t)||Os.push(t))}return A&&sh(i=t)&&krA(i),z3&&v3.has(t)?v3.get(t):t.v}function Kg(t){var e=xg;try{return xg=!0,t()}finally{xg=e}}var y_A=-7169;function Jc(t,e){t.f=t.f&y_A|e}function W(t){if(typeof t=="object"&&t&&!(t instanceof EventTarget)){if(G1 in t)t_(t);else if(!Array.isArray(t))for(var e in t){var A=t[e];typeof A=="object"&&A&&G1 in A&&t_(A)}}}function t_(t){var e=arguments.length>1&&arguments[1]!==void 0?arguments[1]:new Set;if(!(typeof t!="object"||t===null||t instanceof EventTarget||e.has(t))){for(var A in e.add(t),t instanceof Date&&t.getTime(),t)try{t_(t[A],e)}catch{}var i=k_(t);if(i!==Object.prototype&&i!==Array.prototype&&i!==Map.prototype&&i!==Set.prototype&&i!==Date.prototype){var n=prA(i);for(var o in n){var r=n[o].get;if(r)try{r.call(t)}catch{}}}}}var woA=!1;function VrA(t){var e=Io,A=eo;Ug(null),J1(null);try{return t()}finally{Ug(e),J1(A)}}function v_A(t,e,A){var i=arguments.length>3&&arguments[3]!==void 0?arguments[3]:A;t.addEventListener(e,()=>VrA(A));var n=t.__on_r;t.__on_r=n?()=>{n(),i(!0)}:()=>i(!0),woA||(woA=!0,document.addEventListener("reset",o=>{Promise.resolve().then(()=>{if(!o.defaultPrevented)for(var r of o.target.elements){var s;(s=r.__on_r)===null||s===void 0||s.call(r)}})},{capture:!0}))}var ZrA=new Set,i_=new Set;function WrA(t,e,A){var i=arguments.length>3&&arguments[3]!==void 0?arguments[3]:{};function n(o){if(i.capture||f3.call(e,o),!o.cancelBubble)return VrA(()=>A?.call(this,o))}return t.startsWith("pointer")||t.startsWith("touch")||t==="wheel"?fy(()=>{e.addEventListener(t,n,i)}):e.addEventListener(t,n,i),n}function re(t,e,A,i,n){var o={capture:i,passive:n},r=WrA(t,e,A,o);e!==document.body&&e!==window&&e!==document||x_(()=>{e.removeEventListener(t,r,o)})}function H3(t){for(var e=0;e<t.length;e++)ZrA.add(t[e]);for(var A of i_)A(t)}function f3(t){var e,A=this,i=A.ownerDocument,n=t.type,o=((e=t.composedPath)===null||e===void 0?void 0:e.call(t))||[],r=o[0]||t.target,s=0,a=t.__root;if(a){var c=o.indexOf(a);if(c!==-1&&(A===document||A===window))return void(t.__root=A);var l=o.indexOf(A);if(l===-1)return;c<=l&&(s=c)}if((r=o[s]||t.target)!==A){I_A(t,"currentTarget",{configurable:!0,get:()=>r||i});var I=Io,C=eo;Ug(null),J1(null);try{for(var d,B=[];r!==null;){var E=r.assignedSlot||r.parentNode||r.host||null;try{var Q=r["__"+n];if(Q!=null&&(!r.disabled||t.target===r))if(Y3(Q)){var[u,...v]=Q;u.apply(r,[t,...v])}else Q.call(r,t)}catch(y){d?B.push(y):d=y}if(t.cancelBubble||E===A||E===null)break;r=E}if(d){var L=function(y){queueMicrotask(()=>{throw y})};for(var x of B)L(x);throw d}}finally{t.__root=A,delete t.currentTarget,Ug(I),J1(C)}}}function N_(t){var e=document.createElement("template");return e.innerHTML=t.replaceAll("<!>","<!---->"),e.content}function _C(t,e){var A=eo;A.nodes_start===null&&(A.nodes_start=t,A.nodes_end=e)}function pA(t,e){var A,i=!!(1&e),n=!!(2&e),o=!t.startsWith("<!>");return()=>{A===void 0&&(A=N_(o?t:"<!>"+t),i||(A=gc(A)));var r=n||RrA?document.importNode(A,!0):A.cloneNode(!0);return i?_C(gc(r),r.lastChild):_C(r,r),r}}function O1(t,e){return function(A,i){var n,o=arguments.length>2&&arguments[2]!==void 0?arguments[2]:"svg",r=!A.startsWith("<!>"),s=!!(1&i),a="<".concat(o,">").concat(r?A:"<!>"+A,"</").concat(o,">");return()=>{if(!n){var c=gc(N_(a));if(s)for(n=document.createDocumentFragment();gc(c);)n.appendChild(gc(c));else n=gc(c)}var l=n.cloneNode(!0);return s?_C(gc(l),l.lastChild):_C(l,l),l}}(t,e,"svg")}function _r(){var t=Qy((arguments.length>0&&arguments[0]!==void 0?arguments[0]:"")+"");return _C(t,t),t}function po(){var t=document.createDocumentFragment(),e=document.createComment(""),A=Qy();return t.append(e,A),_C(e,A),t}function iA(t,e){t!==null&&t.before(e)}var b_A=["beforeinput","click","change","dblclick","contextmenu","focusin","focusout","input","keydown","keyup","mousedown","mousemove","mouseout","mouseover","mouseup","pointerdown","pointermove","pointerout","pointerover","pointerup","touchend","touchmove","touchstart"],M_A={formnovalidate:"formNoValidate",ismap:"isMap",nomodule:"noModule",playsinline:"playsInline",readonly:"readOnly",defaultvalue:"defaultValue",defaultchecked:"defaultChecked",srcobject:"srcObject",novalidate:"noValidate",allowfullscreen:"allowFullscreen",disablepictureinpicture:"disablePictureInPicture",disableremoteplayback:"disableRemotePlayback"},k_A=["touchstart","touchmove"];function S_A(t){return k_A.includes(t)}function Et(t,e){var A,i=e==null?"":typeof e=="object"?e+"":e;i!==((A=t.__t)!==null&&A!==void 0?A:t.__t=t.nodeValue)&&(t.__t=i,t.nodeValue=i+"")}function R_A(t,e){return function(A,i){var{target:n,anchor:o,props:r={},events:s,context:a,intro:c=!0}=i;(function(){if(q0===void 0){q0=window,RrA=/Firefox/.test(navigator.userAgent);var B=Element.prototype,E=Node.prototype,Q=Text.prototype;LrA=j0(E,"firstChild").get,xrA=j0(E,"nextSibling").get,hoA(B)&&(B.__click=void 0,B.__className=void 0,B.__attributes=null,B.__style=void 0,B.__e=void 0),hoA(Q)&&(Q.__t=void 0)}})();var l=new Set,I=B=>{for(var E=0;E<B.length;E++){var Q=B[E];if(!l.has(Q)){l.add(Q);var u=S_A(Q);n.addEventListener(Q,f3,{passive:u});var v=_E.get(Q);v===void 0?(document.addEventListener(Q,f3,{passive:u}),_E.set(Q,1)):_E.set(Q,v+1)}}};I(VN(ZrA)),i_.add(I);var C=void 0,d=function(B){var E=oh(wrA,B,!0);return function(){var Q=arguments.length>0&&arguments[0]!==void 0?arguments[0]:{};return new Promise(u=>{Q.outro?WE(E,()=>{Gg(E),u(void 0)}):(Gg(E),u(void 0))})}}(()=>{var B=o??n.appendChild(Qy());return $0(()=>{a&&(st({}),Bn.c=a),s&&(r.$$events=s),C=A(B,r)||{},a&&at()}),()=>{for(var E of l){n.removeEventListener(E,f3);var Q=_E.get(E);--Q===0?(document.removeEventListener(E,f3),_E.delete(E)):_E.set(E,Q)}var u;i_.delete(I),B!==o&&((u=B.parentNode)===null||u===void 0||u.removeChild(B))}});return n_.set(C,d),C}(t,e)}var _E=new Map,n_=new WeakMap;function ls(t){Bn===null&&T3(),ih&&Bn.l!==null?XrA(Bn).m.push(t):A_(()=>{var e=Kg(t);if(typeof e=="function")return e})}function Tc(t){Bn===null&&T3(),ls(()=>()=>Kg(t))}function L_A(){var t=Bn;return t===null&&T3(),(e,A,i)=>{var n,o=(n=t.s.$$events)===null||n===void 0?void 0:n[e];if(o){var r=Y3(o)?o.slice():[o],s=function(c,l){var{bubbles:I=!1,cancelable:C=!1}=arguments.length>2&&arguments[2]!==void 0?arguments[2]:{};return new CustomEvent(c,{detail:l,bubbles:I,cancelable:C})}(e,A,i);for(var a of r)a.call(t.x,s);return!s.defaultPrevented}return!0}}function x_A(t){Bn===null&&T3(),Bn.l===null&&function(){throw new Error("https://svelte.dev/e/lifecycle_legacy_only")}(),XrA(Bn).b.push(t)}function XrA(t){var e,A=t.l;return(e=A.u)!==null&&e!==void 0?e:A.u={a:[],b:[],m:[]}}function MA(t,e){var[A,i]=arguments.length>2&&arguments[2]!==void 0?arguments[2]:[0,0],n=t,o=null,r=null,s=Hs,a=!1,c=function(I){a=!0,l(!(arguments.length>1&&arguments[1]!==void 0)||arguments[1],I)},l=(I,C)=>{s!==(s=I)&&(s?(o?XD(o):C&&(o=$0(()=>C(n))),r&&WE(r,()=>{r=null})):(r?XD(r):C&&(r=$0(()=>C(n,[A+1,i]))),o&&WE(o,()=>{o=null})))};zC(()=>{a=!1,e(c),a||l(null,null)},A>0?J3:0)}function $rA(t,e,A){var i,n=t,o=Hs,r=nh()?u_A:R_;zC(()=>{r(o,o=e())&&(i&&WE(i),i=$0(()=>A(n)))})}function Zo(t,e){return e}function Fo(t,e,A,i,n){var o=arguments.length>5&&arguments[5]!==void 0?arguments[5]:null,r=t,s={flags:e,items:new Map,first:null};!(4&e)||(r=t.appendChild(Qy()));var a=null,c=!1,l=PA(()=>{var I=A();return Y3(I)?I:I==null?[]:VN(I)});zC(()=>{var I=g(l),C=I.length;c&&C===0||(c=C===0,function(d,B,E,Q,u,v,L){var x,y,F,U,T,N,K=!!(8&u),H=!!(3&u),j=d.length,IA=B.items,lA=B.first,uA=lA,p=null,V=[],cA=[];if(K)for(N=0;N<j;N+=1){var aA;U=v(F=d[N],N),(T=IA.get(U))!==void 0&&((aA=T.a)===null||aA===void 0||aA.measure(),(y??(y=new Set)).add(T))}for(N=0;N<j;N+=1)if(U=v(F=d[N],N),(T=IA.get(U))!==void 0){var jA;if(H&&F_A(T,F,N,u),(T.e.f&_1)!==0&&(XD(T.e),K&&((jA=T.a)===null||jA===void 0||jA.unfix(),(y??(y=new Set)).delete(T))),T!==uA){if(x!==void 0&&x.has(T)){if(V.length<cA.length){var VA,ce=cA[0];p=ce.prev;var EA=V[0],sA=V[V.length-1];for(VA=0;VA<V.length;VA+=1)DoA(V[VA],ce,E);for(VA=0;VA<cA.length;VA+=1)x.delete(cA[VA]);k1(B,EA.prev,sA.next),k1(B,p,EA),k1(B,sA,ce),uA=ce,p=sA,N-=1,V=[],cA=[]}else x.delete(T),DoA(T,uA,E),k1(B,T.prev,T.next),k1(B,T,p===null?B.first:p.next),k1(B,p,T),p=T;continue}for(V=[],cA=[];uA!==null&&uA.k!==U;)(uA.e.f&_1)===0&&(x??(x=new Set)).add(uA),cA.push(uA),uA=uA.next;if(uA===null)continue;T=uA}V.push(T),p=T,uA=T.next}else p=N_A(uA?uA.e.nodes_start:E,B,p,p===null?B.first:p.next,F,U,N,Q,u,L),IA.set(U,p),V=[],cA=[],uA=p.next;if(uA!==null||x!==void 0){for(var TA=x===void 0?[]:VN(x);uA!==null;)(uA.e.f&_1)===0&&TA.push(uA),uA=uA.next;var Ke=TA.length;if(Ke>0){var Re=4&u&&j===0?E:null;if(K){for(N=0;N<Ke;N+=1){var hA;(hA=TA[N].a)===null||hA===void 0||hA.measure()}for(N=0;N<Ke;N+=1){var eA;(eA=TA[N].a)===null||eA===void 0||eA.fix()}}(function(RA,oA,ne,h){for(var f=[],w=oA.length,D=0;D<w;D++)F_(oA[D].e,f,!0);var O=w>0&&f.length===0&&ne!==null;if(O){var Z=ne.parentNode;Z.textContent="",Z.append(ne),h.clear(),k1(RA,oA[0].prev,oA[w-1].next)}KrA(f,()=>{for(var q=0;q<w;q++){var CA=oA[q];O||(h.delete(CA.k),k1(RA,CA.prev,CA.next)),Gg(CA.e,!O)}})})(B,TA,Re,IA)}}K&&fy(()=>{if(y!==void 0)for(T of y){var RA;(RA=T.a)===null||RA===void 0||RA.apply()}}),eo.first=B.first&&B.first.e,eo.last=p&&p.e}(I,s,r,n,e,i,A),o!==null&&(C===0?a?XD(a):a=$0(()=>o(r)):a!==null&&WE(a,()=>{a=null})),g(l))})}function F_A(t,e,A,i){1&i&&$N(t.v,e),2&i?$N(t.i,A):t.i=A}function N_A(t,e,A,i,n,o,r,s,a,c){var l=1&a?16&a?NC(n):X(n):n,I=2&a?NC(r):r,C={i:I,v:l,k:o,a:null,e:null,prev:A,next:i};try{return C.e=$0(()=>s(t,l,I,c),!1),C.e.prev=A&&A.e,C.e.next=i&&i.e,A===null?e.first=C:(A.next=C,A.e.next=C.e),i!==null&&(i.prev=C,i.e.prev=C.e),C}finally{}}function DoA(t,e,A){for(var i=t.next?t.next.e.nodes_start:A,n=e?e.e.nodes_start:A,o=t.e.nodes_start;o!==i;){var r=uy(o);n.before(o),o=r}}function k1(t,e,A){e===null?t.first=A:(e.next=A,e.e.next=A&&A.e),A!==null&&(A.prev=e,A.e.prev=e&&e.e)}function AsA(t,e){var A=arguments.length>2&&arguments[2]!==void 0&&arguments[2],i=arguments.length>3&&arguments[3]!==void 0&&arguments[3],n=t,o="";Ee(()=>{var r,s=eo;if(o!==(o=(r=e())!==null&&r!==void 0?r:"")&&(s.nodes_start!==null&&(GrA(s.nodes_start,s.nodes_end),s.nodes_start=s.nodes_end=null),o!=="")){var a=o+"";A?a="<svg>".concat(a,"</svg>"):i&&(a="<math>".concat(a,"</math>"));var c=N_(a);if((A||i)&&(c=gc(c)),_C(gc(c),c.lastChild),A||i)for(;gc(c);)n.before(gc(c));else n.before(c)}})}function xo(t,e,A,i,n){var o,r=(o=e.$$slots)===null||o===void 0?void 0:o[A],s=!1;r===!0&&(r=e[A==="default"?"children":A],s=!0),r===void 0?n!==null&&n(t):r(t,s?()=>i:i)}function esA(t,e,A){var i,n,o=t;zC(()=>{i!==(i=e())&&(n&&(WE(n),n=null),i&&(n=$0(()=>A(o,i))))},J3)}function bs(t,e,A){Nr(()=>{var i=Kg(()=>e(t,A?.())||{});if(A&&i!=null&&i.update){var n=!1,o={};rh(()=>{var r=A();W(r),n&&R_(o,r)&&(o=r,i.update(r))}),n=!0}if(i!=null&&i.destroy)return()=>i.destroy()})}function tsA(t){var e,A,i="";if(typeof t=="string"||typeof t=="number")i+=t;else if(typeof t=="object")if(Array.isArray(t)){var n=t.length;for(e=0;e<n;e++)t[e]&&(A=tsA(t[e]))&&(i&&(i+=" "),i+=A)}else for(A in t)t[A]&&(i&&(i+=" "),i+=A);return i}function T1(t){return typeof t=="object"?function(){for(var e,A,i=0,n="",o=arguments.length;i<o;i++)(e=arguments[i])&&(A=tsA(e))&&(n&&(n+=" "),n+=A);return n}(t):t??""}var yoA=[...` 	
\r\f\xA0\v\uFEFF`];function voA(t){var e=arguments.length>1&&arguments[1]!==void 0&&arguments[1]?" !important;":";",A="";for(var i in t){var n=t[i];n!=null&&n!==""&&(A+=" "+i+": "+n+e)}return A}function DN(t){return t[0]!=="-"||t[1]!=="-"?t.toLowerCase():t}function xt(t,e,A,i,n,o){var r=t.__className;if(r!==A||r===void 0){var s=function(l,I,C){var d=l==null?"":""+l;if(I&&(d=d?d+" "+I:I),C){for(var B in C)if(C[B])d=d?d+" "+B:B;else if(d.length)for(var E=B.length,Q=0;(Q=d.indexOf(B,Q))>=0;){var u=Q+E;Q!==0&&!yoA.includes(d[Q-1])||u!==d.length&&!yoA.includes(d[u])?Q=u:d=(Q===0?"":d.substring(0,Q))+d.substring(u+1)}}return d===""?null:d}(A,i,o);s==null?t.removeAttribute("class"):e?t.className=s:t.setAttribute("class",s),t.__className=A}else if(o&&n!==o)for(var a in o){var c=!!o[a];n!=null&&c===!!n[a]||t.classList.toggle(a,c)}return o}function yN(t){var e=arguments.length>1&&arguments[1]!==void 0?arguments[1]:{},A=arguments.length>2?arguments[2]:void 0,i=arguments.length>3?arguments[3]:void 0;for(var n in A){var o=A[n];e[n]!==o&&(A[n]==null?t.style.removeProperty(n):t.style.setProperty(n,o,i))}}function vl(t,e,A,i){if(t.__style!==e){var n=function(o,r){if(r){var s,a,c="";if(Array.isArray(r)?(s=r[0],a=r[1]):s=r,o){o=String(o).replaceAll(/\s*\/\*.*?\*\/\s*/g,"").trim();var l=!1,I=0,C=!1,d=[];s&&d.push(...Object.keys(s).map(DN)),a&&d.push(...Object.keys(a).map(DN));for(var B=0,E=-1,Q=o.length,u=0;u<Q;u++){var v=o[u];if(C?v==="/"&&o[u-1]==="*"&&(C=!1):l?l===v&&(l=!1):v==="/"&&o[u+1]==="*"?C=!0:v==='"'||v==="'"?l=v:v==="("?I++:v===")"&&I--,!C&&l===!1&&I===0){if(v===":"&&E===-1)E=u;else if(v===";"||u===Q-1){if(E!==-1){var L=DN(o.substring(B,E).trim());d.includes(L)||(v!==";"&&u++,c+=" "+o.substring(B,u).trim()+";")}B=u+1,E=-1}}}}return s&&(c+=voA(s)),a&&(c+=voA(a,!0)),(c=c.trim())===""?null:c}return o==null?null:String(o)}(e,i);n==null?t.removeAttribute("style"):t.style.cssText=n,t.__style=e}else i&&(Array.isArray(i)?(yN(t,A?.[0],i[0]),yN(t,A?.[1],i[1],"important")):yN(t,A,i));return i}var YE=Symbol("class"),h3=Symbol("style"),isA=Symbol("is custom element"),nsA=Symbol("is html");function GC(t,e){var A=__(t);A.value!==(A.value=e??void 0)&&(t.value!==e||e===0&&t.nodeName==="PROGRESS")&&(t.value=e??"")}function en(t,e,A,i){var n=__(t);n[e]!==(n[e]=A)&&(e==="loading"&&(t[Q_A]=A),A==null?t.removeAttribute(e):typeof A!="string"&&osA(t).includes(e)?t[e]=A:t.setAttribute(e,A))}function jD(t,e,A,i){var n,o=__(t),r=o[isA],s=!o[nsA],a=e||{},c=t.tagName==="OPTION";for(var l in e)l in A||(A[l]=null);A.class?A.class=T1(A.class):(i||A[YE])&&(A.class=null),A[h3]&&((n=A.style)!==null&&n!==void 0||(A.style=null));var I,C,d,B,E,Q,u=osA(t),v=function(F){var U=A[F];if(c&&F==="value"&&U==null)return t.value=t.__value="",a[F]=U,0;if(F==="class")return I=t.namespaceURI==="http://www.w3.org/1999/xhtml",xt(t,I,U,i,e?.[YE],A[YE]),a[F]=U,a[YE]=A[YE],0;if(F==="style")return vl(t,U,e?.[h3],A[h3]),a[F]=U,a[h3]=A[h3],0;if(U===(C=a[F])||(a[F]=U,(d=F[0]+F[1])==="$$"))return 0;if(d==="on"){var T={},N="$$"+F,K=F.slice(2);if(B=function(p){return b_A.includes(p)}(K),function(p){return p.endsWith("capture")&&p!=="gotpointercapture"&&p!=="lostpointercapture"}(K)&&(K=K.slice(0,-7),T.capture=!0),!B&&C){if(U!=null)return 0;t.removeEventListener(K,a[N],T),a[N]=null}if(U!=null)if(B)t["__".concat(K)]=U,H3([K]);else{let p=function(V){a[F].call(this,V)};var uA=p;a[N]=WrA(K,t,p,T)}else B&&(t["__".concat(K)]=void 0)}else if(F==="style")en(t,F,U);else if(F==="autofocus")(function(p,V){if(V){var cA=document.body;p.autofocus=!0,fy(()=>{document.activeElement===cA&&p.focus()})}})(t,!!U);else if(r||F!=="__value"&&(F!=="value"||U==null))if(F==="selected"&&c)(function(p,V){V?p.hasAttribute("selected")||p.setAttribute("selected",""):p.removeAttribute("selected")})(t,U);else if(E=F,s||(E=function(p){var V;return p=p.toLowerCase(),(V=M_A[p])!==null&&V!==void 0?V:p}(E)),Q=E==="defaultValue"||E==="defaultChecked",U!=null||r||Q)Q||u.includes(E)&&(r||typeof U!="string")?t[E]=U:typeof U!="function"&&en(t,E,U);else if(o[F]=null,E==="value"||E==="checked"){var H=t,j=e===void 0;if(E==="value"){var IA=H.defaultValue;H.removeAttribute(E),H.defaultValue=IA,H.value=H.__value=j?IA:null}else{var lA=H.defaultChecked;H.removeAttribute(E),H.defaultChecked=lA,H.checked=!!j&&lA}}else t.removeAttribute(F);else t.value=t.__value=U};for(var L in A)v(L);var x=function(F){var U,T,N,K;F.description==="@attach"&&(U=t,T=()=>A[F],K=void 0,zC(()=>{K!==(K=T())&&(N&&(Gg(N),N=null),K&&(N=$0(()=>{Nr(()=>K(U))})))}))};for(var y of Object.getOwnPropertySymbols(A))x(y);return a}function __(t){var e;return(e=t.__attributes)!==null&&e!==void 0?e:t.__attributes={[isA]:t.nodeName.includes("-"),[nsA]:t.namespaceURI==="http://www.w3.org/1999/xhtml"}}var boA=new Map;function osA(t){var e,A=boA.get(t.nodeName);if(A)return A;boA.set(t.nodeName,A=[]);for(var i=t,n=Element.prototype;n!==i;){for(var o in e=prA(i))e[o].set&&A.push(o);i=k_(i)}return A}function iy(t,e){var A=arguments.length>2&&arguments[2]!==void 0?arguments[2]:e,i=nh();v_A(t,"input",n=>{var o=n?t.defaultValue:t.value;if(o=vN(t)?bN(o):o,A(o),i&&o!==(o=e())){var r=t.selectionStart,s=t.selectionEnd;t.value=o??"",s!==null&&(t.selectionStart=r,t.selectionEnd=Math.min(s,t.value.length))}}),Kg(e)==null&&t.value&&A(vN(t)?bN(t.value):t.value),rh(()=>{var n=e();vN(t)&&n===bN(t.value)||(t.type!=="date"||n||t.value)&&n!==t.value&&(t.value=n??"")})}function vN(t){var e=t.type;return e==="number"||e==="range"}function bN(t){return t===""?null:+t}function kt(t,e,A){var i=j0(t,e);i&&i.set&&(t[e]=A,x_(()=>{t[e]=null}))}function MoA(t,e){return t===e||t?.[G1]===e}function to(){var t=arguments.length>0&&arguments[0]!==void 0?arguments[0]:{},e=arguments.length>1?arguments[1]:void 0,A=arguments.length>2?arguments[2]:void 0;return Nr(()=>{var i,n;return rh(()=>{i=n,n=[],Kg(()=>{t!==A(...n)&&(e(t,...n),i&&MoA(A(...i),t)&&e(null,...i))})}),()=>{fy(()=>{n&&MoA(A(...n),t)&&e(null,...n)})}}),t}function z0(t){return function(){for(var e=arguments.length,A=new Array(e),i=0;i<e;i++)A[i]=arguments[i];return A[0].stopPropagation(),t?.apply(this,A)}}function S1(t){return function(){for(var e=arguments.length,A=new Array(e),i=0;i<e;i++)A[i]=arguments[i];return A[0].preventDefault(),t?.apply(this,A)}}function Rt(){var t=arguments.length>0&&arguments[0]!==void 0&&arguments[0],e=Bn,A=e.l.u;if(A){var i,n=()=>W(e.s);if(t){var o=0,r={},s=ZE(()=>{var a=!1,c=e.s;for(var l in c)c[l]!==r[l]&&(r[l]=c[l],a=!0);return a&&o++,o});n=()=>g(s)}A.b.length&&(i=()=>{koA(e,n),WD(A.b)},FrA(),rh(i)),A_(()=>{var a=Kg(()=>A.m.map(B_A));return()=>{for(var c of a)typeof c=="function"&&c()}}),A.a.length&&A_(()=>{koA(e,n),WD(A.a)})}}function koA(t,e){if(t.l.s)for(var A of t.l.s)g(A);e()}function Dy(t){var e=NC(0);return function(){return arguments.length===1?(b(e,g(e)+1),arguments[0]):(g(e),t())}}function m3(t,e){var A,i=(A=t.$$events)===null||A===void 0?void 0:A[e.type],n=Y3(i)?i.slice():i==null?[]:[i];for(var o of n)o.call(this,e)}var ND=!1,__A={get(t,e){if(!t.exclude.includes(e))return g(t.version),e in t.special?t.special[e]():t.props[e]},set:(t,e,A)=>(e in t.special||(t.special[e]=k({get[e](){return t.props[e]}},e,4)),t.special[e](A),foA(t.version),!0),getOwnPropertyDescriptor(t,e){if(!t.exclude.includes(e))return e in t.props?{enumerable:!0,configurable:!0,value:t.props[e]}:void 0},deleteProperty:(t,e)=>(t.exclude.includes(e)||(t.exclude.push(e),foA(t.version)),!0),has:(t,e)=>!t.exclude.includes(e)&&e in t.props,ownKeys:t=>Reflect.ownKeys(t.props).filter(e=>!t.exclude.includes(e))};function _D(t,e){return new Proxy({props:t,exclude:e,special:{},version:NC(0)},__A)}var G_A={get(t,e){for(var A=t.props.length;A--;){var i=t.props[A];if(E3(i)&&(i=i()),typeof i=="object"&&i!==null&&e in i)return i[e]}},set(t,e,A){for(var i=t.props.length;i--;){var n=t.props[i];E3(n)&&(n=n());var o=j0(n,e);if(o&&o.set)return o.set(A),!0}return!1},getOwnPropertyDescriptor(t,e){for(var A=t.props.length;A--;){var i=t.props[A];if(E3(i)&&(i=i()),typeof i=="object"&&i!==null&&e in i){var n=j0(i,e);return n&&!n.configurable&&(n.configurable=!0),n}}},has(t,e){if(e===G1||e===DrA)return!1;for(var A of t.props)if(E3(A)&&(A=A()),A!=null&&e in A)return!0;return!1},ownKeys(t){var e=[];for(var A of t.props)if(E3(A)&&(A=A()),A){for(var i in A)e.includes(i)||e.push(i);for(var n of Object.getOwnPropertySymbols(A))e.includes(n)||e.push(n)}return e}};function U1(){for(var t=arguments.length,e=new Array(t),A=0;A<t;A++)e[A]=arguments[A];return new Proxy({props:e},G_A)}function SoA(t){var e,A;return(e=(A=t.ctx)===null||A===void 0?void 0:A.d)!==null&&e!==void 0&&e}function k(t,e,A,i){var n,o,r,s=!!(1&A),a=!ih||!!(2&A),c=!!(8&A),l=!!(16&A),I=!1;c?[r,I]=function(N){var K=ND;try{return ND=!1,[N(),ND]}finally{ND=K}}(()=>t[e]):r=t[e];var C,d=G1 in t||DrA in t,B=c&&((n=(o=j0(t,e))===null||o===void 0?void 0:o.set)!==null&&n!==void 0?n:d&&e in t&&(N=>t[e]=N))||void 0,E=i,Q=!0,u=!1,v=()=>(u=!0,Q&&(Q=!1,E=l?Kg(i):i),E);if(r===void 0&&i!==void 0&&(B&&a&&function(){throw new Error("https://svelte.dev/e/props_invalid_value")}(),r=v(),B&&B(r)),a)C=()=>{var N=t[e];return N===void 0?v():(Q=!0,u=!1,N)};else{var L=(s?ZE:PA)(()=>t[e]);L.f|=E_A,C=()=>{var N=g(L);return N!==void 0&&(E=void 0),N===void 0?E:N}}if(!(4&A))return C;if(B){var x=t.$$legacy;return function(N,K){return arguments.length>0?(a&&K&&!x&&!I||B(K?C():N),N):C()}}var y=!1,F=!1,U=X(r),T=ZE(()=>{var N=C(),K=g(U);return y?(y=!1,F=!0,K):(F=!1,U.v=N)});return c&&g(T),s||(T.equals=L_),function(N,K){if(e_!==null&&(y=F,C(),g(U)),arguments.length>0){var H=K?g(T):a&&c?vC(N):N;if(!T.equals(H)){if(y=!0,b(U,H),u&&E!==void 0&&(E=H),SoA(T))return N;Kg(()=>g(T))}return N}return SoA(T)?T.v:g(T)}}function wr(t){var e=arguments.length>1&&arguments[1]!==void 0?arguments[1]:function(i){var n=function(o){try{if(typeof window<"u"&&window.localStorage!==void 0)return window.localStorage[o]}catch{}}("debug");return n!=null&&n.endsWith("*")?i.startsWith(n.slice(0,-1)):i===n}(t);if(!e)return U_A;var A=function(i){for(var n=0,o=0;o<i.length;o++)n=(n<<5)-n+i.charCodeAt(o),n|=0;return RoA[Math.abs(n)%RoA.length]}(t);return function(){for(var i=arguments.length,n=new Array(i),o=0;o<i;o++)n[o]=arguments[o];console.log("%c".concat(t),"color:".concat(A),...n)}}function U_A(){}var RoA=["#0000CC","#0099FF","#009400","#8dd200","#CCCC00","#CC9933","#ae04e7","#ff35d7","#FF3333","#FF6600","#FF9933","#FFCC33"],K_A=0;function TE(){return++K_A}function jr(t){return parseInt(t,10)}function G_(t){return Y_A.test(t)}var Y_A=/^-?(?:0|[1-9]\d*)(?:\.\d+)?(?:[eE][+-]?\d+)?$/;function tn(t){return typeof t=="object"&&t!==null&&(t.constructor===void 0||t.constructor.name==="Object")}function zo(t){return typeof t=="object"&&t!==null&&(t.constructor===void 0||t.constructor.name==="Object"||t.constructor.name==="Array")}function J_A(t){return t===!0||t===!1}function o_(t){if(typeof t=="number")return t>9466848e5&&isFinite(t)&&Math.floor(t)===t&&!isNaN(new Date(t).valueOf());if(typeof t=="bigint")return o_(Number(t));try{var e=t&&t.valueOf();if(e!==t)return o_(e)}catch{return!1}return!1}function rsA(t){(GD=GD||window.document.createElement("div")).style.color="",GD.style.color=t;var e=GD.style.color;return e!==""?e.replace(/\s+/g,"").toLowerCase():void 0}var GD=void 0;function T_A(t){return typeof t=="string"&&t.length<99&&!!rsA(t)}function U_(t,e){if(typeof t=="number"||typeof t=="string"||typeof t=="boolean"||t===void 0)return typeof t;if(typeof t=="bigint")return"number";if(t===null)return"null";if(Array.isArray(t))return"array";if(tn(t))return"object";var A=e.stringify(t);return A&&G_(A)?"number":A==="true"||A==="false"?"boolean":A==="null"?"null":"unknown"}var z_A=/^https?:\/\/\S+$/;function yy(t){return typeof t=="string"&&z_A.test(t)}function ah(t,e){if(t==="")return"";var A=t.trim();return A==="null"?null:A==="true"||A!=="false"&&(G_(A)?e.parse(A):t)}var H_A=[];function LoA(t,e){if(t.length!==e.length)return!1;for(var A=0;A<t.length;A++)if(t[A]!==e[A])return!1;return!0}function r_(t){var e=arguments.length>1&&arguments[1]!==void 0&&arguments[1],A={};if(!Array.isArray(t))throw new TypeError("Array expected");function i(r,s){(!Array.isArray(r)&&!tn(r)||e&&s.length>0)&&(A[nt(s)]=!0),tn(r)&&Object.keys(r).forEach(a=>{i(r[a],s.concat(a))})}for(var n=Math.min(t.length,1e4),o=0;o<n;o++)i(t[o],H_A);return Object.keys(A).sort().map(da)}function ssA(t,e,A){if(!(e<=t))for(var i=t;i<e;i++)A(i)}function asA(t,e){return t.length>e?t.slice(0,e):t}function xoA(t){return Be({},t)}function FoA(t){return Object.values(t)}function NoA(t,e,A,i){var n=t.slice(0),o=n.splice(e,A);return n.splice.apply(n,[e+i,0,...o]),n}function O_A(t,e,A){return t.slice(0,e).concat(A).concat(t.slice(e))}function O3(t,e){try{return e.parse(t)}catch{return e.parse(yc(t))}}function csA(t,e){try{return O3(t,e)}catch{return}}function P3(t,e){t=t.replace(gsA,"");try{return e(t)}catch{}try{return e("{"+t+"}")}catch{}try{return e("["+t+"]")}catch{}throw new Error("Failed to parse partial JSON")}function lsA(t){t=t.replace(gsA,"");try{return yc(t)}catch{}try{var e=yc("["+t+"]");return e.substring(1,e.length-1)}catch{}try{var A=yc("{"+t+"}");return A.substring(1,A.length-1)}catch{}throw new Error("Failed to repair partial JSON")}var gsA=/,\s*$/;function XE(t,e){var A=GoA.exec(e);if(A){var i=jr(A[2]),n=function(d,B){for(var E=arguments.length>2&&arguments[2]!==void 0?arguments[2]:0,Q=arguments.length>3&&arguments[3]!==void 0?arguments[3]:d.length,u=0,v=E;v<Q;v++)d.charAt(v)===B&&u++;return u}(t,`
`,0,i),o=i-t.lastIndexOf(`
`,i)-1;return{position:i,line:n,column:o,message:e.replace(GoA,()=>"line ".concat(n+1," column ").concat(o+1))}}var r=V_A.exec(e),s=r?jr(r[1]):void 0,a=s!==void 0?s-1:void 0,c=Z_A.exec(e),l=c?jr(c[1]):void 0,I=l!==void 0?l-1:void 0,C=a!==void 0&&I!==void 0?function(d,B,E){for(var Q=d.indexOf(`
`),u=1;u<B&&Q!==-1;)Q=d.indexOf(`
`,Q+1),u++;return Q!==-1?Q+E+1:void 0}(t,a,I):void 0;return{position:C,line:a,column:I,message:e.replace(/^JSON.parse: /,"").replace(/ of the JSON data$/,"")}}function MN(t){return tn(t)?t.json!==void 0?t.text!==void 0?'Content must contain either a property "json" or a property "text" but not both':void 0:t.text===void 0?'Content must contain either a property "json" or a property "text"':typeof t.text!="string"?'Content "text" property must be a string containing a JSON document. Did you mean to use the "json" property instead?':void 0:"Content must be an object"}function M3(t){return tn(t)&&typeof t.text=="string"}function k3(t){return tn(t)&&t.json!==void 0}function P_A(t){var e=arguments.length>1&&arguments[1]!==void 0?arguments[1]:void 0,A=arguments.length>2&&arguments[2]!==void 0?arguments[2]:JSON;return M3(t)?t:{text:A.stringify(t.json,null,e)}}function _oA(t){var e=arguments.length>1&&arguments[1]!==void 0?arguments[1]:JSON;return k3(t)?t:{json:e.parse(t.text)}}function s_(t,e,A){return P_A(t,e,A).text}function j_A(t,e){return q_A(t,e)>e}function q_A(t){var e=arguments.length>1&&arguments[1]!==void 0?arguments[1]:1/0;if(M3(t))return t.text.length;var A=t.json,i=0;return function n(o){if(Array.isArray(o)){if((i+=o.length-1+2)>e)return;for(var r=0;r<o.length;r++)if(n(o[r]),i>e)return}else if(tn(o)){var s=Object.keys(o);i+=2+s.length+(s.length-1);for(var a=0;a<s.length;a++){var c=s[a],l=o[c];i+=c.length+2,n(l)}}else i+=typeof o=="string"?o.length+2:String(o).length}(A),i}var GoA=/(position|char) (\d+)/,V_A=/line (\d+)/,Z_A=/column (\d+)/;function IsA(t,e){return t.parse===e.parse&&t.stringify===e.stringify}var tr,wn,wl,bl,Ml,ml,K1,W_A=/[,:]\S/;function K_(t){var{escapeControlCharacters:e,escapeUnicodeCharacters:A}=t;return e?A?X_A:$_A:A?AGA:eGA}(function(t){t.text="text",t.tree="tree",t.table="table"})(tr||(tr={})),function(t){t.after="after",t.inside="inside",t.key="key",t.value="value",t.multi="multi",t.text="text"}(wn||(wn={})),function(t){t.after="after",t.key="key",t.value="value",t.inside="inside"}(wl||(wl={})),function(t){t.info="info",t.warning="warning",t.error="error"}(bl||(bl={})),function(t){t.key="key",t.value="value"}(Ml||(Ml={})),function(t){t.asc="asc",t.desc="desc"}(ml||(ml={})),function(t){t.no="no",t.self="self",t.nextInside="nextInside"}(K1||(K1={}));var X_A={escapeValue:t=>CsA(EsA(String(t))),unescapeValue:t=>hsA(dsA(t))},$_A={escapeValue:t=>EsA(String(t)),unescapeValue:t=>hsA(t)},AGA={escapeValue:t=>CsA(String(t)),unescapeValue:t=>dsA(t)},eGA={escapeValue:t=>String(t),unescapeValue:t=>t};function CsA(t){return t.replace(/[^\x20-\x7F]/g,e=>{var A;return e==="\b"||e==="\f"||e===`
`||e==="\r"||e==="	"?e:"\\u"+("000"+((A=e.codePointAt(0))===null||A===void 0?void 0:A.toString(16))).slice(-4)})}function dsA(t){return t.replace(/\\u[a-fA-F0-9]{4}/g,e=>{try{var A=JSON.parse('"'+e+'"');return BsA[A]||A}catch{return e}})}var BsA={'"':'\\"',"\\":"\\\\","\b":"\\b","\f":"\\f","\n":"\\n","\r":"\\r","	":"\\t"},tGA={'\\"':'"',"\\\\":"\\","\\/":"/","\\b":"\b","\\f":"\f","\\n":`
`,"\\r":"\r","\\t":"	"};function EsA(t){return t.replace(/["\b\f\n\r\t\\]/g,e=>BsA[e]||e)}function hsA(t){return t.replace(/\\["bfnrt\\]/g,e=>tGA[e]||e)}function vy(t){return typeof t!="string"?String(t):t.endsWith(`
`)?t+`
`:t}function QsA(t,e){return ch(t,A=>A.nodeName.toUpperCase()===e.toUpperCase())}function F1(t,e,A){return ch(t,i=>function(n,o,r){return typeof n.getAttribute=="function"&&n.getAttribute(o)===r}(i,e,A))}function ch(t,e){return!!Y_(t,e)}function Y_(t,e){for(var A=t;A&&!e(A);)A=A.parentNode;return A}function j3(t){var e,A;return(e=t==null||(A=t.ownerDocument)===null||A===void 0?void 0:A.defaultView)!==null&&e!==void 0?e:void 0}function J_(t){var e=j3(t),A=e?.document.activeElement;return!!A&&ch(A,i=>i===t)}function usA(t,e){return Y_(t,A=>A.nodeName===e)}function kN(t){return F1(t,"data-type","selectable-key")?wn.key:F1(t,"data-type","selectable-value")?wn.value:F1(t,"data-type","insert-selection-area-inside")?wn.inside:F1(t,"data-type","insert-selection-area-after")?wn.after:wn.multi}function a_(t){return encodeURIComponent(nt(t))}function fsA(t){var e,A=Y_(t,n=>!(n==null||!n.hasAttribute)&&n.hasAttribute("data-path")),i=(e=A?.getAttribute("data-path"))!==null&&e!==void 0?e:void 0;return i?da(decodeURIComponent(i)):void 0}function iGA(t){var{allElements:e,currentElement:A,direction:i,hasPrio:n=()=>!0,margin:o=10}=t,r=fS(e.filter(function(u){var v=u.getBoundingClientRect();return v.width>0&&v.height>0}),a),s=a(A);function a(u){var v=u.getBoundingClientRect();return{x:v.left+v.width/2,y:v.top+v.height/2,rect:v,element:u}}function c(u,v){var L=arguments.length>2&&arguments[2]!==void 0?arguments[2]:1,x=u.x-v.x,y=(u.y-v.y)*L;return Math.sqrt(x*x+y*y)}var l=u=>c(u,s);if(i==="Left"||i==="Right"){var I=i==="Left"?r.filter(u=>{return v=s,u.rect.left+o<v.rect.left;var v}):r.filter(u=>{return v=s,u.rect.right>v.rect.right+o;var v}),C=I.filter(u=>{return v=u,L=s,Math.abs(v.y-L.y)<o;var v,L}),d=jB(C,l)||jB(I,u=>c(u,s,10));return d?.element}if(i==="Up"||i==="Down"){var B=i==="Up"?r.filter(u=>{return v=s,u.y+o<v.y;var v}):r.filter(u=>{return v=s,u.y>v.y+o;var v}),E=B.filter(u=>n(u.element)),Q=jB(E,l)||jB(B,l);return Q?.element}}function T_(){var t,e,A,i;return typeof navigator<"u"&&(t=(e=(A=navigator)===null||A===void 0||(A=A.platform)===null||A===void 0?void 0:A.toUpperCase().includes("MAC"))!==null&&e!==void 0?e:(i=navigator)===null||i===void 0||(i=i.userAgentData)===null||i===void 0||(i=i.platform)===null||i===void 0?void 0:i.toUpperCase().includes("MAC"))!==null&&t!==void 0&&t}function A2(t){var e=arguments.length>1&&arguments[1]!==void 0?arguments[1]:"+",A=[];z_(t,arguments.length>2&&arguments[2]!==void 0?arguments[2]:T_)&&A.push("Ctrl"),t.altKey&&A.push("Alt"),t.shiftKey&&A.push("Shift");var i=t.key.length===1?t.key.toUpperCase():t.key;return i in nGA||A.push(i),A.join(e)}function z_(t){var e=arguments.length>1&&arguments[1]!==void 0?arguments[1]:T_;return t.ctrlKey||t.metaKey&&e()}var nGA={Ctrl:!0,Command:!0,Control:!0,Alt:!0,Option:!0,Shift:!0};function vt(t,e){e===void 0&&(e={});var A=e.insertAt;if(t&&typeof document<"u"){var i=document.head||document.getElementsByTagName("head")[0],n=document.createElement("style");n.type="text/css",A==="top"&&i.firstChild?i.insertBefore(n,i.firstChild):i.appendChild(n),n.styleSheet?n.styleSheet.cssText=t:n.appendChild(document.createTextNode(t))}}vt(`.jse-absolute-popup.svelte-1r8q3m8 {
  position: relative;
  left: 0;
  top: 0;
  width: 0;
  height: 0;
  z-index: 1001;
}
.jse-absolute-popup.svelte-1r8q3m8 .jse-hidden-input:where(.svelte-1r8q3m8) {
  position: fixed;
  left: 0;
  top: 0;
  width: 0;
  height: 0;
  padding: 0;
  margin: 0;
  border: none;
  outline: none;
  overflow: hidden;
}
.jse-absolute-popup.svelte-1r8q3m8 .jse-absolute-popup-content:where(.svelte-1r8q3m8) {
  position: absolute;
}`);var oGA=pA('<div class="jse-absolute-popup-content svelte-1r8q3m8"><input type="text" readonly="" tabindex="-1" class="jse-hidden-input svelte-1r8q3m8"/> <!></div>'),rGA=pA('<div role="none" class="jse-absolute-popup svelte-1r8q3m8"><!></div>');function sGA(t,e){st(e,!1);var A=k(e,"popup",8),i=k(e,"closeAbsolutePopup",8),n=X(),o=X();function r(I){A().options&&A().options.closeOnOuterClick&&!ch(I.target,C=>C===g(n))&&i()(A().id)}function s(I){A2(I)==="Escape"&&(I.preventDefault(),I.stopPropagation(),i()(A().id))}ls(function(){g(o)&&g(o).focus()}),Rt();var a=rGA();re("mousedown",q0,function(I){r(I)},!0),re("keydown",q0,s,!0),re("wheel",q0,function(I){r(I)},!0);var c=$(a),l=I=>{var C=oGA(),d=$(C);to(d,B=>b(o,B),()=>g(o)),esA(gA(d,2),()=>A().component,(B,E)=>{E(B,U1(()=>A().props))}),Ee(B=>vl(C,B),[()=>function(B,E){var Q=B.getBoundingClientRect(),{left:u,top:v,positionAbove:L,positionLeft:x}=function(){if(E.anchor){var{anchor:y,width:F=0,height:U=0,offsetTop:T=0,offsetLeft:N=0,position:K}=E,{left:H,top:j,bottom:IA,right:lA}=y.getBoundingClientRect(),uA=K==="top"||j+U>window.innerHeight&&j>U,p=K==="left"||H+F>window.innerWidth&&H>F;return{left:p?lA-N:H+N,top:uA?j-T:IA+T,positionAbove:uA,positionLeft:p}}if(typeof E.left=="number"&&typeof E.top=="number"){var{left:V,top:cA,width:aA=0,height:jA=0}=E;return{left:V,top:cA,positionAbove:cA+jA>window.innerHeight&&cA>jA,positionLeft:V+aA>window.innerWidth&&V>aA}}throw new Error('Invalid config: pass either "left" and "top", or pass "anchor"')}();return(L?"bottom: ".concat(Q.top-v,"px;"):"top: ".concat(v-Q.top,"px;"))+(x?"right: ".concat(Q.left-u,"px;"):"left: ".concat(u-Q.left,"px;"))}(g(n),A().options)],PA),iA(I,C)};MA(c,I=>{g(n)&&I(l)}),to(a,I=>b(n,I),()=>g(n)),re("mousedown",a,function(I){I.stopPropagation()}),re("keydown",a,s),iA(t,a),at()}var aGA=pA("<!> <!>",1);function c_(t,e){st(e,!1);var A,i,n=wr("jsoneditor:AbsolutePopup"),o=X([],!0);function r(c){var l=g(o).findIndex(C=>C.id===c);if(l!==-1){var I=g(o)[l];I.options.onClose&&I.options.onClose(),b(o,g(o).filter(C=>C.id!==c))}}A="absolute-popup",i={openAbsolutePopup:function(c,l,I){n("open...",l,I);var C={id:TE(),component:c,props:l||{},options:I||{}};return b(o,[...g(o),C]),C.id},closeAbsolutePopup:r},vrA().set(A,i),fA(()=>g(o),()=>{n("popups",g(o))}),nn(),Rt(!0);var s=aGA(),a=Bt(s);Fo(a,1,()=>g(o),Zo,(c,l)=>{sGA(c,{get popup(){return g(l)},closeAbsolutePopup:r})}),xo(gA(a,2),e,"default",{},null),iA(t,s),at()}function q3(t,e){for(var A=new Set(e),i=t.replace(/ \(copy( \d+)?\)$/,""),n=t,o=1;A.has(n);){var r="copy"+(o>1?" "+o:"");n="".concat(i," (").concat(r,")"),o++}return n}function S3(t,e){var A=e-3;return t.length>e?t.substring(0,A)+"...":t}function cGA(t){if(t==="")return"";var e=t.toLowerCase();if(e==="null")return null;if(e==="true")return!0;if(e==="false")return!1;if(e!=="undefined"){var A=Number(t),i=parseFloat(t);return isNaN(A)||isNaN(i)?t:A}}var lGA={id:"jsonquery",name:"JSONQuery",description:`
<p>
  Enter a <a href="https://jsonquerylang.org" target="_blank" 
  rel="noopener noreferrer">JSON Query</a> function to filter, sort, or transform the data.
  You can use functions like <code>get</code>, <code>filter</code>,
  <code>sort</code>, <code>pick</code>, <code>groupBy</code>, <code>uniq</code>, etcetera. 
  Example query: <code>filter(.age >= 18)</code>
</p>
`,createQuery:function(t,e){var{filter:A,sort:i,projection:n}=e,o=[];A&&A.path&&A.relation&&A.value&&o.push(["filter",[(r=A.relation,kS("1 ".concat(r," 1"))[0]),UD(A.path),cGA(A.value)]]);var r;return i&&i.path&&i.direction&&o.push(["sort",UD(i.path),i.direction==="desc"?"desc":"asc"]),n&&n.paths&&(n.paths.length>1?o.push(["pick",...n.paths.map(UD)]):o.push(["map",UD(n.paths[0])])),dW(["pipe",...o])},executeQuery:function(t,e,A){var i=IsA(A,JSON)?t:function(n){var o=A.stringify(n);return o!==void 0?JSON.parse(o):void 0}(t);return e.trim()!==""?BW(i,e):i}};function UD(t){return["get",...t]}var gGA=O1("<g><!></g>");function IGA(t,e){st(e,!1);var A=870711,i=X(""),n=k(e,"data",8);function o(s){if(!s||!s.raw)return"";var a=s.raw,c={};return a=a.replace(/\s(?:xml:)?id=["']?([^"')\s]+)/g,(l,I)=>{var C="fa-".concat((A+=1).toString(16));return c[I]=C,' id="'.concat(C,'"')}),a=a.replace(/#(?:([^'")\s]+)|xpointer\(id\((['"]?)([^')]+)\2\)\))/g,(l,I,C,d)=>{var B=I||d;return B&&c[B]?"#".concat(c[B]):l}),a}fA(()=>W(n()),()=>{b(i,o(n()))}),nn();var r=gGA();AsA($(r),()=>g(i),!0),iA(t,r),at()}vt(`
  .fa-icon.svelte-1mc5hvj {
    display: inline-block;
    fill: currentColor;
  }
  .fa-flip-horizontal.svelte-1mc5hvj {
    transform: scale(-1, 1);
  }
  .fa-flip-vertical.svelte-1mc5hvj {
    transform: scale(1, -1);
  }
  .fa-spin.svelte-1mc5hvj {
    animation: svelte-1mc5hvj-fa-spin 1s 0s infinite linear;
  }
  .fa-inverse.svelte-1mc5hvj {
    color: #fff;
  }
  .fa-pulse.svelte-1mc5hvj {
    animation: svelte-1mc5hvj-fa-spin 1s infinite steps(8);
  }
  @keyframes svelte-1mc5hvj-fa-spin {
    0% {
      transform: rotate(0deg);
    }
    100% {
      transform: rotate(360deg);
    }
  }
`);var CGA=O1("<svg><!></svg>"),dGA=O1("<path></path>"),BGA=O1("<polygon></polygon>"),EGA=O1("<!><!><!>",1);function Si(t,e){var A=_D(e,["children","$$slots","$$events","$$legacy"]),i=_D(A,["class","data","scale","spin","inverse","pulse","flip","label","style"]);st(e,!1);var n=k(e,"class",8,""),o=k(e,"data",8),r=X(),s=k(e,"scale",8,1),a=k(e,"spin",8,!1),c=k(e,"inverse",8,!1),l=k(e,"pulse",8,!1),I=k(e,"flip",8,void 0),C=k(e,"label",8,""),d=k(e,"style",8,""),B=X(10),E=X(10),Q=X(),u=X();function v(){var x=1;return s()!==void 0&&(x=Number(s())),isNaN(x)||x<=0?(console.warn('Invalid prop: prop "scale" should be a number over 0.'),1):1*x}function L(){return g(r)?Math.max(g(r).width,g(r).height)/16:1}fA(()=>(W(o()),W(d()),W(s())),()=>{b(r,function(x){var y;if(x){if(!("definition"in x)){if("iconName"in x&&"icon"in x){x.iconName;var[F,U,,,T]=x.icon;y={width:F,height:U,paths:(Array.isArray(T)?T:[T]).map(N=>({d:N}))}}else y=x[Object.keys(x)[0]];return y}console.error("`import faIconName from '@fortawesome/package-name/faIconName` not supported - Please use `import { faIconName } from '@fortawesome/package-name/faIconName'` instead")}}(o())),d(),s(),b(B,g(r)?g(r).width/L()*v():0),b(E,g(r)?g(r).height/L()*v():0),b(Q,function(){var x="";d()!==null&&(x+=d());var y=v();return y===1?x.length===0?"":x:(x===""||x.endsWith(";")||(x+="; "),"".concat(x,"font-size: ").concat(y,"em"))}()),b(u,g(r)?"0 0 ".concat(g(r).width," ").concat(g(r).height):"0 0 ".concat(g(B)," ").concat(g(E)))}),nn(),Rt(),function(x,y){var F,U=_D(y,["children","$$slots","$$events","$$legacy"]),T=_D(U,["class","width","height","box","spin","inverse","pulse","flip","style","label"]),N=k(y,"class",8,""),K=k(y,"width",8),H=k(y,"height",8),j=k(y,"box",8,"0 0 0 0"),IA=k(y,"spin",8,!1),lA=k(y,"inverse",8,!1),uA=k(y,"pulse",8,!1),p=k(y,"flip",8,"none"),V=k(y,"style",8,""),cA=k(y,"label",8,""),aA=CGA();xo($(aA),y,"default",{},null),Ee(jA=>{var VA;return F=jD(aA,F,Be(Be({version:"1.1",class:"fa-icon ".concat((VA=N())!==null&&VA!==void 0?VA:""),width:K(),height:H(),"aria-label":cA(),role:cA()?"img":"presentation",viewBox:j(),style:V()},T),{},{[YE]:jA}),"svelte-1mc5hvj")},[()=>({"fa-spin":IA(),"fa-pulse":uA(),"fa-inverse":lA(),"fa-flip-horizontal":p()==="horizontal","fa-flip-vertical":p()==="vertical"})],PA),iA(x,aA)}(t,U1({get label(){return C()},get width(){return g(B)},get height(){return g(E)},get box(){return g(u)},get style(){return g(Q)},get spin(){return a()},get flip(){return I()},get inverse(){return c()},get pulse(){return l()},get class(){return n()}},()=>i,{children:(x,y)=>{var F=po();xo(Bt(F),e,"default",{},U=>{var T=EGA(),N=Bt(T);Fo(N,1,()=>{var IA;return((IA=g(r))===null||IA===void 0?void 0:IA.paths)||[]},Zo,(IA,lA)=>{var uA,p=dGA();Ee(()=>uA=jD(p,uA,Be({},g(lA)))),iA(IA,p)});var K=gA(N);Fo(K,1,()=>{var IA;return((IA=g(r))===null||IA===void 0?void 0:IA.polygons)||[]},Zo,(IA,lA)=>{var uA,p=BGA();Ee(()=>uA=jD(p,uA,Be({},g(lA)))),iA(IA,p)});var H=gA(K),j=IA=>{IGA(IA,{get data(){return g(r)},set data(lA){b(r,lA)},$$legacy:!0})};MA(H,IA=>{var lA;(lA=g(r))!==null&&lA!==void 0&&lA.raw&&IA(j)}),iA(U,T)}),iA(x,F)},$$slots:{default:!0}})),at()}vt(`/* over all fonts, sizes, and colors */
/* "consolas" for Windows, "menlo" for Mac with fallback to "monaco", 'Ubuntu Mono' for Ubuntu */
/* (at Mac this font looks too large at 14px, but 13px is too small for the font on Windows) */
/* main, menu, modal */
/* jsoneditor modal */
/* tooltip in text mode */
/* panels: navigation bar, gutter, search box */
/* navigation-bar */
/* context menu */
/* contents: json key and values */
/* contents: selected or hovered */
/* contents: section of collapsed items in an array */
/* contents: highlighting of search matches */
/* contents: inline tags inside the JSON document */
/* contents: table */
/* controls in modals: inputs, buttons, and \`a\` */
/* messages */
/* svelte-select */
/* color picker */
.jse-boolean-toggle.svelte-1ryp01u {
  padding: 0;
  margin: 1px 0 0;
  vertical-align: top;
  display: inline-flex;
  color: var(--jse-value-color-boolean, #ff8c00);
}

.jse-boolean-toggle.svelte-1ryp01u:not(.jse-readonly) {
  cursor: pointer;
}`);var hGA=pA('<div role="checkbox" tabindex="-1"><!></div>');function QGA(t,e){st(e,!1);var A=k(e,"path",9),i=k(e,"value",9),n=k(e,"readOnly",9),o=k(e,"onPatch",9),r=k(e,"focus",9);Rt(!0);var s,a=hGA(),c=$(a),l=PA(()=>i()===!0?SS:RS);Si(c,{get data(){return g(l)}}),Ee(I=>{en(a,"aria-checked",i()===!0),s=xt(a,1,"jse-boolean-toggle svelte-1ryp01u",null,s,I),en(a,"title",n()?"Boolean value ".concat(i()):"Click to toggle this boolean value")},[()=>({"jse-readonly":n()})],PA),re("mousedown",a,function(I){I.stopPropagation(),n()||(o()([{op:"replace",path:nt(A()),value:!i()}]),r()())}),iA(t,a),at()}vt(`/* over all fonts, sizes, and colors */
/* "consolas" for Windows, "menlo" for Mac with fallback to "monaco", 'Ubuntu Mono' for Ubuntu */
/* (at Mac this font looks too large at 14px, but 13px is too small for the font on Windows) */
/* main, menu, modal */
/* jsoneditor modal */
/* tooltip in text mode */
/* panels: navigation bar, gutter, search box */
/* navigation-bar */
/* context menu */
/* contents: json key and values */
/* contents: selected or hovered */
/* contents: section of collapsed items in an array */
/* contents: highlighting of search matches */
/* contents: inline tags inside the JSON document */
/* contents: table */
/* controls in modals: inputs, buttons, and \`a\` */
/* messages */
/* svelte-select */
/* color picker */
.jse-color-picker-popup.svelte-s1wu8v .picker_wrapper.popup,
.jse-color-picker-popup.svelte-s1wu8v .picker_wrapper.popup .picker_arrow::before,
.jse-color-picker-popup.svelte-s1wu8v .picker_wrapper.popup .picker_arrow::after {
  background: var(--jse-color-picker-background, var(--jse-panel-background, #ebebeb));
  line-height: normal;
}
.jse-color-picker-popup.svelte-s1wu8v .picker_slider,
.jse-color-picker-popup.svelte-s1wu8v .picker_sl,
.jse-color-picker-popup.svelte-s1wu8v .picker_editor input,
.jse-color-picker-popup.svelte-s1wu8v .picker_sample,
.jse-color-picker-popup.svelte-s1wu8v .picker_done button {
  box-shadow: var(--jse-color-picker-border-box-shadow, #cbcbcb 0 0 0 1px);
}
.jse-color-picker-popup.svelte-s1wu8v .picker_editor input {
  background: var(--jse-background-color, #fff);
  color: var(--jse-text-color, #4d4d4d);
}
.jse-color-picker-popup.svelte-s1wu8v .picker_done button {
  background: var(--jse-button-background, #e0e0e0);
  color: var(--jse-button-color, var(--jse-text-color, #4d4d4d));
}
.jse-color-picker-popup.svelte-s1wu8v .picker_done button:hover {
  background: var(--jse-button-background-highlight, #e7e7e7);
}`);var uGA=pA('<div class="jse-color-picker-popup svelte-s1wu8v"></div>');function fGA(t,e){st(e,!1);var A=k(e,"color",8),i=k(e,"onChange",8),n=k(e,"showOnTop",8),o=X(),r=()=>{};ls(yt(function*(){var a,c=new((a=yield import("./chunk-TXJFAAIW.js"))===null||a===void 0?void 0:a.default)({parent:g(o),color:A(),popup:n()?"top":"bottom",onDone(l){var I=l.rgba[3]===1?l.hex.substring(0,7):l.hex;i()(I)}});c.show(),r=()=>{c.destroy()}})),Tc(()=>{r()}),Rt();var s=uGA();to(s,a=>b(o,a),()=>g(o)),iA(t,s),at()}vt(`/* over all fonts, sizes, and colors */
/* "consolas" for Windows, "menlo" for Mac with fallback to "monaco", 'Ubuntu Mono' for Ubuntu */
/* (at Mac this font looks too large at 14px, but 13px is too small for the font on Windows) */
/* main, menu, modal */
/* jsoneditor modal */
/* tooltip in text mode */
/* panels: navigation bar, gutter, search box */
/* navigation-bar */
/* context menu */
/* contents: json key and values */
/* contents: selected or hovered */
/* contents: section of collapsed items in an array */
/* contents: highlighting of search matches */
/* contents: inline tags inside the JSON document */
/* contents: table */
/* controls in modals: inputs, buttons, and \`a\` */
/* messages */
/* svelte-select */
/* color picker */
.jse-color-picker-button.svelte-xeg9n6 {
  font-size: var(--jse-font-size-mono, 14px);
  width: var(--jse-color-picker-button-size, 1em);
  height: var(--jse-color-picker-button-size, 1em);
  box-sizing: border-box;
  padding: 0;
  margin: 2px 0 0 calc(0.5 * var(--jse-padding, 10px));
  display: inline-flex;
  vertical-align: top;
  border: 1px solid var(--jse-text-color, #4d4d4d);
  border-radius: 2px;
  background: inherit;
  outline: none;
}

.jse-color-picker-button.svelte-xeg9n6:not(.jse-readonly) {
  cursor: pointer;
}`);var mGA=pA('<button type="button"></button>');function pGA(t,e){st(e,!1);var A=X(void 0,!0),i=X(void 0,!0),{openAbsolutePopup:n}=H1("absolute-popup"),o=k(e,"path",9),r=k(e,"value",9),s=k(e,"readOnly",9),a=k(e,"onPatch",9),c=k(e,"focus",9);function l(B){a()([{op:"replace",path:nt(o()),value:B}]),I()}function I(){c()()}fA(()=>W(r()),()=>{b(A,rsA(r()))}),fA(()=>(W(s()),W(r())),()=>{b(i,s()?"Color ".concat(r()):"Click to open a color picker")}),nn(),Rt(!0);var C,d=mGA();Ee(B=>{var E;C=xt(d,1,"jse-color-picker-button svelte-xeg9n6",null,C,B),vl(d,"background: ".concat((E=g(A))!==null&&E!==void 0?E:"")),en(d,"title",g(i)),en(d,"aria-label",g(i))},[()=>({"jse-readonly":s()})],PA),re("click",d,function(B){var E,Q;if(!s()){var u=B.target,v=u.getBoundingClientRect().top,L=((E=(Q=j3(u))===null||Q===void 0?void 0:Q.innerHeight)!==null&&E!==void 0?E:0)-v<300&&v>300,x={color:r(),onChange:l,showOnTop:L};n(fGA,x,{anchor:u,closeOnOuterClick:!0,onClose:I,offsetTop:18,offsetLeft:-8,height:300})}}),iA(t,d),at()}var SN=1e3,R3=100,l_=2e4,PE=[{start:0,end:R3}],wGA=1048576,DGA=1048576,UoA=10485760,RN="Insert or paste contents, enter [ insert a new array, enter { to insert a new object, or start typing to insert a new value",H_="Open context menu (Click here, right click on the selection, or use the context menu button or Ctrl+Q)",Q3="hover-insert-inside",LN="hover-insert-after",KoA="hover-collection",xN="valid",YoA="repairable",H0=336,O0=260,p3=100,JoA={[ml.asc]:"ascending",[ml.desc]:"descending"};function msA(t){for(var e=DS(t,s=>s.start),A=[e[0]],i=0;i<e.length;i++){var n=A.length-1,o=A[n],r=e[i];r.start<=o.end?A[n]={start:Math.min(o.start,r.start),end:Math.max(o.end,r.end)}:A.push(r)}return A}function g_(t){return ny(t)+R3}function ny(t){return Math.floor(t/R3)*R3}function psA(t){return!!t&&(t.type==="space"||t.space===!0)}function qD(t){return!!t&&(t.type==="separator"||t.separator===!0)}function yGA(t){return!!t&&t.type==="label"&&typeof t.text=="string"}function y3(t){return!!t&&typeof t.onClick=="function"}function FN(t){return!!t&&t.type==="dropdown-button"&&y3(t.main)&&Array.isArray(t.items)}function vGA(t){return!!t&&t.type==="row"&&Array.isArray(t.items)}function bGA(t){return!!t&&t.type==="column"&&Array.isArray(t.items)}function ToA(t){return tn(t)&&tn(t.parseError)}function MGA(t){return tn(t)&&Array.isArray(t.validationErrors)}function kGA(t){return tn(t)&&Array.isArray(t.path)&&typeof t.message=="string"&&"severity"in t}function SGA(t){return tn(t)&&kGA(t)&&typeof t.isChildError=="boolean"}function RGA(t){return tn(t)&&typeof t.action=="function"&&tn(t.props)}function kl(t){return t!==void 0&&t.type==="object"}function cs(t){return t!==void 0&&t.type==="array"}function O_(t){return t!==void 0&&t.type==="value"}function UC(t){return kl(t)||cs(t)}function zoA(t){return t!==void 0&&Array.isArray(t.searchResults)}function oy(t){return!!t&&t.type==="tree"}function HoA(t){return!!t&&t.type==="text"}function OoA(t){return!!t&&t.type==="mode"}function I_(t){var{json:e,expand:A}=t,i=function(n){var{json:o,factory:r}=n;return Array.isArray(o)?r.createArrayDocumentState():tn(o)?r.createObjectDocumentState():o!==void 0?r.createValueDocumentState():void 0}({json:e,factory:q_});return A&&i?pl(e,i,[],A):i}function P_(){var{expanded:t}=arguments.length>0&&arguments[0]!==void 0?arguments[0]:{expanded:!1};return{type:"array",expanded:t,visibleSections:PE,items:[]}}function j_(){var{expanded:t}=arguments.length>0&&arguments[0]!==void 0?arguments[0]:{expanded:!1};return{type:"object",expanded:t,properties:{}}}var q_={createObjectDocumentState:j_,createArrayDocumentState:P_,createValueDocumentState:function(){return{type:"value"}}};function wsA(t,e,A,i){var{createObjectDocumentState:n,createArrayDocumentState:o,createValueDocumentState:r}=i;return function s(a,c,l){if(Array.isArray(a)){var I=cs(c)?c:o();if(l.length===0)return I;var C=jr(l[0]),d=s(a[C],I.items[C],l.slice(1));return As(I,["items",l[0]],d)}if(tn(a)){var B=kl(c)?c:n();if(l.length===0)return B;var E=l[0],Q=s(a[E],B.properties[E],l.slice(1));return As(B,["properties",E],Q)}return O_(c)?c:r()}(t,e,A)}function cc(t,e){return L3(t,e,arguments.length>2&&arguments[2]!==void 0?arguments[2]:[],(A,i)=>{if(A!==void 0&&i!==void 0)return Array.isArray(A)?cs(i)?i:P_({expanded:!!UC(i)&&i.expanded}):tn(A)?kl(i)?i:j_({expanded:!!UC(i)&&i.expanded}):O_(i)?i:void 0},()=>!0)}function L3(t,e,A,i,n){var o=i(t,e,A);if(Array.isArray(t)&&cs(o)&&n(o)){var r=[];return V_(t,o.visibleSections,a=>{var c=A.concat(String(a)),l=L3(t[a],o.items[a],c,i,n);l!==void 0&&(r[a]=l)}),LoA(r,o.items)?o:Be(Be({},o),{},{items:r})}if(tn(t)&&kl(o)&&n(o)){var s={};return Object.keys(t).forEach(a=>{var c=A.concat(a),l=L3(t[a],o.properties[a],c,i,n);l!==void 0&&(s[a]=l)}),LoA(Object.values(s),Object.values(o.properties))?o:Be(Be({},o),{},{properties:s})}return o}function V_(t,e,A){e.forEach(i=>{var{start:n,end:o}=i;ssA(n,Math.min(t.length,o),A)})}function x3(t,e){for(var A=t,i=[],n=0;n<e.length;){if(Array.isArray(A)){var o=e[n];i.push("items",o),A=A[jr(o)]}else{if(!tn(A))throw new Error("Cannot convert path: Object or Array expected at index ".concat(n));var r=e[n];i.push("properties",r),A=A[r]}n++}return i}function pl(t,e,A,i){for(var n=e,o=function(s){var a=A.slice(0,s);n=$E(t,n,a,(c,l)=>{var I=UC(l)&&!l.expanded?Be(Be({},l),{},{expanded:!0}):l;return cs(I)?function(C,d){if(function(Q,u){return Q.some(v=>u>=v.start&&u<v.end)}(C.visibleSections,d))return C;var B=ny(d),E={start:B,end:g_(B)};return Be(Be({},C),{},{visibleSections:msA(C.visibleSections.concat(E))})}(I,jr(A[s])):I})},r=0;r<A.length;r++)o(r);return $E(t,n,A,(s,a)=>function(c,l,I,C){return L3(c,l,I,(d,B,E)=>Array.isArray(d)&&C(E)?cs(B)?B.expanded?B:Be(Be({},B),{},{expanded:!0}):P_({expanded:!0}):tn(d)&&C(E)?kl(B)?B.expanded?B:Be(Be({},B),{},{expanded:!0}):j_({expanded:!0}):B,d=>UC(d)&&d.expanded)}(s,a,[],i))}function PoA(t,e,A,i){return $E(t,e,A,(n,o)=>i?function(r,s,a){return L3(r,s,a,(c,l)=>joA(l),()=>!0)}(n,o,A):joA(o))}function joA(t){return cs(t)&&t.expanded?Be(Be({},t),{},{expanded:!1,visibleSections:PE}):kl(t)&&t.expanded?Be(Be({},t),{},{expanded:!1}):t}function DsA(t,e,A){var i={json:t,documentState:e},n=A.reduce((o,r)=>({json:Ba(o.json,[r]),documentState:LGA(o.json,o.documentState,r)}),i);return{json:n.json,documentState:cc(n.json,n.documentState)}}function LGA(t,e,A){if(Vk(A))return qoA(t,e,A,void 0);if(Zk(A))return VoA(t,e,A);if(Q8(A)){var i=Ea(t,A.path),n=Z0(t,e,i);return n?by(t,e,i,{type:"value",enforceString:n}):e}return u8(A)||HI(A)?function(o,r,s){if(HI(s)&&s.from===s.path)return r;var a=r,c=Ea(o,s.from),l=kC(o,a,c);return HI(s)&&(a=VoA(o,a,{path:s.from})),a=qoA(o,a,{path:s.path},l),a}(t,e,A):e}function kC(t,e,A){try{return Fe(e,x3(t,A))}catch{return}}function Z_(t,e,A,i,n){var o=wsA(t,e,A,n);return Lu(o,x3(t,A),r=>{var s=Fe(t,A);return i(s,r)})}function by(t,e,A,i){return function(n,o,r,s,a){var c=wsA(n,o,r,a);return As(c,x3(n,r),s)}(t,e,A,i,q_)}function $E(t,e,A,i){return Z_(t,e,A,i,q_)}function qoA(t,e,A,i){var n=Ea(t,A.path),o=e;return o=$E(t,o,pi(n),(r,s)=>{if(!cs(s))return s;var a=jr(ri(n)),{items:c,visibleSections:l}=s;return Be(Be({},s),{},{items:a<c.length?O_A(c,a,i!==void 0?[i]:Array(1)):c,visibleSections:ysA(l,a,1)})}),by(t,o,n,i)}function VoA(t,e,A){var i=Ea(t,A.path),n=pi(i),o=Fe(t,n);return Array.isArray(o)?$E(t,e,n,(r,s)=>{if(!cs(s))return s;var a=jr(ri(i)),{items:c,visibleSections:l}=s;return Be(Be({},s),{},{items:c.slice(0,a).concat(c.slice(a+1)),visibleSections:ysA(l,a,-1)})}):function(r,s,a){var c=x3(r,a);return Qs(s,c)?OI(s,x3(r,a)):s}(t,e,i)}function ysA(t,e,A){return function(i){for(var n=i.slice(0),o=1;o<n.length;)n[o-1].end===n[o].start&&(n[o-1]={start:n[o-1].start,end:n[o].end},n.splice(o)),o++;return n}(t.map(i=>({start:i.start>e?i.start+A:i.start,end:i.end>e?i.end+A:i.end})))}function Z0(t,e,A){var i,n=Fe(t,A),o=kC(t,e,A),r=O_(o)?o.enforceString:void 0;return typeof r=="boolean"?r:typeof(i=n)=="string"&&typeof ah(i,JSON)!="string"}function V3(t,e){var A=arguments.length>2&&arguments[2]!==void 0&&arguments[2],i=t.indexOf(e);return i!==-1?A?t.slice(i):t.slice(i+1):[]}function W_(t,e){var A=[];return function i(n,o,r){A.push(r),ao(n)&&cs(o)&&o.expanded&&V_(n,o.visibleSections,s=>{i(n[s],o.items[s],r.concat(String(s)))}),Mo(n)&&kl(o)&&o.expanded&&Object.keys(n).forEach(s=>{i(n[s],o.properties[s],r.concat(s))})}(t,e,[]),A}function vsA(t,e){var A=!(arguments.length>2&&arguments[2]!==void 0)||arguments[2],i=[];return function n(o,r){i.push({path:r,type:wl.value});var s=kC(t,e,r);if(o&&UC(s)&&s.expanded){if(A&&i.push({path:r,type:wl.inside}),ao(o)){var a=cs(s)?s.visibleSections:PE;V_(o,a,c=>{var l=r.concat(String(c));n(o[c],l),A&&i.push({path:l,type:wl.after})})}Mo(o)&&Object.keys(o).forEach(c=>{var l=r.concat(c);i.push({path:l,type:wl.key}),n(o[c],l),A&&i.push({path:l,type:wl.after})})}}(t,[]),i}function NN(t,e,A){var i=W_(t,e),n=i.map(nt).indexOf(nt(A));if(n!==-1&&n<i.length-1)return i[n+1]}function KC(t,e,A){var i=arguments.length>3&&arguments[3]!==void 0?arguments[3]:10240;return pl(t,e,A,j_A({json:Fe(t,A)},i)?w3:X_)}function _N(t,e,A){var i=kC(t,e,A);return UC(i)&&i.expanded?e:KC(t,e,A)}function w3(t){return t.length===0||t.length===1&&t[0]==="0"}function ZoA(t){return t.length===0}function X_(){return!0}function VD(){return!1}function Yc(t){return t&&t.type===wn.after||!1}function as(t){return t&&t.type===wn.inside||!1}function pr(t){return t&&t.type===wn.key||!1}function dn(t){return t&&t.type===wn.value||!1}function Ao(t){return t&&t.type===wn.multi||!1}function My(t){return Ao(t)&&Ei(t.focusPath,t.anchorPath)}function F3(t){return Ao(t)||Yc(t)||as(t)||pr(t)||dn(t)}function GN(t){return t&&t.type===wn.text||!1}function z1(t,e){var A=[];return function(i,n,o){if(n){var r=SC(n),s=je(n);if(Ei(r,s))return o(r);if(i!==void 0){var a=MsA(r,s);if(r.length===a.length||s.length===a.length)return o(a);var c=ys(r,s),l=P0(i,c),I=Y1(i,c),C=X0(i,c,l),d=X0(i,c,I);if(!(C===-1||d===-1)){var B=Fe(i,a);if(Mo(B)){for(var E=Object.keys(B),Q=C;Q<=d;Q++){var u=o(a.concat(E[Q]));if(u!==void 0)return u}return}if(ao(B)){for(var v=C;v<=d;v++){var L=o(a.concat(String(v)));if(L!==void 0)return L}return}throw new Error("Failed to create selection")}}}}(t,e,i=>{A.push(i)}),A}function bsA(t){return as(t)?t.path:pi(je(t))}function P0(t,e){if(!Ao(e))return e.path;var A=X0(t,e,e.anchorPath);return X0(t,e,e.focusPath)<A?e.focusPath:e.anchorPath}function Y1(t,e){if(!Ao(e))return e.path;var A=X0(t,e,e.anchorPath);return X0(t,e,e.focusPath)>A?e.focusPath:e.anchorPath}function WoA(t,e,A){var i=arguments.length>3&&arguments[3]!==void 0&&arguments[3];if(A){var n=i?je(A):P0(t,A),o=function(a,c,l){var I=W_(a,c),C=I.map(nt),d=nt(l),B=C.indexOf(d);if(B!==-1&&B>0)return I[B-1]}(t,e,n);if(i)return as(A)||Yc(A)?o!==void 0?ys(n,n):void 0:o!==void 0?ys(SC(A),o):void 0;if(Yc(A)||as(A))return hi(n);if(pr(A)){if(o===void 0||o.length===0)return;var r=pi(o),s=Fe(t,r);return Array.isArray(s)||sn(o)?hi(o):t2(o)}return dn(A),o!==void 0?hi(o):void 0}}function XoA(t,e,A,i){if(!A)return{caret:void 0,previous:void 0,next:void 0};var n=vsA(t,e,i),o=n.findIndex(r=>Ei(r.path,je(A))&&String(r.type)===String(A.type));return{caret:o!==-1?n[o]:void 0,previous:o!==-1&&o>0?n[o-1]:void 0,next:o!==-1&&o<n.length-1?n[o+1]:void 0}}function GE(t,e){for(var A=W_(t,e),i=0;i<A.length-1&&A[i+1].length>A[i].length;)i++;var n=A[i];return n===void 0||n.length===0||Array.isArray(Fe(t,pi(n)))?hi(n):t2(n)}function Ah(t,e){if(e.length===1){var A=Mc(e);if(A.op==="replace")return hi(Ea(t,A.path))}if(!sn(e)&&e.every(r=>r.op==="move")){var i=Mc(e),n=e.slice(1);if((u8(i)||HI(i))&&i.from!==i.path&&n.every(r=>(u8(r)||HI(r))&&r.from===r.path))return t2(Ea(t,i.path))}var o=e.filter(r=>r.op!=="test"&&r.op!=="remove"&&(r.op!=="move"||r.from!==r.path)&&typeof r.path=="string").map(r=>Ea(t,r.path));if(!sn(o))return{type:wn.multi,anchorPath:Mc(o),focusPath:ri(o)}}function MsA(t,e){for(var A=0;A<t.length&&A<e.length&&t[A]===e[A];)A++;return t.slice(0,A)}function ry(t){return pr(t)||dn(t)||My(t)}function $oA(t,e){return ry(e)&&zo(Fe(t,je(e)))?je(e):pi(je(e))}function e2(t,e){if(t.length<e.length)return!1;for(var A=0;A<e.length;A++)if(t[A]!==e[A])return!1;return!0}function Fg(t){if(Ma(t)){var{type:e,path:A}=t;return{type:e,path:A}}return t}function t2(t){return{type:wn.key,path:t}}function $_(t,e){return{type:wn.key,path:t,edit:!0,initialValue:e}}function hi(t){return{type:wn.value,path:t}}function sy(t,e){return{type:wn.value,path:t,edit:!0,initialValue:e}}function i2(t){return{type:wn.inside,path:t}}function W0(t){return{type:wn.after,path:t}}function ys(t,e){var A=MsA(t,e),i=t.length>A.length&&e.length>A.length;return{type:wn.multi,anchorPath:i?A.concat(t[A.length]):A,focusPath:i?A.concat(e[A.length]):A}}function ksA(t,e,A,i){if(pr(e))return String(ri(e.path));if(dn(e)){var n=Fe(t,e.path);return typeof n=="string"?n:i.stringify(n,null,A)}if(Ao(e)){if(sn(e.focusPath))return i.stringify(t,null,A);var o=bsA(e),r=Fe(t,o);if(Array.isArray(r)){if(My(e)){var s=Fe(t,e.focusPath);return i.stringify(s,null,A)}return z1(t,e).map(a=>{var c=Fe(t,a);return"".concat(i.stringify(c,null,A),",")}).join(`
`)}return z1(t,e).map(a=>{var c=ri(a),l=Fe(t,a);return"".concat(i.stringify(c),": ").concat(i.stringify(l,null,A),",")}).join(`
`)}}function Ma(t){return(pr(t)||dn(t))&&t.edit===!0}function zE(t){return pr(t)||dn(t)||Ao(t)}function KD(t){return pr(t)||dn(t)||My(t)}function C_(t){switch(t.type){case wl.key:return t2(t.path);case wl.value:return hi(t.path);case wl.after:return W0(t.path);case wl.inside:return i2(t.path)}}function ArA(t,e){switch(t){case wn.key:return t2(e);case wn.value:return hi(e);case wn.after:return W0(e);case wn.inside:return i2(e);case wn.multi:case wn.text:return ys(e,e)}}function erA(t,e,A){if(e)return N3(t,e,A)||e2(Ao(e)?pi(e.focusPath):e.path,A)?e:void 0}function N3(t,e,A){if(t===void 0||!e)return!1;if(pr(e)||as(e)||Yc(e))return Ei(e.path,A);if(dn(e))return e2(A,e.path);if(Ao(e)){var i=P0(t,e),n=Y1(t,e),o=pi(e.focusPath);if(!e2(A,o)||A.length<=o.length)return!1;var r=X0(t,e,i),s=X0(t,e,n),a=X0(t,e,A);return a!==-1&&a>=r&&a<=s}return!1}function X0(t,e,A){var i=pi(e.focusPath);if(!e2(A,i)||A.length<=i.length)return-1;var n=A[i.length],o=Fe(t,i);if(Mo(o))return Object.keys(o).indexOf(n);if(ao(o)){var r=jr(n);if(r<o.length)return r}return-1}function je(t){return Ao(t)?t.focusPath:t.path}function SC(t){return Ao(t)?t.anchorPath:t.path}function lh(){for(var t=[],e=arguments.length,A=new Array(e),i=0;i<e;i++)A[i]=arguments[i];for(var n of A)if(typeof n=="string"&&t.push(n),n&&typeof n=="object")for(var o in n)Object.hasOwnProperty.call(n,o)&&n[o]&&t.push(o);return t.join(" ")}function SsA(t,e,A){return lh("jse-value","jse-"+U_(t,A),{"jse-url":yy(t),"jse-empty":typeof t=="string"&&t.length===0,"jse-table-cell":e===tr.table})}vt(`/* over all fonts, sizes, and colors */
/* "consolas" for Windows, "menlo" for Mac with fallback to "monaco", 'Ubuntu Mono' for Ubuntu */
/* (at Mac this font looks too large at 14px, but 13px is too small for the font on Windows) */
/* main, menu, modal */
/* jsoneditor modal */
/* tooltip in text mode */
/* panels: navigation bar, gutter, search box */
/* navigation-bar */
/* context menu */
/* contents: json key and values */
/* contents: selected or hovered */
/* contents: section of collapsed items in an array */
/* contents: highlighting of search matches */
/* contents: inline tags inside the JSON document */
/* contents: table */
/* controls in modals: inputs, buttons, and \`a\` */
/* messages */
/* svelte-select */
/* color picker */
.jse-value.jse-string.svelte-f9kmxj {
  color: var(--jse-value-color-string, #008000);
}
.jse-value.jse-object.svelte-f9kmxj, .jse-value.jse-array.svelte-f9kmxj {
  min-width: 16px;
  color: var(--jse-delimiter-color, rgba(0, 0, 0, 0.38));
}
.jse-value.jse-number.svelte-f9kmxj {
  color: var(--jse-value-color-number, #ee422e);
}
.jse-value.jse-boolean.svelte-f9kmxj {
  color: var(--jse-value-color-boolean, #ff8c00);
}
.jse-value.jse-null.svelte-f9kmxj {
  color: var(--jse-value-color-null, #004ed0);
}
.jse-value.jse-invalid.svelte-f9kmxj {
  color: var(--jse-text-color, #4d4d4d);
}
.jse-value.jse-url.svelte-f9kmxj {
  color: var(--jse-value-color-url, #008000);
  text-decoration: underline;
}

div.jse-editable-div.svelte-f9kmxj {
  min-width: 2em;
  padding: 0 5px;
  box-sizing: border-box;
  outline: none;
  border-radius: 1px;
  vertical-align: top;
  cursor: text !important;
  word-break: normal;
  white-space: pre-wrap;
  overflow-wrap: anywhere;
}
div.jse-editable-div.jse-short-text.svelte-f9kmxj {
  overflow-wrap: normal;
}
div.jse-editable-div.jse-table-cell.svelte-f9kmxj {
  overflow-wrap: normal;
  white-space: nowrap;
}
div.jse-editable-div[contenteditable=true].svelte-f9kmxj {
  outline: var(--jse-edit-outline, 2px solid #656565);
  background: var(--jse-background-color, #fff);
  position: relative;
  display: inline-block;
  border-radius: 0;
  z-index: 3;
}
div.jse-editable-div.jse-empty.svelte-f9kmxj:not(:focus) {
  outline: 1px dotted var(--jse-tag-background, rgba(0, 0, 0, 0.2));
  -moz-outline-radius: 2px;
}
div.jse-editable-div.jse-empty.svelte-f9kmxj::after {
  pointer-events: none;
  color: var(--jse-tag-background, rgba(0, 0, 0, 0.2));
}`);var xGA=pA('<div role="textbox" tabindex="0" contenteditable="true" spellcheck="false"></div>');function RsA(t,e){st(e,!1);var A=wr("jsoneditor:EditableDiv"),i=k(e,"value",9),n=k(e,"initialValue",9),o=k(e,"shortText",9,!1),r=k(e,"label",9),s=k(e,"onChange",9),a=k(e,"onCancel",9),c=k(e,"onFind",9),l=k(e,"onPaste",9,Jo),I=k(e,"onValueClass",9,()=>""),C=X(void 0,!0),d=X(void 0,!0),B=!1;function E(){return g(C)?function(v){return v.replace(/\n$/,"")}(g(C).innerText):""}function Q(v){g(C)&&lc(C,g(C).innerText=vy(v))}ls(()=>{A("onMount",{value:i(),initialValue:n()}),Q(n()!==void 0?n():i()),g(C)&&function(v){if(v.firstChild!=null){var L=document.createRange(),x=window.getSelection();L.setStart(v,1),L.collapse(!0),x?.removeAllRanges(),x?.addRange(L)}else v.focus()}(g(C))}),Tc(()=>{var v=E();A("onDestroy",{closed:B,value:i(),newValue:v}),B||v===i()||s()(v,K1.no)}),fA(()=>(W(I()),W(i())),()=>{b(d,I()(i()))}),nn(),Rt(!0);var u=xGA();to(u,v=>b(C,v),()=>g(C)),Ee(v=>{en(u,"aria-label",r()),xt(u,1,v,"svelte-f9kmxj")},[()=>T1(lh("jse-editable-div",g(d),{"jse-short-text":o()}))],PA),re("input",u,function(){var v=E();v===""&&Q(""),b(d,I()(v))}),re("keydown",u,function(v){v.stopPropagation();var L=A2(v);if(L==="Escape"&&(v.preventDefault(),B=!0,a()()),L==="Enter"||L==="Tab"){v.preventDefault(),B=!0;var x=E();s()(x,K1.nextInside)}L==="Ctrl+F"&&(v.preventDefault(),c()(!1)),L==="Ctrl+H"&&(v.preventDefault(),c()(!0))}),re("paste",u,function(v){if(v.stopPropagation(),l()&&v.clipboardData){var L=v.clipboardData.getData("text/plain");l()(L)}}),re("blur",u,function(){var v=document.hasFocus(),L=E();A("handleBlur",{hasFocus:v,closed:B,value:i(),newValue:L}),document.hasFocus()&&!B&&(B=!0,L!==i()&&s()(L,K1.self))}),iA(t,u),at()}function FGA(t,e){st(e,!1);var A=k(e,"path",9),i=k(e,"value",9),n=k(e,"selection",9),o=k(e,"mode",9),r=k(e,"parser",9),s=k(e,"normalization",9),a=k(e,"enforceString",9),c=k(e,"onPatch",9),l=k(e,"onPasteJson",9),I=k(e,"onSelect",9),C=k(e,"onFind",9),d=k(e,"focus",9),B=k(e,"findNextInside",9);function E(L){return a()?L:ah(L,r())}function Q(){I()(hi(A())),d()()}Rt(!0);var u=PA(()=>s().escapeValue(i())),v=PA(()=>Ma(n())?n().initialValue:void 0);RsA(t,{get value(){return g(u)},get initialValue(){return g(v)},label:"Edit value",onChange:function(L,x){c()([{op:"replace",path:nt(A()),value:E(s().unescapeValue(L))}],(y,F,U)=>{if(!U||Ei(A(),je(U)))return{state:F,selection:x===K1.nextInside?B()(A()):hi(A())}}),d()()},onCancel:Q,onPaste:function(L){try{var x=r().parse(L);zo(x)&&l()({path:A(),contents:x,onPasteAsJson:()=>{Q();var y=[{op:"replace",path:nt(A()),value:x}];c()(y,(F,U)=>({state:KC(F,U,A())}))}})}catch{}},get onFind(){return C()},onValueClass:function(L){return SsA(E(s().unescapeValue(L)),o(),r())}}),at()}function HE(t,e,A){var i=pi(e),n=Fe(t,i);if(ao(n)){var o=jr(ri(e));return A.map((c,l)=>({op:"add",path:nt(i.concat(String(o+l))),value:c.value}))}if(Mo(n)){var r=ri(e),s=Object.keys(n),a=r!==void 0?V3(s,r,!0):[];return[...A.map(c=>{var l=q3(c.key,s);return{op:"add",path:nt(i.concat(l)),value:c.value}}),...a.map(c=>YC(i,c))]}throw new Error("Cannot create insert operations: parent must be an Object or Array")}function d_(t,e,A){var i=Fe(t,e);if(Array.isArray(i)){var n=i.length;return A.map((o,r)=>({op:"add",path:nt(e.concat(String(n+r))),value:o.value}))}return A.map(o=>{var r=q3(o.key,Object.keys(i));return{op:"add",path:nt(e.concat(r)),value:o.value}})}function Z3(t,e,A,i){var n=q3(i,e.filter(r=>r!==A)),o=V3(e,A,!1);return[{op:"move",from:nt(t.concat(A)),path:nt(t.concat(n))},...o.map(r=>YC(t,r))]}function LsA(t,e){var A=ri(e);if(sn(A))throw new Error("Cannot duplicate root object");var i=pi(A),n=ri(A),o=Fe(t,i);if(ao(o)){var r=ri(e),s=r?jr(ri(r))+1:0;return[...e.map((l,I)=>({op:"copy",from:nt(l),path:nt(i.concat(String(I+s)))}))]}if(Mo(o)){var a=Object.keys(o),c=n!==void 0?V3(a,n,!1):[];return[...e.map(l=>{var I=q3(ri(l),a);return{op:"copy",from:nt(l),path:nt(i.concat(I))}}),...c.map(l=>YC(i,l))]}throw new Error("Cannot create duplicate operations: parent must be an Object or Array")}function xsA(t,e){if(dn(e))return[{op:"move",from:nt(e.path),path:""}];if(!Ao(e))throw new Error("Cannot create extract operations: parent must be an Object or Array");var A=pi(e.focusPath),i=Fe(t,A);if(ao(i)){var n=z1(t,e).map(r=>{var s=jr(ri(r));return i[s]});return[{op:"replace",path:"",value:n}]}if(Mo(i)){var o={};return z1(t,e).forEach(r=>{var s=String(ri(r));o[s]=i[s]}),[{op:"replace",path:"",value:o}]}throw new Error("Cannot extract: unsupported type of selection "+JSON.stringify(e))}function FsA(t,e,A,i){if(pr(e)){var n=csA(A,i),o=pi(e.path),r=Fe(t,o);return Z3(o,Object.keys(r),ri(e.path),typeof n=="string"?n:A)}if(dn(e)||Ao(e)&&sn(e.focusPath))try{return[{op:"replace",path:nt(je(e)),value:P3(A,F=>O3(F,i))}]}catch{return[{op:"replace",path:nt(je(e)),value:A}]}if(Ao(e)){var s=UN(A,i);return function(F,U,T){var N=Mc(U),K=pi(N),H=Fe(F,K);if(ao(H)){var j=Mc(U),IA=j?jr(ri(j)):0;return[...ay(U),...T.map((VA,ce)=>({op:"add",path:nt(K.concat(String(ce+IA))),value:VA.value}))]}if(Mo(H)){var lA=ri(U),uA=pi(lA),p=ri(lA),V=Object.keys(H),cA=p!==void 0?V3(V,p,!1):[],aA=new Set(U.map(VA=>ri(VA))),jA=V.filter(VA=>!aA.has(VA));return[...ay(U),...T.map(VA=>{var ce=q3(VA.key,jA);return{op:"add",path:nt(uA.concat(ce)),value:VA.value}}),...cA.map(VA=>YC(uA,VA))]}throw new Error("Cannot create replace operations: parent must be an Object or Array")}(t,z1(t,e),s)}if(Yc(e)){var a=UN(A,i),c=e.path,l=pi(c),I=Fe(t,l);if(ao(I)){var C=jr(ri(c));return HE(t,l.concat(String(C+1)),a)}if(Mo(I)){var d=String(ri(c)),B=Object.keys(I);if(sn(B)||ri(B)===d)return d_(t,l,a);var E=B.indexOf(d),Q=B[E+1];return HE(t,l.concat(Q),a)}throw new Error("Cannot create insert operations: parent must be an Object or Array")}if(as(e)){var u=UN(A,i),v=e.path,L=Fe(t,v);if(ao(L))return HE(t,v.concat("0"),u);if(Mo(L)){var x=Object.keys(L);if(sn(x))return d_(t,v,u);var y=Mc(x);return HE(t,v.concat(y),u)}throw new Error("Cannot create insert operations: parent must be an Object or Array")}throw new Error("Cannot insert: unsupported type of selection "+JSON.stringify(e))}function ay(t){return t.map(e=>({op:"remove",path:nt(e)})).reverse()}function YC(t,e){return{op:"move",from:nt(t.concat(e)),path:nt(t.concat(e))}}function UN(t,e){var A=/^\s*{/.test(t),i=/^\s*\[/.test(t),n=csA(t,e),o=n!==void 0?n:P3(t,r=>O3(r,e));return A&&tn(o)||i&&Array.isArray(o)?[{key:"New item",value:o}]:Array.isArray(o)?o.map((r,s)=>({key:"New item "+s,value:r})):tn(o)?Object.keys(o).map(r=>({key:r,value:o[r]})):[{key:"New item",value:o}]}function NsA(t,e){if(pr(e)){var A=pi(e.path),i=Fe(t,A),n=Z3(A,Object.keys(i),ri(e.path),"");return{operations:n,newSelection:Ah(t,n)}}if(dn(e))return{operations:[{op:"replace",path:nt(e.path),value:""}],newSelection:e};if(Ao(e)){var o=z1(t,e),r=ay(o),s=ri(o);if(sn(s))return{operations:[{op:"replace",path:"",value:""}],newSelection:hi([])};var a=pi(s),c=Fe(t,a);if(ao(c)){var l=Mc(o),I=jr(ri(l));return{operations:r,newSelection:I===0?i2(a):W0(a.concat(String(I-1)))}}if(Mo(c)){var C=Object.keys(c),d=Mc(o),B=ri(d),E=C.indexOf(B),Q=C[E-1];return{operations:r,newSelection:E===0?i2(a):W0(a.concat(Q))}}throw new Error("Cannot create remove operations: parent must be an Object or Array")}throw new Error("Cannot remove: unsupported type of selection "+JSON.stringify(e))}function _sA(t,e){return function(A){var i=arguments.length>1&&arguments[1]!==void 0?arguments[1]:Ei;return A.filter((n,o)=>{for(var r=o+1;r<A.length;r++)if(i(n,A[r]))return!1;return!0})}(f8(t,e,{before:(A,i,n)=>{if(Zk(i)){var o=da(i.path);return{revertOperations:[...n,...KN(A,o)]}}if(HI(i)){var r=da(i.from);return{revertOperations:i.from===i.path?[i,...KN(A,r)]:[...n,...KN(A,r)]}}return{document:A}}}))}function KN(t,e){var A=pi(e),i=ri(e),n=Fe(t,A);return Mo(n)?V3(Object.keys(n),i,!1).map(o=>YC(A,o)):[]}function trA(t){var e=t.activeIndex<t.items.length-1?t.activeIndex+1:t.items.length>0?0:-1,A=t.items[e],i=t.items.map((n,o)=>Be(Be({},n),{},{active:o===e}));return Be(Be({},t),{},{items:i,activeItem:A,activeIndex:e})}function irA(t,e){var A,i=arguments.length>2&&arguments[2]!==void 0?arguments[2]:{},n=t.toLowerCase(),o=(A=i?.maxResults)!==null&&A!==void 0?A:1/0,r=i?.columns,s=[],a=[];function c(Q){s.length>=o||s.push(Q)}function l(Q,u){if(ao(u)){var v=a.length;a.push("0");for(var L=0;L<u.length;L++)if(a[v]=String(L),l(Q,u[L]),s.length>=o)return;a.pop()}else if(Mo(u)){var x=Object.keys(u),y=a.length;for(var F of(a.push(""),x))if(a[y]=F,nrA(F,Q,a,Ml.key,c),l(Q,u[F]),s.length>=o)return;a.pop()}else nrA(String(u),Q,a,Ml.value,c)}if(t==="")return[];if(r){if(!Array.isArray(e))throw new Error("json must be an Array when option columns is defined");for(var I=0;I<e.length;I++){a[0]=String(I);for(var C=e[I],d=0;d<r.length;d++){var B=r[d];if(B.length===1)a[1]=B[0];else for(var E=0;E<B.length;E++)a[E+1]=B[E];for(;a.length>B.length+1;)a.pop();l(n,Fe(C,B))}if(s.length>=o)break}return s}return l(n,e),s}function nrA(t,e,A,i,n){var o=t.toLowerCase(),r=0,s=-1,a=-1;do(a=o.indexOf(e,s))!==-1&&(s=a+e.length,n({path:A.slice(0),field:i,fieldIndex:r,start:a,end:s}),r++);while(a!==-1)}function B_(t,e,A,i){return t.substring(0,A)+e+t.substring(i)}function orA(t,e,A){var i=t;return uS(A,n=>{i=B_(i,e,n.start,n.end)}),i}function NGA(t,e,A,i,n){var{field:o,path:r,start:s,end:a}=i;if(o===Ml.key){var c=pi(r),l=Fe(t,c),I=ri(r),C=Z3(c,Object.keys(l),I,B_(I,A,s,a));return{newSelection:Ah(t,C),operations:C}}if(o===Ml.value){var d=Fe(t,r);if(d===void 0)throw new Error("Cannot replace: path not found ".concat(nt(r)));var B=typeof d=="string"?d:String(d),E=Z0(t,e,r),Q=B_(B,A,s,a),u=[{op:"replace",path:nt(r),value:E?Q:ah(Q,n)}];return{newSelection:Ah(t,u),operations:u}}throw new Error("Cannot replace: unknown type of search result field ".concat(o))}function rrA(t){return t.path.concat(t.field,String(t.fieldIndex))}var _GA={createObjectDocumentState:()=>({type:"object",properties:{}}),createArrayDocumentState:()=>({type:"array",items:[]}),createValueDocumentState:()=>({type:"value"})};function GsA(t,e){return e.reduce((A,i)=>function(n,o,r,s){return Z_(n,o,r,s,_GA)}(t,A,i.path,(n,o)=>Be(Be({},o),{},{searchResults:o.searchResults?o.searchResults.concat(i):[i]})),void 0)}function E_(t){var e,A=(e=t?.searchResults)!==null&&e!==void 0?e:[],i=kl(t)?Object.values(t.properties).flatMap(E_):cs(t)?t.items.flatMap(E_):[];return A.concat(i)}vt(`/* over all fonts, sizes, and colors */
/* "consolas" for Windows, "menlo" for Mac with fallback to "monaco", 'Ubuntu Mono' for Ubuntu */
/* (at Mac this font looks too large at 14px, but 13px is too small for the font on Windows) */
/* main, menu, modal */
/* jsoneditor modal */
/* tooltip in text mode */
/* panels: navigation bar, gutter, search box */
/* navigation-bar */
/* context menu */
/* contents: json key and values */
/* contents: selected or hovered */
/* contents: section of collapsed items in an array */
/* contents: highlighting of search matches */
/* contents: inline tags inside the JSON document */
/* contents: table */
/* controls in modals: inputs, buttons, and \`a\` */
/* messages */
/* svelte-select */
/* color picker */
.jse-highlight.svelte-5fb7bl {
  background-color: var(--jse-search-match-color, #ffe665);
  outline: var(--jse-search-match-outline, none);
}
.jse-highlight.jse-active.svelte-5fb7bl {
  background-color: var(--jse-search-match-active-color, var(--jse-search-match-color, #ffe665));
  outline: var(--jse-search-match-outline, 2px solid #e0be00);
}`);var GGA=pA("<span> </span>");function UsA(t,e){st(e,!1);var A=X(),i=k(e,"text",8),n=k(e,"searchResultItems",8);fA(()=>(W(i()),W(n())),()=>{b(A,function(r,s){var a=[],c=0;for(var l of s){var I=r.slice(c,l.start);I!==""&&a.push({resultIndex:void 0,type:"normal",text:I,active:!1});var C=r.slice(l.start,l.end);a.push({resultIndex:l.resultIndex,type:"highlight",text:C,active:l.active}),c=l.end}var d=ri(s);return d&&d.end<r.length&&a.push({type:"normal",text:r.slice(d.end),resultIndex:void 0,active:!1}),a}(String(i()),n()))}),nn(),Rt();var o=po();Fo(Bt(o),1,()=>g(A),Zo,(r,s)=>{var a=po(),c=Bt(a),l=C=>{var d=_r();Ee(()=>Et(d,g(s).text)),iA(C,d)},I=C=>{var d,B=GGA(),E=$(B);Ee((Q,u,v)=>{d=xt(B,1,"jse-highlight svelte-5fb7bl",null,d,Q),en(B,"data-search-result-index",u),Et(E,v)},[()=>({"jse-active":g(s).active}),()=>String(g(s).resultIndex),()=>vy(g(s).text)],PA),iA(C,B)};MA(c,C=>{g(s).type==="normal"?C(l):C(I,!1)}),iA(r,a)}),iA(t,o),at()}function h_(t){var e=1e3;if(t<900)return t.toFixed()+" B";var A=t/e;if(A<900)return A.toFixed(1)+" KB";var i=A/e;if(i<900)return i.toFixed(1)+" MB";var n=i/e;return n<900?n.toFixed(1)+" GB":(n/e).toFixed(1)+" TB"}vt(`/* over all fonts, sizes, and colors */
/* "consolas" for Windows, "menlo" for Mac with fallback to "monaco", 'Ubuntu Mono' for Ubuntu */
/* (at Mac this font looks too large at 14px, but 13px is too small for the font on Windows) */
/* main, menu, modal */
/* jsoneditor modal */
/* tooltip in text mode */
/* panels: navigation bar, gutter, search box */
/* navigation-bar */
/* context menu */
/* contents: json key and values */
/* contents: selected or hovered */
/* contents: section of collapsed items in an array */
/* contents: highlighting of search matches */
/* contents: inline tags inside the JSON document */
/* contents: table */
/* controls in modals: inputs, buttons, and \`a\` */
/* messages */
/* svelte-select */
/* color picker */
.jse-tag.svelte-tqwlgz {
  border: none;
  font-size: 80%;
  font-family: var(--jse-font-family, -apple-system, BlinkMacSystemFont, "Segoe UI", Roboto, Oxygen-Sans, Ubuntu, Cantarell, "Helvetica Neue", sans-serif);
  color: var(--jse-tag-color, var(--jse-text-color-inverse, #fff));
  background: var(--jse-tag-background, rgba(0, 0, 0, 0.2));
  border-radius: 2px;
  cursor: pointer;
  display: inline-block;
  padding: 0 4px;
  line-height: normal;
  margin: 1px 0;
}
.jse-tag.svelte-tqwlgz:hover {
  opacity: 0.8;
}
.jse-tag.svelte-tqwlgz:disabled {
  opacity: 0.7;
  cursor: inherit;
}`);var UGA=pA('<button type="button" class="jse-tag svelte-tqwlgz"><!></button>');function ZD(t,e){st(e,!0);var A=ba(()=>e.onclick?n=>{n.preventDefault(),n.stopPropagation(),e.onclick()}:void 0),i=UGA();i.__click=function(){for(var n,o=arguments.length,r=new Array(o),s=0;s<o;s++)r[s]=arguments[s];(n=g(A))===null||n===void 0||n.apply(this,r)},function(n,o){for(var r=arguments.length,s=new Array(r>2?r-2:0),a=2;a<r;a++)s[a-2]=arguments[a];var c,l=n,I=QoA;zC(()=>{I!==(I=o())&&(c&&(Gg(c),c=null),c=$0(()=>I(l,...s)))},J3)}($(i),()=>{var n;return(n=e.children)!==null&&n!==void 0?n:QoA}),Ee(()=>i.disabled=!e.onclick),iA(t,i),at()}H3(["click"]);function KGA(t,e,A){typeof e.value=="string"&&g(A)&&z_(t)&&(t.preventDefault(),t.stopPropagation(),window.open(e.value,"_blank"))}function YGA(t,e){e.readOnly||(t.preventDefault(),e.onSelect(sy(e.path)))}vt(`/* over all fonts, sizes, and colors */
/* "consolas" for Windows, "menlo" for Mac with fallback to "monaco", 'Ubuntu Mono' for Ubuntu */
/* (at Mac this font looks too large at 14px, but 13px is too small for the font on Windows) */
/* main, menu, modal */
/* jsoneditor modal */
/* tooltip in text mode */
/* panels: navigation bar, gutter, search box */
/* navigation-bar */
/* context menu */
/* contents: json key and values */
/* contents: selected or hovered */
/* contents: section of collapsed items in an array */
/* contents: highlighting of search matches */
/* contents: inline tags inside the JSON document */
/* contents: table */
/* controls in modals: inputs, buttons, and \`a\` */
/* messages */
/* svelte-select */
/* color picker */
.jse-value.jse-string.svelte-c0g9qz {
  color: var(--jse-value-color-string, #008000);
}
.jse-value.jse-object.svelte-c0g9qz, .jse-value.jse-array.svelte-c0g9qz {
  min-width: 16px;
  color: var(--jse-delimiter-color, rgba(0, 0, 0, 0.38));
}
.jse-value.jse-number.svelte-c0g9qz {
  color: var(--jse-value-color-number, #ee422e);
}
.jse-value.jse-boolean.svelte-c0g9qz {
  color: var(--jse-value-color-boolean, #ff8c00);
}
.jse-value.jse-null.svelte-c0g9qz {
  color: var(--jse-value-color-null, #004ed0);
}
.jse-value.jse-invalid.svelte-c0g9qz {
  color: var(--jse-text-color, #4d4d4d);
}
.jse-value.jse-url.svelte-c0g9qz {
  color: var(--jse-value-color-url, #008000);
  text-decoration: underline;
}

.jse-value.svelte-c0g9qz {
  display: inline-block;
  min-width: 2em;
  padding: 0 5px;
  box-sizing: border-box;
  outline: none;
  border-radius: 1px;
  vertical-align: top;
  word-break: normal;
  overflow-wrap: anywhere;
  white-space: pre-wrap;
}
.jse-value.jse-table-cell.svelte-c0g9qz {
  overflow-wrap: normal;
  white-space: nowrap;
}
.jse-value.jse-empty.svelte-c0g9qz {
  min-width: 4em;
  outline: 1px dotted var(--jse-tag-background, rgba(0, 0, 0, 0.2));
  -moz-outline-radius: 2px;
}
.jse-value.jse-empty.svelte-c0g9qz::after {
  pointer-events: none;
  color: var(--jse-tag-background, rgba(0, 0, 0, 0.2));
  content: "value";
}`);var JGA=pA('<div role="button" tabindex="-1" data-type="selectable-value"><!> <!></div>');function TGA(t,e){st(e,!0);var A=T0(!0),i=ba(()=>g(A)&&typeof e.value=="string"&&e.value.length>e.truncateTextSize&&(!e.searchResultItems||!e.searchResultItems.some(d=>d.active&&d.end>e.truncateTextSize))),n=ba(()=>g(i)&&typeof e.value=="string"?e.value.substring(0,e.truncateTextSize).trim():e.value),o=ba(()=>yy(e.value));function r(){b(A,!1)}var s=JGA();s.__click=[KGA,e,o],s.__dblclick=[YGA,e];var a=$(s),c=d=>{var B=ba(()=>e.normalization.escapeValue(g(n)));UsA(d,{get text(){return g(B)},get searchResultItems(){return e.searchResultItems}})},l=d=>{var B=_r();Ee(E=>Et(B,E),[()=>vy(e.normalization.escapeValue(g(n)))]),iA(d,B)};MA(a,d=>{e.searchResultItems?d(c):d(l,!1)});var I=gA(a,2),C=d=>{ZD(d,{onclick:r,children:(B,E)=>{var Q=_r();Ee(u=>Et(Q,"Show more (".concat(u??"",")")),[()=>h_(e.value.length)]),iA(B,Q)},$$slots:{default:!0}})};MA(I,d=>{g(i)&&typeof e.value=="string"&&d(C)}),Ee(d=>{xt(s,1,d,"svelte-c0g9qz"),en(s,"title",g(o)?"Ctrl+Click or Ctrl+Enter to open url in new window":void 0)},[()=>T1(SsA(e.value,e.mode,e.parser))]),iA(t,s),at()}H3(["click","dblclick"]);vt(`/* over all fonts, sizes, and colors */
/* "consolas" for Windows, "menlo" for Mac with fallback to "monaco", 'Ubuntu Mono' for Ubuntu */
/* (at Mac this font looks too large at 14px, but 13px is too small for the font on Windows) */
/* main, menu, modal */
/* jsoneditor modal */
/* tooltip in text mode */
/* panels: navigation bar, gutter, search box */
/* navigation-bar */
/* context menu */
/* contents: json key and values */
/* contents: selected or hovered */
/* contents: section of collapsed items in an array */
/* contents: highlighting of search matches */
/* contents: inline tags inside the JSON document */
/* contents: table */
/* controls in modals: inputs, buttons, and \`a\` */
/* messages */
/* svelte-select */
/* color picker */
.jse-tooltip.svelte-14y3y8t {
  font-family: var(--jse-font-family, -apple-system, BlinkMacSystemFont, "Segoe UI", Roboto, Oxygen-Sans, Ubuntu, Cantarell, "Helvetica Neue", sans-serif);
  font-size: var(--jse-font-size, 16px);
  line-height: normal;
  padding: calc(0.5 * var(--jse-padding, 10px)) var(--jse-padding, 10px);
  border-radius: 3px;
  background: var(--jse-context-menu-background, #656565);
  color: var(--jse-context-menu-color, var(--jse-text-color-inverse, #fff));
  white-space: nowrap;
  box-shadow: var(--jse-controls-box-shadow, 0 2px 6px 0 rgba(0, 0, 0, 0.24));
}`);var zGA=pA('<div class="jse-tooltip svelte-14y3y8t"> </div>');function HGA(t,e){var A=k(e,"text",8),i=zGA(),n=$(i);Ee(()=>Et(n,A())),iA(t,i)}function eh(t,e){var A,{text:i,openAbsolutePopup:n,closeAbsolutePopup:o}=e;function r(){A=n(HGA,{text:i},{position:"top",width:10*i.length,offsetTop:3,anchor:t,closeOnOuterClick:!0})}function s(){o(A)}return t.addEventListener("mouseenter",r),t.addEventListener("mouseleave",s),{destroy(){t.removeEventListener("mouseenter",r),t.removeEventListener("mouseleave",s)}}}vt(`/* over all fonts, sizes, and colors */
/* "consolas" for Windows, "menlo" for Mac with fallback to "monaco", 'Ubuntu Mono' for Ubuntu */
/* (at Mac this font looks too large at 14px, but 13px is too small for the font on Windows) */
/* main, menu, modal */
/* jsoneditor modal */
/* tooltip in text mode */
/* panels: navigation bar, gutter, search box */
/* navigation-bar */
/* context menu */
/* contents: json key and values */
/* contents: selected or hovered */
/* contents: section of collapsed items in an array */
/* contents: highlighting of search matches */
/* contents: inline tags inside the JSON document */
/* contents: table */
/* controls in modals: inputs, buttons, and \`a\` */
/* messages */
/* svelte-select */
/* color picker */
.jse-timestamp.svelte-1jla5ec {
  padding: 0;
  margin: 0;
  vertical-align: middle;
  display: inline-flex;
  color: var(--jse-value-color-number, #ee422e);
}`);var OGA=pA('<div class="jse-timestamp svelte-1jla5ec"><!></div>');function PGA(t,e){st(e,!1);var A=X(void 0,!0),i=H1("absolute-popup"),n=k(e,"value",9);fA(()=>W(n()),()=>{b(A,"Time: ".concat(new Date(n()).toString()))}),nn(),Rt(!0);var o=OGA();Si($(o),{data:hW}),bs(o,(r,s)=>eh?.(r,s),()=>Be({text:g(A)},i)),iA(t,o),at()}function jGA(t){var e=[];return!t.isEditing&&J_A(t.value)&&e.push({component:QGA,props:t}),!t.isEditing&&T_A(t.value)&&e.push({component:pGA,props:t}),t.isEditing&&e.push({component:FGA,props:t}),t.isEditing||e.push({component:TGA,props:t}),!t.isEditing&&o_(t.value)&&e.push({component:PGA,props:t}),e}function Dl(t){return t.map((e,A)=>VGA.test(e)?"["+e+"]":/[.[\]]/.test(e)||e===""?'["'+function(i){return i.replace(/"/g,'\\"')}(e)+'"]':(A>0?".":"")+e).join("")}function qGA(t){for(var e=[],A=0;A<t.length;)t[A]==="."&&A++,t[A]==="["?(A++,t[A]==='"'?(A++,e.push(i(o=>o==='"',!0)),n('"')):e.push(i(o=>o==="]")),n("]")):e.push(i(o=>o==="."||o==="["));function i(o){for(var r=arguments.length>1&&arguments[1]!==void 0&&arguments[1],s="";A<t.length&&!o(t[A]);)r&&t[A]==="\\"&&t[A+1]==='"'?(s+='"',A+=2):(s+=t[A],A++);return s}function n(o){if(t[A]!==o)throw new SyntaxError("Invalid JSON path: ".concat(o," expected at position ").concat(A));A++}return e}function L1(t){return{value:t,label:sn(t)?"(item root)":Dl(t)}}var VGA=/^\d+$/,ZGA={},WGA={showWizard:!0,showOriginal:!0},cy=Math.min,RC=Math.max,ly=Math.round,YD=Math.floor,Ng=t=>({x:t,y:t}),XGA={left:"right",right:"left",bottom:"top",top:"bottom"},$GA={start:"end",end:"start"};function srA(t,e,A){return RC(t,cy(e,A))}function ky(t,e){return typeof t=="function"?t(e):t}function LC(t){return t.split("-")[0]}function gy(t){return t.split("-")[1]}function KsA(t){return t==="x"?"y":"x"}function YsA(t){return t==="y"?"height":"width"}function xC(t){return["top","bottom"].includes(LC(t))?"y":"x"}function JsA(t){return KsA(xC(t))}function YN(t){return t.replace(/start|end/g,e=>$GA[e])}function JD(t){return t.replace(/left|right|bottom|top/g,e=>XGA[e])}function AUA(t){return typeof t!="number"?function(e){return Be({top:0,right:0,bottom:0,left:0},e)}(t):{top:t,right:t,bottom:t,left:t}}function Iy(t){var{x:e,y:A,width:i,height:n}=t;return{width:i,height:n,top:A,left:e,right:e+i,bottom:A+n,x:e,y:A}}function arA(t,e,A){var i,{reference:n,floating:o}=t,r=xC(e),s=JsA(e),a=YsA(s),c=LC(e),l=r==="y",I=n.x+n.width/2-o.width/2,C=n.y+n.height/2-o.height/2,d=n[a]/2-o[a]/2;switch(c){case"top":i={x:I,y:n.y-o.height};break;case"bottom":i={x:I,y:n.y+n.height};break;case"right":i={x:n.x+n.width,y:C};break;case"left":i={x:n.x-o.width,y:C};break;default:i={x:n.x,y:n.y}}switch(gy(e)){case"start":i[s]-=d*(A&&l?-1:1);break;case"end":i[s]+=d*(A&&l?-1:1)}return i}var eUA=function(){var t=yt(function*(e,A,i){for(var{placement:n="bottom",strategy:o="absolute",middleware:r=[],platform:s}=i,a=r.filter(Boolean),c=yield s.isRTL==null?void 0:s.isRTL(A),l=yield s.getElementRects({reference:e,floating:A,strategy:o}),{x:I,y:C}=arA(l,n,c),d=n,B={},E=0,Q=0;Q<a.length;Q++){var{name:u,fn:v}=a[Q],{x:L,y:x,data:y,reset:F}=yield v({x:I,y:C,initialPlacement:n,placement:d,strategy:o,middlewareData:B,rects:l,platform:s,elements:{reference:e,floating:A}});I=L??I,C=x??C,B=Be(Be({},B),{},{[u]:Be(Be({},B[u]),y)}),F&&E<=50&&(E++,typeof F=="object"&&(F.placement&&(d=F.placement),F.rects&&(l=F.rects===!0?yield s.getElementRects({reference:e,floating:A,strategy:o}):F.rects),{x:I,y:C}=arA(l,d,c)),Q=-1)}return{x:I,y:C,placement:d,strategy:o,middlewareData:B}});return function(e,A,i){return t.apply(this,arguments)}}();function TsA(t,e){return Q_.apply(this,arguments)}function Q_(){return Q_=yt(function*(t,e){var A;e===void 0&&(e={});var{x:i,y:n,platform:o,rects:r,elements:s,strategy:a}=t,{boundary:c="clippingAncestors",rootBoundary:l="viewport",elementContext:I="floating",altBoundary:C=!1,padding:d=0}=ky(e,t),B=AUA(d),E=s[C?I==="floating"?"reference":"floating":I],Q=Iy(yield o.getClippingRect({element:(A=yield o.isElement==null?void 0:o.isElement(E))==null||A?E:E.contextElement||(yield o.getDocumentElement==null?void 0:o.getDocumentElement(s.floating)),boundary:c,rootBoundary:l,strategy:a})),u=I==="floating"?{x:i,y:n,width:r.floating.width,height:r.floating.height}:r.reference,v=yield o.getOffsetParent==null?void 0:o.getOffsetParent(s.floating),L=(yield o.isElement==null?void 0:o.isElement(v))&&(yield o.getScale==null?void 0:o.getScale(v))||{x:1,y:1},x=Iy(o.convertOffsetParentRelativeRectToViewportRelativeRect?yield o.convertOffsetParentRelativeRectToViewportRelativeRect({elements:s,rect:u,offsetParent:v,strategy:a}):u);return{top:(Q.top-x.top+B.top)/L.y,bottom:(x.bottom-Q.bottom+B.bottom)/L.y,left:(Q.left-x.left+B.left)/L.x,right:(x.right-Q.right+B.right)/L.x}}),Q_.apply(this,arguments)}function u_(){return u_=yt(function*(t,e){var{placement:A,platform:i,elements:n}=t,o=yield i.isRTL==null?void 0:i.isRTL(n.floating),r=LC(A),s=gy(A),a=xC(A)==="y",c=["left","top"].includes(r)?-1:1,l=o&&a?-1:1,I=ky(e,t),{mainAxis:C,crossAxis:d,alignmentAxis:B}=typeof I=="number"?{mainAxis:I,crossAxis:0,alignmentAxis:null}:{mainAxis:I.mainAxis||0,crossAxis:I.crossAxis||0,alignmentAxis:I.alignmentAxis};return s&&typeof B=="number"&&(d=s==="end"?-1*B:B),a?{x:d*l,y:C*c}:{x:C*c,y:d*l}}),u_.apply(this,arguments)}function Sy(){return typeof window<"u"}function th(t){return zsA(t)?(t.nodeName||"").toLowerCase():"#document"}function Ic(t){var e;return(t==null||(e=t.ownerDocument)==null?void 0:e.defaultView)||window}function _g(t){var e;return(e=(zsA(t)?t.ownerDocument:t.document)||window.document)==null?void 0:e.documentElement}function zsA(t){return!!Sy()&&(t instanceof Node||t instanceof Ic(t).Node)}function Sl(t){return!!Sy()&&(t instanceof Element||t instanceof Ic(t).Element)}function Yg(t){return!!Sy()&&(t instanceof HTMLElement||t instanceof Ic(t).HTMLElement)}function crA(t){return!(!Sy()||typeof ShadowRoot>"u")&&(t instanceof ShadowRoot||t instanceof Ic(t).ShadowRoot)}function _3(t){var{overflow:e,overflowX:A,overflowY:i,display:n}=Rl(t);return/auto|scroll|overlay|hidden|clip/.test(e+i+A)&&!["inline","contents"].includes(n)}function tUA(t){return["table","td","th"].includes(th(t))}function Cy(t){return[":popover-open",":modal"].some(e=>{try{return t.matches(e)}catch{return!1}})}function f_(t){var e=AG(),A=Sl(t)?Rl(t):t;return["transform","translate","scale","rotate","perspective"].some(i=>!!A[i]&&A[i]!=="none")||!!A.containerType&&A.containerType!=="normal"||!e&&!!A.backdropFilter&&A.backdropFilter!=="none"||!e&&!!A.filter&&A.filter!=="none"||["transform","translate","scale","rotate","perspective","filter"].some(i=>(A.willChange||"").includes(i))||["paint","layout","strict","content"].some(i=>(A.contain||"").includes(i))}function AG(){return!(typeof CSS>"u"||!CSS.supports)&&CSS.supports("-webkit-backdrop-filter","none")}function jE(t){return["html","body","#document"].includes(th(t))}function Rl(t){return Ic(t).getComputedStyle(t)}function Ry(t){return Sl(t)?{scrollLeft:t.scrollLeft,scrollTop:t.scrollTop}:{scrollLeft:t.scrollX,scrollTop:t.scrollY}}function N1(t){if(th(t)==="html")return t;var e=t.assignedSlot||t.parentNode||crA(t)&&t.host||_g(t);return crA(e)?e.host:e}function HsA(t){var e=N1(t);return jE(e)?t.ownerDocument?t.ownerDocument.body:t.body:Yg(e)&&_3(e)?e:HsA(e)}function G3(t,e,A){var i;e===void 0&&(e=[]),A===void 0&&(A=!0);var n=HsA(t),o=n===((i=t.ownerDocument)==null?void 0:i.body),r=Ic(n);if(o){var s=m_(r);return e.concat(r,r.visualViewport||[],_3(n)?n:[],s&&A?G3(s):[])}return e.concat(n,G3(n,[],A))}function m_(t){return t.parent&&Object.getPrototypeOf(t.parent)?t.frameElement:null}function OsA(t){var e=Rl(t),A=parseFloat(e.width)||0,i=parseFloat(e.height)||0,n=Yg(t),o=n?t.offsetWidth:A,r=n?t.offsetHeight:i,s=ly(A)!==o||ly(i)!==r;return s&&(A=o,i=r),{width:A,height:i,$:s}}function eG(t){return Sl(t)?t:t.contextElement}function qE(t){var e=eG(t);if(!Yg(e))return Ng(1);var A=e.getBoundingClientRect(),{width:i,height:n,$:o}=OsA(e),r=(o?ly(A.width):A.width)/i,s=(o?ly(A.height):A.height)/n;return r&&Number.isFinite(r)||(r=1),s&&Number.isFinite(s)||(s=1),{x:r,y:s}}var iUA=Ng(0);function PsA(t){var e=Ic(t);return AG()&&e.visualViewport?{x:e.visualViewport.offsetLeft,y:e.visualViewport.offsetTop}:iUA}function JC(t,e,A,i){e===void 0&&(e=!1),A===void 0&&(A=!1);var n=t.getBoundingClientRect(),o=eG(t),r=Ng(1);e&&(i?Sl(i)&&(r=qE(i)):r=qE(t));var s=function(y,F,U){return F===void 0&&(F=!1),!(!U||F&&U!==Ic(y))&&F}(o,A,i)?PsA(o):Ng(0),a=(n.left+s.x)/r.x,c=(n.top+s.y)/r.y,l=n.width/r.x,I=n.height/r.y;if(o)for(var C=Ic(o),d=i&&Sl(i)?Ic(i):i,B=C,E=m_(B);E&&i&&d!==B;){var Q=qE(E),u=E.getBoundingClientRect(),v=Rl(E),L=u.left+(E.clientLeft+parseFloat(v.paddingLeft))*Q.x,x=u.top+(E.clientTop+parseFloat(v.paddingTop))*Q.y;a*=Q.x,c*=Q.y,l*=Q.x,I*=Q.y,a+=L,c+=x,E=m_(B=Ic(E))}return Iy({width:l,height:I,x:a,y:c})}function tG(t,e){var A=Ry(t).scrollLeft;return e?e.left+A:JC(_g(t)).left+A}function jsA(t,e,A){A===void 0&&(A=!1);var i=t.getBoundingClientRect();return{x:i.left+e.scrollLeft-(A?0:tG(t,i)),y:i.top+e.scrollTop}}function lrA(t,e,A){var i;if(e==="viewport")i=function(o,r){var s=Ic(o),a=_g(o),c=s.visualViewport,l=a.clientWidth,I=a.clientHeight,C=0,d=0;if(c){l=c.width,I=c.height;var B=AG();(!B||B&&r==="fixed")&&(C=c.offsetLeft,d=c.offsetTop)}return{width:l,height:I,x:C,y:d}}(t,A);else if(e==="document")i=function(o){var r=_g(o),s=Ry(o),a=o.ownerDocument.body,c=RC(r.scrollWidth,r.clientWidth,a.scrollWidth,a.clientWidth),l=RC(r.scrollHeight,r.clientHeight,a.scrollHeight,a.clientHeight),I=-s.scrollLeft+tG(o),C=-s.scrollTop;return Rl(a).direction==="rtl"&&(I+=RC(r.clientWidth,a.clientWidth)-c),{width:c,height:l,x:I,y:C}}(_g(t));else if(Sl(e))i=function(o,r){var s=JC(o,!0,r==="fixed"),a=s.top+o.clientTop,c=s.left+o.clientLeft,l=Yg(o)?qE(o):Ng(1);return{width:o.clientWidth*l.x,height:o.clientHeight*l.y,x:c*l.x,y:a*l.y}}(e,A);else{var n=PsA(t);i={x:e.x-n.x,y:e.y-n.y,width:e.width,height:e.height}}return Iy(i)}function qsA(t,e){var A=N1(t);return!(A===e||!Sl(A)||jE(A))&&(Rl(A).position==="fixed"||qsA(A,e))}function nUA(t,e,A){var i=Yg(e),n=_g(e),o=A==="fixed",r=JC(t,!0,o,e),s={scrollLeft:0,scrollTop:0},a=Ng(0);function c(){a.x=tG(n)}if(i||!i&&!o)if((th(e)!=="body"||_3(n))&&(s=Ry(e)),i){var l=JC(e,!0,o,e);a.x=l.x+e.clientLeft,a.y=l.y+e.clientTop}else n&&c();o&&!i&&n&&c();var I=!n||i||o?Ng(0):jsA(n,s);return{x:r.left+s.scrollLeft-a.x-I.x,y:r.top+s.scrollTop-a.y-I.y,width:r.width,height:r.height}}function JN(t){return Rl(t).position==="static"}function grA(t,e){if(!Yg(t)||Rl(t).position==="fixed")return null;if(e)return e(t);var A=t.offsetParent;return _g(t)===A&&(A=A.ownerDocument.body),A}function IrA(t,e){var A=Ic(t);if(Cy(t))return A;if(!Yg(t)){for(var i=N1(t);i&&!jE(i);){if(Sl(i)&&!JN(i))return i;i=N1(i)}return A}for(var n=grA(t,e);n&&tUA(n)&&JN(n);)n=grA(n,e);return n&&jE(n)&&JN(n)&&!f_(n)?A:n||function(o){for(var r=N1(o);Yg(r)&&!jE(r);){if(f_(r))return r;if(Cy(r))return null;r=N1(r)}return null}(t)||A}var oUA={convertOffsetParentRelativeRectToViewportRelativeRect:function(t){var{elements:e,rect:A,offsetParent:i,strategy:n}=t,o=n==="fixed",r=_g(i),s=!!e&&Cy(e.floating);if(i===r||s&&o)return A;var a={scrollLeft:0,scrollTop:0},c=Ng(1),l=Ng(0),I=Yg(i);if((I||!I&&!o)&&((th(i)!=="body"||_3(r))&&(a=Ry(i)),Yg(i))){var C=JC(i);c=qE(i),l.x=C.x+i.clientLeft,l.y=C.y+i.clientTop}var d=!r||I||o?Ng(0):jsA(r,a,!0);return{width:A.width*c.x,height:A.height*c.y,x:A.x*c.x-a.scrollLeft*c.x+l.x+d.x,y:A.y*c.y-a.scrollTop*c.y+l.y+d.y}},getDocumentElement:_g,getClippingRect:function(t){var{element:e,boundary:A,rootBoundary:i,strategy:n}=t,o=[...A==="clippingAncestors"?Cy(e)?[]:function(a,c){var l=c.get(a);if(l)return l;for(var I=G3(a,[],!1).filter(u=>Sl(u)&&th(u)!=="body"),C=null,d=Rl(a).position==="fixed",B=d?N1(a):a;Sl(B)&&!jE(B);){var E=Rl(B),Q=f_(B);Q||E.position!=="fixed"||(C=null),(d?!Q&&!C:!Q&&E.position==="static"&&C&&["absolute","fixed"].includes(C.position)||_3(B)&&!Q&&qsA(a,B))?I=I.filter(u=>u!==B):C=E,B=N1(B)}return c.set(a,I),I}(e,this._c):[].concat(A),i],r=o[0],s=o.reduce((a,c)=>{var l=lrA(e,c,n);return a.top=RC(l.top,a.top),a.right=cy(l.right,a.right),a.bottom=cy(l.bottom,a.bottom),a.left=RC(l.left,a.left),a},lrA(e,r,n));return{width:s.right-s.left,height:s.bottom-s.top,x:s.left,y:s.top}},getOffsetParent:IrA,getElementRects:function(){var t=yt(function*(e){var A=this.getOffsetParent||IrA,i=this.getDimensions,n=yield i(e.floating);return{reference:nUA(e.reference,yield A(e.floating),e.strategy),floating:{x:0,y:0,width:n.width,height:n.height}}});return function(e){return t.apply(this,arguments)}}(),getClientRects:function(t){return Array.from(t.getClientRects())},getDimensions:function(t){var{width:e,height:A}=OsA(t);return{width:e,height:A}},getScale:qE,isElement:Sl,isRTL:function(t){return Rl(t).direction==="rtl"}};function CrA(t,e){return t.x===e.x&&t.y===e.y&&t.width===e.width&&t.height===e.height}function rUA(t,e,A,i){i===void 0&&(i={});var{ancestorScroll:n=!0,ancestorResize:o=!0,elementResize:r=typeof ResizeObserver=="function",layoutShift:s=typeof IntersectionObserver=="function",animationFrame:a=!1}=i,c=eG(t),l=n||o?[...c?G3(c):[],...G3(e)]:[];l.forEach(Q=>{n&&Q.addEventListener("scroll",A,{passive:!0}),o&&Q.addEventListener("resize",A)});var I,C=c&&s?function(Q,u){var v,L=null,x=_g(Q);function y(){var F;clearTimeout(v),(F=L)==null||F.disconnect(),L=null}return function F(U,T){U===void 0&&(U=!1),T===void 0&&(T=1),y();var N=Q.getBoundingClientRect(),{left:K,top:H,width:j,height:IA}=N;if(U||u(),j&&IA){var lA={rootMargin:-YD(H)+"px "+-YD(x.clientWidth-(K+j))+"px "+-YD(x.clientHeight-(H+IA))+"px "+-YD(K)+"px",threshold:RC(0,cy(1,T))||1},uA=!0;try{L=new IntersectionObserver(p,Be(Be({},lA),{},{root:x.ownerDocument}))}catch{L=new IntersectionObserver(p,lA)}L.observe(Q)}function p(V){var cA=V[0].intersectionRatio;if(cA!==T){if(!uA)return F();cA?F(!1,cA):v=setTimeout(()=>{F(!1,1e-7)},1e3)}cA!==1||CrA(N,Q.getBoundingClientRect())||F(),uA=!1}}(!0),y}(c,A):null,d=-1,B=null;r&&(B=new ResizeObserver(Q=>{var[u]=Q;u&&u.target===c&&B&&(B.unobserve(e),cancelAnimationFrame(d),d=requestAnimationFrame(()=>{var v;(v=B)==null||v.observe(e)})),A()}),c&&!a&&B.observe(c),B.observe(e));var E=a?JC(t):null;return a&&function Q(){var u=JC(t);E&&!CrA(E,u)&&A(),E=u,I=requestAnimationFrame(Q)}(),A(),()=>{var Q;l.forEach(u=>{n&&u.removeEventListener("scroll",A),o&&u.removeEventListener("resize",A)}),C?.(),(Q=B)==null||Q.disconnect(),B=null,a&&cancelAnimationFrame(I)}}var sUA=function(t){return t===void 0&&(t=0),{name:"offset",options:t,fn:e=>yt(function*(){var A,i,{x:n,y:o,placement:r,middlewareData:s}=e,a=yield function(c,l){return u_.apply(this,arguments)}(e,t);return r===((A=s.offset)==null?void 0:A.placement)&&(i=s.arrow)!=null&&i.alignmentOffset?{}:{x:n+a.x,y:o+a.y,data:Be(Be({},a),{},{placement:r})}})()}},aUA=function(t){return t===void 0&&(t={}),{name:"shift",options:t,fn:e=>yt(function*(){var{x:A,y:i,placement:n}=e,o=ky(t,e),{mainAxis:r=!0,crossAxis:s=!1,limiter:a={fn:L=>{var{x,y}=L;return{x,y}}}}=o,c=frA(o,r_A),l={x:A,y:i},I=yield TsA(e,c),C=xC(LC(n)),d=KsA(C),B=l[d],E=l[C];if(r){var Q=d==="y"?"bottom":"right";B=srA(B+I[d==="y"?"top":"left"],B,B-I[Q])}if(s){var u=C==="y"?"bottom":"right";E=srA(E+I[C==="y"?"top":"left"],E,E-I[u])}var v=a.fn(Be(Be({},e),{},{[d]:B,[C]:E}));return Be(Be({},v),{},{data:{x:v.x-A,y:v.y-i,enabled:{[d]:r,[C]:s}}})})()}},cUA=function(t){return t===void 0&&(t={}),{name:"flip",options:t,fn:e=>yt(function*(){var A,i,{placement:n,middlewareData:o,rects:r,initialPlacement:s,platform:a,elements:c}=e,l=ky(t,e),{mainAxis:I=!0,crossAxis:C=!0,fallbackPlacements:d,fallbackStrategy:B="bestFit",fallbackAxisSideDirection:E="none",flipAlignment:Q=!0}=l,u=frA(l,o_A);if((A=o.arrow)!=null&&A.alignmentOffset)return{};var v=LC(n),L=xC(s),x=LC(s)===s,y=yield a.isRTL==null?void 0:a.isRTL(c.floating),F=d||(x||!Q?[JD(s)]:function(EA){var sA=JD(EA);return[YN(EA),sA,YN(sA)]}(s)),U=E!=="none";!d&&U&&F.push(...function(EA,sA,TA,Ke){var Re=gy(EA),hA=function(eA,RA,oA){var ne=["left","right"],h=["right","left"];switch(eA){case"top":case"bottom":return oA?RA?h:ne:RA?ne:h;case"left":case"right":return RA?["top","bottom"]:["bottom","top"];default:return[]}}(LC(EA),TA==="start",Ke);return Re&&(hA=hA.map(eA=>eA+"-"+Re),sA&&(hA=hA.concat(hA.map(YN)))),hA}(s,Q,E,y));var T=[s,...F],N=yield TsA(e,u),K=[],H=((i=o.flip)==null?void 0:i.overflows)||[];if(I&&K.push(N[v]),C){var j=function(EA,sA,TA){TA===void 0&&(TA=!1);var Ke=gy(EA),Re=JsA(EA),hA=YsA(Re),eA=Re==="x"?Ke===(TA?"end":"start")?"right":"left":Ke==="start"?"bottom":"top";return sA.reference[hA]>sA.floating[hA]&&(eA=JD(eA)),[eA,JD(eA)]}(n,r,y);K.push(N[j[0]],N[j[1]])}if(H=[...H,{placement:n,overflows:K}],!K.every(EA=>EA<=0)){var IA,lA,uA=(((IA=o.flip)==null?void 0:IA.index)||0)+1,p=T[uA];if(p){var V,cA=C==="alignment"&&L!==xC(p),aA=((V=H[0])==null?void 0:V.overflows[0])>0;if(!cA||aA)return{data:{index:uA,overflows:H},reset:{placement:p}}}var jA=(lA=H.filter(EA=>EA.overflows[0]<=0).sort((EA,sA)=>EA.overflows[1]-sA.overflows[1])[0])==null?void 0:lA.placement;if(!jA)switch(B){case"bestFit":var VA,ce=(VA=H.filter(EA=>{if(U){var sA=xC(EA.placement);return sA===L||sA==="y"}return!0}).map(EA=>[EA.placement,EA.overflows.filter(sA=>sA>0).reduce((sA,TA)=>sA+TA,0)]).sort((EA,sA)=>EA[1]-sA[1])[0])==null?void 0:VA[0];ce&&(jA=ce);break;case"initialPlacement":jA=s}if(n!==jA)return{reset:{placement:jA}}}return{}})()}};function lUA(t){var e,A,i={autoUpdate:!0},n=t,o=a=>Be(Be(Be({},i),t||{}),a||{}),r=a=>{e&&A&&(n=o(a),((c,l,I)=>{var C=new Map,d=Be({platform:oUA},I),B=Be(Be({},d.platform),{},{_c:C});return eUA(c,l,Be(Be({},d),{},{platform:B}))})(e,A,n).then(c=>{var l;Object.assign(A.style,{position:c.strategy,left:"".concat(c.x,"px"),top:"".concat(c.y,"px")}),!((l=n)===null||l===void 0)&&l.onComputed&&n.onComputed(c)}))},s=a=>{Tc(a.subscribe(c=>{e===void 0?(e=c,r()):(Object.assign(e,c),r())}))};return[a=>{if("subscribe"in a)return s(a),{};e=a,r()},(a,c)=>{var l;A=a,n=o(c),setTimeout(()=>r(c),0),r(c);var I=()=>{l&&(l(),l=void 0)},C=function(){var{autoUpdate:d}=arguments.length>0&&arguments[0]!==void 0?arguments[0]:n||{};I(),d!==!1&&function(){return qrA.apply(this,arguments)}().then(()=>rUA(e,A,()=>r(n),d===!0?{}:d))};return l=C(),{update(d){r(d),l=C(d)},destroy(){I()}}},r]}function gUA(t){var{loadOptions:e,filterText:A,items:i,multiple:n,value:o,itemId:r,groupBy:s,filterSelectedItems:a,itemFilter:c,convertStringItemsToObjects:l,filterGroupedItems:I,label:C}=t;if(i&&e)return i;if(!i)return[];i&&i.length>0&&typeof i[0]!="object"&&(i=l(i));var d=i.filter(B=>{var E=c(B[C],A,B);return E&&n&&o!=null&&o.length&&(E=!o.some(Q=>!!a&&Q[r]===B[r])),E});return s&&(d=I(d)),d}function IUA(t){return VsA.apply(this,arguments)}function VsA(){return(VsA=yt(function*(t){var{dispatch:e,loadOptions:A,convertStringItemsToObjects:i,filterText:n}=t,o=yield A(n).catch(r=>{console.warn("svelte-select loadOptions error :>> ",r),e("error",{type:"loadOptions",details:r})});if(o&&!o.cancelled)return o?(o&&o.length>0&&typeof o[0]!="object"&&(o=i(o)),e("loaded",{items:o})):o=[],{filteredItems:o,loading:!1,focused:!0,listOpen:!0}})).apply(this,arguments)}vt(`
  svg.svelte-qbd276 {
      width: var(--chevron-icon-width, 20px);
      height: var(--chevron-icon-width, 20px);
      color: var(--chevron-icon-colour, currentColor);
  }
`);var CUA=O1(`<svg width="100%" height="100%" viewBox="0 0 20 20" focusable="false" aria-hidden="true" class="svelte-qbd276"><path fill="currentColor" d="M4.516 7.548c0.436-0.446 1.043-0.481 1.576 0l3.908 3.747
          3.908-3.747c0.533-0.481 1.141-0.446 1.574 0 0.436 0.445 0.408 1.197 0
          1.615-0.406 0.418-4.695 4.502-4.695 4.502-0.217 0.223-0.502
          0.335-0.787 0.335s-0.57-0.112-0.789-0.335c0
          0-4.287-4.084-4.695-4.502s-0.436-1.17 0-1.615z"></path></svg>`);vt(`
    svg.svelte-whdbu1 {
        width: var(--clear-icon-width, 20px);
        height: var(--clear-icon-width, 20px);
        color: var(--clear-icon-color, currentColor);
    }
`);var dUA=O1(`<svg width="100%" height="100%" viewBox="-2 -2 50 50" focusable="false" aria-hidden="true" role="presentation" class="svelte-whdbu1"><path fill="currentColor" d="M34.923,37.251L24,26.328L13.077,37.251L9.436,33.61l10.923-10.923L9.436,11.765l3.641-3.641L24,19.047L34.923,8.124
    l3.641,3.641L27.641,22.688L38.564,33.61L34.923,37.251z"></path></svg>`);function TN(t){iA(t,dUA())}vt(`
    .loading.svelte-1p3nqvd {
        width: var(--spinner-width, 20px);
        height: var(--spinner-height, 20px);
        color: var(--spinner-color, var(--icons-color));
        animation: svelte-1p3nqvd-rotate 0.75s linear infinite;
        transform-origin: center center;
        transform: none;
    }

    .circle_path.svelte-1p3nqvd {
        stroke-dasharray: 90;
        stroke-linecap: round;
    }

    @keyframes svelte-1p3nqvd-rotate {
        100% {
            transform: rotate(360deg);
        }
    }
`);var BUA=O1('<svg class="loading svelte-1p3nqvd" viewBox="25 25 50 50"><circle class="circle_path svelte-1p3nqvd" cx="50" cy="50" r="20" fill="none" stroke="currentColor" stroke-width="5" stroke-miterlimit="10"></circle></svg>');vt(`
    .svelte-select.svelte-82qwg8 {
        /* deprecating camelCase custom props in favour of kebab-case for v5 */
        --borderRadius: var(--border-radius);
        --clearSelectColor: var(--clear-select-color);
        --clearSelectWidth: var(--clear-select-width);
        --disabledBackground: var(--disabled-background);
        --disabledBorderColor: var(--disabled-border-color);
        --disabledColor: var(--disabled-color);
        --disabledPlaceholderColor: var(--disabled-placeholder-color);
        --disabledPlaceholderOpacity: var(--disabled-placeholder-opacity);
        --errorBackground: var(--error-background);
        --errorBorder: var(--error-border);
        --groupItemPaddingLeft: var(--group-item-padding-left);
        --groupTitleColor: var(--group-title-color);
        --groupTitleFontSize: var(--group-title-font-size);
        --groupTitleFontWeight: var(--group-title-font-weight);
        --groupTitlePadding: var(--group-title-padding);
        --groupTitleTextTransform: var(--group-title-text-transform);
        --groupTitleBorderColor: var(--group-title-border-color);
        --groupTitleBorderWidth: var(--group-title-border-width);
        --groupTitleBorderStyle: var(--group-title-border-style);
        --indicatorColor: var(--chevron-color);
        --indicatorHeight: var(--chevron-height);
        --indicatorWidth: var(--chevron-width);
        --inputColor: var(--input-color);
        --inputLeft: var(--input-left);
        --inputLetterSpacing: var(--input-letter-spacing);
        --inputMargin: var(--input-margin);
        --inputPadding: var(--input-padding);
        --itemActiveBackground: var(--item-active-background);
        --itemColor: var(--item-color);
        --itemFirstBorderRadius: var(--item-first-border-radius);
        --itemHoverBG: var(--item-hover-bg);
        --itemHoverColor: var(--item-hover-color);
        --itemIsActiveBG: var(--item-is-active-bg);
        --itemIsActiveColor: var(--item-is-active-color);
        --itemIsNotSelectableColor: var(--item-is-not-selectable-color);
        --itemPadding: var(--item-padding);
        --listBackground: var(--list-background);
        --listBorder: var(--list-border);
        --listBorderRadius: var(--list-border-radius);
        --listEmptyColor: var(--list-empty-color);
        --listEmptyPadding: var(--list-empty-padding);
        --listEmptyTextAlign: var(--list-empty-text-align);
        --listMaxHeight: var(--list-max-height);
        --listPosition: var(--list-position);
        --listShadow: var(--list-shadow);
        --listZIndex: var(--list-z-index);
        --multiItemBG: var(--multi-item-bg);
        --multiItemBorderRadius: var(--multi-item-border-radius);
        --multiItemDisabledHoverBg: var(--multi-item-disabled-hover-bg);
        --multiItemDisabledHoverColor: var(--multi-item-disabled-hover-color);
        --multiItemHeight: var(--multi-item-height);
        --multiItemMargin: var(--multi-item-margin);
        --multiItemPadding: var(--multi-item-padding);
        --multiSelectInputMargin: var(--multi-select-input-margin);
        --multiSelectInputPadding: var(--multi-select-input-padding);
        --multiSelectPadding: var(--multi-select-padding);
        --placeholderColor: var(--placeholder-color);
        --placeholderOpacity: var(--placeholder-opacity);
        --selectedItemPadding: var(--selected-item-padding);
        --spinnerColor: var(--spinner-color);
        --spinnerHeight: var(--spinner-height);
        --spinnerWidth: var(--spinner-width);

        --internal-padding: 0 0 0 16px;

        border: var(--border, 1px solid #d8dbdf);
        border-radius: var(--border-radius, 6px);
        min-height: var(--height, 42px);
        position: relative;
        display: flex;
        align-items: stretch;
        padding: var(--padding, var(--internal-padding));
        background: var(--background, #fff);
        margin: var(--margin, 0);
        width: var(--width, 100%);
        font-size: var(--font-size, 16px);
        max-height: var(--max-height);
    }

    .svelte-82qwg8 {
        box-sizing: var(--box-sizing, border-box);
    }

    .svelte-select.svelte-82qwg8:hover {
        border: var(--border-hover, 1px solid #b2b8bf);
    }

    .value-container.svelte-82qwg8 {
        display: flex;
        flex: 1 1 0%;
        flex-wrap: wrap;
        align-items: center;
        gap: 5px 10px;
        padding: var(--value-container-padding, 5px 0);
        position: relative;
        overflow: var(--value-container-overflow, hidden);
        align-self: stretch;
    }

    .prepend.svelte-82qwg8,
    .indicators.svelte-82qwg8 {
        display: flex;
        flex-shrink: 0;
        align-items: center;
    }

    .indicators.svelte-82qwg8 {
        position: var(--indicators-position);
        top: var(--indicators-top);
        right: var(--indicators-right);
        bottom: var(--indicators-bottom);
    }

    input.svelte-82qwg8 {
        position: absolute;
        cursor: default;
        border: none;
        color: var(--input-color, var(--item-color));
        padding: var(--input-padding, 0);
        letter-spacing: var(--input-letter-spacing, inherit);
        margin: var(--input-margin, 0);
        min-width: 10px;
        top: 0;
        right: 0;
        bottom: 0;
        left: 0;
        background: transparent;
        font-size: var(--font-size, 16px);
    }

    .svelte-82qwg8:not(.multi) > .value-container:where(.svelte-82qwg8) > input:where(.svelte-82qwg8) {
        width: 100%;
        height: 100%;
    }

    input.svelte-82qwg8::placeholder {
        color: var(--placeholder-color, #78848f);
        opacity: var(--placeholder-opacity, 1);
    }

    input.svelte-82qwg8:focus {
        outline: none;
    }

    .svelte-select.focused.svelte-82qwg8 {
        border: var(--border-focused, 1px solid #006fe8);
        border-radius: var(--border-radius-focused, var(--border-radius, 6px));
    }

    .disabled.svelte-82qwg8 {
        background: var(--disabled-background, #ebedef);
        border-color: var(--disabled-border-color, #ebedef);
        color: var(--disabled-color, #c1c6cc);
    }

    .disabled.svelte-82qwg8 input:where(.svelte-82qwg8)::placeholder {
        color: var(--disabled-placeholder-color, #c1c6cc);
        opacity: var(--disabled-placeholder-opacity, 1);
    }

    .selected-item.svelte-82qwg8 {
        position: relative;
        overflow: var(--selected-item-overflow, hidden);
        padding: var(--selected-item-padding, 0 20px 0 0);
        text-overflow: ellipsis;
        white-space: nowrap;
        color: var(--selected-item-color, inherit);
        font-size: var(--font-size, 16px);
    }

    .multi.svelte-82qwg8 .selected-item:where(.svelte-82qwg8) {
        position: absolute;
        line-height: var(--height, 42px);
        height: var(--height, 42px);
    }

    .selected-item.svelte-82qwg8:focus {
        outline: none;
    }

    .hide-selected-item.svelte-82qwg8 {
        opacity: 0;
    }

    .icon.svelte-82qwg8 {
        display: flex;
        align-items: center;
        justify-content: center;
    }

    .clear-select.svelte-82qwg8 {
        all: unset;
        display: flex;
        align-items: center;
        justify-content: center;
        width: var(--clear-select-width, 40px);
        height: var(--clear-select-height, 100%);
        color: var(--clear-select-color, var(--icons-color));
        margin: var(--clear-select-margin, 0);
        pointer-events: all;
        flex-shrink: 0;
    }

    .clear-select.svelte-82qwg8:focus {
        outline: var(--clear-select-focus-outline, 1px solid #006fe8);
    }

    .loading.svelte-82qwg8 {
        width: var(--loading-width, 40px);
        height: var(--loading-height);
        color: var(--loading-color, var(--icons-color));
        margin: var(--loading--margin, 0);
        flex-shrink: 0;
    }

    .chevron.svelte-82qwg8 {
        width: var(--chevron-width, 40px);
        height: var(--chevron-height, 40px);
        background: var(--chevron-background, transparent);
        pointer-events: var(--chevron-pointer-events, none);
        color: var(--chevron-color, var(--icons-color));
        border: var(--chevron-border, 0 0 0 1px solid #d8dbdf);
        flex-shrink: 0;
    }

    .multi.svelte-82qwg8 {
        padding: var(--multi-select-padding, var(--internal-padding));
    }

    .multi.svelte-82qwg8 input:where(.svelte-82qwg8) {
        padding: var(--multi-select-input-padding, 0);
        position: relative;
        margin: var(--multi-select-input-margin, 5px 0);
        flex: 1 1 40px;
    }

    .svelte-select.error.svelte-82qwg8 {
        border: var(--error-border, 1px solid #ff2d55);
        background: var(--error-background, #fff);
    }

    .a11y-text.svelte-82qwg8 {
        z-index: 9999;
        border: 0px;
        clip: rect(1px, 1px, 1px, 1px);
        height: 1px;
        width: 1px;
        position: absolute;
        overflow: hidden;
        padding: 0px;
        white-space: nowrap;
    }

    .multi-item.svelte-82qwg8 {
        background: var(--multi-item-bg, #ebedef);
        margin: var(--multi-item-margin, 0);
        outline: var(--multi-item-outline, 1px solid #ddd);
        border-radius: var(--multi-item-border-radius, 4px);
        height: var(--multi-item-height, 25px);
        line-height: var(--multi-item-height, 25px);
        display: flex;
        cursor: default;
        padding: var(--multi-item-padding, 0 5px);
        overflow: hidden;
        gap: var(--multi-item-gap, 4px);
        outline-offset: -1px;
        max-width: var(--multi-max-width, none);
        color: var(--multi-item-color, var(--item-color));
    }

    .multi-item.disabled.svelte-82qwg8:hover {
        background: var(--multi-item-disabled-hover-bg, #ebedef);
        color: var(--multi-item-disabled-hover-color, #c1c6cc);
    }

    .multi-item-text.svelte-82qwg8 {
        overflow: hidden;
        text-overflow: ellipsis;
        white-space: nowrap;
    }

    .multi-item-clear.svelte-82qwg8 {
        display: flex;
        align-items: center;
        justify-content: center;
        --clear-icon-color: var(--multi-item-clear-icon-color, #000);
    }

    .multi-item.active.svelte-82qwg8 {
        outline: var(--multi-item-active-outline, 1px solid #006fe8);
    }

    .svelte-select-list.svelte-82qwg8 {
        box-shadow: var(--list-shadow, 0 2px 3px 0 rgba(44, 62, 80, 0.24));
        border-radius: var(--list-border-radius, 4px);
        max-height: var(--list-max-height, 252px);
        overflow-y: auto;
        background: var(--list-background, #fff);
        position: var(--list-position, absolute);
        z-index: var(--list-z-index, 2);
        border: var(--list-border);
    }

    .prefloat.svelte-82qwg8 {
        opacity: 0;
        pointer-events: none;
    }

    .list-group-title.svelte-82qwg8 {
        color: var(--group-title-color, #8f8f8f);
        cursor: default;
        font-size: var(--group-title-font-size, 16px);
        font-weight: var(--group-title-font-weight, 600);
        height: var(--height, 42px);
        line-height: var(--height, 42px);
        padding: var(--group-title-padding, 0 20px);
        text-overflow: ellipsis;
        overflow-x: hidden;
        white-space: nowrap;
        text-transform: var(--group-title-text-transform, uppercase);
        border-width: var(--group-title-border-width, medium);
        border-style: var(--group-title-border-style, none);
        border-color: var(--group-title-border-color, color);
    }

    .empty.svelte-82qwg8 {
        text-align: var(--list-empty-text-align, center);
        padding: var(--list-empty-padding, 20px 0);
        color: var(--list-empty-color, #78848f);
    }

    .item.svelte-82qwg8 {
        cursor: default;
        height: var(--item-height, var(--height, 42px));
        line-height: var(--item-line-height, var(--height, 42px));
        padding: var(--item-padding, 0 20px);
        color: var(--item-color, inherit);
        text-overflow: ellipsis;
        overflow: hidden;
        white-space: nowrap;
        transition: var(--item-transition, all 0.2s);
        align-items: center;
        width: 100%;
    }

    .item.group-item.svelte-82qwg8 {
        padding-left: var(--group-item-padding-left, 40px);
    }

    .item.svelte-82qwg8:active {
        background: var(--item-active-background, #b9daff);
    }

    .item.active.svelte-82qwg8 {
        background: var(--item-is-active-bg, #007aff);
        color: var(--item-is-active-color, #fff);
    }

    .item.first.svelte-82qwg8 {
        border-radius: var(--item-first-border-radius, 4px 4px 0 0);
    }

    .item.hover.svelte-82qwg8:not(.active) {
        background: var(--item-hover-bg, #e7f2ff);
        color: var(--item-hover-color, inherit);
    }

    .item.not-selectable.svelte-82qwg8,
    .item.hover.item.not-selectable.svelte-82qwg8,
    .item.active.item.not-selectable.svelte-82qwg8,
    .item.not-selectable.svelte-82qwg8:active {
        color: var(--item-is-not-selectable-color, #999);
        background: transparent;
    }

    .required.svelte-82qwg8 {
        opacity: 0;
        z-index: -1;
        position: absolute;
        top: 0;
        left: 0;
        bottom: 0;
        right: 0;
    }
`);var EUA=pA('<div class="list-item svelte-82qwg8" tabindex="-1" role="none"><div><!></div></div>'),hUA=pA('<div class="empty svelte-82qwg8">No options</div>'),QUA=pA('<div role="none"><!> <!> <!></div>'),uUA=pA('<span id="aria-selection" class="svelte-82qwg8"> </span> <span id="aria-context" class="svelte-82qwg8"> </span>',1),fUA=pA('<div class="multi-item-clear svelte-82qwg8"><!></div>'),mUA=pA('<div role="none"><span class="multi-item-text svelte-82qwg8"><!></span> <!></div>'),pUA=pA("<div><!></div>"),wUA=pA('<div class="icon loading svelte-82qwg8" aria-hidden="true"><!></div>'),DUA=pA('<button type="button" class="icon clear-select svelte-82qwg8"><!></button>'),yUA=pA('<div class="icon chevron svelte-82qwg8" aria-hidden="true"><!></div>'),vUA=pA('<input type="hidden" class="svelte-82qwg8"/>'),bUA=pA('<select class="required svelte-82qwg8" required tabindex="-1" aria-hidden="true"></select>'),MUA=pA('<div role="none"><!> <span aria-live="polite" aria-atomic="false" aria-relevant="additions text" class="a11y-text svelte-82qwg8"><!></span> <div class="prepend svelte-82qwg8"><!></div> <div class="value-container svelte-82qwg8"><!> <input/></div> <div class="indicators svelte-82qwg8"><!> <!> <!></div> <!> <!></div>');function bC(t,e){var A=function(QA){var _A={};for(var Ce in QA.children&&(_A.default=!0),QA.$$slots)_A[Ce]=!0;return _A}(e);st(e,!1);var i,n=X(),o=X(),r=X(),s=X(),a=X(),c=X(),l=X(),I=X(),C=X(),d=L_A(),B=k(e,"justValue",12,null),E=k(e,"filter",8,gUA),Q=k(e,"getItems",8,IUA),u=k(e,"id",8,null),v=k(e,"name",8,null),L=k(e,"container",12,void 0),x=k(e,"input",12,void 0),y=k(e,"multiple",8,!1),F=k(e,"multiFullItemClearable",8,!1),U=k(e,"disabled",8,!1),T=k(e,"focused",12,!1),N=k(e,"value",12,null),K=k(e,"filterText",12,""),H=k(e,"placeholder",8,"Please select"),j=k(e,"placeholderAlwaysShow",8,!1),IA=k(e,"items",12,null),lA=k(e,"label",8,"label"),uA=k(e,"itemFilter",8,(QA,_A,Ce)=>"".concat(QA).toLowerCase().includes(_A.toLowerCase())),p=k(e,"groupBy",8,void 0),V=k(e,"groupFilter",8,QA=>QA),cA=k(e,"groupHeaderSelectable",8,!1),aA=k(e,"itemId",8,"value"),jA=k(e,"loadOptions",8,void 0),VA=k(e,"containerStyles",8,""),ce=k(e,"hasError",8,!1),EA=k(e,"filterSelectedItems",8,!0),sA=k(e,"required",8,!1),TA=k(e,"closeListOnChange",8,!0),Ke=k(e,"clearFilterTextOnBlur",8,!0),Re=k(e,"createGroupHeaderItem",8,(QA,_A)=>({value:QA,[lA()]:QA})),hA=()=>g(l),eA=k(e,"searchable",8,!0),RA=k(e,"inputStyles",8,""),oA=k(e,"clearable",8,!0),ne=k(e,"loading",12,!1),h=k(e,"listOpen",12,!1),f=k(e,"debounce",8,function(QA){var _A=arguments.length>1&&arguments[1]!==void 0?arguments[1]:1;clearTimeout(i),i=setTimeout(QA,_A)}),w=k(e,"debounceWait",8,300),D=k(e,"hideEmptyState",8,!1),O=k(e,"inputAttributes",24,()=>({})),Z=k(e,"listAutoWidth",8,!0),q=k(e,"showChevron",8,!1),CA=k(e,"listOffset",8,5),kA=k(e,"hoverItemIndex",12,0),KA=k(e,"floatingConfig",24,()=>({})),Ie=k(e,"class",8,""),GA=X(),oe=X(),M=X(),G=X(),Y=X();function AA(QA){return QA.map((_A,Ce)=>({index:Ce,value:_A,label:"".concat(_A)}))}function dA(QA){var _A=[],Ce={};QA.forEach(Li=>{var ai=p()(Li);_A.includes(ai)||(_A.push(ai),Ce[ai]=[],ai&&Ce[ai].push(Object.assign(Re()(ai,Li),{id:ai,groupHeader:!0,selectable:cA()}))),Ce[ai].push(Object.assign({groupItem:!!ai},Li))});var Pt=[];return V()(_A).forEach(Li=>{Ce[Li]&&Pt.push(...Ce[Li])}),Pt}function WA(){var QA=arguments.length>0&&arguments[0]!==void 0?arguments[0]:0,_A=arguments.length>1?arguments[1]:void 0;kA(QA<0?0:QA),!_A&&p()&&g(l)[kA()]&&!g(l)[kA()].selectable&&ei(1)}function Qe(){var QA=!0;if(N()){var _A=[],Ce=[];N().forEach(Pt=>{_A.includes(Pt[aA()])?QA=!1:(_A.push(Pt[aA()]),Ce.push(Pt))}),QA||N(Ce)}return QA}function yA(QA){var _A=QA?QA[aA()]:N()[aA()];return IA().find(Ce=>Ce[aA()]===_A)}function DA(QA){return We.apply(this,arguments)}function We(){return(We=yt(function*(QA){var _A=N()[QA];N().length===1?N(void 0):N(N().filter(Ce=>Ce!==_A)),d("clear",_A)})).apply(this,arguments)}function be(QA){if(T())switch(QA.stopPropagation(),QA.key){case"Escape":QA.preventDefault(),Ci();break;case"Enter":if(QA.preventDefault(),h()){if(g(l).length===0)break;var _A=g(l)[kA()];if(N()&&!y()&&N()[aA()]===_A[aA()]){Ci();break}Ye(g(l)[kA()])}break;case"ArrowDown":QA.preventDefault(),h()?ei(1):(h(!0),b(GA,void 0));break;case"ArrowUp":QA.preventDefault(),h()?ei(-1):(h(!0),b(GA,void 0));break;case"Tab":if(h()&&T()){if(g(l).length===0||N()&&N()[aA()]===g(l)[kA()][aA()])return Ci();QA.preventDefault(),Ye(g(l)[kA()]),Ci()}break;case"Backspace":if(!y()||K().length>0)return;if(y()&&N()&&N().length>0){if(DA(g(GA)!==void 0?g(GA):N().length-1),g(GA)===0||g(GA)===void 0)break;b(GA,N().length>g(GA)?g(GA)-1:void 0)}break;case"ArrowLeft":if(!N()||!y()||K().length>0)return;g(GA)===void 0?b(GA,N().length-1):N().length>g(GA)&&g(GA)!==0&&b(GA,g(GA)-1);break;case"ArrowRight":if(!N()||!y()||K().length>0||g(GA)===void 0)return;g(GA)===N().length-1?b(GA,void 0):g(GA)<N().length-1&&b(GA,g(GA)+1)}}function qA(QA){var _A,Ce;T()&&x()===((_A=document)===null||_A===void 0?void 0:_A.activeElement)||(QA&&d("focus",QA),(Ce=x())===null||Ce===void 0||Ce.focus(),T(!0))}function It(QA){return Vi.apply(this,arguments)}function Vi(){return(Vi=yt(function*(QA){var _A;ui||(h()||T())&&(d("blur",QA),Ci(),T(!1),b(GA,void 0),(_A=x())===null||_A===void 0||_A.blur())})).apply(this,arguments)}function on(){if(!U())return K().length>0?h(!0):void h(!h())}function Hi(){d("clear",N()),N(void 0),Ci(),qA()}function Ci(){Ke()&&K(""),h(!1)}x_A(yt(function*(){b(oe,N()),b(M,K()),b(G,y())})),ls(()=>{h()&&T(!0),T()&&x()&&x().focus()});var Zi=k(e,"ariaValues",8,QA=>"Option ".concat(QA,", selected.")),Qi=k(e,"ariaListOpen",8,(QA,_A)=>"You are currently focused on option ".concat(QA,". There are ").concat(_A," results available.")),Ft=k(e,"ariaFocused",8,()=>"Select is focused, type to refine list, press down to open the menu."),Tt,Ht=X(null);function zi(){clearTimeout(Tt),Tt=setTimeout(()=>{ui=!1},100)}Tc(()=>{var QA;(QA=g(Ht))===null||QA===void 0||QA.remove()});var ui=!1;function Ye(QA){QA&&QA.selectable!==!1&&function(_A){if(_A){K("");var Ce=Object.assign({},_A);if(Ce.groupHeader&&!Ce.selectable)return;N(y()?N()?N().concat([Ce]):[Ce]:N(Ce)),setTimeout(()=>{TA()&&Ci(),b(GA,void 0),d("change",N()),d("select",_A)})}}(QA)}function Ai(QA){ui||kA(QA)}function ei(QA){if(g(l).filter(Ce=>!Object.hasOwn(Ce,"selectable")||Ce.selectable===!0).length===0)return kA(0);QA>0&&kA()===g(l).length-1?kA(0):QA<0&&kA()===0?kA(g(l).length-1):kA(kA()+QA);var _A=g(l)[kA()];_A&&_A.selectable===!1&&(QA!==1&&QA!==-1||ei(QA))}function Oi(QA,_A,Ce){if(!y())return _A&&_A[Ce]===QA[Ce]}var Yn=Ho,Dn=Ho;function Ho(QA){return{update(_A){_A.scroll&&(zi(),QA.scrollIntoView({behavior:"auto",block:"nearest"}))}}}var Sn=X({strategy:"absolute",placement:"bottom-start",middleware:[sUA(CA()),cUA(),aUA()],autoUpdate:!1}),[io,Wo,No]=lUA(g(Sn)),Jn=X(!0);fA(()=>(W(IA()),W(N())),()=>{IA(),N()&&function(){if(typeof N()=="string"){var QA=(IA()||[]).find(_A=>_A[aA()]===N());N(QA||{[aA()]:N(),label:N()})}else y()&&Array.isArray(N())&&N().length>0&&N(N().map(_A=>typeof _A=="string"?{value:_A,label:_A}:_A))}()}),fA(()=>(W(O()),W(eA())),()=>{!O()&&eA()||(b(Y,Object.assign({autocapitalize:"none",autocomplete:"off",autocorrect:"off",spellcheck:!1,tabindex:0,type:"text","aria-autocomplete":"list"},O())),u()&&lc(Y,g(Y).id=u()),eA()||lc(Y,g(Y).readonly=!0))}),fA(()=>W(y()),()=>{y()&&N()&&(Array.isArray(N())?N([...N()]):N([N()]))}),fA(()=>(g(G),W(y())),()=>{g(G)&&!y()&&N()&&N(null)}),fA(()=>(W(y()),W(N())),()=>{y()&&N()&&N().length>1&&Qe()}),fA(()=>W(N()),()=>{N()&&(y()?JSON.stringify(N())!==JSON.stringify(g(oe))&&Qe()&&d("input",N()):g(oe)&&JSON.stringify(N()[aA()])===JSON.stringify(g(oe)[aA()])||d("input",N()))}),fA(()=>(W(N()),W(y()),g(oe)),()=>{!N()&&y()&&g(oe)&&d("input",N())}),fA(()=>(W(T()),W(x())),()=>{!T()&&x()&&Ci()}),fA(()=>(W(K()),g(M)),()=>{K()!==g(M)&&(jA()||K().length!==0)&&(jA()?f()(yt(function*(){ne(!0);var QA=yield Q()({dispatch:d,loadOptions:jA(),convertStringItemsToObjects:AA,filterText:K()});QA?(ne(QA.loading),h(h()?QA.listOpen:K().length>0),T(h()&&QA.focused),IA(p()?dA(QA.filteredItems):QA.filteredItems)):(ne(!1),T(!0),h(!0))}),w()):(h(!0),y()&&b(GA,void 0)))}),fA(()=>(W(E()),W(jA()),W(K()),W(IA()),W(y()),W(N()),W(aA()),W(p()),W(lA()),W(EA()),W(uA())),()=>{b(l,E()({loadOptions:jA(),filterText:K(),items:IA(),multiple:y(),value:N(),itemId:aA(),groupBy:p(),label:lA(),filterSelectedItems:EA(),itemFilter:uA(),convertStringItemsToObjects:AA,filterGroupedItems:dA}))}),fA(()=>(W(y()),W(h()),W(N()),g(l)),()=>{!y()&&h()&&N()&&g(l)&&WA(g(l).findIndex(QA=>QA[aA()]===N()[aA()]),!0)}),fA(()=>(W(h()),W(y())),()=>{h()&&y()&&kA(0)}),fA(()=>W(K()),()=>{K()&&kA(0)}),fA(()=>W(kA()),()=>{var QA;QA=kA(),d("hoverItem",QA)}),fA(()=>(W(y()),W(N())),()=>{b(n,y()?N()&&N().length>0:N())}),fA(()=>(g(n),W(K())),()=>{b(o,g(n)&&K().length>0)}),fA(()=>(g(n),W(oA()),W(U()),W(ne())),()=>{b(r,g(n)&&oA()&&!U()&&!ne())}),fA(()=>(W(j()),W(y()),W(H()),W(N())),()=>{var QA;b(s,j()&&y()||y()&&((QA=N())===null||QA===void 0?void 0:QA.length)===0?H():N()?"":H())}),fA(()=>(W(N()),W(y())),()=>{var QA,_A;b(a,N()?(QA=y(),_A=void 0,_A=QA&&N().length>0?N().map(Ce=>Ce[lA()]).join(", "):N()[lA()],Zi()(_A)):"")}),fA(()=>(g(l),W(kA()),W(T()),W(h())),()=>{b(c,function(){if(!g(l)||g(l).length===0)return"";var QA=g(l)[kA()];if(h()&&QA){var _A=g(l)?g(l).length:0;return Qi()(QA[lA()],_A)}return Ft()()}((g(l),kA(),T(),h())))}),fA(()=>W(IA()),()=>{(function(QA){QA&&QA.length!==0&&!QA.some(_A=>typeof _A!="object")&&N()&&(y()?!N().some(_A=>!_A||!_A[aA()]):N()[aA()])&&(Array.isArray(N())?N(N().map(_A=>yA(_A)||_A)):N(yA()||N()))})(IA())}),fA(()=>(W(y()),W(N()),W(aA())),()=>{B((y(),N(),aA(),y()?N()?N().map(QA=>QA[aA()]):null:N()?N()[aA()]:N()))}),fA(()=>(W(y()),g(oe),W(N())),()=>{y()||!g(oe)||N()||d("input",N())}),fA(()=>(W(h()),g(l),W(y()),W(N())),()=>{h()&&g(l)&&!y()&&!N()&&WA()}),fA(()=>g(l),()=>{(function(QA){h()&&d("filter",QA)})(g(l))}),fA(()=>(W(L()),W(KA()),g(Sn)),()=>{L()&&KA()&&No(Object.assign(g(Sn),KA()))}),fA(()=>g(Ht),()=>{b(I,!!g(Ht))}),fA(()=>(g(Ht),W(h())),()=>{(function(QA,_A){if(!QA||!_A)return b(Jn,!0);setTimeout(()=>{b(Jn,!1)},0)})(g(Ht),h())}),fA(()=>(W(h()),W(L()),g(Ht)),()=>{h()&&L()&&g(Ht)&&function(){var{width:QA}=L().getBoundingClientRect();lc(Ht,g(Ht).style.width=Z()?QA+"px":"auto")}()}),fA(()=>W(kA()),()=>{b(C,kA())}),fA(()=>(W(x()),W(h()),W(T())),()=>{x()&&h()&&!T()&&qA()}),fA(()=>(W(L()),W(KA())),()=>{var QA;L()&&((QA=KA())===null||QA===void 0?void 0:QA.autoUpdate)===void 0&&lc(Sn,g(Sn).autoUpdate=!0)}),nn(),Rt();var hn,wo=MUA();re("click",q0,function(QA){var _A;h()||T()||!L()||L().contains(QA.target)||(_A=g(Ht))!==null&&_A!==void 0&&_A.contains(QA.target)||It()}),re("keydown",q0,be);var se=$(wo),fi=QA=>{var _A,Ce=QUA(),Pt=$(Ce),Li=jt=>{var Nn=po();xo(Bt(Nn),e,"list-prepend",{},null),iA(jt,Nn)};MA(Pt,jt=>{A["list-prepend"]&&jt(Li)});var ai=gA(Pt,2),Fn=jt=>{var Nn=po();xo(Bt(Nn),e,"list",{get filteredItems(){return g(l)}},null),iA(jt,Nn)},Co=(jt,Nn)=>{var ut=Oe=>{var ni=po();Fo(Bt(ni),1,()=>g(l),Zo,(fn,Yi,ir)=>{var Xi,ks=EUA(),La=$(ks);xo($(La),e,"item",{get item(){return g(Yi)},index:ir},_o=>{var yn=_r();Ee(()=>{var Gr;return Et(yn,(Gr=g(Yi))===null||Gr===void 0?void 0:Gr[lA()])}),iA(_o,yn)}),bs(La,(_o,yn)=>Yn?.(_o),()=>({scroll:Oi(g(Yi),N(),aA()),listDom:g(I)})),bs(La,(_o,yn)=>Dn?.(_o),()=>({scroll:g(C)===ir,listDom:g(I)})),Ee(_o=>Xi=xt(La,1,"item svelte-82qwg8",null,Xi,_o),[()=>{var _o,yn;return{"list-group-title":g(Yi).groupHeader,active:Oi(g(Yi),N(),aA()),first:(yn=ir,yn===0),hover:kA()===ir,"group-item":g(Yi).groupItem,"not-selectable":((_o=g(Yi))===null||_o===void 0?void 0:_o.selectable)===!1}}],PA),re("mouseover",ks,()=>Ai(ir)),re("focus",ks,()=>Ai(ir)),re("click",ks,z0(()=>function(_o){var{item:yn,i:Gr}=_o;if(yn?.selectable!==!1)return N()&&!y()&&N()[aA()]===yn[aA()]?Ci():void(function(z){return z.groupHeader&&z.selectable||z.selectable||!z.hasOwnProperty("selectable")}(yn)&&(kA(Gr),Ye(yn)))}({item:g(Yi),i:ir}))),re("keydown",ks,S1(z0(function(_o){m3.call(this,e,_o)}))),iA(fn,ks)}),iA(Oe,ni)},Xo=(Oe,ni)=>{var fn=Yi=>{var ir=po();xo(Bt(ir),e,"empty",{},Xi=>{iA(Xi,hUA())}),iA(Yi,ir)};MA(Oe,Yi=>{D()||Yi(fn)},ni)};MA(jt,Oe=>{g(l).length>0?Oe(ut):Oe(Xo,!1)},Nn)};MA(ai,jt=>{A.list?jt(Fn):jt(Co,!1)});var Qn=gA(ai,2),un=jt=>{var Nn=po();xo(Bt(Nn),e,"list-append",{},null),iA(jt,Nn)};MA(Qn,jt=>{A["list-append"]&&jt(un)}),bs(Ce,jt=>Wo?.(jt)),to(Ce,jt=>b(Ht,jt),()=>g(Ht)),Nr(()=>re("scroll",Ce,zi)),Nr(()=>re("pointerup",Ce,S1(z0(function(jt){m3.call(this,e,jt)})))),Nr(()=>re("mousedown",Ce,S1(z0(function(jt){m3.call(this,e,jt)})))),Ee(jt=>_A=xt(Ce,1,"svelte-select-list svelte-82qwg8",null,_A,jt),[()=>({prefloat:g(Jn)})],PA),iA(QA,Ce)};MA(se,QA=>{h()&&QA(fi)});var bA=gA(se,2),fe=$(bA),it=QA=>{var _A=uUA(),Ce=Bt(_A),Pt=$(Ce),Li=$(gA(Ce,2));Ee(()=>{Et(Pt,g(a)),Et(Li,g(c))}),iA(QA,_A)};MA(fe,QA=>{T()&&QA(it)});var Gt=gA(bA,2);xo($(Gt),e,"prepend",{},null);var Xe=gA(Gt,2),Ot=$(Xe),Pi=QA=>{var _A=po(),Ce=Bt(_A),Pt=ai=>{var Fn=po();Fo(Bt(Fn),1,N,Zo,(Co,Qn,un)=>{var jt,Nn=mUA(),ut=$(Nn);xo($(ut),e,"selection",{get selection(){return g(Qn)},index:un},ni=>{var fn=_r();Ee(()=>Et(fn,g(Qn)[lA()])),iA(ni,fn)});var Xo=gA(ut,2),Oe=ni=>{var fn=fUA();xo($(fn),e,"multi-clear-icon",{},Yi=>{TN(Yi)}),re("pointerup",fn,S1(z0(()=>DA(un)))),iA(ni,fn)};MA(Xo,ni=>{U()||F()||!TN||ni(Oe)}),Ee(ni=>jt=xt(Nn,1,"multi-item svelte-82qwg8",null,jt,ni),[()=>({active:g(GA)===un,disabled:U()})],PA),re("click",Nn,S1(()=>F()?DA(un):{})),re("keydown",Nn,S1(z0(function(ni){m3.call(this,e,ni)}))),iA(Co,Nn)}),iA(ai,Fn)},Li=ai=>{var Fn,Co=pUA();xo($(Co),e,"selection",{get selection(){return N()}},Qn=>{var un=_r();Ee(()=>Et(un,N()[lA()])),iA(Qn,un)}),Ee(Qn=>Fn=xt(Co,1,"selected-item svelte-82qwg8",null,Fn,Qn),[()=>({"hide-selected-item":g(o)})],PA),iA(ai,Co)};MA(Ce,ai=>{y()?ai(Pt):ai(Li,!1)}),iA(QA,_A)};MA(Ot,QA=>{g(n)&&QA(Pi)});var Jt,Ki=gA(Ot,2);to(Ki,QA=>x(QA),()=>x());var Ct=gA(Xe,2),ti=$(Ct),$e=QA=>{var _A=wUA();xo($(_A),e,"loading-icon",{},Ce=>{(function(Pt){iA(Pt,BUA())})(Ce)}),iA(QA,_A)};MA(ti,QA=>{ne()&&QA($e)});var Nt=gA(ti,2),Wi=QA=>{var _A=DUA();xo($(_A),e,"clear-icon",{},Ce=>{TN(Ce)}),re("click",_A,Hi),iA(QA,_A)};MA(Nt,QA=>{g(r)&&QA(Wi)});var Tn=gA(Nt,2),ii=QA=>{var _A=yUA();xo($(_A),e,"chevron-icon",{get listOpen(){return h()}},Ce=>{(function(Pt){iA(Pt,CUA())})(Ce)}),iA(QA,_A)};MA(Tn,QA=>{q()&&QA(ii)});var Ri=gA(Ct,2);xo(Ri,e,"input-hidden",{get value(){return N()}},QA=>{var _A=vUA();Ee(Ce=>{en(_A,"name",v()),GC(_A,Ce)},[()=>N()?JSON.stringify(N()):null],PA),iA(QA,_A)});var dt=gA(Ri,2),zn=QA=>{var _A=po();xo(Bt(_A),e,"required",{get value(){return N()}},Ce=>{iA(Ce,bUA())}),iA(QA,_A)};return MA(dt,QA=>{!sA()||N()&&N().length!==0||QA(zn)}),Nr(()=>re("pointerup",wo,S1(on))),to(wo,QA=>L(QA),()=>L()),bs(wo,QA=>io?.(QA)),Ee(QA=>{var _A;hn=xt(wo,1,"svelte-select ".concat((_A=Ie())!==null&&_A!==void 0?_A:""),"svelte-82qwg8",hn,QA),vl(wo,VA()),Jt=jD(Ki,Jt,Be(Be({readOnly:!eA()},g(Y)),{},{placeholder:g(s),style:RA(),disabled:U()}),"svelte-82qwg8")},[()=>({multi:y(),disabled:U(),focused:T(),"list-open":h(),"show-chevron":q(),error:ce()})],PA),re("keydown",Ki,be),re("blur",Ki,It),re("focus",Ki,qA),iy(Ki,K),iA(t,wo),kt(e,"getFilteredItems",hA),kt(e,"handleClear",Hi),at({getFilteredItems:hA,handleClear:Hi})}vt(`/* over all fonts, sizes, and colors */
/* "consolas" for Windows, "menlo" for Mac with fallback to "monaco", 'Ubuntu Mono' for Ubuntu */
/* (at Mac this font looks too large at 14px, but 13px is too small for the font on Windows) */
/* main, menu, modal */
/* jsoneditor modal */
/* tooltip in text mode */
/* panels: navigation bar, gutter, search box */
/* navigation-bar */
/* context menu */
/* contents: json key and values */
/* contents: selected or hovered */
/* contents: section of collapsed items in an array */
/* contents: highlighting of search matches */
/* contents: inline tags inside the JSON document */
/* contents: table */
/* controls in modals: inputs, buttons, and \`a\` */
/* messages */
/* svelte-select */
/* color picker */
table.jse-transform-wizard.svelte-qbze6z {
  border-collapse: collapse;
  border-spacing: 0;
  width: 100%;
}
table.jse-transform-wizard.svelte-qbze6z input:where(.svelte-qbze6z) {
  font-family: inherit;
  font-size: inherit;
}
table.jse-transform-wizard.svelte-qbze6z tr:where(.svelte-qbze6z) th:where(.svelte-qbze6z) {
  font-weight: normal;
  text-align: left;
  width: 60px;
}
table.jse-transform-wizard.svelte-qbze6z tr:where(.svelte-qbze6z) td:where(.svelte-qbze6z) .jse-horizontal:where(.svelte-qbze6z) {
  width: 100%;
  display: flex;
  flex-direction: row;
  margin-bottom: calc(0.5 * var(--jse-padding, 10px));
}
table.jse-transform-wizard.svelte-qbze6z tr:where(.svelte-qbze6z) td:where(.svelte-qbze6z) .jse-horizontal:where(.svelte-qbze6z) .svelte-select .multi-item {
  align-items: center;
}
table.jse-transform-wizard.svelte-qbze6z tr:where(.svelte-qbze6z) td:where(.svelte-qbze6z) .jse-horizontal:where(.svelte-qbze6z) .svelte-select .value-container {
  gap: 0 !important;
}
table.jse-transform-wizard.svelte-qbze6z tr:where(.svelte-qbze6z) td:where(.svelte-qbze6z) .jse-horizontal:where(.svelte-qbze6z) .svelte-select.jse-filter-path {
  flex: 4;
  margin-right: calc(0.5 * var(--jse-padding, 10px));
}
table.jse-transform-wizard.svelte-qbze6z tr:where(.svelte-qbze6z) td:where(.svelte-qbze6z) .jse-horizontal:where(.svelte-qbze6z) .svelte-select.jse-filter-relation {
  flex: 1.5;
  margin-right: calc(0.5 * var(--jse-padding, 10px));
}
table.jse-transform-wizard.svelte-qbze6z tr:where(.svelte-qbze6z) td:where(.svelte-qbze6z) .jse-horizontal:where(.svelte-qbze6z) .svelte-select.jse-sort-path {
  flex: 3;
  margin-right: calc(0.5 * var(--jse-padding, 10px));
}
table.jse-transform-wizard.svelte-qbze6z tr:where(.svelte-qbze6z) td:where(.svelte-qbze6z) .jse-horizontal:where(.svelte-qbze6z) .svelte-select.jse-sort-direction {
  flex: 1;
}
table.jse-transform-wizard.svelte-qbze6z tr:where(.svelte-qbze6z) td:where(.svelte-qbze6z) .jse-horizontal:where(.svelte-qbze6z) .svelte-select.jse-projection-paths {
  flex: 1;
}
table.jse-transform-wizard.svelte-qbze6z tr:where(.svelte-qbze6z) td:where(.svelte-qbze6z) .jse-horizontal:where(.svelte-qbze6z) .svelte-select input {
  box-sizing: border-box;
}
table.jse-transform-wizard.svelte-qbze6z tr:where(.svelte-qbze6z) td:where(.svelte-qbze6z) .jse-horizontal:where(.svelte-qbze6z) .jse-filter-value:where(.svelte-qbze6z) {
  flex: 4;
  padding: 4px 8px;
  border: var(--jse-input-border, 1px solid #d8dbdf);
  border-radius: var(--jse-input-radius, 3px);
  outline: none;
  background: var(--jse-input-background, var(--jse-background-color, #fff));
  color: inherit;
}
table.jse-transform-wizard.svelte-qbze6z tr:where(.svelte-qbze6z) td:where(.svelte-qbze6z) .jse-horizontal:where(.svelte-qbze6z) .jse-filter-value:where(.svelte-qbze6z):focus {
  border: var(--jse-input-border-focus, 1px solid var(--jse-input-border-focus, var(--jse-theme-color, #3883fa)));
}`);var kUA=pA('<table class="jse-transform-wizard svelte-qbze6z"><tbody><tr class="svelte-qbze6z"><th class="svelte-qbze6z">Filter</th><td class="svelte-qbze6z"><div class="jse-horizontal svelte-qbze6z"><!> <!> <input class="jse-filter-value svelte-qbze6z"/></div></td></tr><tr class="svelte-qbze6z"><th class="svelte-qbze6z">Sort</th><td class="svelte-qbze6z"><div class="jse-horizontal svelte-qbze6z"><!> <!></div></td></tr><tr class="svelte-qbze6z"><th class="svelte-qbze6z">Pick</th><td class="svelte-qbze6z"><div class="jse-horizontal svelte-qbze6z"><!></div></td></tr></tbody></table>');function SUA(t,e){var A,i,n,o,r;st(e,!1);var s=X(void 0,!0),a=X(void 0,!0),c=X(void 0,!0),l=X(void 0,!0),I=X(void 0,!0),C=X(void 0,!0),d=wr("jsoneditor:TransformWizard"),B=k(e,"json",9),E=k(e,"queryOptions",29,()=>({})),Q=k(e,"onChange",9),u=["==","!=","<","<=",">",">="].map(EA=>({value:EA,label:EA})),v=[{value:"asc",label:"ascending"},{value:"desc",label:"descending"}],L=X((A=E())!==null&&A!==void 0&&(A=A.filter)!==null&&A!==void 0&&A.path?L1(E().filter.path):void 0,!0),x=X((i=u.find(EA=>{var sA;return EA.value===((sA=E().filter)===null||sA===void 0?void 0:sA.relation)}))!==null&&i!==void 0?i:u[0],!0),y=X(((n=E())===null||n===void 0||(n=n.filter)===null||n===void 0?void 0:n.value)||"",!0),F=X((o=E())!==null&&o!==void 0&&(o=o.sort)!==null&&o!==void 0&&o.path?L1(E().sort.path):void 0,!0),U=X((r=v.find(EA=>{var sA;return EA.value===((sA=E().sort)===null||sA===void 0?void 0:sA.direction)}))!==null&&r!==void 0?r:v[0],!0);fA(()=>W(B()),()=>{b(s,Array.isArray(B()))}),fA(()=>(g(s),W(B())),()=>{b(a,g(s)?r_(B()):[])}),fA(()=>(g(s),W(B())),()=>{b(c,g(s)?r_(B(),!0):[])}),fA(()=>(g(a),L1),()=>{b(l,g(a).map(L1))}),fA(()=>(g(c),L1),()=>{b(I,g(c)?g(c).map(L1):[])}),fA(()=>(W(E()),g(I),Ei),()=>{var EA;b(C,(EA=E())!==null&&EA!==void 0&&(EA=EA.projection)!==null&&EA!==void 0&&EA.paths&&g(I)?E().projection.paths.map(sA=>g(I).find(TA=>Ei(TA.value,sA))).filter(sA=>!!sA):void 0)}),fA(()=>g(L),()=>{var EA,sA,TA;sA=(EA=g(L))===null||EA===void 0?void 0:EA.value,Ei((TA=E())===null||TA===void 0||(TA=TA.filter)===null||TA===void 0?void 0:TA.path,sA)||(d("changeFilterPath",sA),E(As(E(),["filter","path"],sA,!0)),Q()(E()))}),fA(()=>g(x),()=>{var EA,sA,TA;sA=(EA=g(x))===null||EA===void 0?void 0:EA.value,Ei((TA=E())===null||TA===void 0||(TA=TA.filter)===null||TA===void 0?void 0:TA.relation,sA)||(d("changeFilterRelation",sA),E(As(E(),["filter","relation"],sA,!0)),Q()(E()))}),fA(()=>g(y),()=>{var EA,sA;EA=g(y),Ei((sA=E())===null||sA===void 0||(sA=sA.filter)===null||sA===void 0?void 0:sA.value,EA)||(d("changeFilterValue",EA),E(As(E(),["filter","value"],EA,!0)),Q()(E()))}),fA(()=>g(F),()=>{var EA,sA,TA;sA=(EA=g(F))===null||EA===void 0?void 0:EA.value,Ei((TA=E())===null||TA===void 0||(TA=TA.sort)===null||TA===void 0?void 0:TA.path,sA)||(d("changeSortPath",sA),E(As(E(),["sort","path"],sA,!0)),Q()(E()))}),fA(()=>g(U),()=>{var EA,sA,TA;sA=(EA=g(U))===null||EA===void 0?void 0:EA.value,Ei((TA=E())===null||TA===void 0||(TA=TA.sort)===null||TA===void 0?void 0:TA.direction,sA)||(d("changeSortDirection",sA),E(As(E(),["sort","direction"],sA,!0)),Q()(E()))}),fA(()=>g(C),()=>{(function(EA){var sA;Ei((sA=E())===null||sA===void 0||(sA=sA.projection)===null||sA===void 0?void 0:sA.paths,EA)||(d("changeProjectionPaths",EA),E(As(E(),["projection","paths"],EA,!0)),Q()(E()))})(g(C)?g(C).map(EA=>EA.value):void 0)}),nn(),Rt(!0);var T=kUA(),N=$(T),K=$(N),H=gA($(K)),j=$(H),IA=$(j);bC(IA,{class:"jse-filter-path",showChevron:!0,get items(){return g(l)},get value(){return g(L)},set value(EA){b(L,EA)},$$legacy:!0});var lA=gA(IA,2);bC(lA,{class:"jse-filter-relation",showChevron:!0,clearable:!1,items:u,get value(){return g(x)},set value(EA){b(x,EA)},$$legacy:!0});var uA=gA(lA,2),p=gA(K),V=gA($(p)),cA=$(V),aA=$(cA);bC(aA,{class:"jse-sort-path",showChevron:!0,get items(){return g(l)},get value(){return g(F)},set value(EA){b(F,EA)},$$legacy:!0}),bC(gA(aA,2),{class:"jse-sort-direction",showChevron:!0,clearable:!1,items:v,get value(){return g(U)},set value(EA){b(U,EA)},$$legacy:!0});var jA=gA(p),VA=gA($(jA)),ce=$(VA);bC($(ce),{class:"jse-projection-paths",multiple:!0,showChevron:!0,get items(){return g(I)},get value(){return g(C)},set value(EA){b(C,EA)},$$legacy:!0}),iy(uA,()=>g(y),EA=>b(y,EA)),iA(t,T),at()}vt(`/* over all fonts, sizes, and colors */
/* "consolas" for Windows, "menlo" for Mac with fallback to "monaco", 'Ubuntu Mono' for Ubuntu */
/* (at Mac this font looks too large at 14px, but 13px is too small for the font on Windows) */
/* main, menu, modal */
/* jsoneditor modal */
/* tooltip in text mode */
/* panels: navigation bar, gutter, search box */
/* navigation-bar */
/* context menu */
/* contents: json key and values */
/* contents: selected or hovered */
/* contents: section of collapsed items in an array */
/* contents: highlighting of search matches */
/* contents: inline tags inside the JSON document */
/* contents: table */
/* controls in modals: inputs, buttons, and \`a\` */
/* messages */
/* svelte-select */
/* color picker */
.jse-select-query-language.svelte-atm4um {
  position: relative;
  width: 32px;
}
.jse-select-query-language.svelte-atm4um .jse-select-query-language-container:where(.svelte-atm4um) {
  position: absolute;
  top: 0;
  right: 0;
  display: flex;
  flex-direction: column;
  box-shadow: var(--jse-controls-box-shadow, 0 2px 6px 0 rgba(0, 0, 0, 0.24));
}
.jse-select-query-language.svelte-atm4um .jse-select-query-language-container:where(.svelte-atm4um) .jse-query-language:where(.svelte-atm4um) {
  border: none;
  background: transparent;
  color: inherit;
  cursor: pointer;
  font-family: var(--jse-font-family, -apple-system, BlinkMacSystemFont, "Segoe UI", Roboto, Oxygen-Sans, Ubuntu, Cantarell, "Helvetica Neue", sans-serif);
  font-size: var(--jse-font-size, 16px);
  padding: 5px;
  margin: 0;
  text-align: left;
  padding: var(--jse-padding, 10px) calc(2 * var(--jse-padding, 10px));
  white-space: nowrap;
  color: var(--jse-context-menu-color, var(--jse-text-color-inverse, #fff));
  background: var(--jse-context-menu-background, #656565);
}
.jse-select-query-language.svelte-atm4um .jse-select-query-language-container:where(.svelte-atm4um) .jse-query-language:where(.svelte-atm4um):hover {
  background: var(--jse-context-menu-background-highlight, #7a7a7a);
}`);var RUA=pA('<button type="button"><!> </button>'),LUA=pA('<div class="jse-select-query-language svelte-atm4um"><div class="jse-select-query-language-container svelte-atm4um"></div></div>');function xUA(t,e){st(e,!1);var A=k(e,"queryLanguages",8),i=k(e,"queryLanguageId",12),n=k(e,"onChangeQueryLanguage",8);Rt();var o=LUA();Fo($(o),5,A,Zo,(r,s)=>{var a,c=RUA(),l=$(c),I=B=>{Si(B,{data:SS})},C=B=>{Si(B,{data:RS})};MA(l,B=>{g(s).id===i()?B(I):B(C,!1)});var d=gA(l);Ee(B=>{var E;a=xt(c,1,"jse-query-language svelte-atm4um",null,a,B),en(c,"title","Select ".concat(g(s).name," as query language")),Et(d," ".concat((E=g(s).name)!==null&&E!==void 0?E:""))},[()=>({selected:g(s).id===i()})],PA),re("click",c,()=>{return B=g(s).id,i(B),void n()(B);var B}),iA(r,c)}),iA(t,o),at()}vt(`/* over all fonts, sizes, and colors */
/* "consolas" for Windows, "menlo" for Mac with fallback to "monaco", 'Ubuntu Mono' for Ubuntu */
/* (at Mac this font looks too large at 14px, but 13px is too small for the font on Windows) */
/* main, menu, modal */
/* jsoneditor modal */
/* tooltip in text mode */
/* panels: navigation bar, gutter, search box */
/* navigation-bar */
/* context menu */
/* contents: json key and values */
/* contents: selected or hovered */
/* contents: section of collapsed items in an array */
/* contents: highlighting of search matches */
/* contents: inline tags inside the JSON document */
/* contents: table */
/* controls in modals: inputs, buttons, and \`a\` */
/* messages */
/* svelte-select */
/* color picker */
.jse-header.svelte-1y24war {
  display: flex;
  background: var(--jse-theme-color, #3883fa);
  color: var(--jse-menu-color, var(--jse-text-color-inverse, #fff));
}
.jse-header.svelte-1y24war .jse-title:where(.svelte-1y24war) {
  flex: 1;
  padding: 5px;
  vertical-align: middle;
}
.jse-header.svelte-1y24war button:where(.svelte-1y24war) {
  border: none;
  background: transparent;
  min-width: 32px;
  color: inherit;
  cursor: pointer;
}
.jse-header.svelte-1y24war button:where(.svelte-1y24war):hover {
  background: rgba(255, 255, 255, 0.1);
}`);var FUA=pA('<button type="button" class="jse-fullscreen svelte-1y24war" title="Toggle full screen"><!></button>'),NUA=pA('<div class="jse-header svelte-1y24war"><div class="jse-title svelte-1y24war"> </div> <!> <!> <button type="button" class="jse-close svelte-1y24war"><!></button></div>');function dy(t,e){st(e,!1);var A=k(e,"title",9,"Modal"),i=k(e,"fullScreenButton",9,!1),n=k(e,"fullscreen",13,!1),o=k(e,"onClose",9,void 0);Rt(!0);var r=NUA(),s=$(r),a=$(s),c=gA(s,2);xo(c,e,"actions",{},null);var l=gA(c,2),I=d=>{var B=FUA(),E=$(B),Q=PA(()=>n()?QW:FW);Si(E,{get data(){return g(Q)}}),re("click",B,()=>n(!n())),iA(d,B)};MA(l,d=>{i()&&d(I)});var C=gA(l,2);Si($(C),{data:Wu}),Ee(()=>Et(a,A())),re("click",C,()=>{var d;return(d=o())===null||d===void 0?void 0:d()}),iA(t,r),at()}vt(`/* over all fonts, sizes, and colors */
/* "consolas" for Windows, "menlo" for Mac with fallback to "monaco", 'Ubuntu Mono' for Ubuntu */
/* (at Mac this font looks too large at 14px, but 13px is too small for the font on Windows) */
/* main, menu, modal */
/* jsoneditor modal */
/* tooltip in text mode */
/* panels: navigation bar, gutter, search box */
/* navigation-bar */
/* context menu */
/* contents: json key and values */
/* contents: selected or hovered */
/* contents: section of collapsed items in an array */
/* contents: highlighting of search matches */
/* contents: inline tags inside the JSON document */
/* contents: table */
/* controls in modals: inputs, buttons, and \`a\` */
/* messages */
/* svelte-select */
/* color picker */
.jse-config.svelte-1kpylsp {
  border: none;
  background: transparent;
  min-width: 32px;
  color: inherit;
  cursor: pointer;
}
.jse-config.svelte-1kpylsp:hover {
  background: rgba(255, 255, 255, 0.1);
}
.jse-config.hide.svelte-1kpylsp {
  display: none;
}`);var _UA=pA('<button slot="actions" type="button" title="Select a query language"><!></button>'),zN=wr("jsoneditor:AutoScrollHandler");function drA(t){var e,A;function i(s){return s<20?200:s<50?400:1200}function n(){if(t){var s=.05*(e||0);t.scrollTop+=s}}function o(s){A&&s===e||(r(),zN("startAutoScroll",s),e=s,A=setInterval(n,50))}function r(){A&&(zN("stopAutoScroll"),clearInterval(A),A=void 0,e=void 0)}return zN("createAutoScrollHandler",t),{onDrag:function(s){if(t){var a=s.clientY,{top:c,bottom:l}=t.getBoundingClientRect();a<c?o(-i(c-a)):a>l?o(i(a-l)):r()}},onDragEnd:function(){r()}}}var GUA=(t,e,A,i)=>(t/=i/2)<1?A/2*t*t+e:-A/2*(--t*(t-2)-1)+e,ZsA=()=>{var t,e,A,i,n,o,r,s,a,c,l,I,C;function d(Q){return Q.getBoundingClientRect().top-(t.getBoundingClientRect?t.getBoundingClientRect().top:0)+A}function B(Q){t.scrollTo?t.scrollTo(t.scrollLeft,Q):t.scrollTop=Q}function E(Q){c||(c=Q),B(o(l=Q-c,A,s,a)),C=!0,l<a?requestAnimationFrame(E):function(){B(A+s),e&&r&&(e.setAttribute("tabindex","-1"),e.focus()),typeof I=="function"&&I(),c=0,C=!1}()}return function(Q){var u=arguments.length>1&&arguments[1]!==void 0?arguments[1]:{};switch(a=1e3,n=u.offset||0,I=u.callback,o=u.easing||GUA,r=u.a11y||!1,typeof u.container){case"object":t=u.container;break;case"string":t=document.querySelector(u.container);break;default:t=window.document.documentElement}switch(A=t.scrollTop,typeof Q){case"number":e=void 0,r=!1,i=A+Q;break;case"object":i=d(e=Q);break;case"string":e=document.querySelector(Q),i=d(e)}switch(s=i-A+n,typeof u.duration){case"number":a=u.duration;break;case"function":a=u.duration(s)}C?c=0:requestAnimationFrame(E)}};function OE(t,e){var A=Date.now(),i=t();return e(Date.now()-A),i}var JE=wr("validation"),UUA={createObjectDocumentState:()=>({type:"object",properties:{}}),createArrayDocumentState:()=>({type:"array",items:[]}),createValueDocumentState:()=>({type:"value"})};function BrA(t,e,A,i){return Z_(t,e,A,i,UUA)}function WsA(t,e,A,i){if(JE("validateJSON"),!e)return[];if(A!==i){var n=A.stringify(t);return e(n!==void 0?i.parse(n):void 0)}return e(t)}function KUA(t,e,A,i){if(JE("validateText"),t.length>104857600)return{validationErrors:[{path:[],message:"Validation turned off: the document is too large",severity:bl.info}]};if(t.length!==0)try{var n=OE(()=>A.parse(t),a=>JE("validate: parsed json in ".concat(a," ms")));if(!e)return;var o=A===i?n:OE(()=>i.parse(t),a=>JE("validate: parsed json with the validationParser in ".concat(a," ms"))),r=OE(()=>e(o),a=>JE("validate: validated json in ".concat(a," ms")));return sn(r)?void 0:{validationErrors:r}}catch(a){var s=OE(()=>function(c,l){if(c.length>wGA)return!1;try{return l.parse(yc(c)),!0}catch{return!1}}(t,A),c=>JE("validate: checked whether repairable in ".concat(c," ms")));return{parseError:XE(t,a.message||a.toString()),isRepairable:s}}}var TD=wr("jsoneditor:FocusTracker");function iG(t){var e,{onMount:A,onDestroy:i,getWindow:n,hasFocus:o,onFocus:r,onBlur:s}=t,a=!1;function c(){var I=o();I&&(clearTimeout(e),a||(TD("focus"),r(),a=I))}function l(){a&&(clearTimeout(e),e=setTimeout(()=>{o()||(TD("blur"),a=!1,s())}))}A(()=>{TD("mount FocusTracker");var I=n();I&&(I.addEventListener("focusin",c,!0),I.addEventListener("focusout",l,!0))}),i(()=>{TD("destroy FocusTracker");var I=n();I&&(I.removeEventListener("focusin",c,!0),I.removeEventListener("focusout",l,!0))})}vt(`/* over all fonts, sizes, and colors */
/* "consolas" for Windows, "menlo" for Mac with fallback to "monaco", 'Ubuntu Mono' for Ubuntu */
/* (at Mac this font looks too large at 14px, but 13px is too small for the font on Windows) */
/* main, menu, modal */
/* jsoneditor modal */
/* tooltip in text mode */
/* panels: navigation bar, gutter, search box */
/* navigation-bar */
/* context menu */
/* contents: json key and values */
/* contents: selected or hovered */
/* contents: section of collapsed items in an array */
/* contents: highlighting of search matches */
/* contents: inline tags inside the JSON document */
/* contents: table */
/* controls in modals: inputs, buttons, and \`a\` */
/* messages */
/* svelte-select */
/* color picker */
.jse-message.svelte-czprfx {
  font-family: var(--jse-font-family-mono, consolas, menlo, monaco, "Ubuntu Mono", "source-code-pro", monospace);
  font-size: var(--jse-font-size-mono, 14px);
  padding: var(--jse-padding, 10px);
  display: flex;
  gap: var(--jse-padding, 10px);
  flex-wrap: wrap;
  align-items: stretch;
}
.jse-message.jse-success.svelte-czprfx {
  background: var(--message-success-background, #9ac45d);
  color: var(--jse-message-success-color, #fff);
}
.jse-message.svelte-czprfx .jse-text:where(.svelte-czprfx) {
  display: flex;
  flex: 1;
  min-width: 60%;
  align-items: center;
}
.jse-message.svelte-czprfx .jse-text.jse-clickable:where(.svelte-czprfx) {
  cursor: pointer;
}
.jse-message.svelte-czprfx .jse-text.jse-clickable:where(.svelte-czprfx):hover {
  background-color: rgba(255, 255, 255, 0.1);
}
.jse-message.jse-error.svelte-czprfx {
  background: var(--jse-message-error-background, var(--jse-error-color, #ee5341));
  color: var(--jse-message-error-color, #fff);
}
.jse-message.jse-warning.svelte-czprfx {
  background: var(--jse-message-warning-background, #ffde5c);
  color: var(--jse-message-warning-color, #4d4d4d);
}
.jse-message.jse-info.svelte-czprfx {
  background: var(--jse-message-info-background, #4f91ff);
  color: var(--jse-message-info-color, #fff);
}
.jse-message.svelte-czprfx .jse-actions:where(.svelte-czprfx) {
  display: flex;
  gap: var(--jse-padding, 10px);
}
.jse-message.svelte-czprfx .jse-actions:where(.svelte-czprfx) button.jse-action:where(.svelte-czprfx) {
  border: none;
  background: transparent;
  color: inherit;
  cursor: pointer;
  font-family: var(--jse-font-family, -apple-system, BlinkMacSystemFont, "Segoe UI", Roboto, Oxygen-Sans, Ubuntu, Cantarell, "Helvetica Neue", sans-serif);
  font-size: var(--jse-font-size, 16px);
  padding: 5px;
  margin: 0;
  background: var(--jse-message-action-background, rgba(255, 255, 255, 0.2));
  color: inherit;
  padding: calc(0.5 * var(--jse-padding, 10px)) var(--jse-padding, 10px);
}
.jse-message.svelte-czprfx .jse-actions:where(.svelte-czprfx) button.jse-action:where(.svelte-czprfx):hover {
  background: var(--jse-message-action-background-highlight, rgba(255, 255, 255, 0.3));
}`);var YUA=pA('<button type="button" class="jse-button jse-action jse-primary svelte-czprfx"><!> </button>'),JUA=pA('<div><div role="button" tabindex="-1"><div class="jse-text-centered"><!> </div></div> <div class="jse-actions svelte-czprfx"></div></div>');function Cc(t,e){st(e,!1);var A=k(e,"type",9,"success"),i=k(e,"icon",9,void 0),n=k(e,"message",9,void 0),o=k(e,"actions",25,()=>[]),r=k(e,"onClick",9,void 0),s=k(e,"onClose",9,void 0);s()&&Tc(s()),Rt(!0);var a,c=JUA(),l=$(c),I=$(l),C=$(I),d=E=>{Si(E,{get data(){return i()}})};MA(C,E=>{i()&&E(d)});var B=gA(C);Fo(gA(l,2),5,o,Zo,(E,Q)=>{var u=YUA(),v=$(u),L=y=>{Si(y,{get data(){return g(Q).icon}})};MA(v,y=>{g(Q).icon&&y(L)});var x=gA(v);Ee(()=>{var y;en(u,"title",g(Q).title),u.disabled=g(Q).disabled,Et(x," ".concat((y=g(Q).text)!==null&&y!==void 0?y:""))}),re("click",u,()=>{g(Q).onClick&&g(Q).onClick()}),re("mousedown",u,()=>{g(Q).onMouseDown&&g(Q).onMouseDown()}),iA(E,u)}),Ee(E=>{var Q,u;xt(c,1,"jse-message jse-".concat((Q=A())!==null&&Q!==void 0?Q:""),"svelte-czprfx"),a=xt(l,1,"jse-text svelte-czprfx",null,a,E),Et(B," ".concat((u=n())!==null&&u!==void 0?u:""))},[()=>({"jse-clickable":!!r()})],PA),re("click",l,function(){r()&&r()()}),iA(t,c),at()}vt(`/* over all fonts, sizes, and colors */
/* "consolas" for Windows, "menlo" for Mac with fallback to "monaco", 'Ubuntu Mono' for Ubuntu */
/* (at Mac this font looks too large at 14px, but 13px is too small for the font on Windows) */
/* main, menu, modal */
/* jsoneditor modal */
/* tooltip in text mode */
/* panels: navigation bar, gutter, search box */
/* navigation-bar */
/* context menu */
/* contents: json key and values */
/* contents: selected or hovered */
/* contents: section of collapsed items in an array */
/* contents: highlighting of search matches */
/* contents: inline tags inside the JSON document */
/* contents: table */
/* controls in modals: inputs, buttons, and \`a\` */
/* messages */
/* svelte-select */
/* color picker */
.jse-validation-errors-overview.svelte-1uindol {
  font-family: var(--jse-font-family-mono, consolas, menlo, monaco, "Ubuntu Mono", "source-code-pro", monospace);
  font-size: var(--jse-font-size-mono, 14px);
  overflow: auto;
  max-height: 25%;
}
.jse-validation-errors-overview.svelte-1uindol table:where(.svelte-1uindol) {
  border-collapse: collapse;
  width: 100%;
}
.jse-validation-errors-overview.svelte-1uindol table:where(.svelte-1uindol) tr:where(.svelte-1uindol) {
  cursor: pointer;
}
.jse-validation-errors-overview.svelte-1uindol table:where(.svelte-1uindol) tr.jse-validation-error:where(.svelte-1uindol) {
  background: var(--jse-message-error-background, var(--jse-error-color, #ee5341));
  color: var(--jse-message-error-color, #fff);
}
.jse-validation-errors-overview.svelte-1uindol table:where(.svelte-1uindol) tr.jse-validation-warning:where(.svelte-1uindol) {
  background: var(--jse-message-warning-background, #ffde5c);
  color: var(--jse-message-warning-color, #4d4d4d);
}
.jse-validation-errors-overview.svelte-1uindol table:where(.svelte-1uindol) tr.jse-validation-warning:where(.svelte-1uindol):hover {
  filter: brightness(105%);
}
.jse-validation-errors-overview.svelte-1uindol table:where(.svelte-1uindol) tr.jse-validation-info:where(.svelte-1uindol) {
  background: var(--jse-message-info-background, #4f91ff);
  color: var(--jse-message-info-color, #fff);
}
.jse-validation-errors-overview.svelte-1uindol table:where(.svelte-1uindol) tr:where(.svelte-1uindol):hover {
  filter: brightness(110%);
}
.jse-validation-errors-overview.svelte-1uindol table:where(.svelte-1uindol) tr:where(.svelte-1uindol) td:where(.svelte-1uindol) {
  padding: 4px var(--jse-padding, 10px);
  vertical-align: middle;
}
.jse-validation-errors-overview.svelte-1uindol table:where(.svelte-1uindol) tr:where(.svelte-1uindol) td.jse-validation-error-icon:where(.svelte-1uindol) {
  width: 36px;
  box-sizing: border-box;
}
.jse-validation-errors-overview.svelte-1uindol table:where(.svelte-1uindol) tr:where(.svelte-1uindol) td.jse-validation-error-action:where(.svelte-1uindol) {
  width: 36px;
  box-sizing: border-box;
  padding: 0;
}
.jse-validation-errors-overview.svelte-1uindol table:where(.svelte-1uindol) tr:where(.svelte-1uindol) td.jse-validation-error-action:where(.svelte-1uindol) button.jse-validation-errors-collapse:where(.svelte-1uindol) {
  border: none;
  background: transparent;
  color: inherit;
  cursor: pointer;
  font-family: var(--jse-font-family, -apple-system, BlinkMacSystemFont, "Segoe UI", Roboto, Oxygen-Sans, Ubuntu, Cantarell, "Helvetica Neue", sans-serif);
  font-size: var(--jse-font-size, 16px);
  padding: 5px;
  margin: 0;
  width: 36px;
  height: 26px;
  cursor: pointer;
}
.jse-validation-errors-overview.svelte-1uindol table:where(.svelte-1uindol) tr:where(.svelte-1uindol) td.jse-validation-error-action:where(.svelte-1uindol) button.jse-validation-errors-collapse:where(.svelte-1uindol):hover {
  background-color: rgba(255, 255, 255, 0.2);
}
.jse-validation-errors-overview.svelte-1uindol table:where(.svelte-1uindol) tr:where(.svelte-1uindol) td:where(.svelte-1uindol) div.jse-validation-errors-expand:where(.svelte-1uindol) {
  display: inline-block;
  position: relative;
  top: 3px;
}`);var TUA=pA('<button type="button" class="jse-validation-errors-collapse svelte-1uindol" title="Collapse validation errors"><!></button>'),zUA=pA('<tr tabindex="0"><td class="jse-validation-error-icon svelte-1uindol"><!></td><td class="jse-validation-error-path svelte-1uindol"> </td><td class="jse-validation-error-message svelte-1uindol"> </td><td class="jse-validation-error-action svelte-1uindol"><!></td></tr>'),HUA=pA('<tr class="jse-validation-error svelte-1uindol"><td class="svelte-1uindol"></td><td class="svelte-1uindol"></td><td class="svelte-1uindol"> </td><td class="svelte-1uindol"></td></tr>'),OUA=pA('<table class="jse-validation-errors-overview-expanded svelte-1uindol"><tbody><!><!></tbody></table>'),PUA=pA('<table class="jse-validation-errors-overview-collapsed svelte-1uindol"><tbody><tr><td class="jse-validation-error-icon svelte-1uindol"><!></td><td class="jse-validation-error-count svelte-1uindol"> <div class="jse-validation-errors-expand svelte-1uindol"><!></div></td></tr></tbody></table>'),jUA=pA('<div class="jse-validation-errors-overview svelte-1uindol"><!></div>');function nG(t,e){st(e,!1);var A=X(void 0,!0),i=k(e,"validationErrors",9),n=k(e,"selectError",9),o=X(!0,!0);function r(){b(o,!1)}function s(){b(o,!0)}fA(()=>W(i()),()=>{b(A,i().length)}),nn(),Rt(!0);var a=po(),c=Bt(a),l=I=>{var C=jUA(),d=$(C),B=Q=>{var u=OUA(),v=$(u),L=$(v);Fo(L,1,()=>asA(i(),100),Zo,(F,U,T)=>{var N=zUA(),K=$(N);Si($(K),{data:r1});var H=gA(K),j=$(H),IA=gA(H),lA=$(IA),uA=$(gA(IA)),p=V=>{var cA=TUA();Si($(cA),{data:kW}),re("click",cA,z0(r)),iA(V,cA)};MA(uA,V=>{T===0&&i().length>1&&V(p)}),Ee(V=>{var cA;xt(N,1,"jse-validation-".concat((cA=g(U).severity)!==null&&cA!==void 0?cA:""),"svelte-1uindol"),Et(j,V),Et(lA,g(U).message)},[()=>Dl(g(U).path)],PA),re("click",N,()=>{setTimeout(()=>n()(g(U)))}),iA(F,N)});var x=gA(L),y=F=>{var U=HUA(),T=gA($(U),2),N=$(T);Ee(()=>Et(N,"(and ".concat(g(A)-100," more errors)"))),iA(F,U)};MA(x,F=>{g(A)>100&&F(y)}),iA(Q,u)},E=Q=>{var u=PUA(),v=$(u),L=$(v),x=$(L);Si($(x),{data:r1});var y=$(gA(x));Si($(gA(y)),{data:FS}),Ee(F=>{var U;xt(L,1,"jse-validation-".concat(F??""),"svelte-1uindol"),Et(y,"".concat((U=g(A))!==null&&U!==void 0?U:""," validation errors "))},[()=>{return F=i(),[bl.error,bl.warning,bl.info].find(U=>F.some(T=>T.severity===U));var F}],PA),re("click",L,s),iA(Q,u)};MA(d,Q=>{g(o)||g(A)===1?Q(B):Q(E,!1)}),iA(I,C)};MA(c,I=>{sn(i())||I(l)}),iA(t,a),at()}function By(t,e){if(t)return t.addEventListener("keydown",A),{destroy(){t.removeEventListener("keydown",A)}};function A(i){i.key==="Escape"&&(i.preventDefault(),i.stopPropagation(),e())}}vt(`/* over all fonts, sizes, and colors */
/* "consolas" for Windows, "menlo" for Mac with fallback to "monaco", 'Ubuntu Mono' for Ubuntu */
/* (at Mac this font looks too large at 14px, but 13px is too small for the font on Windows) */
/* main, menu, modal */
/* jsoneditor modal */
/* tooltip in text mode */
/* panels: navigation bar, gutter, search box */
/* navigation-bar */
/* context menu */
/* contents: json key and values */
/* contents: selected or hovered */
/* contents: section of collapsed items in an array */
/* contents: highlighting of search matches */
/* contents: inline tags inside the JSON document */
/* contents: table */
/* controls in modals: inputs, buttons, and \`a\` */
/* messages */
/* svelte-select */
/* color picker */
dialog.jse-modal.svelte-1s9c2ql {
  border-radius: 3px;
  font-size: var(--jse-padding, 10px);
  border: none;
  padding: 0;
  display: flex;
  min-width: 0;
  margin: auto;
  overflow: visible;
  transition: width 0.1s ease-in-out, height 0.1s ease-in-out;
}
dialog.jse-modal.jse-sort-modal.svelte-1s9c2ql {
  width: 400px;
}
dialog.jse-modal.jse-repair-modal.svelte-1s9c2ql {
  width: 600px;
  height: 500px;
}
dialog.jse-modal.jse-jsoneditor-modal.svelte-1s9c2ql {
  width: 800px;
  height: 600px;
}
dialog.jse-modal.jse-transform-modal.svelte-1s9c2ql {
  width: 1200px;
  height: 800px;
}
dialog.jse-modal.jse-fullscreen.svelte-1s9c2ql {
  width: 100%;
  height: 100%;
}
dialog.jse-modal.svelte-1s9c2ql::backdrop {
  background: var(--jse-overlay-background, rgba(0, 0, 0, 0.3));
}
dialog.jse-modal[open].svelte-1s9c2ql {
  animation: svelte-1s9c2ql-zoom 0.3s cubic-bezier(0.34, 1.56, 0.64, 1);
}
dialog.jse-modal[open].svelte-1s9c2ql::backdrop {
  animation: svelte-1s9c2ql-fade 0.2s ease-out;
}
dialog.jse-modal.svelte-1s9c2ql .jse-modal-inner:where(.svelte-1s9c2ql) {
  flex: 1;
  display: flex;
  flex-direction: column;
  min-width: 0;
  min-height: 0;
  padding: 0;
  font-family: var(--jse-font-family, -apple-system, BlinkMacSystemFont, "Segoe UI", Roboto, Oxygen-Sans, Ubuntu, Cantarell, "Helvetica Neue", sans-serif);
  font-size: var(--jse-font-size, 16px);
  line-height: normal;
  background: var(--jse-modal-background, #f5f5f5);
  color: var(--jse-text-color, #4d4d4d);
}
@keyframes svelte-1s9c2ql-zoom {
  from {
    transform: scale(0.95);
  }
  to {
    transform: scale(1);
  }
}
@keyframes svelte-1s9c2ql-fade {
  from {
    opacity: 0;
  }
  to {
    opacity: 1;
  }
}
dialog.jse-modal.svelte-1s9c2ql .svelte-select {
  --border: var(--jse-svelte-select-border, 1px solid #d8dbdf);
  --item-is-active-bg: var(--jse-item-is-active-bg, #3883fa);
  --border-radius: var(--jse-svelte-select-border-radius, 3px);
  --background: var(--jse-svelte-select-background, #fff);
  --padding: var(--jse-svelte-select-padding, 0 10px);
  --multi-select-padding: var(--jse-svelte-select-multi-select-padding, 0 10px);
  --font-size: var(--jse-svelte-select-font-size, var(--jse-font-size, 16px));
  --height: 36px;
  --multi-item-height: 28px;
  --multi-item-margin: 2px;
  --multi-item-padding: 2px 8px;
  --multi-item-border-radius: 6px;
  --indicator-top: 8px;
}`);var qUA=pA('<dialog><div class="jse-modal-inner svelte-1s9c2ql"><!></div></dialog>');function U3(t,e){st(e,!1);var A=k(e,"className",8,void 0),i=k(e,"fullscreen",8,!1),n=k(e,"onClose",8),o=X();function r(){n()()}ls(()=>g(o).showModal()),Tc(()=>g(o).close()),Rt();var s,a=qUA(),c=$(a);xo($(c),e,"default",{},null),to(a,l=>b(o,l),()=>g(o)),Nr(()=>re("close",a,r)),Nr(()=>{return re("pointerdown",a,(l=r,function(){for(var I=arguments.length,C=new Array(I),d=0;d<I;d++)C[d]=arguments[d];C[0].target===this&&l?.apply(this,C)}));var l}),Nr(()=>re("cancel",a,S1(function(l){m3.call(this,e,l)}))),bs(a,(l,I)=>By?.(l,I),()=>r),Ee((l,I)=>s=xt(a,1,l,"svelte-1s9c2ql",s,I),[()=>T1(lh("jse-modal",A())),()=>({"jse-fullscreen":i()})],PA),iA(t,a),at()}vt(`/* over all fonts, sizes, and colors */
/* "consolas" for Windows, "menlo" for Mac with fallback to "monaco", 'Ubuntu Mono' for Ubuntu */
/* (at Mac this font looks too large at 14px, but 13px is too small for the font on Windows) */
/* main, menu, modal */
/* jsoneditor modal */
/* tooltip in text mode */
/* panels: navigation bar, gutter, search box */
/* navigation-bar */
/* context menu */
/* contents: json key and values */
/* contents: selected or hovered */
/* contents: section of collapsed items in an array */
/* contents: highlighting of search matches */
/* contents: inline tags inside the JSON document */
/* contents: table */
/* controls in modals: inputs, buttons, and \`a\` */
/* messages */
/* svelte-select */
/* color picker */
.jse-modal-contents.svelte-189qksl {
  flex: 1;
  display: flex;
  flex-direction: column;
  padding: 20px;
  overflow: auto;
  min-width: 0;
  min-height: 0;
}
.jse-modal-contents.svelte-189qksl .jse-actions:where(.svelte-189qksl) {
  display: flex;
  flex-direction: row;
  justify-content: flex-end;
  padding-top: var(--jse-padding, 10px);
}
.jse-modal-contents.svelte-189qksl .jse-actions:where(.svelte-189qksl) button.jse-primary:where(.svelte-189qksl) {
  border: none;
  background: transparent;
  color: inherit;
  cursor: pointer;
  font-family: var(--jse-font-family, -apple-system, BlinkMacSystemFont, "Segoe UI", Roboto, Oxygen-Sans, Ubuntu, Cantarell, "Helvetica Neue", sans-serif);
  font-size: var(--jse-font-size, 16px);
  padding: 5px;
  margin: 0;
  background: var(--jse-button-primary-background, var(--jse-theme-color, #3883fa));
  color: var(--jse-button-primary-color, #fff);
  padding: var(--jse-padding, 10px) calc(2 * var(--jse-padding, 10px));
  border-radius: 3px;
}
.jse-modal-contents.svelte-189qksl .jse-actions:where(.svelte-189qksl) button.jse-primary:where(.svelte-189qksl):hover {
  background: var(--jse-button-primary-background-highlight, var(--jse-theme-color-highlight, #5f9dff));
}
.jse-modal-contents.svelte-189qksl .jse-actions:where(.svelte-189qksl) button.jse-primary:where(.svelte-189qksl):disabled {
  background: var(--jse-button-primary-background-disabled, #9d9d9d);
}

.jse-shortcuts.svelte-189qksl {
  display: flex;
  flex-wrap: wrap;
  justify-content: space-around;
  margin: calc(2 * var(--jse-padding, 10px)) 0;
}
.jse-shortcuts.svelte-189qksl .jse-shortcut:where(.svelte-189qksl) .jse-key:where(.svelte-189qksl) {
  font-size: 200%;
  color: var(--jse-theme-color, #3883fa);
}`);var VUA=pA('<!> <div class="jse-modal-contents svelte-189qksl"><div>Clipboard permission is disabled by your browser. You can use:</div> <div class="jse-shortcuts svelte-189qksl"><div class="jse-shortcut svelte-189qksl"><div class="jse-key svelte-189qksl"></div> for copy</div> <div class="jse-shortcut svelte-189qksl"><div class="jse-key svelte-189qksl"></div> for cut</div> <div class="jse-shortcut svelte-189qksl"><div class="jse-key svelte-189qksl"></div> for paste</div></div> <div class="jse-actions svelte-189qksl"><button type="button" class="jse-primary svelte-189qksl">Close</button></div></div>',1);function XsA(t,e){st(e,!1);var A=k(e,"onClose",9),i=T_()?"\u2318":"Ctrl";Rt(!0),U3(t,{get onClose(){return A()},className:"jse-copy-paste",children:(n,o)=>{var r=VUA(),s=Bt(r);dy(s,{title:"Copying and pasting",get onClose(){return A()}});var a=gA(s,2),c=gA($(a),2),l=$(c);$(l).textContent="".concat(i,"+C");var I=gA(l,2);$(I).textContent="".concat(i,"+X"),$(gA(I,2)).textContent="".concat(i,"+V"),re("click",$(gA(c,2)),function(){for(var C,d=arguments.length,B=new Array(d),E=0;E<d;E++)B[E]=arguments[E];(C=A())===null||C===void 0||C.apply(this,B)}),iA(n,r)},$$slots:{default:!0}}),at()}vt(`/* over all fonts, sizes, and colors */
/* "consolas" for Windows, "menlo" for Mac with fallback to "monaco", 'Ubuntu Mono' for Ubuntu */
/* (at Mac this font looks too large at 14px, but 13px is too small for the font on Windows) */
/* main, menu, modal */
/* jsoneditor modal */
/* tooltip in text mode */
/* panels: navigation bar, gutter, search box */
/* navigation-bar */
/* context menu */
/* contents: json key and values */
/* contents: selected or hovered */
/* contents: section of collapsed items in an array */
/* contents: highlighting of search matches */
/* contents: inline tags inside the JSON document */
/* contents: table */
/* controls in modals: inputs, buttons, and \`a\` */
/* messages */
/* svelte-select */
/* color picker */
.jse-menu.svelte-pf7s2l {
  background: var(--jse-theme-color, #3883fa);
  font-family: var(--jse-font-family, -apple-system, BlinkMacSystemFont, "Segoe UI", Roboto, Oxygen-Sans, Ubuntu, Cantarell, "Helvetica Neue", sans-serif);
  font-size: var(--jse-font-size-main-menu, 14px);
  color: var(--jse-menu-color, var(--jse-text-color-inverse, #fff));
  display: flex;
  flex-wrap: wrap;
  align-items: stretch;
  position: relative;
}
.jse-menu.svelte-pf7s2l .jse-button:where(.svelte-pf7s2l) {
  font-family: inherit;
  font-size: inherit;
  line-height: 1.5em;
  border: none;
  background: transparent;
  color: inherit;
  cursor: pointer;
  width: var(--jse-menu-button-size, 32px);
  height: var(--jse-menu-button-size, 32px);
  padding: calc(0.5 * var(--jse-padding, 10px));
  margin: 0;
  border-radius: 0;
  display: inline-flex;
  align-items: center;
  text-align: center;
  justify-content: center;
}
.jse-menu.svelte-pf7s2l .jse-button:where(.svelte-pf7s2l):hover, .jse-menu.svelte-pf7s2l .jse-button:where(.svelte-pf7s2l):focus {
  background: var(--jse-theme-color-highlight, #5f9dff);
}
.jse-menu.svelte-pf7s2l .jse-button:where(.svelte-pf7s2l):disabled {
  color: var(--jse-menu-color, var(--jse-text-color-inverse, #fff));
  opacity: 0.5;
  background: transparent;
}
.jse-menu.svelte-pf7s2l .jse-button.jse-group-button:where(.svelte-pf7s2l) {
  width: auto;
  height: calc(var(--jse-menu-button-size, 32px) - var(--jse-padding, 10px));
  margin: calc(0.5 * var(--jse-padding, 10px)) 0;
  padding: 0 calc(0.5 * var(--jse-padding, 10px)) 1px;
  border: 1px solid var(--jse-menu-color, var(--jse-text-color-inverse, #fff));
}
.jse-menu.svelte-pf7s2l .jse-button.jse-group-button:where(.svelte-pf7s2l):not(.jse-last) {
  border-right: none;
}
.jse-menu.svelte-pf7s2l .jse-button.jse-group-button.jse-first:where(.svelte-pf7s2l) {
  margin-left: calc(0.5 * var(--jse-padding, 10px));
}
.jse-menu.svelte-pf7s2l .jse-button.jse-group-button.jse-last:where(.svelte-pf7s2l) {
  margin-right: calc(0.5 * var(--jse-padding, 10px));
}
.jse-menu.svelte-pf7s2l .jse-button.jse-group-button:where(.svelte-pf7s2l):hover, .jse-menu.svelte-pf7s2l .jse-button.jse-group-button:where(.svelte-pf7s2l):focus {
  background: var(--jse-theme-color-highlight, #5f9dff);
}
.jse-menu.svelte-pf7s2l .jse-button.jse-group-button.jse-selected:where(.svelte-pf7s2l) {
  background: var(--jse-menu-color, var(--jse-text-color-inverse, #fff));
  color: var(--jse-theme-color, #3883fa);
}
.jse-menu.svelte-pf7s2l .jse-space:where(.svelte-pf7s2l) {
  flex: 1;
}
.jse-menu.svelte-pf7s2l .jse-separator:where(.svelte-pf7s2l) {
  background: var(--jse-menu-color, var(--jse-text-color-inverse, #fff));
  opacity: 0.3;
  width: 1px;
  margin: 3px;
}`);var ZUA=pA('<div class="jse-separator svelte-pf7s2l"></div>'),WUA=pA('<div class="jse-space svelte-pf7s2l"></div>'),XUA=pA('<button type="button"><!> <!></button>'),$UA=pA('<div class="jse-menu svelte-pf7s2l"><!> <!> <!></div>');function Ly(t,e){st(e,!1);var A=k(e,"items",25,()=>[]);Rt(!0);var i=$UA(),n=$(i);xo(n,e,"left",{},null);var o=gA(n,2);Fo(o,1,A,Zo,(r,s)=>{var a=po(),c=Bt(a),l=C=>{iA(C,ZUA())},I=(C,d)=>{var B=Q=>{iA(Q,WUA())},E=(Q,u)=>{var v=x=>{var y=XUA(),F=$(y),U=K=>{Si(K,{get data(){return g(s).icon}})};MA(F,K=>{g(s).icon&&K(U)});var T=gA(F,2),N=K=>{var H=_r();Ee(()=>Et(H,g(s).text)),iA(K,H)};MA(T,K=>{g(s).text&&K(N)}),Ee(()=>{var K;xt(y,1,"jse-button ".concat((K=g(s).className)!==null&&K!==void 0?K:""),"svelte-pf7s2l"),en(y,"title",g(s).title),y.disabled=g(s).disabled||!1}),re("click",y,function(){for(var K,H=arguments.length,j=new Array(H),IA=0;IA<H;IA++)j[IA]=arguments[IA];(K=g(s).onClick)===null||K===void 0||K.apply(this,j)}),iA(x,y)},L=x=>{var y=_r();Ee(F=>Et(y,F),[()=>function(F){return console.error("Unknown type of menu item",F),"???"}(g(s))],PA),iA(x,y)};MA(Q,x=>{y3(g(s))?x(v):x(L,!1)},u)};MA(C,Q=>{psA(g(s))?Q(B):Q(E,!1)},d)};MA(c,C=>{qD(g(s))?C(l):C(I,!1)}),iA(r,a)}),xo(gA(o,2),e,"right",{},null),iA(t,i),at()}vt(`/* over all fonts, sizes, and colors */
/* "consolas" for Windows, "menlo" for Mac with fallback to "monaco", 'Ubuntu Mono' for Ubuntu */
/* (at Mac this font looks too large at 14px, but 13px is too small for the font on Windows) */
/* main, menu, modal */
/* jsoneditor modal */
/* tooltip in text mode */
/* panels: navigation bar, gutter, search box */
/* navigation-bar */
/* context menu */
/* contents: json key and values */
/* contents: selected or hovered */
/* contents: section of collapsed items in an array */
/* contents: highlighting of search matches */
/* contents: inline tags inside the JSON document */
/* contents: table */
/* controls in modals: inputs, buttons, and \`a\` */
/* messages */
/* svelte-select */
/* color picker */
.jse-json-repair-component.svelte-3golau {
  flex: 1;
  display: flex;
  flex-direction: column;
  background: var(--jse-background-color, #fff);
  color: var(--jse-text-color, #4d4d4d);
}
.jse-json-repair-component.svelte-3golau .jse-info:where(.svelte-3golau) {
  padding: calc(0.5 * var(--jse-padding, 10px));
  font-family: var(--jse-font-family, -apple-system, BlinkMacSystemFont, "Segoe UI", Roboto, Oxygen-Sans, Ubuntu, Cantarell, "Helvetica Neue", sans-serif);
  font-size: var(--jse-font-size, 16px);
  vertical-align: center;
}
.jse-json-repair-component.svelte-3golau .jse-json-text:where(.svelte-3golau) {
  flex: 1;
  border: none;
  padding: 2px;
  font-family: var(--jse-font-family-mono, consolas, menlo, monaco, "Ubuntu Mono", "source-code-pro", monospace);
  font-size: var(--jse-font-size-mono, 14px);
  background: var(--jse-input-background, var(--jse-background-color, #fff));
  color: var(--jse-text-color, #4d4d4d);
  resize: none;
  outline: none;
}`);var AKA=pA('<div slot="left" class="jse-info svelte-3golau">Repair invalid JSON, then click apply</div>'),eKA=pA('<div class="jse-json-repair-component svelte-3golau"><!> <!> <textarea class="jse-json-text svelte-3golau" autocomplete="off" autocapitalize="off" spellcheck="false"></textarea></div>');function tKA(t,e){st(e,!1);var A=X(void 0,!0),i=X(void 0,!0),n=X(void 0,!0),o=X(void 0,!0),r=X(void 0,!0),s=X(void 0,!0),a=k(e,"text",13,""),c=k(e,"readOnly",9,!1),l=k(e,"onParse",9),I=k(e,"onRepair",9),C=k(e,"onChange",9,void 0),d=k(e,"onApply",9),B=k(e,"onCancel",9),E=wr("jsoneditor:JSONRepair"),Q=X(void 0,!0);function u(){if(g(Q)&&g(A)){var H=g(A).position!==void 0?g(A).position:0;g(Q).setSelectionRange(H,H),g(Q).focus()}}function v(){d()(a())}function L(){try{a(I()(a())),C()&&C()(a())}catch{}}var x=X(void 0,!0);fA(()=>W(a()),()=>{b(A,function(H){try{return void l()(H)}catch(j){return XE(H,j.message)}}(a()))}),fA(()=>W(a()),()=>{b(i,function(H){try{return I()(H),!0}catch{return!1}}(a()))}),fA(()=>g(A),()=>{E("error",g(A))}),fA(()=>W(B()),()=>{b(x,[{type:"space"},{type:"button",icon:Wu,title:"Cancel repair",className:"jse-cancel",onClick:B()}])}),fA(()=>GS,()=>{b(n,{icon:GS,text:"Show me",title:"Scroll to the error location",onClick:u})}),fA(()=>M0,()=>{b(o,{icon:M0,text:"Auto repair",title:"Automatically repair JSON",onClick:L})}),fA(()=>(g(i),g(n),g(o)),()=>{b(r,g(i)?[g(n),g(o)]:[g(n)])}),fA(()=>W(c()),()=>{b(s,[{icon:a5,text:"Apply",title:"Apply fixed JSON",disabled:c(),onClick:v}])}),nn(),Rt(!0);var y=eKA(),F=$(y);Ly(F,{get items(){return g(x)},$$slots:{left:(H,j)=>{iA(H,AKA())}}});var U=gA(F,2),T=H=>{var j=PA(()=>"Cannot parse JSON: ".concat(g(A).message));Cc(H,{type:"error",icon:r1,get message(){return g(j)},get actions(){return g(r)}})},N=H=>{Cc(H,{type:"success",message:"JSON is valid now and can be parsed.",get actions(){return g(s)}})};MA(U,H=>{g(A)?H(T):H(N,!1)});var K=gA(U,2);to(K,H=>b(Q,H),()=>g(Q)),Ee(()=>{K.readOnly=c(),GC(K,a())}),re("input",K,function(H){E("handleChange");var j=H.target.value;a()!==j&&(a(j),C()&&C()(a()))}),iA(t,y),at()}function $sA(t,e){st(e,!1);var A=k(e,"text",13),i=k(e,"onParse",9),n=k(e,"onRepair",9),o=k(e,"onApply",9),r=k(e,"onClose",9);function s(c){o()(c),r()()}function a(){r()()}Rt(!0),U3(t,{get onClose(){return r()},className:"jse-repair-modal",children:(c,l)=>{tKA(c,{get onParse(){return i()},get onRepair(){return n()},onApply:s,onCancel:a,get text(){return A()},set text(I){A(I)},$$legacy:!0})},$$slots:{default:!0}}),at()}vt(`/* over all fonts, sizes, and colors */
/* "consolas" for Windows, "menlo" for Mac with fallback to "monaco", 'Ubuntu Mono' for Ubuntu */
/* (at Mac this font looks too large at 14px, but 13px is too small for the font on Windows) */
/* main, menu, modal */
/* jsoneditor modal */
/* tooltip in text mode */
/* panels: navigation bar, gutter, search box */
/* navigation-bar */
/* context menu */
/* contents: json key and values */
/* contents: selected or hovered */
/* contents: section of collapsed items in an array */
/* contents: highlighting of search matches */
/* contents: inline tags inside the JSON document */
/* contents: table */
/* controls in modals: inputs, buttons, and \`a\` */
/* messages */
/* svelte-select */
/* color picker */
div.jse-collapsed-items.svelte-1h6hzoq {
  margin-left: calc(var(--level) * var(--jse-indent-size, calc(1em + 4px)));
  font-family: var(--jse-font-family, -apple-system, BlinkMacSystemFont, "Segoe UI", Roboto, Oxygen-Sans, Ubuntu, Cantarell, "Helvetica Neue", sans-serif);
  font-size: var(--jse-font-size, 16px);
  color: var(--jse-collapsed-items-link-color, rgba(0, 0, 0, 0.38));
  padding: calc(0.5 * var(--jse-padding, 10px));
  border: 8px solid transparent;
  border-width: 8px 0;
  background-color: var(--jse-contents-background-color, transparent);
  background-image: linear-gradient(var(--jse-collapsed-items-background-color, #f5f5f5), var(--jse-collapsed-items-background-color, #f5f5f5)), linear-gradient(to bottom right, transparent 50.5%, var(--jse-collapsed-items-background-color, #f5f5f5) 50.5%), linear-gradient(to bottom left, transparent 50.5%, var(--jse-collapsed-items-background-color, #f5f5f5) 50.5%), linear-gradient(to top right, transparent 50.5%, var(--jse-collapsed-items-background-color, #f5f5f5) 50.5%), linear-gradient(to top left, transparent 50.5%, var(--jse-collapsed-items-background-color, #f5f5f5) 50.5%);
  background-repeat: repeat, repeat-x, repeat-x, repeat-x, repeat-x;
  background-position: 0 0, 8px 0, 8px 0, 8px 100%, 8px 100%;
  background-size: auto auto, 16px 16px, 16px 16px, 16px 16px, 16px 16px;
  background-clip: padding-box, border-box, border-box, border-box, border-box;
  background-origin: padding-box, border-box, border-box, border-box, border-box;
  display: flex;
}
div.jse-collapsed-items.jse-selected.svelte-1h6hzoq {
  background-color: var(--jse-selection-background-color, #d3d3d3);
  --jse-collapsed-items-background-color: var(--jse-collapsed-items-selected-background-color, #c2c2c2);
}
div.jse-collapsed-items.svelte-1h6hzoq div.jse-text:where(.svelte-1h6hzoq),
div.jse-collapsed-items.svelte-1h6hzoq button.jse-expand-items:where(.svelte-1h6hzoq) {
  margin: 0 calc(0.5 * var(--jse-padding, 10px));
}
div.jse-collapsed-items.svelte-1h6hzoq div.jse-text:where(.svelte-1h6hzoq) {
  display: inline;
}
div.jse-collapsed-items.svelte-1h6hzoq button.jse-expand-items:where(.svelte-1h6hzoq) {
  font-family: inherit;
  font-size: inherit;
  color: var(--jse-collapsed-items-link-color, rgba(0, 0, 0, 0.38));
  background: none;
  border: none;
  padding: 0;
  text-decoration: underline;
  cursor: pointer;
}
div.jse-collapsed-items.svelte-1h6hzoq button.jse-expand-items:where(.svelte-1h6hzoq):hover, div.jse-collapsed-items.svelte-1h6hzoq button.jse-expand-items:where(.svelte-1h6hzoq):focus {
  color: var(--jse-collapsed-items-link-color-highlight, #ee5341);
}`);var iKA=pA('<button type="button" class="jse-expand-items svelte-1h6hzoq"> </button>'),nKA=pA('<div role="none"><div><div class="jse-text svelte-1h6hzoq"> </div> <!></div></div>');function oKA(t,e){st(e,!1);var A=X(void 0,!0),i=X(void 0,!0),n=X(void 0,!0),o=X(void 0,!0),r=X(void 0,!0),s=k(e,"visibleSections",9),a=k(e,"sectionIndex",9),c=k(e,"total",9),l=k(e,"path",9),I=k(e,"selection",9),C=k(e,"onExpandSection",9),d=k(e,"context",9);fA(()=>(W(s()),W(a())),()=>{b(A,s()[a()])}),fA(()=>g(A),()=>{b(i,g(A).end)}),fA(()=>(W(s()),W(a()),W(c())),()=>{b(n,s()[a()+1]?s()[a()+1].start:c())}),fA(()=>(W(d()),W(I()),W(l()),g(i)),()=>{b(o,N3(d().getJson(),I(),l().concat(String(g(i)))))}),fA(()=>(g(i),g(n)),()=>{b(r,function(x,y){var F={start:x,end:Math.min(g_(x),y)},U=Math.max(ny((x+y)/2),x),T={start:U,end:Math.min(g_(U),y)},N=ny(y),K=N===y?N-R3:N,H={start:Math.max(K,x),end:y},j=[F],IA=T.start>=F.end&&T.end<=H.start;return IA&&j.push(T),H.start>=(IA?T.end:F.end)&&j.push(H),j}(g(i),g(n)))}),nn(),Rt(!0);var B,E,Q=nKA(),u=$(Q),v=$(u),L=$(v);Fo(gA(v,2),1,()=>g(r),Zo,(x,y)=>{var F=iKA(),U=$(F);Ee(()=>{var T,N;return Et(U,"show ".concat((T=g(y).start)!==null&&T!==void 0?T:"","-").concat((N=g(y).end)!==null&&N!==void 0?N:""))}),re("click",F,()=>C()(l(),g(y))),iA(x,F)}),Ee(x=>{var y,F;B=xt(Q,1,"jse-collapsed-items svelte-1h6hzoq",null,B,x),E=vl(Q,"",E,{"--level":l().length+2}),Et(L,"Items ".concat((y=g(i))!==null&&y!==void 0?y:"","-").concat((F=g(n))!==null&&F!==void 0?F:""))},[()=>({"jse-selected":g(o)})],PA),re("mousemove",Q,function(x){x.stopPropagation()}),iA(t,Q),at()}vt(`/* over all fonts, sizes, and colors */
/* "consolas" for Windows, "menlo" for Mac with fallback to "monaco", 'Ubuntu Mono' for Ubuntu */
/* (at Mac this font looks too large at 14px, but 13px is too small for the font on Windows) */
/* main, menu, modal */
/* jsoneditor modal */
/* tooltip in text mode */
/* panels: navigation bar, gutter, search box */
/* navigation-bar */
/* context menu */
/* contents: json key and values */
/* contents: selected or hovered */
/* contents: section of collapsed items in an array */
/* contents: highlighting of search matches */
/* contents: inline tags inside the JSON document */
/* contents: table */
/* controls in modals: inputs, buttons, and \`a\` */
/* messages */
/* svelte-select */
/* color picker */
.jse-context-menu-pointer.svelte-137iwnw {
  position: absolute;
  top: calc(-0.5 * var(--jse-context-menu-pointer-size, calc(1em + 4px)));
  right: calc(-0.5 * var(--jse-context-menu-pointer-size, calc(1em + 4px)));
  width: var(--jse-context-menu-pointer-size, calc(1em + 4px));
  height: var(--jse-context-menu-pointer-size, calc(1em + 4px));
  padding: 0;
  margin: 0;
  cursor: pointer;
  background: transparent;
  border-radius: 2px;
  background: var(--jse-context-menu-pointer-hover-background, #b2b2b2);
  color: var(--jse-context-menu-pointer-color, var(--jse-context-menu-color, var(--jse-text-color-inverse, #fff)));
  border: none;
  box-shadow: var(--jse-controls-box-shadow, 0 2px 6px 0 rgba(0, 0, 0, 0.24));
}
.jse-context-menu-pointer.jse-root.svelte-137iwnw {
  top: 0;
  right: calc(-2px - var(--jse-context-menu-pointer-size, calc(1em + 4px)));
}
.jse-context-menu-pointer.jse-insert.svelte-137iwnw {
  right: -1px;
}
.jse-context-menu-pointer.svelte-137iwnw:hover {
  background: var(--jse-context-menu-pointer-background-highlight, var(--jse-context-menu-background-highlight, #7a7a7a));
}
.jse-context-menu-pointer.jse-selected.svelte-137iwnw {
  background: var(--jse-context-menu-pointer-background, var(--jse-context-menu-background, #656565));
}
.jse-context-menu-pointer.jse-selected.svelte-137iwnw:hover {
  background: var(--jse-context-menu-pointer-background-highlight, var(--jse-context-menu-background-highlight, #7a7a7a));
}`);var rKA=pA('<button type="button"><!></button>');function R1(t,e){st(e,!1);var A=k(e,"root",9,!1),i=k(e,"insert",9,!1),n=k(e,"selected",9),o=k(e,"onContextMenu",9);Rt(!0);var r,s=rKA();en(s,"title",H_),Si($(s),{data:k0}),Ee(a=>r=xt(s,1,"jse-context-menu-pointer svelte-137iwnw",null,r,a),[()=>({"jse-root":A(),"jse-insert":i(),"jse-selected":n()})],PA),re("click",s,function(a){for(var c=a.target;c&&c.nodeName!=="BUTTON";)c=c.parentNode;c&&o()({anchor:c,left:0,top:0,width:O0,height:H0,offsetTop:2,offsetLeft:0,showTip:!0})}),iA(t,s),at()}vt(`/* over all fonts, sizes, and colors */
/* "consolas" for Windows, "menlo" for Mac with fallback to "monaco", 'Ubuntu Mono' for Ubuntu */
/* (at Mac this font looks too large at 14px, but 13px is too small for the font on Windows) */
/* main, menu, modal */
/* jsoneditor modal */
/* tooltip in text mode */
/* panels: navigation bar, gutter, search box */
/* navigation-bar */
/* context menu */
/* contents: json key and values */
/* contents: selected or hovered */
/* contents: section of collapsed items in an array */
/* contents: highlighting of search matches */
/* contents: inline tags inside the JSON document */
/* contents: table */
/* controls in modals: inputs, buttons, and \`a\` */
/* messages */
/* svelte-select */
/* color picker */
.jse-key.svelte-2iqnqn {
  display: inline-block;
  min-width: 2em;
  padding: 0 5px;
  box-sizing: border-box;
  outline: none;
  border-radius: 1px;
  vertical-align: top;
  color: var(--jse-key-color, #1a1a1a);
  word-break: normal;
  overflow-wrap: normal;
  white-space: pre-wrap;
}
.jse-key.jse-empty.svelte-2iqnqn {
  min-width: 3em;
  outline: 1px dotted var(--jse-tag-background, rgba(0, 0, 0, 0.2));
  -moz-outline-radius: 2px;
}
.jse-key.jse-empty.svelte-2iqnqn::after {
  pointer-events: none;
  color: var(--jse-tag-background, rgba(0, 0, 0, 0.2));
  content: "key";
}`);var sKA=pA('<div role="none" data-type="selectable-key"><!></div>'),aKA=pA("<!> <!>",1),cKA=pA('<div role="button" tabindex="-1" class="jse-value" data-type="selectable-value"></div>');function AaA(t,e){st(e,!0);var A=ba(()=>dn(e.selection)&&Ma(e.selection)),i=ba(()=>e.context.onRenderValue({path:e.path,value:e.value,mode:e.context.mode,truncateTextSize:e.context.truncateTextSize,readOnly:e.context.readOnly,enforceString:e.enforceString,isEditing:g(A),parser:e.context.parser,normalization:e.context.normalization,selection:e.selection,searchResultItems:e.searchResultItems,onPatch:e.context.onPatch,onPasteJson:e.context.onPasteJson,onSelect:e.context.onSelect,onFind:e.context.onFind,findNextInside:e.context.findNextInside,focus:e.context.focus})),n=po();Fo(Bt(n),17,()=>g(i),Zo,(o,r)=>{var s=po(),a=Bt(s),c=I=>{var C=cKA(),d=ba(()=>g(r).action);bs(C,(B,E)=>{var Q;return(Q=g(d))===null||Q===void 0?void 0:Q(B,E)},()=>g(r).props),iA(I,C)},l=I=>{var C=po(),d=ba(()=>g(r).component);esA(Bt(C),()=>g(d),(B,E)=>{E(B,U1(()=>g(r).props))}),iA(I,C)};MA(a,I=>{RGA(g(r))?I(c):I(l,!1)}),iA(o,s)}),iA(t,n),at()}var lKA={selecting:!1,selectionAnchor:void 0,selectionAnchorType:void 0,selectionFocus:void 0,dragging:!1};function HN(t){var{json:e,selection:A,deltaY:i,items:n}=t;if(!A)return{operations:void 0,updatedSelection:void 0,offset:0};var o=i<0?function(l){for(var{json:I,items:C,selection:d,deltaY:B}=l,E=P0(I,d),Q=C.findIndex(F=>Ei(F.path,E)),u=()=>{var F;return(F=C[v-1])===null||F===void 0?void 0:F.height},v=Q,L=0;u()!==void 0&&Math.abs(B)>L+u()/2;)L+=u(),v-=1;var x=C[v].path,y=v-Q;return v!==Q&&C[v]!==void 0?{beforePath:x,offset:y}:void 0}({json:e,selection:A,deltaY:i,items:n}):function(l){for(var I,{json:C,items:d,selection:B,deltaY:E}=l,Q=Y1(C,B),u=d.findIndex(K=>Ei(K.path,Q)),v=0,L=u,x=()=>{var K;return(K=d[L+1])===null||K===void 0?void 0:K.height};x()!==void 0&&Math.abs(E)>v+x()/2;)v+=x(),L+=1;var y=pi(Q),F=Fe(C,y),U=Array.isArray(F)?L:L+1,T=(I=d[U])===null||I===void 0?void 0:I.path,N=L-u;return T?{beforePath:T,offset:N}:{append:!0,offset:N}}({json:e,selection:A,deltaY:i,items:n});if(!o||o.offset===0)return{operations:void 0,updatedSelection:void 0,offset:0};var r=function(l,I,C){if(!I)return[];var d="beforePath"in C?C.beforePath:void 0,B="append"in C?C.append:void 0,E=pi(je(I)),Q=Fe(l,E);if(!(B||d&&e2(d,E)&&d.length>E.length))return[];var u=P0(l,I),v=Y1(l,I),L=ri(u),x=ri(v),y=d?d[E.length]:void 0;if(!Mo(Q)){if(ao(Q)){var F=jr(L),U=jr(x),T=y!==void 0?jr(y):Q.length;return vS(U-F+1,T<F?IA=>({op:"move",from:nt(E.concat(String(F+IA))),path:nt(E.concat(String(T+IA)))}):()=>({op:"move",from:nt(E.concat(String(F))),path:nt(E.concat(String(T)))}))}throw new Error("Cannot create move operations: parent must be an Object or Array")}var N=Object.keys(Q),K=N.indexOf(L),H=N.indexOf(x),j=B?N.length:y!==void 0?N.indexOf(y):-1;return K!==-1&&H!==-1&&j!==-1?j>K?[...N.slice(K,H+1),...N.slice(j,N.length)].map(IA=>YC(E,IA)):[...N.slice(j,K),...N.slice(H+1,N.length)].map(IA=>YC(E,IA)):[]}(e,A,o),s=pi(P0(e,A)),a=Fe(e,s);if(Array.isArray(a)){var c=function(l){var I,C,{items:d,json:B,selection:E,offset:Q}=l,u=P0(B,E),v=Y1(B,E),L=d.findIndex(U=>Ei(U.path,u)),x=d.findIndex(U=>Ei(U.path,v)),y=(I=d[L+Q])===null||I===void 0?void 0:I.path,F=(C=d[x+Q])===null||C===void 0?void 0:C.path;return ys(y,F)}({items:n,json:e,selection:A,offset:o.offset});return{operations:r,updatedSelection:c,offset:o.offset}}return{operations:r,updatedSelection:void 0,offset:o.offset}}vt(`/* over all fonts, sizes, and colors */
/* "consolas" for Windows, "menlo" for Mac with fallback to "monaco", 'Ubuntu Mono' for Ubuntu */
/* (at Mac this font looks too large at 14px, but 13px is too small for the font on Windows) */
/* main, menu, modal */
/* jsoneditor modal */
/* tooltip in text mode */
/* panels: navigation bar, gutter, search box */
/* navigation-bar */
/* context menu */
/* contents: json key and values */
/* contents: selected or hovered */
/* contents: section of collapsed items in an array */
/* contents: highlighting of search matches */
/* contents: inline tags inside the JSON document */
/* contents: table */
/* controls in modals: inputs, buttons, and \`a\` */
/* messages */
/* svelte-select */
/* color picker */
button.jse-validation-error.svelte-1a8aobl {
  border: none;
  background: transparent;
  color: inherit;
  cursor: pointer;
  font-family: var(--jse-font-family, -apple-system, BlinkMacSystemFont, "Segoe UI", Roboto, Oxygen-Sans, Ubuntu, Cantarell, "Helvetica Neue", sans-serif);
  font-size: var(--jse-font-size, 16px);
  padding: 5px;
  margin: 0;
  padding: 0;
  margin: 0;
  vertical-align: top;
  display: inline-flex;
  color: var(--jse-error-color, #ee5341);
}

button.jse-validation-info.svelte-1a8aobl {
  border: none;
  background: transparent;
  color: inherit;
  cursor: pointer;
  font-family: var(--jse-font-family, -apple-system, BlinkMacSystemFont, "Segoe UI", Roboto, Oxygen-Sans, Ubuntu, Cantarell, "Helvetica Neue", sans-serif);
  font-size: var(--jse-font-size, 16px);
  padding: 5px;
  margin: 0;
  padding: 0;
  margin: 0;
  vertical-align: top;
  display: inline-flex;
  color: var(--jse-info-color, #4f91ff);
}

button.jse-validation-warning.svelte-1a8aobl {
  border: none;
  background: transparent;
  color: inherit;
  cursor: pointer;
  font-family: var(--jse-font-family, -apple-system, BlinkMacSystemFont, "Segoe UI", Roboto, Oxygen-Sans, Ubuntu, Cantarell, "Helvetica Neue", sans-serif);
  font-size: var(--jse-font-size, 16px);
  padding: 5px;
  margin: 0;
  padding: 0;
  margin: 0;
  vertical-align: top;
  display: inline-flex;
  color: var(--jse-warning-color, #fdc539);
}`);var gKA=pA('<button type="button"><!></button>');function VE(t,e){st(e,!1);var A=X(),i=H1("absolute-popup"),n=k(e,"validationError",8),o=k(e,"onExpand",8);fA(()=>W(n()),()=>{b(A,SGA(n())&&n().isChildError?"Contains invalid data":n().message)}),nn(),Rt();var r=gKA();Si($(r),{data:r1}),Nr(()=>re("click",r,function(){for(var s,a=arguments.length,c=new Array(a),l=0;l<a;l++)c[l]=arguments[l];(s=o())===null||s===void 0||s.apply(this,c)})),bs(r,(s,a)=>eh?.(s,a),()=>Be({text:g(A)},i)),Ee(()=>{var s;return xt(r,1,"jse-validation-".concat((s=n().severity)!==null&&s!==void 0?s:""),"svelte-1a8aobl")}),iA(t,r),at()}vt(`/* over all fonts, sizes, and colors */
/* "consolas" for Windows, "menlo" for Mac with fallback to "monaco", 'Ubuntu Mono' for Ubuntu */
/* (at Mac this font looks too large at 14px, but 13px is too small for the font on Windows) */
/* main, menu, modal */
/* jsoneditor modal */
/* tooltip in text mode */
/* panels: navigation bar, gutter, search box */
/* navigation-bar */
/* context menu */
/* contents: json key and values */
/* contents: selected or hovered */
/* contents: section of collapsed items in an array */
/* contents: highlighting of search matches */
/* contents: inline tags inside the JSON document */
/* contents: table */
/* controls in modals: inputs, buttons, and \`a\` */
/* messages */
/* svelte-select */
/* color picker */
.jse-expand.svelte-oawf7x {
  width: var(--jse-indent-size, calc(1em + 4px));
  padding: 0;
  margin: 0;
  border: none;
  cursor: pointer;
  background: transparent;
  color: var(--jse-delimiter-color, rgba(0, 0, 0, 0.38));
  font-size: var(--jse-font-size-mono, 14px);
  height: var(--jse-line-height, calc(1em + 4px));
}
.jse-expand.svelte-oawf7x:hover {
  opacity: 0.8;
}

.jse-meta.svelte-oawf7x,
.jse-separator.svelte-oawf7x,
.jse-index.svelte-oawf7x,
.jse-bracket.svelte-oawf7x {
  vertical-align: top;
  color: var(--jse-delimiter-color, rgba(0, 0, 0, 0.38));
}

.jse-index.svelte-oawf7x {
  padding: 0 calc(0.5 * var(--jse-padding, 10px));
}

.jse-bracket.svelte-oawf7x {
  padding: 0 2px;
}
.jse-bracket.jse-expanded.svelte-oawf7x {
  padding-right: var(--jse-padding, 10px);
}

.jse-identifier.svelte-oawf7x {
  vertical-align: top;
  position: relative;
}

.jse-json-node.svelte-oawf7x {
  position: relative;
  color: var(--jse-text-color, #4d4d4d);
}
.jse-json-node.jse-root.svelte-oawf7x {
  min-height: 100%;
  padding-bottom: 2px;
  box-sizing: border-box;
}
.jse-json-node.jse-root.svelte-oawf7x > .jse-contents-outer:where(.svelte-oawf7x) > .jse-contents:where(.svelte-oawf7x) {
  padding-left: 0;
}
.jse-json-node.svelte-oawf7x .jse-props:where(.svelte-oawf7x),
.jse-json-node.svelte-oawf7x .jse-items:where(.svelte-oawf7x) {
  position: relative;
}
.jse-json-node.svelte-oawf7x .jse-header-outer:where(.svelte-oawf7x),
.jse-json-node.svelte-oawf7x .jse-footer-outer:where(.svelte-oawf7x) {
  display: flex;
  margin-left: calc(var(--level) * var(--jse-indent-size, calc(1em + 4px)));
}
.jse-json-node.svelte-oawf7x .jse-header:where(.svelte-oawf7x) {
  position: relative;
}
.jse-json-node.svelte-oawf7x .jse-header:where(.svelte-oawf7x) .jse-meta:where(.svelte-oawf7x) > .jse-meta-inner:where(.svelte-oawf7x) {
  display: flex;
  justify-content: center;
}
.jse-json-node.svelte-oawf7x .jse-contents-outer:where(.svelte-oawf7x) {
  display: flex;
  margin-left: calc(var(--level) * var(--jse-indent-size, calc(1em + 4px)));
}
.jse-json-node.svelte-oawf7x .jse-header:where(.svelte-oawf7x),
.jse-json-node.svelte-oawf7x .jse-contents:where(.svelte-oawf7x) {
  display: flex;
  flex-direction: row;
  align-items: flex-start;
}
.jse-json-node.svelte-oawf7x .jse-contents:where(.svelte-oawf7x) {
  padding-left: var(--jse-indent-size, calc(1em + 4px));
  cursor: var(--jse-contents-cursor, pointer);
}
.jse-json-node.svelte-oawf7x .jse-contents:where(.svelte-oawf7x) .jse-value-outer:where(.svelte-oawf7x) {
  display: inline-flex;
}
.jse-json-node.svelte-oawf7x .jse-footer:where(.svelte-oawf7x) {
  display: inline-flex;
  padding-left: calc(var(--jse-indent-size, calc(1em + 4px)) + 5px);
}
.jse-json-node.svelte-oawf7x .jse-header:where(.svelte-oawf7x),
.jse-json-node.svelte-oawf7x .jse-contents:where(.svelte-oawf7x),
.jse-json-node.svelte-oawf7x .jse-footer:where(.svelte-oawf7x) {
  background: var(--jse-contents-background-color, transparent);
}
.jse-json-node.svelte-oawf7x .jse-insert-selection-area:where(.svelte-oawf7x) {
  padding: 0 calc(0.5 * var(--jse-padding, 10px));
  flex: 1;
}
.jse-json-node.svelte-oawf7x .jse-insert-selection-area.jse-inside:where(.svelte-oawf7x) {
  display: inline-flex;
  align-items: center;
}
.jse-json-node.svelte-oawf7x .jse-insert-selection-area.jse-after:where(.svelte-oawf7x) {
  display: flex;
  align-items: flex-end;
}
.jse-json-node.svelte-oawf7x .jse-context-menu-pointer-anchor:where(.svelte-oawf7x) {
  position: relative;
}
.jse-json-node.svelte-oawf7x .jse-insert-area:where(.svelte-oawf7x) {
  display: flex;
  position: relative;
  z-index: 1;
  margin-left: calc(var(--level) * var(--jse-indent-size, calc(1em + 4px)));
  max-width: 250px;
  min-width: 100px;
  height: 0;
  margin-right: calc(0.5 * var(--jse-padding, 10px));
  outline: 1px solid;
}
.jse-json-node.svelte-oawf7x .jse-insert-area.jse-hovered:where(.svelte-oawf7x) {
  outline-color: var(--jse-context-menu-pointer-hover-background, #b2b2b2);
}
.jse-json-node.svelte-oawf7x .jse-key-outer:where(.svelte-oawf7x) {
  position: relative;
}
.jse-json-node.svelte-oawf7x .jse-key-outer:where(.svelte-oawf7x):hover,
.jse-json-node.svelte-oawf7x .jse-value-outer:where(.svelte-oawf7x):hover,
.jse-json-node.svelte-oawf7x .jse-meta:where(.svelte-oawf7x):hover,
.jse-json-node.svelte-oawf7x .jse-footer:where(.svelte-oawf7x):hover {
  background: var(--jse-hover-background-color, rgba(0, 0, 0, 0.06));
  cursor: var(--jse-contents-cursor, pointer);
}
.jse-json-node.jse-hovered.svelte-oawf7x:not(.jse-selected):not(.jse-selected-value) .jse-value-outer,
.jse-json-node.jse-hovered.svelte-oawf7x:not(.jse-selected):not(.jse-selected-value) .jse-meta,
.jse-json-node.jse-hovered.svelte-oawf7x:not(.jse-selected):not(.jse-selected-value) .jse-items .jse-header,
.jse-json-node.jse-hovered.svelte-oawf7x:not(.jse-selected):not(.jse-selected-value) .jse-items .jse-contents,
.jse-json-node.jse-hovered.svelte-oawf7x:not(.jse-selected):not(.jse-selected-value) .jse-props .jse-header,
.jse-json-node.jse-hovered.svelte-oawf7x:not(.jse-selected):not(.jse-selected-value) .jse-props .jse-contents,
.jse-json-node.jse-hovered.svelte-oawf7x:not(.jse-selected):not(.jse-selected-value) .jse-footer {
  background: var(--jse-hover-background-color, rgba(0, 0, 0, 0.06));
  cursor: var(--jse-contents-cursor, pointer);
}
.jse-json-node.jse-hovered.svelte-oawf7x:not(.jse-selected):not(.jse-selected-value) .jse-value-outer .jse-value-outer,
.jse-json-node.jse-hovered.svelte-oawf7x:not(.jse-selected):not(.jse-selected-value) .jse-value-outer .jse-meta,
.jse-json-node.jse-hovered.svelte-oawf7x:not(.jse-selected):not(.jse-selected-value) .jse-meta .jse-value-outer,
.jse-json-node.jse-hovered.svelte-oawf7x:not(.jse-selected):not(.jse-selected-value) .jse-meta .jse-meta,
.jse-json-node.jse-hovered.svelte-oawf7x:not(.jse-selected):not(.jse-selected-value) .jse-items .jse-header .jse-value-outer,
.jse-json-node.jse-hovered.svelte-oawf7x:not(.jse-selected):not(.jse-selected-value) .jse-items .jse-header .jse-meta,
.jse-json-node.jse-hovered.svelte-oawf7x:not(.jse-selected):not(.jse-selected-value) .jse-items .jse-contents .jse-value-outer,
.jse-json-node.jse-hovered.svelte-oawf7x:not(.jse-selected):not(.jse-selected-value) .jse-items .jse-contents .jse-meta,
.jse-json-node.jse-hovered.svelte-oawf7x:not(.jse-selected):not(.jse-selected-value) .jse-props .jse-header .jse-value-outer,
.jse-json-node.jse-hovered.svelte-oawf7x:not(.jse-selected):not(.jse-selected-value) .jse-props .jse-header .jse-meta,
.jse-json-node.jse-hovered.svelte-oawf7x:not(.jse-selected):not(.jse-selected-value) .jse-props .jse-contents .jse-value-outer,
.jse-json-node.jse-hovered.svelte-oawf7x:not(.jse-selected):not(.jse-selected-value) .jse-props .jse-contents .jse-meta,
.jse-json-node.jse-hovered.svelte-oawf7x:not(.jse-selected):not(.jse-selected-value) .jse-footer .jse-value-outer,
.jse-json-node.jse-hovered.svelte-oawf7x:not(.jse-selected):not(.jse-selected-value) .jse-footer .jse-meta {
  background: none;
}
.jse-json-node.jse-selected.svelte-oawf7x .jse-header:where(.svelte-oawf7x),
.jse-json-node.jse-selected.svelte-oawf7x .jse-contents:where(.svelte-oawf7x),
.jse-json-node.jse-selected.svelte-oawf7x .jse-footer:where(.svelte-oawf7x) {
  background: var(--jse-selection-background-color, #d3d3d3);
  cursor: var(--jse-contents-selected-cursor, grab);
}
.jse-json-node.jse-selected.svelte-oawf7x .jse-key-outer:where(.svelte-oawf7x):hover,
.jse-json-node.jse-selected.svelte-oawf7x .jse-value-outer:where(.svelte-oawf7x):hover,
.jse-json-node.jse-selected.svelte-oawf7x .jse-meta:where(.svelte-oawf7x):hover,
.jse-json-node.jse-selected.svelte-oawf7x .jse-footer:where(.svelte-oawf7x):hover {
  background: inherit;
  cursor: inherit;
}
.jse-json-node.svelte-oawf7x .jse-key-outer.jse-selected-key:where(.svelte-oawf7x) {
  background: var(--jse-selection-background-color, #d3d3d3);
  cursor: var(--jse-contents-selected-cursor, grab);
}
.jse-json-node.jse-selected-value.svelte-oawf7x .jse-value-outer,
.jse-json-node.jse-selected-value.svelte-oawf7x .jse-meta,
.jse-json-node.jse-selected-value.svelte-oawf7x .jse-items .jse-header,
.jse-json-node.jse-selected-value.svelte-oawf7x .jse-items .jse-contents,
.jse-json-node.jse-selected-value.svelte-oawf7x .jse-props .jse-header,
.jse-json-node.jse-selected-value.svelte-oawf7x .jse-props .jse-contents,
.jse-json-node.jse-selected-value.svelte-oawf7x .jse-footer {
  background: var(--jse-selection-background-color, #d3d3d3);
  cursor: var(--jse-contents-selected-cursor, grab);
}
.jse-json-node.jse-selected-value.svelte-oawf7x .jse-value-outer .jse-key-outer:hover,
.jse-json-node.jse-selected-value.svelte-oawf7x .jse-meta .jse-key-outer:hover,
.jse-json-node.jse-selected-value.svelte-oawf7x .jse-items .jse-header .jse-key-outer:hover,
.jse-json-node.jse-selected-value.svelte-oawf7x .jse-items .jse-contents .jse-key-outer:hover,
.jse-json-node.jse-selected-value.svelte-oawf7x .jse-props .jse-header .jse-key-outer:hover,
.jse-json-node.jse-selected-value.svelte-oawf7x .jse-props .jse-contents .jse-key-outer:hover,
.jse-json-node.jse-selected-value.svelte-oawf7x .jse-footer .jse-key-outer:hover {
  background: inherit;
  cursor: inherit;
}
.jse-json-node.jse-readonly.svelte-oawf7x {
  --jse-contents-selected-cursor: pointer;
}
.jse-json-node.svelte-oawf7x .jse-insert-area.jse-selected:where(.svelte-oawf7x) {
  outline-color: var(--jse-context-menu-pointer-background, var(--jse-context-menu-background, #656565));
}`);var $n=Dy(()=>lKA),IKA=pA('<div class="jse-separator svelte-oawf7x">:</div>'),CKA=pA('<div class="jse-bracket svelte-oawf7x">[</div> <!> &nbsp;',1),dKA=pA('<div class="jse-bracket svelte-oawf7x">[</div> <!> <div class="jse-bracket svelte-oawf7x">]</div>',1),BKA=pA('<div class="jse-context-menu-pointer-anchor svelte-oawf7x"><!></div>'),EKA=pA('<div role="none" class="jse-insert-selection-area jse-inside svelte-oawf7x" data-type="insert-selection-area-inside"></div>'),hKA=pA('<div role="none" class="jse-insert-selection-area jse-after svelte-oawf7x" data-type="insert-selection-area-after"></div>'),QKA=pA('<div data-type="insert-selection-area-inside"><!></div>'),uKA=pA('<div slot="identifier" class="jse-identifier svelte-oawf7x"><div class="jse-index svelte-oawf7x"> </div></div>'),fKA=pA("<!> <!>",1),mKA=pA('<div role="none" class="jse-insert-selection-area jse-after svelte-oawf7x" data-type="insert-selection-area-after"></div>'),pKA=pA('<div class="jse-items svelte-oawf7x"><!> <!></div> <div class="jse-footer-outer svelte-oawf7x"><div data-type="selectable-value" class="jse-footer svelte-oawf7x"><span class="jse-bracket svelte-oawf7x">]</span></div> <!></div>',1),wKA=pA('<div class="jse-header-outer svelte-oawf7x"><div class="jse-header svelte-oawf7x"><button type="button" class="jse-expand svelte-oawf7x" title="Expand or collapse this array (Ctrl+Click to expand/collapse recursively)"><!></button> <!> <!> <div class="jse-meta svelte-oawf7x"><div class="jse-meta-inner svelte-oawf7x" data-type="selectable-value"><!></div></div> <!></div> <!> <!></div> <!>',1),DKA=pA('<div class="jse-separator svelte-oawf7x">:</div>'),yKA=pA('<div class="jse-bracket jse-expanded svelte-oawf7x">&lbrace;</div>'),vKA=pA('<div class="jse-bracket svelte-oawf7x">&lbrace;</div> <!> <div class="jse-bracket svelte-oawf7x">&rbrace;</div>',1),bKA=pA('<div class="jse-context-menu-pointer-anchor svelte-oawf7x"><!></div>'),MKA=pA('<div role="none" class="jse-insert-selection-area jse-inside svelte-oawf7x" data-type="insert-selection-area-inside"></div>'),kKA=pA('<div role="none" class="jse-insert-selection-area jse-after svelte-oawf7x" data-type="insert-selection-area-after"></div>'),SKA=pA('<div data-type="insert-selection-area-inside"><!></div>'),RKA=pA('<div slot="identifier"><!></div>'),LKA=pA('<div role="none" class="jse-insert-selection-area jse-after svelte-oawf7x" data-type="insert-selection-area-after"></div>'),xKA=pA('<div class="jse-props svelte-oawf7x"><!> <!></div> <div class="jse-footer-outer svelte-oawf7x"><div data-type="selectable-value" class="jse-footer svelte-oawf7x"><div class="jse-bracket svelte-oawf7x">&rbrace;</div></div> <!></div>',1),FKA=pA('<div class="jse-header-outer svelte-oawf7x"><div class="jse-header svelte-oawf7x"><button type="button" class="jse-expand svelte-oawf7x" title="Expand or collapse this object (Ctrl+Click to expand/collapse recursively)"><!></button> <!> <!> <div class="jse-meta svelte-oawf7x" data-type="selectable-value"><div class="jse-meta-inner svelte-oawf7x"><!></div></div> <!></div> <!> <!></div> <!>',1),NKA=pA('<div class="jse-separator svelte-oawf7x">:</div>'),_KA=pA('<div class="jse-context-menu-pointer-anchor svelte-oawf7x"><!></div>'),GKA=pA('<div role="none" class="jse-insert-selection-area jse-after svelte-oawf7x" data-type="insert-selection-area-after"></div>'),UKA=pA('<div class="jse-contents-outer svelte-oawf7x"><div class="jse-contents svelte-oawf7x"><!> <!> <div class="jse-value-outer svelte-oawf7x"><!></div> <!></div> <!> <!></div>'),KKA=pA('<div data-type="insert-selection-area-after"><!></div>'),YKA=pA('<div role="treeitem" tabindex="-1"><!> <!></div>');function p_(t,e){st(e,!1);var A=X(void 0,!0),i=X(void 0,!0),n=k(e,"pointer",9),o=k(e,"value",9),r=k(e,"state",9),s=k(e,"validationErrors",9),a=k(e,"searchResults",9),c=k(e,"selection",9),l=k(e,"context",9),I=k(e,"onDragSelectionStart",9),C=wr("jsoneditor:JSONNode"),d=X(void 0,!0),B=void 0,E=X(void 0,!0),Q=X(void 0,!0),u=X(void 0,!0),v=X(void 0,!0),L=X(void 0,!0),x=X(void 0,!0),y=X(void 0,!0);function F(hA){hA.stopPropagation();var eA=z_(hA);l().onExpand(g(Q),!g(u),eA)}function U(){l().onExpand(g(Q),!0)}function T(hA,eA){var RA=Z3(g(Q),Object.keys(o()),hA,eA);return l().onPatch(RA),ri(da(RA[0].path))}function N(hA){l().onDrag(hA)}function K(hA){$n().selecting&&($n($n().selecting=!1),hA.stopPropagation()),l().onDragEnd(),document.removeEventListener("mousemove",N,!0),document.removeEventListener("mouseup",K)}function H(){var hA;return((hA=l().findElement([]))===null||hA===void 0||(hA=hA.getBoundingClientRect())===null||hA===void 0?void 0:hA.top)||0}function j(hA,eA){var RA=H()-hA.initialContentTop;return eA.clientY-hA.initialClientY-RA}function IA(hA){if(!l().readOnly&&c()){var eA=pi(je(c()));if(Ei(g(Q),eA)){var RA=function(w,D){var O=[];function Z(G){var Y=g(Q).concat(G),AA=l().findElement(Y);AA!==void 0&&O.push({path:Y,height:AA.clientHeight})}if(Array.isArray(o())){var q=l().getJson();if(q===void 0)return;var CA=P0(q,w),kA=Y1(q,w),KA=parseInt(ri(CA),10),Ie=parseInt(ri(kA),10),GA=D.find(G=>KA>=G.start&&Ie<=G.end);if(!GA)return;var{start:oe,end:M}=GA;ssA(oe,Math.min(o().length,M),G=>Z(String(G)))}else Object.keys(o()).forEach(Z);return O}(c(),g(L)||PE);if(C("dragSelectionStart",{selection:c(),items:RA}),RA){var oA=l().getJson();if(oA!==void 0){var ne=P0(oA,c()),h=RA.findIndex(w=>Ei(w.path,ne)),{offset:f}=HN({json:oA,selection:l().getSelection(),deltaY:0,items:RA});b(E,{initialTarget:hA.target,initialClientY:hA.clientY,initialContentTop:H(),selectionStartIndex:h,selectionItemsCount:z1(oA,c()).length,items:RA,offset:f,didMoveItems:!1}),$n($n().dragging=!0),document.addEventListener("mousemove",lA,!0),document.addEventListener("mouseup",uA)}}else C("Cannot drag the current selection (probably spread over multiple sections)")}else I()(hA)}}function lA(hA){if(g(E)){var eA=l().getJson();if(eA===void 0)return;var RA=j(g(E),hA),{offset:oA}=HN({json:eA,selection:l().getSelection(),deltaY:RA,items:g(E).items});oA!==g(E).offset&&(C("drag selection",oA,RA),b(E,Be(Be({},g(E)),{},{offset:oA,didMoveItems:!0})))}}function uA(hA){if(g(E)){var eA=l().getJson();if(eA===void 0)return;var RA=j(g(E),hA),{operations:oA,updatedSelection:ne}=HN({json:eA,selection:l().getSelection(),deltaY:RA,items:g(E).items});if(oA)l().onPatch(oA,(w,D)=>({state:D,selection:ne??c()}));else if(hA.target===g(E).initialTarget&&!g(E).didMoveItems){var h=kN(hA.target),f=fsA(hA.target);f&&l().onSelect(ArA(h,f))}b(E,void 0),$n($n().dragging=!1),document.removeEventListener("mousemove",lA,!0),document.removeEventListener("mouseup",uA)}}function p(hA){hA.shiftKey||(hA.stopPropagation(),hA.preventDefault(),l().onSelect(i2(g(Q))))}function V(hA){hA.shiftKey||(hA.stopPropagation(),hA.preventDefault(),l().onSelect(W0(g(Q))))}function cA(hA){l().onSelect(i2(g(Q))),l().onContextMenu(hA)}function aA(hA){l().onSelect(W0(g(Q))),l().onContextMenu(hA)}fA(()=>W(n()),()=>{b(Q,da(n()))}),fA(()=>W(n()),()=>{b(A,encodeURIComponent(n()))}),fA(()=>W(r()),()=>{b(u,!!UC(r())&&r().expanded)}),fA(()=>(W(o()),W(r())),()=>{b(v,Z0(o(),r(),[]))}),fA(()=>W(r()),()=>{b(L,cs(r())?r().visibleSections:void 0)}),fA(()=>W(s()),()=>{var hA;b(x,(hA=s())===null||hA===void 0?void 0:hA.validationError)}),fA(()=>(W(l()),W(c()),g(Q)),()=>{b(y,N3(l().getJson(),c(),g(Q)))}),fA(()=>g(Q),()=>{b(i,g(Q).length===0)}),nn(),Rt(!0);var jA,VA,ce=YKA(),EA=$(ce),sA=hA=>{var eA=wKA(),RA=Bt(eA),oA=$(RA),ne=$(oA),h=$(ne),f=yA=>{Si(yA,{data:k0})},w=yA=>{Si(yA,{data:qB})};MA(h,yA=>{g(u)?yA(f):yA(w,!1)});var D=gA(ne,2);xo(D,e,"identifier",{},null);var O=gA(D,2),Z=yA=>{iA(yA,IKA())};MA(O,yA=>{g(i)||yA(Z)});var q=gA(O,2),CA=$(q),kA=$(CA),KA=yA=>{var DA=CKA();ZD(gA(Bt(DA),2),{children:(We,be)=>{var qA=_r();Ee(()=>{var It;return Et(qA,"".concat((It=o().length)!==null&&It!==void 0?It:"",`
                `).concat(o().length===1?"item":"items"))}),iA(We,qA)},$$slots:{default:!0}}),iA(yA,DA)},Ie=yA=>{var DA=dKA();ZD(gA(Bt(DA),2),{onclick:U,children:(We,be)=>{var qA=_r();Ee(()=>{var It;return Et(qA,"".concat((It=o().length)!==null&&It!==void 0?It:"",`
                `).concat(o().length===1?"item":"items"))}),iA(We,qA)},$$slots:{default:!0}}),iA(yA,DA)};MA(kA,yA=>{g(u)?yA(KA):yA(Ie,!1)});var GA=gA(q,2),oe=yA=>{var DA=BKA();R1($(DA),{get root(){return g(i)},selected:!0,get onContextMenu(){return l().onContextMenu}}),iA(yA,DA)};MA(GA,yA=>{!l().readOnly&&g(y)&&c()&&(dn(c())||Ao(c()))&&!Ma(c())&&Ei(je(c()),g(Q))&&yA(oe)});var M=gA(oA,2),G=yA=>{VE(yA,{get validationError(){return g(x)},onExpand:U})};MA(M,yA=>{!g(x)||g(u)&&g(x).isChildError||yA(G)});var Y=gA(M,2),AA=yA=>{var DA=EKA();re("click",DA,p),iA(yA,DA)},dA=yA=>{var DA=hKA();re("click",DA,V),iA(yA,DA)};MA(Y,yA=>{g(u)?yA(AA):yA(dA,!1)});var WA=gA(RA,2),Qe=yA=>{var DA=pKA(),We=Bt(DA),be=$(We),qA=Hi=>{var Ci,Zi,Qi=QKA();en(Qi,"title",RN);var Ft=$(Qi),Tt=PA(()=>g(y)&&as(c()));R1(Ft,{insert:!0,get selected(){return g(Tt)},onContextMenu:cA}),Ee(Ht=>{Ci=xt(Qi,1,"jse-insert-area jse-inside svelte-oawf7x",null,Ci,Ht),Zi=vl(Qi,"",Zi,{"--level":g(Q).length+1})},[()=>({"jse-hovered":g(d)===Q3,"jse-selected":g(y)&&as(c())})],PA),iA(Hi,Qi)};MA(be,Hi=>{!l().readOnly&&(g(d)===Q3||g(y)&&as(c()))&&Hi(qA)}),Fo(gA(be,2),1,()=>g(L)||PE,Zo,(Hi,Ci,Zi)=>{var Qi=fKA(),Ft=Bt(Qi);Fo(Ft,1,()=>function(zi,ui,Ye){var Ai=ui.start,ei=Math.min(ui.end,zi.length),Oi=i5(Ai,ei);return Ye&&Ye.offset!==0?NoA(Oi,Ye.selectionStartIndex,Ye.selectionItemsCount,Ye.offset).map((Yn,Dn)=>({index:Yn,gutterIndex:Dn})):Oi.map(Yn=>({index:Yn,gutterIndex:Yn}))}(o(),g(Ci),g(E)),zi=>zi.index,(zi,ui)=>{var Ye=po(),Ai=PA(()=>cs(s())?s().items[g(ui).index]:void 0),ei=PA(()=>erA(l().getJson(),c(),g(Q).concat(String(g(ui).index)))),Oi=Bt(Ye),Yn=PA(()=>eS(n(),g(ui).index)),Dn=PA(()=>cs(r())?r().items[g(ui).index]:void 0),Ho=PA(()=>cs(a())?a().items[g(ui).index]:void 0);p_(Oi,{get value(){return o()[g(ui).index]},get pointer(){return g(Yn)},get state(){return g(Dn)},get validationErrors(){return g(Ai)},get searchResults(){return g(Ho)},get selection(){return g(ei)},get context(){return l()},onDragSelectionStart:IA,$$slots:{identifier:(Sn,io)=>{var Wo=uKA(),No=$(Wo),Jn=$(No);Ee(()=>Et(Jn,g(ui).gutterIndex)),iA(Sn,Wo)}}}),iA(zi,Ye)});var Tt=gA(Ft,2),Ht=zi=>{var ui=PA(()=>g(L)||PE);oKA(zi,{get visibleSections(){return g(ui)},sectionIndex:Zi,get total(){return o().length},get path(){return g(Q)},get onExpandSection(){return l().onExpandSection},get selection(){return c()},get context(){return l()}})};MA(Tt,zi=>{g(Ci).end<o().length&&zi(Ht)}),iA(Hi,Qi)});var It=gA(We,2),Vi=gA($(It),2),on=Hi=>{var Ci=mKA();re("click",Ci,V),iA(Hi,Ci)};MA(Vi,Hi=>{g(i)||Hi(on)}),iA(yA,DA)};MA(WA,yA=>{g(u)&&yA(Qe)}),re("click",ne,F),iA(hA,eA)},TA=(hA,eA)=>{var RA=ne=>{var h=FKA(),f=Bt(h),w=$(f),D=$(w),O=$(D),Z=qA=>{Si(qA,{data:k0})},q=qA=>{Si(qA,{data:qB})};MA(O,qA=>{g(u)?qA(Z):qA(q,!1)});var CA=gA(D,2);xo(CA,e,"identifier",{},null);var kA=gA(CA,2),KA=qA=>{iA(qA,DKA())};MA(kA,qA=>{g(i)||qA(KA)});var Ie=gA(kA,2),GA=$(Ie),oe=$(GA),M=qA=>{iA(qA,yKA())},G=qA=>{var It=vKA();ZD(gA(Bt(It),2),{onclick:U,children:(Vi,on)=>{var Hi=_r();Ee((Ci,Zi)=>Et(Hi,"".concat(Ci??"",`
                `).concat(Zi??"")),[()=>Object.keys(o()).length,()=>Object.keys(o()).length===1?"prop":"props"],PA),iA(Vi,Hi)},$$slots:{default:!0}}),iA(qA,It)};MA(oe,qA=>{g(u)?qA(M):qA(G,!1)});var Y=gA(Ie,2),AA=qA=>{var It=bKA();R1($(It),{get root(){return g(i)},selected:!0,get onContextMenu(){return l().onContextMenu}}),iA(qA,It)};MA(Y,qA=>{!l().readOnly&&g(y)&&c()&&(dn(c())||Ao(c()))&&!Ma(c())&&Ei(je(c()),g(Q))&&qA(AA)});var dA=gA(w,2),WA=qA=>{VE(qA,{get validationError(){return g(x)},onExpand:U})};MA(dA,qA=>{!g(x)||g(u)&&g(x).isChildError||qA(WA)});var Qe=gA(dA,2),yA=qA=>{var It=MKA();re("click",It,p),iA(qA,It)},DA=(qA,It)=>{var Vi=on=>{var Hi=kKA();re("click",Hi,V),iA(on,Hi)};MA(qA,on=>{g(i)||on(Vi)},It)};MA(Qe,qA=>{g(u)?qA(yA):qA(DA,!1)});var We=gA(f,2),be=qA=>{var It=xKA(),Vi=Bt(It),on=$(Vi),Hi=Ft=>{var Tt,Ht,zi=SKA();en(zi,"title",RN);var ui=$(zi),Ye=PA(()=>g(y)&&as(c()));R1(ui,{insert:!0,get selected(){return g(Ye)},onContextMenu:cA}),Ee(Ai=>{Tt=xt(zi,1,"jse-insert-area jse-inside svelte-oawf7x",null,Tt,Ai),Ht=vl(zi,"",Ht,{"--level":g(Q).length+1})},[()=>({"jse-hovered":g(d)===Q3,"jse-selected":g(y)&&as(c())})],PA),iA(Ft,zi)};MA(on,Ft=>{!l().readOnly&&(g(d)===Q3||g(y)&&as(c()))&&Ft(Hi)}),Fo(gA(on,2),1,()=>function(Ft,Tt){var Ht=Object.keys(Ft);return Tt&&Tt.offset!==0?NoA(Ht,Tt.selectionStartIndex,Tt.selectionItemsCount,Tt.offset):Ht}(o(),g(E)),Zo,(Ft,Tt)=>{var Ht=po(),zi=PA(()=>eS(n(),g(Tt))),ui=PA(()=>kl(a())?a().properties[g(Tt)]:void 0),Ye=PA(()=>kl(s())?s().properties[g(Tt)]:void 0),Ai=PA(()=>g(Q).concat(g(Tt))),ei=PA(()=>erA(l().getJson(),c(),g(Ai))),Oi=Bt(Ht),Yn=PA(()=>kl(r())?r().properties[g(Tt)]:void 0);p_(Oi,{get value(){return o()[g(Tt)]},get pointer(){return g(zi)},get state(){return g(Yn)},get validationErrors(){return g(Ye)},get searchResults(){return g(ui)},get selection(){return g(ei)},get context(){return l()},onDragSelectionStart:IA,$$slots:{identifier:(Dn,Ho)=>{var Sn,io=RKA(),Wo=$(io),No=PA(()=>{return Jn=g(ui),(hn=zoA(Jn)?Jn.searchResults.filter(wo=>wo.field===Ml.key):void 0)&&hn.length>0?hn:void 0;var Jn,hn});(function(Jn,hn){st(hn,!1);var wo=X(void 0,!0),se=X(void 0,!0),fi=k(hn,"pointer",9),bA=k(hn,"key",9),fe=k(hn,"selection",9),it=k(hn,"searchResultItems",9),Gt=k(hn,"onUpdateKey",9),Xe=k(hn,"context",9),Ot=X(void 0,!0);function Pi(ii){g(se)||Xe().readOnly||(ii.preventDefault(),Xe().onSelect($_(g(Ot))))}function Jt(ii,Ri){var dt=Gt()(bA(),Xe().normalization.unescapeValue(ii)),zn=pi(g(Ot)).concat(dt);Xe().onSelect(Ri===K1.nextInside?hi(zn):t2(zn)),Ri!==K1.self&&Xe().focus()}function Ki(){Xe().onSelect(t2(g(Ot))),Xe().focus()}fA(()=>W(fi()),()=>{b(Ot,da(fi()))}),fA(()=>(W(fe()),g(Ot)),()=>{b(wo,pr(fe())&&Ei(fe().path,g(Ot)))}),fA(()=>(g(wo),W(fe())),()=>{b(se,g(wo)&&Ma(fe()))}),nn(),Rt(!0);var Ct=aKA(),ti=Bt(Ct),$e=ii=>{var Ri=PA(()=>Xe().normalization.escapeValue(bA())),dt=PA(()=>Ma(fe())?fe().initialValue:void 0);RsA(ii,{get value(){return g(Ri)},get initialValue(){return g(dt)},label:"Edit key",shortText:!0,onChange:Jt,onCancel:Ki,get onFind(){return Xe().onFind}})},Nt=ii=>{var Ri,dt=sKA(),zn=$(dt),QA=Ce=>{var Pt=PA(()=>Xe().normalization.escapeValue(bA()));UsA(Ce,{get text(){return g(Pt)},get searchResultItems(){return it()}})},_A=Ce=>{var Pt=_r();Ee(Li=>Et(Pt,Li),[()=>vy(Xe().normalization.escapeValue(bA()))],PA),iA(Ce,Pt)};MA(zn,Ce=>{it()?Ce(QA):Ce(_A,!1)}),Ee(Ce=>Ri=xt(dt,1,"jse-key svelte-2iqnqn",null,Ri,Ce),[()=>({"jse-empty":bA()===""})],PA),re("dblclick",dt,Pi),iA(ii,dt)};MA(ti,ii=>{!Xe().readOnly&&g(se)?ii($e):ii(Nt,!1)});var Wi=gA(ti,2),Tn=ii=>{R1(ii,{selected:!0,get onContextMenu(){return Xe().onContextMenu}})};MA(Wi,ii=>{Xe().readOnly||!g(wo)||g(se)||ii(Tn)}),iA(Jn,Ct),at()})(Wo,{get pointer(){return g(zi)},get key(){return g(Tt)},get selection(){return g(ei)},get searchResultItems(){return g(No)},get context(){return l()},onUpdateKey:T}),Ee(Jn=>Sn=xt(io,1,"jse-key-outer svelte-oawf7x",null,Sn,Jn),[()=>({"jse-selected-key":pr(g(ei))&&Ei(g(ei).path,g(Ai))})],PA),iA(Dn,io)}}}),iA(Ft,Ht)});var Ci=gA(Vi,2),Zi=gA($(Ci),2),Qi=Ft=>{var Tt=LKA();re("click",Tt,V),iA(Ft,Tt)};MA(Zi,Ft=>{g(i)||Ft(Qi)}),iA(qA,It)};MA(We,qA=>{g(u)&&qA(be)}),re("click",D,F),iA(ne,h)},oA=ne=>{var h=UKA(),f=$(h),w=$(f);xo(w,e,"identifier",{},null);var D=gA(w,2),O=Y=>{iA(Y,NKA())};MA(D,Y=>{g(i)||Y(O)});var Z=gA(D,2),q=$(Z),CA=PA(()=>g(y)?c():void 0),kA=PA(()=>{return Y=a(),(AA=zoA(Y)?Y.searchResults.filter(dA=>dA.field===Ml.value):void 0)&&AA.length>0?AA:void 0;var Y,AA});AaA(q,{get path(){return g(Q)},get value(){return o()},get enforceString(){return g(v)},get selection(){return g(CA)},get searchResultItems(){return g(kA)},get context(){return l()}});var KA=gA(Z,2),Ie=Y=>{var AA=_KA();R1($(AA),{get root(){return g(i)},selected:!0,get onContextMenu(){return l().onContextMenu}}),iA(Y,AA)};MA(KA,Y=>{!l().readOnly&&g(y)&&c()&&(dn(c())||Ao(c()))&&!Ma(c())&&Ei(je(c()),g(Q))&&Y(Ie)});var GA=gA(f,2),oe=Y=>{VE(Y,{get validationError(){return g(x)},onExpand:U})};MA(GA,Y=>{g(x)&&Y(oe)});var M=gA(GA,2),G=Y=>{var AA=GKA();re("click",AA,V),iA(Y,AA)};MA(M,Y=>{g(i)||Y(G)}),iA(ne,h)};MA(hA,ne=>{tn(o())?ne(RA):ne(oA,!1)},eA)};MA(EA,hA=>{Array.isArray(o())?hA(sA):hA(TA,!1)});var Ke=gA(EA,2),Re=hA=>{var eA,RA=KKA();en(RA,"title",RN);var oA=$(RA),ne=PA(()=>g(y)&&Yc(c()));R1(oA,{insert:!0,get selected(){return g(ne)},onContextMenu:aA}),Ee(h=>eA=xt(RA,1,"jse-insert-area jse-after svelte-oawf7x",null,eA,h),[()=>({"jse-hovered":g(d)===LN,"jse-selected":g(y)&&Yc(c())})],PA),iA(hA,RA)};MA(Ke,hA=>{!l().readOnly&&(g(d)===LN||g(y)&&Yc(c()))&&hA(Re)}),Ee((hA,eA)=>{jA=xt(ce,1,hA,"svelte-oawf7x",jA,eA),en(ce,"data-path",g(A)),en(ce,"aria-selected",g(y)),VA=vl(ce,"",VA,{"--level":g(Q).length})},[()=>T1(lh("jse-json-node",{"jse-expanded":g(u)},l().onClassName(g(Q),o()))),()=>({"jse-root":g(i),"jse-selected":g(y)&&Ao(c()),"jse-selected-value":g(y)&&dn(c()),"jse-readonly":l().readOnly,"jse-hovered":g(d)===KoA})],PA),re("mousedown",ce,function(hA){if((hA.buttons===1||hA.buttons===2)&&!((eA=hA.target).nodeName==="DIV"&&eA.contentEditable==="true"||hA.buttons===1&&QsA(hA.target,"BUTTON"))){var eA;hA.stopPropagation(),hA.preventDefault(),l().focus(),document.addEventListener("mousemove",N,!0),document.addEventListener("mouseup",K);var RA=kN(hA.target),oA=l().getJson(),ne=l().getDocumentState();if(!c()||RA===wn.after||RA===wn.inside||c().type!==RA&&c().type!==wn.multi||!N3(oA,c(),g(Q)))if($n($n().selecting=!0),$n($n().selectionAnchor=g(Q)),$n($n().selectionAnchorType=RA),$n($n().selectionFocus=g(Q)),hA.shiftKey){var h=l().getSelection();h&&l().onSelect(ys(SC(h),g(Q)))}else if(RA===wn.multi)if(g(i)&&hA.target.hasAttribute("data-path")){var f=ri(vsA(o(),ne));l().onSelect(C_(f))}else l().onSelect(ys(g(Q),g(Q)));else oA!==void 0&&l().onSelect(ArA(RA,g(Q)));else hA.button===0&&I()(hA)}}),re("mousemove",ce,function(hA){if($n().selecting){hA.preventDefault(),hA.stopPropagation(),$n().selectionFocus===void 0&&window.getSelection&&window.getSelection().empty();var eA=kN(hA.target);Ei(g(Q),$n().selectionFocus)&&eA===$n().selectionAnchorType||($n($n().selectionFocus=g(Q)),$n($n().selectionAnchorType=eA),l().onSelect(ys($n().selectionAnchor||$n().selectionFocus,$n().selectionFocus)))}}),re("mouseover",ce,function(hA){$n().selecting||$n().dragging||(hA.stopPropagation(),F1(hA.target,"data-type","selectable-value")?b(d,KoA):F1(hA.target,"data-type","selectable-key")?b(d,void 0):F1(hA.target,"data-type","insert-selection-area-inside")?b(d,Q3):F1(hA.target,"data-type","insert-selection-area-after")&&b(d,LN),clearTimeout(B))}),re("mouseout",ce,function(hA){hA.stopPropagation(),B=window.setTimeout(()=>b(d,void 0))}),iA(t,ce),at()}var JKA={prefix:"fas",iconName:"jsoneditor-expand",icon:[512,512,[],"","M 0,448 V 512 h 512 v -64 z M 0,0 V 64 H 512 V 0 Z M 256,96 128,224 h 256 z M 256,416 384,288 H 128 Z"]},TKA={prefix:"fas",iconName:"jsoneditor-collapse",icon:[512,512,[],"","m 0,224 v 64 h 512 v -64 z M 256,192 384,64 H 128 Z M 256,320 128,448 h 256 z"]},ErA={prefix:"fas",iconName:"jsoneditor-format",icon:[512,512,[],"","M 0,32 v 64 h 416 v -64 z M 160,160 v 64 h 352 v -64 z M 160,288 v 64 h 288 v -64 z M 0,416 v 64 h 320 v -64 z"]},zKA={prefix:"fas",iconName:"jsoneditor-compact",icon:[512,512,[],"","M 0,32 v 64 h 512 v -64 z M 0,160 v 64 h 512 v -64 z M 0,288 v 64 h 352 v -64 z"]};function HKA(t,e){t.stopPropagation(),e.onCreateObject()}function OKA(t,e){t.stopPropagation(),e.onCreateArray()}vt(`/* over all fonts, sizes, and colors */
/* "consolas" for Windows, "menlo" for Mac with fallback to "monaco", 'Ubuntu Mono' for Ubuntu */
/* (at Mac this font looks too large at 14px, but 13px is too small for the font on Windows) */
/* main, menu, modal */
/* jsoneditor modal */
/* tooltip in text mode */
/* panels: navigation bar, gutter, search box */
/* navigation-bar */
/* context menu */
/* contents: json key and values */
/* contents: selected or hovered */
/* contents: section of collapsed items in an array */
/* contents: highlighting of search matches */
/* contents: inline tags inside the JSON document */
/* contents: table */
/* controls in modals: inputs, buttons, and \`a\` */
/* messages */
/* svelte-select */
/* color picker */
.jse-welcome.svelte-1eamlhk {
  flex: 1;
  overflow: auto;
  font-family: var(--jse-font-family, -apple-system, BlinkMacSystemFont, "Segoe UI", Roboto, Oxygen-Sans, Ubuntu, Cantarell, "Helvetica Neue", sans-serif);
  font-size: var(--jse-font-size, 16px);
  display: flex;
  flex-direction: column;
  align-items: center;
  border-left: var(--jse-main-border, 1px solid #d7d7d7);
  border-right: var(--jse-main-border, 1px solid #d7d7d7);
}
.jse-welcome.svelte-1eamlhk:last-child {
  border-bottom: var(--jse-main-border, 1px solid #d7d7d7);
}
.jse-welcome.svelte-1eamlhk .jse-space.jse-before:where(.svelte-1eamlhk) {
  flex: 1;
}
.jse-welcome.svelte-1eamlhk .jse-space.jse-after:where(.svelte-1eamlhk) {
  flex: 2;
}
.jse-welcome.svelte-1eamlhk .jse-contents:where(.svelte-1eamlhk) {
  display: flex;
  flex-direction: column;
  max-width: 300px;
  margin: 2em var(--jse-padding, 10px);
  gap: var(--jse-padding, 10px);
}
.jse-welcome.svelte-1eamlhk .jse-contents:where(.svelte-1eamlhk) .jse-welcome-info:where(.svelte-1eamlhk) {
  color: var(--jse-panel-color-readonly, #b2b2b2);
}
.jse-welcome.svelte-1eamlhk .jse-contents:where(.svelte-1eamlhk) button:where(.svelte-1eamlhk) {
  border: none;
  background: transparent;
  color: inherit;
  cursor: pointer;
  font-family: var(--jse-font-family, -apple-system, BlinkMacSystemFont, "Segoe UI", Roboto, Oxygen-Sans, Ubuntu, Cantarell, "Helvetica Neue", sans-serif);
  font-size: var(--jse-font-size, 16px);
  padding: 5px;
  margin: 0;
  background: var(--jse-button-primary-background, var(--jse-theme-color, #3883fa));
  color: var(--jse-button-primary-color, #fff);
  padding: var(--jse-padding, 10px) calc(2 * var(--jse-padding, 10px));
  border-radius: 3px;
}
.jse-welcome.svelte-1eamlhk .jse-contents:where(.svelte-1eamlhk) button:where(.svelte-1eamlhk):hover {
  background: var(--jse-button-primary-background-highlight, var(--jse-theme-color-highlight, #5f9dff));
}
.jse-welcome.svelte-1eamlhk .jse-contents:where(.svelte-1eamlhk) button:where(.svelte-1eamlhk):disabled {
  background: var(--jse-button-primary-background-disabled, #9d9d9d);
}`);var PKA=(t,e)=>e.onClick(),jKA=pA('<div class="jse-welcome-info svelte-1eamlhk">You can paste clipboard data using <b>Ctrl+V</b>, or use the following options:</div> <button class="svelte-1eamlhk">Create object</button> <button class="svelte-1eamlhk">Create array</button>',1),qKA=pA('<div class="jse-welcome svelte-1eamlhk" role="none"><div class="jse-space jse-before svelte-1eamlhk"></div> <div class="jse-contents svelte-1eamlhk"><div class="jse-welcome-title">Empty document</div> <!></div> <div class="jse-space jse-after svelte-1eamlhk"></div></div>');function w_(t,e){var A=typeof t=="string"?t.toLowerCase():t,i=typeof e=="string"?e.toLowerCase():e;return(0,mrA.default)(A,i)}function eaA(t){var e=arguments.length>1&&arguments[1]!==void 0?arguments[1]:[],A=arguments.length>2&&arguments[2]!==void 0?arguments[2]:[],i=arguments.length>3&&arguments[3]!==void 0?arguments[3]:1,n=Fe(t,e);if(ao(n)){if(A===void 0)throw new Error("Cannot sort: no property selected by which to sort the array");return function(o){var r=arguments.length>1&&arguments[1]!==void 0?arguments[1]:[],s=arguments.length>2&&arguments[2]!==void 0?arguments[2]:[],a=arguments.length>3&&arguments[3]!==void 0?arguments[3]:1,c=function(I,C){var d={boolean:0,number:1,string:2,undefined:4},B=3;return function(E,Q){var u=Fe(E,I),v=Fe(Q,I);if(typeof u!=typeof v){var L,x,y=(L=d[typeof u])!==null&&L!==void 0?L:B,F=(x=d[typeof v])!==null&&x!==void 0?x:B;return y>F?C:y<F?-C:0}return typeof u=="number"||typeof u=="boolean"?u>v?C:u<v?-C:0:zo(u)?0:C*w_(u,v)}}(s,a),l=Fe(o,r);return[{op:"replace",path:nt(r),value:l.slice(0).sort(c)}]}(t,e,A,i)}if(tn(n))return function(o){var r=arguments.length>1&&arguments[1]!==void 0?arguments[1]:[],s=arguments.length>2&&arguments[2]!==void 0?arguments[2]:1,a=Fe(o,r),c=Object.keys(a).slice();c.sort((I,C)=>s*w_(I,C));var l={};return c.forEach(I=>l[I]=a[I]),[{op:"replace",path:nt(r),value:l}]}(t,e,i);throw new Error("Cannot sort: no array or object")}H3(["click"]);vt(`/* over all fonts, sizes, and colors */
/* "consolas" for Windows, "menlo" for Mac with fallback to "monaco", 'Ubuntu Mono' for Ubuntu */
/* (at Mac this font looks too large at 14px, but 13px is too small for the font on Windows) */
/* main, menu, modal */
/* jsoneditor modal */
/* tooltip in text mode */
/* panels: navigation bar, gutter, search box */
/* navigation-bar */
/* context menu */
/* contents: json key and values */
/* contents: selected or hovered */
/* contents: section of collapsed items in an array */
/* contents: highlighting of search matches */
/* contents: inline tags inside the JSON document */
/* contents: table */
/* controls in modals: inputs, buttons, and \`a\` */
/* messages */
/* svelte-select */
/* color picker */
.jse-navigation-bar-dropdown.svelte-2nnd2m {
  position: absolute;
  top: 100%;
  left: 0;
  z-index: 3;
  background: var(--jse-navigation-bar-background, var(--jse-background-color, #fff));
  color: var(--jse-navigation-bar-dropdown-color, #656565);
  box-shadow: var(--jse-controls-box-shadow, 0 2px 6px 0 rgba(0, 0, 0, 0.24));
  display: flex;
  flex-direction: column;
  max-height: 300px;
  overflow: auto;
  min-width: 80px;
}
.jse-navigation-bar-dropdown.svelte-2nnd2m button.jse-navigation-bar-dropdown-item:where(.svelte-2nnd2m) {
  font-family: var(--jse-font-family-mono, consolas, menlo, monaco, "Ubuntu Mono", "source-code-pro", monospace);
  font-size: var(--jse-font-size-mono, 14px);
  border: none;
  background: transparent;
  color: inherit;
  cursor: pointer;
  outline: none;
  text-align: left;
  white-space: nowrap;
  box-sizing: border-box;
  padding: calc(0.5 * var(--jse-padding, 10px)) 36px;
}
.jse-navigation-bar-dropdown.svelte-2nnd2m button.jse-navigation-bar-dropdown-item:where(.svelte-2nnd2m):focus, .jse-navigation-bar-dropdown.svelte-2nnd2m button.jse-navigation-bar-dropdown-item:where(.svelte-2nnd2m):hover {
  background: var(--jse-navigation-bar-background-highlight, #e5e5e5);
}
.jse-navigation-bar-dropdown.svelte-2nnd2m button.jse-navigation-bar-dropdown-item.jse-selected:where(.svelte-2nnd2m) {
  background: var(--jse-navigation-bar-dropdown-color, #656565);
  color: var(--jse-navigation-bar-background, var(--jse-background-color, #fff));
}`);var VKA=pA('<button type="button"> </button>'),ZKA=pA('<button type="button" class="jse-navigation-bar-dropdown-item svelte-2nnd2m">...</button>'),WKA=pA('<div class="jse-navigation-bar-dropdown svelte-2nnd2m"><!> <!></div>');function XKA(t,e){st(e,!1);var A=k(e,"items",9),i=k(e,"selectedItem",9),n=k(e,"onSelect",9);Rt(!0);var o=WKA(),r=$(o);Fo(r,1,()=>asA(A(),100),c=>c,(c,l)=>{var I,C=VKA(),d=$(C);Ee((B,E,Q)=>{I=xt(C,1,"jse-navigation-bar-dropdown-item svelte-2nnd2m",null,I,B),en(C,"title",E),Et(d,Q)},[()=>({"jse-selected":g(l)===i()}),()=>g(l).toString(),()=>S3(g(l).toString(),30)],PA),re("click",C,z0(()=>n()(g(l)))),iA(c,C)});var s=gA(r,2),a=c=>{var l=ZKA();en(l,"title","Limited to 100 items"),iA(c,l)};MA(s,c=>{A().length>100&&c(a)}),iA(t,o),at()}vt(`/* over all fonts, sizes, and colors */
/* "consolas" for Windows, "menlo" for Mac with fallback to "monaco", 'Ubuntu Mono' for Ubuntu */
/* (at Mac this font looks too large at 14px, but 13px is too small for the font on Windows) */
/* main, menu, modal */
/* jsoneditor modal */
/* tooltip in text mode */
/* panels: navigation bar, gutter, search box */
/* navigation-bar */
/* context menu */
/* contents: json key and values */
/* contents: selected or hovered */
/* contents: section of collapsed items in an array */
/* contents: highlighting of search matches */
/* contents: inline tags inside the JSON document */
/* contents: table */
/* controls in modals: inputs, buttons, and \`a\` */
/* messages */
/* svelte-select */
/* color picker */
.jse-navigation-bar-item.svelte-752ro1 {
  position: relative;
  display: flex;
}
.jse-navigation-bar-item.svelte-752ro1 button.jse-navigation-bar-button:where(.svelte-752ro1) {
  font-family: inherit;
  font-size: inherit;
  padding: calc(0.5 * var(--jse-padding, 10px)) 2px;
  border: none;
  background: transparent;
  color: inherit;
  cursor: pointer;
  outline: none;
  min-width: 2em;
  white-space: nowrap;
}
.jse-navigation-bar-item.svelte-752ro1 button.jse-navigation-bar-button:where(.svelte-752ro1):focus, .jse-navigation-bar-item.svelte-752ro1 button.jse-navigation-bar-button:where(.svelte-752ro1):hover {
  background: var(--jse-panel-button-background-highlight, #e0e0e0);
  color: var(--panel-button-color-highlight, var(--jse-text-color, #4d4d4d));
}
.jse-navigation-bar-item.svelte-752ro1 button.jse-navigation-bar-button.jse-navigation-bar-arrow:where(.svelte-752ro1) {
  padding: 2px var(--jse-padding, 10px) 0;
}
.jse-navigation-bar-item.svelte-752ro1 button.jse-navigation-bar-button.jse-navigation-bar-arrow.jse-open:where(.svelte-752ro1) {
  background: var(--jse-navigation-bar-background, var(--jse-background-color, #fff));
  color: var(--jse-navigation-bar-dropdown-color, #656565);
}
.jse-navigation-bar-item.svelte-752ro1:last-child {
  padding-right: var(--jse-padding, 10px);
}`);var $KA=pA('<button type="button" class="jse-navigation-bar-button svelte-752ro1"> </button>'),AYA=pA('<div class="jse-navigation-bar-item svelte-752ro1"><button type="button"><!></button> <!></div>');function hrA(t,e){st(e,!1);var A,i=X(void 0,!0),n=X(void 0,!0),{openAbsolutePopup:o,closeAbsolutePopup:r}=H1("absolute-popup"),s=k(e,"path",9),a=k(e,"index",9),c=k(e,"onSelect",9),l=k(e,"getItems",9),I=X(void 0,!0),C=X(!1,!0);function d(L){r(A),c()(g(i).concat(L))}fA(()=>(W(s()),W(a())),()=>{b(i,s().slice(0,a()))}),fA(()=>(W(s()),W(a())),()=>{b(n,s()[a()])}),nn(),Rt(!0);var B,E=AYA(),Q=$(E);Si($(Q),{data:FS});var u=gA(Q,2),v=L=>{var x=$KA(),y=$(x);Ee(()=>Et(y,g(n))),re("click",x,()=>d(g(n))),iA(L,x)};MA(u,L=>{g(n)!==void 0&&L(v)}),to(E,L=>b(I,L),()=>g(I)),Ee(L=>B=xt(Q,1,"jse-navigation-bar-button jse-navigation-bar-arrow svelte-752ro1",null,B,L),[()=>({"jse-open":g(C)})],PA),re("click",Q,function(){if(g(I)){b(C,!0);var L={items:l()(g(i)),selectedItem:g(n),onSelect:d};A=o(XKA,L,{anchor:g(I),closeOnOuterClick:!0,onClose:()=>{b(C,!1)}})}}),iA(t,E),at()}function oG(t){var e,A;if(navigator.clipboard)return navigator.clipboard.writeText(t);if((e=(A=document).queryCommandSupported)!==null&&e!==void 0&&e.call(A,"copy")){var i=document.createElement("textarea");i.value=t,i.style.position="fixed",i.style.opacity="0",document.body.appendChild(i),i.select();try{document.execCommand("copy")}catch(n){console.error(n)}finally{document.body.removeChild(i)}return Promise.resolve()}return console.error("Copy failed."),Promise.resolve()}vt(`/* over all fonts, sizes, and colors */
/* "consolas" for Windows, "menlo" for Mac with fallback to "monaco", 'Ubuntu Mono' for Ubuntu */
/* (at Mac this font looks too large at 14px, but 13px is too small for the font on Windows) */
/* main, menu, modal */
/* jsoneditor modal */
/* tooltip in text mode */
/* panels: navigation bar, gutter, search box */
/* navigation-bar */
/* context menu */
/* contents: json key and values */
/* contents: selected or hovered */
/* contents: section of collapsed items in an array */
/* contents: highlighting of search matches */
/* contents: inline tags inside the JSON document */
/* contents: table */
/* controls in modals: inputs, buttons, and \`a\` */
/* messages */
/* svelte-select */
/* color picker */
.jse-navigation-bar-path-editor.svelte-zc2wx7 {
  flex: 1;
  display: flex;
  border: var(--jse-edit-outline, 2px solid #656565);
  background: var(--jse-background-color, #fff);
}
.jse-navigation-bar-path-editor.svelte-zc2wx7 input.jse-navigation-bar-text:where(.svelte-zc2wx7) {
  flex: 1;
  font-family: inherit;
  font-size: inherit;
  padding: 0 5px 1px;
  background: var(--jse-background-color, #fff);
  color: var(--jse-text-color, #4d4d4d);
  border: none;
  outline: none;
}
.jse-navigation-bar-path-editor.svelte-zc2wx7 button:where(.svelte-zc2wx7) {
  border: none;
  background: var(--jse-background-color, #fff);
  cursor: pointer;
  font-family: inherit;
  font-size: 80%;
  color: inherit;
}
.jse-navigation-bar-path-editor.svelte-zc2wx7 button.jse-navigation-bar-copy.copied:where(.svelte-zc2wx7) {
  color: var(--message-success-background, #9ac45d);
}
.jse-navigation-bar-path-editor.svelte-zc2wx7 button.jse-navigation-bar-validation-error:where(.svelte-zc2wx7) {
  color: var(--jse-error-color, #ee5341);
}
.jse-navigation-bar-path-editor.error.svelte-zc2wx7 {
  border-color: var(--jse-error-color, #ee5341);
}
.jse-navigation-bar-path-editor.error.svelte-zc2wx7 input.jse-navigation-bar-text:where(.svelte-zc2wx7) {
  color: var(--jse-error-color, #ee5341);
}
.jse-navigation-bar-path-editor.svelte-zc2wx7 .jse-copied-text:where(.svelte-zc2wx7) {
  background: var(--message-success-background, #9ac45d);
  color: var(--jse-message-success-color, #fff);
  position: relative;
  margin: 2px;
  padding: 0 5px;
  border-radius: 3px;
}`);var eYA=pA('<button type="button" class="jse-navigation-bar-validation-error svelte-zc2wx7"><!></button>'),tYA=pA('<div class="jse-copied-text svelte-zc2wx7">Copied!</div>'),iYA=pA('<div><input type="text" class="jse-navigation-bar-text svelte-zc2wx7"/> <!> <!> <button type="button" title="Copy selected path to the clipboard"><!></button></div>');function nYA(t,e){st(e,!1);var A=X(),i=H1("absolute-popup"),n=k(e,"path",8),o=k(e,"pathParser",8),r=k(e,"onChange",8),s=k(e,"onClose",8),a=k(e,"onError",8),c=k(e,"pathExists",8),l=X(),I=X(),C=X(!1),d=void 0,B=X(!1);function E(){g(l).focus()}function Q(K){try{var H=o().parse(K);return function(j){if(!c()(j))throw new Error("Path does not exist in current document")}(H),{path:H,error:void 0}}catch(j){return{path:void 0,error:j}}}ls(()=>{E()}),Tc(()=>{clearTimeout(d)}),fA(()=>(W(o()),W(n())),()=>{b(I,o().stringify(n()))}),fA(()=>(g(C),g(I)),()=>{b(A,g(C)?Q(g(I)).error:void 0)}),nn(),Rt();var u,v=iYA(),L=$(v);to(L,K=>b(l,K),()=>g(l));var x=gA(L,2),y=K=>{var H=eYA();Si($(H),{data:r1}),bs(H,(j,IA)=>eh?.(j,IA),()=>Be({text:String(g(A)||"")},i)),iA(K,H)};MA(x,K=>{g(A)&&K(y)});var F=gA(x,2),U=K=>{iA(K,tYA())};MA(F,K=>{g(B)&&K(U)});var T,N=gA(F,2);Si($(N),{data:S0}),Ee((K,H)=>{u=xt(v,1,"jse-navigation-bar-path-editor svelte-zc2wx7",null,u,K),GC(L,g(I)),T=xt(N,1,"jse-navigation-bar-copy svelte-zc2wx7",null,T,H)},[()=>({error:g(A)}),()=>({copied:g(B)})],PA),re("keydown",L,z0(function(K){var H=A2(K);if(H==="Escape"&&(K.preventDefault(),s()()),H==="Enter"){K.preventDefault(),b(C,!0);var j=Q(g(I));j.path!==void 0?r()(j.path):a()(j.error)}})),re("input",L,function(K){b(I,K.currentTarget.value)}),re("click",N,function(){oG(g(I)),b(B,!0),d=window.setTimeout(()=>b(B,!1),1e3),E()}),iA(t,v),at()}vt(`/* over all fonts, sizes, and colors */
/* "consolas" for Windows, "menlo" for Mac with fallback to "monaco", 'Ubuntu Mono' for Ubuntu */
/* (at Mac this font looks too large at 14px, but 13px is too small for the font on Windows) */
/* main, menu, modal */
/* jsoneditor modal */
/* tooltip in text mode */
/* panels: navigation bar, gutter, search box */
/* navigation-bar */
/* context menu */
/* contents: json key and values */
/* contents: selected or hovered */
/* contents: section of collapsed items in an array */
/* contents: highlighting of search matches */
/* contents: inline tags inside the JSON document */
/* contents: table */
/* controls in modals: inputs, buttons, and \`a\` */
/* messages */
/* svelte-select */
/* color picker */
.jse-navigation-bar.svelte-xs03gj {
  font-family: var(--jse-font-family-mono, consolas, menlo, monaco, "Ubuntu Mono", "source-code-pro", monospace);
  font-size: var(--jse-font-size-mono, 14px);
  background: var(--jse-panel-background, #ebebeb);
  color: var(--jse-panel-button-color, inherit);
  padding: 0;
  margin: 0;
  display: flex;
  overflow: auto;
  border-left: var(--jse-main-border, 1px solid #d7d7d7);
  border-right: var(--jse-main-border, 1px solid #d7d7d7);
}
.jse-navigation-bar.svelte-xs03gj .jse-navigation-bar-edit:where(.svelte-xs03gj) {
  font-family: var(--jse-font-family-mono, consolas, menlo, monaco, "Ubuntu Mono", "source-code-pro", monospace);
  font-size: var(--jse-font-size-mono, 14px);
  padding: calc(0.5 * var(--jse-padding, 10px)) var(--jse-padding, 10px);
  color: var(--jse-panel-color-readonly, #b2b2b2);
  background: transparent;
  border: none;
  display: flex;
  cursor: pointer;
  outline: none;
  align-items: center;
}
.jse-navigation-bar.svelte-xs03gj .jse-navigation-bar-edit.flex:where(.svelte-xs03gj) {
  flex: 1;
}
.jse-navigation-bar.svelte-xs03gj .jse-navigation-bar-edit:where(.svelte-xs03gj):focus, .jse-navigation-bar.svelte-xs03gj .jse-navigation-bar-edit:where(.svelte-xs03gj):hover, .jse-navigation-bar.svelte-xs03gj .jse-navigation-bar-edit.editing:where(.svelte-xs03gj) {
  background: var(--jse-panel-button-background-highlight, #e0e0e0);
  color: var(--panel-button-color-highlight, var(--jse-text-color, #4d4d4d));
  transition: color 0.2s ease-in, background 0.2s ease-in;
}
.jse-navigation-bar.svelte-xs03gj .jse-navigation-bar-edit:where(.svelte-xs03gj) .jse-navigation-bar-space:where(.svelte-xs03gj) {
  flex: 1;
  text-align: left;
}`);var oYA=pA("<!> <!>",1),rYA=pA('<div class="jse-navigation-bar svelte-xs03gj"><!> <button type="button"><span class="jse-navigation-bar-space svelte-xs03gj"> </span> <!></button></div>');function sYA(t,e){st(e,!1);var A=X(void 0,!0),i=X(void 0,!0),n=wr("jsoneditor:NavigationBar"),o=k(e,"json",9),r=k(e,"selection",9),s=k(e,"onSelect",9),a=k(e,"onError",9),c=k(e,"pathParser",9),l=X(void 0,!0),I=X(!1,!0);function C(H){n("get items for path",H);var j=Fe(o(),H);if(Array.isArray(j))return i5(0,j.length).map(String);if(tn(j)){var IA=Object.keys(j).slice(0);return IA.sort(w_),IA}return[]}function d(H){return Qs(o(),H)}function B(H){n("select path",JSON.stringify(H)),s()(ys(H,H))}function E(){b(I,!1)}function Q(H){E(),B(H)}fA(()=>(W(r()),je),()=>{b(A,r()?je(r()):[])}),fA(()=>(W(o()),g(A)),()=>{b(i,zo(Fe(o(),g(A))))}),fA(()=>g(A),()=>{g(A),setTimeout(()=>{if(g(l)&&g(l).scrollTo){var H=g(l).scrollWidth-g(l).clientWidth;H>0&&(n("scrollTo ",H),g(l).scrollTo({left:H,behavior:"smooth"}))}})}),nn(),Rt(!0);var u=rYA(),v=$(u),L=H=>{var j=oYA(),IA=Bt(j);Fo(IA,1,()=>g(A),Zo,(p,V,cA)=>{hrA(p,{getItems:C,get path(){return g(A)},index:cA,onSelect:B})});var lA=gA(IA,2),uA=p=>{hrA(p,{getItems:C,get path(){return g(A)},get index(){return g(A).length},onSelect:B})};MA(lA,p=>{g(i)&&p(uA)}),iA(H,j)},x=H=>{nYA(H,{get path(){return g(A)},onClose:E,onChange:Q,get onError(){return a()},pathExists:d,get pathParser(){return c()}})};MA(v,H=>{g(I)?H(x,!1):H(L)});var y,F=gA(v,2),U=$(F),T=$(U),N=gA(U,2),K=PA(()=>g(I)?LW:pW);Si(N,{get data(){return g(K)}}),to(u,H=>b(l,H),()=>g(l)),Ee((H,j)=>{y=xt(F,1,"jse-navigation-bar-edit svelte-xs03gj",null,y,H),en(F,"title",g(I)?"Cancel editing the selected path":"Edit the selected path"),Et(T,j)},[()=>({flex:!g(I),editing:g(I)}),()=>zo(o())||g(I)?"\xA0":"Navigation bar"],PA),re("click",F,function(){b(I,!g(I))}),iA(t,u),at()}vt(`/* over all fonts, sizes, and colors */
/* "consolas" for Windows, "menlo" for Mac with fallback to "monaco", 'Ubuntu Mono' for Ubuntu */
/* (at Mac this font looks too large at 14px, but 13px is too small for the font on Windows) */
/* main, menu, modal */
/* jsoneditor modal */
/* tooltip in text mode */
/* panels: navigation bar, gutter, search box */
/* navigation-bar */
/* context menu */
/* contents: json key and values */
/* contents: selected or hovered */
/* contents: section of collapsed items in an array */
/* contents: highlighting of search matches */
/* contents: inline tags inside the JSON document */
/* contents: table */
/* controls in modals: inputs, buttons, and \`a\` */
/* messages */
/* svelte-select */
/* color picker */
.jse-search-box.svelte-1mxl2uo {
  border: var(--jse-panel-border, var(--jse-main-border, 1px solid #d7d7d7));
  border-radius: 3px;
  font-family: var(--jse-font-family, -apple-system, BlinkMacSystemFont, "Segoe UI", Roboto, Oxygen-Sans, Ubuntu, Cantarell, "Helvetica Neue", sans-serif);
  font-size: var(--jse-font-size, 16px);
  background: var(--jse-panel-background, #ebebeb);
  color: var(--jse-panel-color-readonly, #b2b2b2);
  box-shadow: var(--jse-controls-box-shadow, 0 2px 6px 0 rgba(0, 0, 0, 0.24));
  display: inline-block;
  width: 400px;
  max-width: 100%;
  overflow: auto;
}
.jse-search-box.svelte-1mxl2uo .jse-search-form:where(.svelte-1mxl2uo) {
  display: flex;
  align-items: stretch;
}
.jse-search-box.svelte-1mxl2uo .jse-search-form:where(.svelte-1mxl2uo) button:where(.svelte-1mxl2uo),
.jse-search-box.svelte-1mxl2uo .jse-search-form:where(.svelte-1mxl2uo) input:where(.svelte-1mxl2uo) {
  font-family: inherit;
  font-size: inherit;
}
.jse-search-box.svelte-1mxl2uo .jse-search-form:where(.svelte-1mxl2uo) button:where(.svelte-1mxl2uo) {
  display: block;
  text-align: center;
  border: none;
  padding: 0 5px;
  margin: 0;
  cursor: pointer;
  color: var(--jse-panel-button-color, inherit);
  background: var(--jse-panel-button-background, transparent);
}
.jse-search-box.svelte-1mxl2uo .jse-search-form:where(.svelte-1mxl2uo) button:where(.svelte-1mxl2uo):hover {
  color: var(--panel-button-color-highlight, var(--jse-text-color, #4d4d4d));
  background: var(--jse-panel-button-background-highlight, #e0e0e0);
}
.jse-search-box.svelte-1mxl2uo .jse-search-form:where(.svelte-1mxl2uo) input:where(.svelte-1mxl2uo) {
  color: var(--jse-panel-color, var(--jse-text-color, #4d4d4d));
  border: var(--jse-input-border, 1px solid #d8dbdf);
  border-radius: 3px;
  background: var(--jse-input-background, var(--jse-background-color, #fff));
  height: 28px;
  padding: 0 5px;
  margin: 0;
  flex: 1;
  width: 0;
  min-width: 50px;
  outline: none;
}
.jse-search-box.svelte-1mxl2uo .jse-search-form:where(.svelte-1mxl2uo) .jse-replace-toggle:where(.svelte-1mxl2uo) {
  padding: var(--jse-padding, 10px) calc(0.5 * var(--jse-padding, 10px));
  min-width: 20px;
  background: var(--jse-panel-button-background-highlight, #e0e0e0);
}
.jse-search-box.svelte-1mxl2uo .jse-search-form:where(.svelte-1mxl2uo) .jse-search-contents:where(.svelte-1mxl2uo) {
  flex: 1;
  display: flex;
  flex-direction: column;
  padding: calc(0.5 * var(--jse-padding, 10px));
  gap: calc(0.5 * var(--jse-padding, 10px));
}
.jse-search-box.svelte-1mxl2uo .jse-search-form:where(.svelte-1mxl2uo) .jse-search-contents:where(.svelte-1mxl2uo) .jse-search-section:where(.svelte-1mxl2uo) {
  flex: 1;
  display: flex;
  align-items: center;
  position: relative;
}
.jse-search-box.svelte-1mxl2uo .jse-search-form:where(.svelte-1mxl2uo) .jse-search-contents:where(.svelte-1mxl2uo) .jse-search-section:where(.svelte-1mxl2uo) .jse-search-icon:where(.svelte-1mxl2uo) {
  color: inherit;
  cursor: inherit;
  background: inherit;
  width: 32px;
  text-align: center;
}
.jse-search-box.svelte-1mxl2uo .jse-search-form:where(.svelte-1mxl2uo) .jse-search-contents:where(.svelte-1mxl2uo) .jse-search-section:where(.svelte-1mxl2uo) label.jse-search-input-label:where(.svelte-1mxl2uo) {
  flex: 1;
  display: flex;
}
.jse-search-box.svelte-1mxl2uo .jse-search-form:where(.svelte-1mxl2uo) .jse-search-contents:where(.svelte-1mxl2uo) .jse-search-section:where(.svelte-1mxl2uo) .jse-search-count:where(.svelte-1mxl2uo) {
  color: inherit;
  font-size: 80%;
  visibility: hidden;
  padding: 0 5px;
  min-width: 36px;
  text-align: center;
}
.jse-search-box.svelte-1mxl2uo .jse-search-form:where(.svelte-1mxl2uo) .jse-search-contents:where(.svelte-1mxl2uo) .jse-search-section:where(.svelte-1mxl2uo) .jse-search-count.jse-visible:where(.svelte-1mxl2uo) {
  visibility: visible;
}
.jse-search-box.svelte-1mxl2uo .jse-search-form:where(.svelte-1mxl2uo) .jse-search-contents:where(.svelte-1mxl2uo) .jse-replace-section:where(.svelte-1mxl2uo) {
  flex: 1;
  display: flex;
  padding-left: 32px;
}
.jse-search-box.svelte-1mxl2uo .jse-search-form:where(.svelte-1mxl2uo) .jse-search-contents:where(.svelte-1mxl2uo) .jse-replace-section:where(.svelte-1mxl2uo) button:where(.svelte-1mxl2uo) {
  width: auto;
}`);var aYA=pA('<button type="button" class="jse-replace-toggle svelte-1mxl2uo" title="Toggle visibility of replace options (Ctrl+H)"><!></button>'),cYA=pA('<div class="jse-replace-section svelte-1mxl2uo"><input class="jse-replace-input svelte-1mxl2uo" title="Enter replacement text" type="text" placeholder="Replace"/> <button type="button" title="Replace current occurrence (Ctrl+Enter)" class="svelte-1mxl2uo">Replace</button> <button type="button" title="Replace all occurrences" class="svelte-1mxl2uo">All</button></div>'),lYA=pA('<div class="jse-search-box svelte-1mxl2uo"><form class="jse-search-form svelte-1mxl2uo"><!> <div class="jse-search-contents svelte-1mxl2uo"><div class="jse-search-section svelte-1mxl2uo"><div class="jse-search-icon svelte-1mxl2uo"><!></div> <label class="jse-search-input-label svelte-1mxl2uo" about="jse-search input"><input class="jse-search-input svelte-1mxl2uo" title="Enter text to search" type="text" placeholder="Find"/></label> <div> </div> <button type="button" class="jse-search-next svelte-1mxl2uo" title="Go to next search result (Enter)"><!></button> <button type="button" class="jse-search-previous svelte-1mxl2uo" title="Go to previous search result (Shift+Enter)"><!></button> <button type="button" class="jse-search-clear svelte-1mxl2uo" title="Close search box (Esc)"><!></button></div> <!></div></form></div>');function taA(t,e){st(e,!1);var A=X(void 0,!0),i=X(void 0,!0),n=X(void 0,!0),o=wr("jsoneditor:SearchBox"),r=k(e,"json",9),s=k(e,"documentState",9),a=k(e,"parser",9),c=k(e,"showSearch",9),l=k(e,"showReplace",13),I=k(e,"readOnly",9),C=k(e,"columns",9),d=k(e,"onSearch",9),B=k(e,"onFocus",9),E=k(e,"onPatch",9),Q=k(e,"onClose",9),u=X("",!0),v="",L=X("",!0),x=X(!1,!0),y=X(void 0,!0),F=PB(function(h){return TA.apply(this,arguments)},300),U=PB(function(h){return Ke.apply(this,arguments)},300);function T(){l(!l()&&!I())}function N(h){h.stopPropagation();var f=A2(h);f==="Enter"&&(h.preventDefault(),g(u)!==v?F.flush():cA()),f==="Shift+Enter"&&(h.preventDefault(),jA()),f==="Ctrl+Enter"&&(h.preventDefault(),l()?IA():cA()),f==="Ctrl+H"&&(h.preventDefault(),T()),f==="Escape"&&(h.preventDefault(),eA())}function K(h){A2(h)==="Enter"&&(h.preventDefault(),h.stopPropagation(),IA())}function H(){return j.apply(this,arguments)}function j(){return(j=yt(function*(){go(),yield F.flush()})).apply(this,arguments)}function IA(){return lA.apply(this,arguments)}function lA(){return(lA=yt(function*(){var h;if(!I()){var f=(h=g(y))===null||h===void 0?void 0:h.activeItem;if(o("handleReplace",{replaceText:g(L),activeItem:f}),g(y)&&f&&r()!==void 0){b(y,Be(Be({},trA(g(y))),{},{activeIndex:g(i)}));var{operations:w,newSelection:D}=NGA(r(),s(),g(L),f,a());E()(w,(O,Z)=>({state:Z,selection:D})),go(),yield U.flush(),yield ce()}}})).apply(this,arguments)}function uA(){return p.apply(this,arguments)}function p(){return(p=yt(function*(){if(!I()){o("handleReplaceAll",{text:g(u),replaceText:g(L)});var{operations:h,newSelection:f}=function(w,D,O,Z,q){for(var CA=irA(O,w,{maxResults:1/0}),kA=[],KA=0;KA<CA.length;KA++){var Ie=CA[KA-1],GA=CA[KA];KA!==0&&GA.field===Ie.field&&Ei(GA.path,Ie.path)?ri(kA).items.push(GA):kA.push({path:GA.path,field:GA.field,items:[GA]})}kA.sort((G,Y)=>G.field!==Y.field?G.field===Ml.key?1:-1:Y.path.length-G.path.length);var oe,M=[];return kA.forEach(G=>{var{field:Y,path:AA,items:dA}=G;if(Y===Ml.key){var WA=pi(AA),Qe=Fe(w,WA),yA=ri(AA),DA=Z3(WA,Object.keys(Qe),yA,orA(yA,Z,dA));M=M.concat(DA),oe=Ah(w,DA)}else{if(Y!==Ml.value)throw new Error("Cannot replace: unknown type of search result field ".concat(Y));var We=Fe(w,AA);if(We===void 0)throw new Error("Cannot replace: path not found ".concat(nt(AA)));var be=typeof We=="string"?We:String(We),qA=Z0(w,D,AA),It=orA(be,Z,dA),Vi=[{op:"replace",path:nt(AA),value:qA?It:ah(It,q)}];M=M.concat(Vi),oe=Ah(w,Vi)}}),{operations:M,newSelection:oe}}(r(),s(),g(u),g(L),a());E()(h,(w,D)=>({state:D,selection:f})),yield ce()}})).apply(this,arguments)}function V(h){h.select()}function cA(){return aA.apply(this,arguments)}function aA(){return(aA=yt(function*(){b(y,g(y)?trA(g(y)):void 0),yield ce()})).apply(this,arguments)}function jA(){return VA.apply(this,arguments)}function VA(){return VA=yt(function*(){b(y,g(y)?function(h){var f=h.activeIndex>0?h.activeIndex-1:h.items.length-1,w=h.items[f],D=h.items.map((O,Z)=>Be(Be({},O),{},{active:Z===f}));return Be(Be({},h),{},{items:D,activeItem:w,activeIndex:f})}(g(y)):void 0),yield ce()}),VA.apply(this,arguments)}function ce(){return EA.apply(this,arguments)}function EA(){return(EA=yt(function*(){var h;o("handleFocus",g(y));var f=(h=g(y))===null||h===void 0?void 0:h.activeItem;f&&r()!==void 0&&(yield B()(f.path,f.resultIndex))})).apply(this,arguments)}function sA(){return sA=yt(function*(h){yield Re(h,g(u),r())}),sA.apply(this,arguments)}function TA(){return TA=yt(function*(h){yield Re(c(),h,r()),yield ce()}),TA.apply(this,arguments)}function Ke(){return Ke=yt(function*(h){yield Re(c(),g(u),h)}),Ke.apply(this,arguments)}function Re(h,f,w){return hA.apply(this,arguments)}function hA(){return hA=yt(function*(h,f,w){return h?(o("applySearch",{showSearch:h,text:f}),f===""?(o("clearing search result"),g(y)!==void 0&&b(y,void 0),Promise.resolve()):(v=f,b(x,!0),new Promise(D=>{setTimeout(()=>{var O=irA(f,w,{maxResults:SN,columns:C()});b(y,function(Z,q){var CA=q!=null&&q.activeItem?rrA(q.activeItem):void 0,kA=Z.findIndex(GA=>Ei(CA,rrA(GA))),KA=kA!==-1?kA:q?.activeIndex!==void 0&&q?.activeIndex<Z.length?q?.activeIndex:Z.length>0?0:-1,Ie=Z.map((GA,oe)=>Be(Be({resultIndex:oe},GA),{},{active:oe===KA}));return{items:Ie,activeItem:Ie[KA],activeIndex:KA}}(O,g(y))),b(x,!1),D()})}))):(g(y)&&b(y,void 0),Promise.resolve())}),hA.apply(this,arguments)}function eA(){o("handleClose"),F.cancel(),U.cancel(),Re(!1,g(u),r()),Q()()}fA(()=>g(y),()=>{var h;b(A,((h=g(y))===null||h===void 0||(h=h.items)===null||h===void 0?void 0:h.length)||0)}),fA(()=>g(y),()=>{var h;b(i,((h=g(y))===null||h===void 0?void 0:h.activeIndex)||0)}),fA(()=>(g(A),SN),()=>{b(n,g(A)>=SN?"".concat(999,"+"):String(g(A)))}),fA(()=>(W(d()),g(y)),()=>{d()(g(y))}),fA(()=>W(c()),()=>{(function(h){sA.apply(this,arguments)})(c())}),fA(()=>g(u),()=>{F(g(u))}),fA(()=>W(r()),()=>{U(r())}),nn(),Rt(!0);var RA=po(),oA=Bt(RA),ne=h=>{var f=lYA(),w=$(f),D=$(w),O=yA=>{var DA=aYA(),We=$(DA),be=PA(()=>l()?k0:qB);Si(We,{get data(){return g(be)}}),re("click",DA,T),iA(yA,DA)};MA(D,yA=>{I()||yA(O)});var Z=$(gA(D,2)),q=$(Z),CA=$(q),kA=yA=>{Si(yA,{data:uW,spin:!0})},KA=yA=>{Si(yA,{data:Zu})};MA(CA,yA=>{g(x)?yA(kA):yA(KA,!1)});var Ie=gA(q,2),GA=$(Ie);Nr(()=>iy(GA,()=>g(u),yA=>b(u,yA))),bs(GA,yA=>V?.(yA)),Nr(()=>re("paste",GA,H));var oe,M=gA(Ie,2),G=$(M),Y=gA(M,2);Si($(Y),{data:SW});var AA=gA(Y,2);Si($(AA),{data:wW});var dA=gA(AA,2);Si($(dA),{data:Wu});var WA=gA(Z,2),Qe=yA=>{var DA=cYA(),We=$(DA),be=gA(We,2),qA=gA(be,2);iy(We,()=>g(L),It=>b(L,It)),re("keydown",We,K),re("click",be,IA),re("click",qA,uA),iA(yA,DA)};MA(WA,yA=>{l()&&!I()&&yA(Qe)}),Ee(yA=>{var DA;oe=xt(M,1,"jse-search-count svelte-1mxl2uo",null,oe,yA),Et(G,"".concat(g(i)!==-1&&g(i)<g(A)?"".concat(g(i)+1,"/"):"").concat((DA=g(n))!==null&&DA!==void 0?DA:""))},[()=>({"jse-visible":g(u)!==""})],PA),re("click",Y,cA),re("click",AA,jA),re("click",dA,eA),re("keydown",w,N),iA(h,f)};MA(oA,h=>{c()&&h(ne)}),iA(t,RA),at()}var K3=Symbol("path");function gYA(t,e){var A=arguments.length>2&&arguments[2]!==void 0?arguments[2]:1/0,i={};Array.isArray(t)&&function(o,r,s){if(o.length<r)o.forEach(s);else for(var a=r>1?(o.length-1)/(r-1):o.length,c=0;c<r;c++){var l=Math.floor(c*a);s(o[l],l,o)}}(t,A,o=>{tn(o)?iaA(o,i,e):i[K3]=!0});var n=[];return K3 in i&&n.push([]),naA(i,[],n,e),n}function iaA(t,e,A){for(var i in t){var n=t[i],o=e[i]||(e[i]={});tn(n)&&A?iaA(n,o,A):o[K3]===void 0&&(o[K3]=!0)}}function naA(t,e,A,i){for(var n in t){var o=e.concat(n),r=t[n];r&&r[K3]===!0&&A.push(o),Mo(r)&&i&&naA(r,o,A,i)}}function IYA(t,e,A,i,n,o){for(var r=arguments.length>6&&arguments[6]!==void 0?arguments[6]:80,s=ao(A)?A.length:0,a=function(v,L){var x=Object.values(v);if(sn(x))return L;var y=(F,U)=>F+U;return x.reduce(y)/x.length}(i,n),c=t-r,l=e+2*r,I=v=>i[v]||n,C=0,d=o;d<c&&C<s;)d+=I(C),C++;C>0&&(d-=I(--C));for(var B=C,E=0;E<l&&B<s;)E+=I(B),B++;for(var Q=0,u=B;u<s;u++)Q+=I(u);return{startIndex:C,endIndex:B,startHeight:d,endHeight:Q,averageItemHeight:a,visibleHeight:E,visibleItems:ao(A)?A.slice(C,B):[]}}function QrA(t,e,A,i){for(var{rowIndex:n}=Uc(t,e),o=0,r=0;r<n;r++)o+=A[r]||i;return o}function Uc(t,e){var[A,...i]=t,n=parseInt(A,10);return{rowIndex:isNaN(n)?-1:n,columnIndex:e.findIndex(o=>e2(i,o))}}function yC(t,e){var{rowIndex:A,columnIndex:i}=t;return[String(A),...e[i]]}function CYA(t,e){var[A,i]=wS(t,r=>G_(r.path[0])),n=mS(A,dYA),o=pS(n,r=>{var s={row:[],columns:{}};return r.forEach(a=>{var c=function(l,I){var C=Uc(l.path,I);return C.columnIndex!==-1?C.columnIndex:-1}(a,e);c!==-1?(s.columns[c]===void 0&&(s.columns[c]=[]),s.columns[c].push(a)):s.row.push(a)}),s});return{root:i,rows:o}}function ON(t,e){if(e&&e.length!==0)return e.length===1?e[0]:{path:t,message:"Multiple validation issues: "+e.map(A=>Dl(A.path)+" "+A.message).join(", "),severity:bl.warning}}function dYA(t){return parseInt(t.path[0],10)}function BYA(t,e,A){var i=e.some(n=>function(o,r,s){if(!o)return!1;if(r.op==="replace"){var a=da(r.path),{rowIndex:c,columnIndex:l}=Uc(a,s),I=s.findIndex(C=>Ei(C,o.path));if(c!==-1&&l!==-1&&l!==I)return!1}return!0}(t,n,A));return i?void 0:t}var vs=wr("jsoneditor:actions");function oaA(t){return D_.apply(this,arguments)}function D_(){return D_=yt(function*(t){var{json:e,selection:A,indentation:i,readOnly:n,parser:o,onPatch:r}=t;if(!n&&e!==void 0&&A&&zE(A)){var s=ksA(e,A,i,o);if(s!==void 0){vs("cut",{selection:A,clipboard:s,indentation:i}),yield oG(s);var{operations:a,newSelection:c}=NsA(e,A);r(a,(l,I)=>({state:I,selection:c}))}}}),D_.apply(this,arguments)}function raA(t){return y_.apply(this,arguments)}function y_(){return y_=yt(function*(t){var{json:e,selection:A,indentation:i,parser:n}=t,o=ksA(e,A,i,n);o!==void 0&&(vs("copy",{clipboard:o,indentation:i}),yield oG(o))}),y_.apply(this,arguments)}function saA(t){var{clipboardText:e,json:A,selection:i,readOnly:n,parser:o,onPatch:r,onChangeText:s,onPasteMultilineText:a,openRepairModal:c}=t;if(!n)try{l(e)}catch{c(e,C=>{vs("repaired pasted text: ",C),l(C)})}function l(I){if(A!==void 0){var C=i||hi([]),d=FsA(A,C,I,o),B=function(E,Q,u){var v=arguments.length>3&&arguments[3]!==void 0?arguments[3]:DGA;if(E.length>v)return!1;var L=/\n/.test(E);if(!L)return!1;var x=Q.some(F=>F.op==="replace"&&Array.isArray(F.value)),y=Q.filter(F=>F.op==="add").length>1;if(!x&&!y)return!1;try{return P3(E,u.parse),!1}catch{return!0}}(e,d,o);vs("paste",{pastedText:I,operations:d,ensureSelection:C,pasteMultilineText:B}),r(d,(E,Q)=>{var u=Q;return d.filter(v=>(Vk(v)||Q8(v))&&zo(v.value)).forEach(v=>{var L=Ea(A,v.path);u=KC(E,u,L)}),{state:u}}),B&&a(I)}else vs("paste text",{pastedText:I}),s(e,(E,Q)=>{if(E)return{state:KC(E,Q,[])}})}}function aaA(t){var{json:e,text:A,selection:i,keepSelection:n,readOnly:o,onChange:r,onPatch:s}=t;if(!o&&i){var a=e!==void 0&&(pr(i)||dn(i))?ys(i.path,i.path):i;if(sn(je(i)))vs("remove root",{selection:i}),r&&r({text:"",json:void 0},e!==void 0?{text:void 0,json:e}:{text:A||"",json:e},{contentErrors:void 0,patchResult:void 0});else if(e!==void 0){var{operations:c,newSelection:l}=NsA(e,a);vs("remove",{operations:c,selection:i,newSelection:l}),s(c,(I,C)=>({state:C,selection:n?i:l}))}}}function Ey(t){var{insertType:e,selectInside:A,initialValue:i,json:n,selection:o,readOnly:r,parser:s,onPatch:a,onReplaceJson:c}=t;if(!r){var l=function(E,Q,u){if(u==="object")return{};if(u==="array")return[];if(u==="structure"&&E!==void 0){var v=Q?bsA(Q):[],L=Fe(E,v);if(Array.isArray(L)&&!sn(L)){var x=Mc(L);return zo(x)?hS(x,y=>Array.isArray(y)?[]:tn(y)?void 0:""):""}}return""}(n,o,e);if(n!==void 0){var I=s.stringify(l),C=FsA(n,o,I,s);vs("onInsert",{insertType:e,operations:C,newValue:l,data:I});var d=ri(C.filter(E=>E.op==="add"||E.op==="replace"));a(C,(E,Q,u)=>{if(d){var v=Ea(E,d.path);if(zo(l))return{state:pl(E,Q,v,X_),selection:A?i2(v):u};if(l===""){var L=sn(v)?void 0:Fe(E,pi(v));return{state:pl(E,Q,v,VD),selection:tn(L)?$_(v,i):sy(v,i)}}}}),vs("after patch")}else{vs("onInsert",{insertType:e,newValue:l});var B=[];c(l,(E,Q)=>({state:KC(E,Q,B),selection:zo(l)?i2(B):sy(B)}))}}}function caA(t){return v_.apply(this,arguments)}function v_(){return v_=yt(function*(t){var{char:e,selectInside:A,json:i,selection:n,readOnly:o,parser:r,onPatch:s,onReplaceJson:a,onSelect:c}=t;o||(pr(n)?c(Be(Be({},n),{},{edit:!0,initialValue:e})):e==="{"?Ey({insertType:"object",selectInside:A,initialValue:void 0,json:i,selection:n,readOnly:o,parser:r,onPatch:s,onReplaceJson:a}):e==="["?Ey({insertType:"array",selectInside:A,initialValue:void 0,json:i,selection:n,readOnly:o,parser:r,onPatch:s,onReplaceJson:a}):dn(n)&&i!==void 0?zo(Fe(i,n.path))||c(Be(Be({},n),{},{edit:!0,initialValue:e})):(vs("onInsertValueWithCharacter",{char:e}),yield function(l){return b_.apply(this,arguments)}({char:e,json:i,selection:n,readOnly:o,parser:r,onPatch:s,onReplaceJson:a})))}),v_.apply(this,arguments)}function b_(){return b_=yt(function*(t){var{char:e,json:A,selection:i,readOnly:n,parser:o,onPatch:r,onReplaceJson:s}=t;n||Ey({insertType:"value",selectInside:!1,initialValue:e,json:A,selection:i,readOnly:n,parser:o,onPatch:r,onReplaceJson:s})}),b_.apply(this,arguments)}vt(`/* over all fonts, sizes, and colors */
/* "consolas" for Windows, "menlo" for Mac with fallback to "monaco", 'Ubuntu Mono' for Ubuntu */
/* (at Mac this font looks too large at 14px, but 13px is too small for the font on Windows) */
/* main, menu, modal */
/* jsoneditor modal */
/* tooltip in text mode */
/* panels: navigation bar, gutter, search box */
/* navigation-bar */
/* context menu */
/* contents: json key and values */
/* contents: selected or hovered */
/* contents: section of collapsed items in an array */
/* contents: highlighting of search matches */
/* contents: inline tags inside the JSON document */
/* contents: table */
/* controls in modals: inputs, buttons, and \`a\` */
/* messages */
/* svelte-select */
/* color picker */
.jse-json-preview.svelte-1vjn89h {
  flex: 1;
  font-family: var(--jse-font-family-mono, consolas, menlo, monaco, "Ubuntu Mono", "source-code-pro", monospace);
  font-size: var(--jse-font-size-mono, 14px);
  color: var(--jse-panel-color-readonly, #b2b2b2);
  overflow: auto;
  white-space: pre-wrap;
  padding: 2px;
  border-left: var(--jse-main-border, 1px solid #d7d7d7);
  border-right: var(--jse-main-border, 1px solid #d7d7d7);
  border-bottom: var(--jse-main-border, 1px solid #d7d7d7);
}`);var EYA=pA('<div class="jse-json-preview svelte-1vjn89h"> </div>');function laA(t,e){st(e,!1);var A=X(),i=X(),n=k(e,"text",8),o=k(e,"json",8),r=k(e,"indentation",8),s=k(e,"parser",8);fA(()=>(W(o()),W(n())),()=>{b(A,o()!==void 0?{json:o()}:{text:n()||""})}),fA(()=>(g(A),W(r()),W(s()),l_),()=>{b(i,S3(s_(g(A),r(),s()),l_))}),nn(),Rt();var a=EYA(),c=$(a);Ee(()=>Et(c,g(i))),iA(t,a),at()}vt(`/* over all fonts, sizes, and colors */
/* "consolas" for Windows, "menlo" for Mac with fallback to "monaco", 'Ubuntu Mono' for Ubuntu */
/* (at Mac this font looks too large at 14px, but 13px is too small for the font on Windows) */
/* main, menu, modal */
/* jsoneditor modal */
/* tooltip in text mode */
/* panels: navigation bar, gutter, search box */
/* navigation-bar */
/* context menu */
/* contents: json key and values */
/* contents: selected or hovered */
/* contents: section of collapsed items in an array */
/* contents: highlighting of search matches */
/* contents: inline tags inside the JSON document */
/* contents: table */
/* controls in modals: inputs, buttons, and \`a\` */
/* messages */
/* svelte-select */
/* color picker */
button.jse-context-menu-button.svelte-1idfykj {
  border: none;
  background: transparent;
  color: inherit;
  cursor: pointer;
  font-family: var(--jse-font-family, -apple-system, BlinkMacSystemFont, "Segoe UI", Roboto, Oxygen-Sans, Ubuntu, Cantarell, "Helvetica Neue", sans-serif);
  font-size: var(--jse-font-size, 16px);
  padding: 5px;
  margin: 0;
  flex: 1;
  white-space: nowrap;
  padding: var(--jse-padding, 10px);
  color: inherit;
}
button.jse-context-menu-button.svelte-1idfykj:hover {
  background: var(--jse-context-menu-background-highlight, #7a7a7a);
}
button.jse-context-menu-button.svelte-1idfykj:focus {
  background: var(--jse-context-menu-background-highlight, #7a7a7a);
  z-index: 1;
}
button.jse-context-menu-button.svelte-1idfykj:disabled {
  color: var(--jse-context-menu-color-disabled, #9d9d9d);
  background: unset;
}
button.jse-context-menu-button.left.svelte-1idfykj {
  text-align: left;
}
button.jse-context-menu-button.svelte-1idfykj svg {
  width: 16px;
}`);var hYA=pA('<button type="button"><!> <!></button>');function PN(t,e){st(e,!1);var A=k(e,"item",8),i=k(e,"className",8,void 0),n=k(e,"onRequestClose",8);Rt();var o=hYA(),r=$(o),s=l=>{Si(l,{get data(){return A().icon}})};MA(r,l=>{A().icon&&l(s)});var a=gA(r,2),c=l=>{var I=_r();Ee(()=>Et(I,A().text)),iA(l,I)};MA(a,l=>{A().text&&l(c)}),Ee(l=>{xt(o,1,l,"svelte-1idfykj"),en(o,"title",A().title),o.disabled=A().disabled||!1},[()=>T1(lh("jse-context-menu-button",i(),A().className))],PA),re("click",o,l=>{n()(),A().onClick(l)}),iA(t,o),at()}vt(`/* over all fonts, sizes, and colors */
/* "consolas" for Windows, "menlo" for Mac with fallback to "monaco", 'Ubuntu Mono' for Ubuntu */
/* (at Mac this font looks too large at 14px, but 13px is too small for the font on Windows) */
/* main, menu, modal */
/* jsoneditor modal */
/* tooltip in text mode */
/* panels: navigation bar, gutter, search box */
/* navigation-bar */
/* context menu */
/* contents: json key and values */
/* contents: selected or hovered */
/* contents: section of collapsed items in an array */
/* contents: highlighting of search matches */
/* contents: inline tags inside the JSON document */
/* contents: table */
/* controls in modals: inputs, buttons, and \`a\` */
/* messages */
/* svelte-select */
/* color picker */
.jse-dropdown-button.svelte-11rxb2m {
  flex: 1;
  line-height: normal;
  border: none;
  background: transparent;
  color: inherit;
  cursor: pointer;
  font-family: var(--jse-font-family, -apple-system, BlinkMacSystemFont, "Segoe UI", Roboto, Oxygen-Sans, Ubuntu, Cantarell, "Helvetica Neue", sans-serif);
  font-size: var(--jse-font-size, 16px);
  padding: 5px;
  margin: 0;
  position: relative;
  padding: 0;
  display: flex;
}
.jse-dropdown-button.svelte-11rxb2m ul:where(.svelte-11rxb2m) {
  margin: 0;
  padding: 0;
}
.jse-dropdown-button.svelte-11rxb2m ul:where(.svelte-11rxb2m) li:where(.svelte-11rxb2m) {
  margin: 0;
  padding: 0;
  list-style-type: none;
}
.jse-dropdown-button.svelte-11rxb2m button.jse-open-dropdown:where(.svelte-11rxb2m) {
  border: none;
  background: transparent;
  color: inherit;
  cursor: pointer;
  font-family: var(--jse-font-family, -apple-system, BlinkMacSystemFont, "Segoe UI", Roboto, Oxygen-Sans, Ubuntu, Cantarell, "Helvetica Neue", sans-serif);
  font-size: var(--jse-font-size, 16px);
  padding: 5px;
  margin: 0;
  width: 2em;
  background: var(--jse-context-menu-background, #656565);
  color: var(--jse-context-menu-color, var(--jse-text-color-inverse, #fff));
  border-radius: 0;
}
.jse-dropdown-button.svelte-11rxb2m button.jse-open-dropdown.jse-visible:where(.svelte-11rxb2m) {
  background: var(--jse-context-menu-background, #656565);
}
.jse-dropdown-button.svelte-11rxb2m button.jse-open-dropdown:where(.svelte-11rxb2m):hover {
  background: var(--jse-context-menu-background-highlight, #7a7a7a);
}
.jse-dropdown-button.svelte-11rxb2m button.jse-open-dropdown:where(.svelte-11rxb2m):focus {
  z-index: 1;
}
.jse-dropdown-button.svelte-11rxb2m button.jse-open-dropdown:where(.svelte-11rxb2m):disabled {
  color: var(--jse-context-menu-color-disabled, #9d9d9d);
  background: unset;
}
.jse-dropdown-button.svelte-11rxb2m .jse-dropdown-items:where(.svelte-11rxb2m) {
  display: none;
  position: absolute;
  top: 100%;
  left: 0;
  z-index: 1;
  background: var(--jse-context-menu-background, #656565);
  color: var(--jse-context-menu-color, var(--jse-text-color-inverse, #fff));
  box-shadow: var(--jse-controls-box-shadow, 0 2px 6px 0 rgba(0, 0, 0, 0.24));
}
.jse-dropdown-button.svelte-11rxb2m .jse-dropdown-items.jse-visible:where(.svelte-11rxb2m) {
  display: block;
}
.jse-dropdown-button.svelte-11rxb2m .jse-dropdown-items:where(.svelte-11rxb2m) button:where(.svelte-11rxb2m) {
  border: none;
  background: transparent;
  color: inherit;
  cursor: pointer;
  font-family: var(--jse-font-family, -apple-system, BlinkMacSystemFont, "Segoe UI", Roboto, Oxygen-Sans, Ubuntu, Cantarell, "Helvetica Neue", sans-serif);
  font-size: var(--jse-font-size, 16px);
  padding: 5px;
  margin: 0;
  width: 100%;
  text-align: left;
  padding: var(--jse-padding, 10px);
  margin: 0;
}
.jse-dropdown-button.svelte-11rxb2m .jse-dropdown-items:where(.svelte-11rxb2m) button:where(.svelte-11rxb2m):hover {
  background: var(--jse-context-menu-background-highlight, #7a7a7a);
}
.jse-dropdown-button.svelte-11rxb2m .jse-dropdown-items:where(.svelte-11rxb2m) button:where(.svelte-11rxb2m):disabled {
  color: var(--jse-context-menu-color-disabled, #9d9d9d);
  background: unset;
}`);var QYA=pA('<li class="svelte-11rxb2m"><button type="button"><!> </button></li>'),uYA=pA('<div role="button" tabindex="0" class="jse-dropdown-button svelte-11rxb2m"><!> <button type="button" data-type="jse-open-dropdown"><!></button> <div><ul class="svelte-11rxb2m"></ul></div></div>');vt(`/* over all fonts, sizes, and colors */
/* "consolas" for Windows, "menlo" for Mac with fallback to "monaco", 'Ubuntu Mono' for Ubuntu */
/* (at Mac this font looks too large at 14px, but 13px is too small for the font on Windows) */
/* main, menu, modal */
/* jsoneditor modal */
/* tooltip in text mode */
/* panels: navigation bar, gutter, search box */
/* navigation-bar */
/* context menu */
/* contents: json key and values */
/* contents: selected or hovered */
/* contents: section of collapsed items in an array */
/* contents: highlighting of search matches */
/* contents: inline tags inside the JSON document */
/* contents: table */
/* controls in modals: inputs, buttons, and \`a\` */
/* messages */
/* svelte-select */
/* color picker */
button.jse-context-menu-button.svelte-1idfykj {
  border: none;
  background: transparent;
  color: inherit;
  cursor: pointer;
  font-family: var(--jse-font-family, -apple-system, BlinkMacSystemFont, "Segoe UI", Roboto, Oxygen-Sans, Ubuntu, Cantarell, "Helvetica Neue", sans-serif);
  font-size: var(--jse-font-size, 16px);
  padding: 5px;
  margin: 0;
  flex: 1;
  white-space: nowrap;
  padding: var(--jse-padding, 10px);
  color: inherit;
}
button.jse-context-menu-button.svelte-1idfykj:hover {
  background: var(--jse-context-menu-background-highlight, #7a7a7a);
}
button.jse-context-menu-button.svelte-1idfykj:focus {
  background: var(--jse-context-menu-background-highlight, #7a7a7a);
  z-index: 1;
}
button.jse-context-menu-button.svelte-1idfykj:disabled {
  color: var(--jse-context-menu-color-disabled, #9d9d9d);
  background: unset;
}
button.jse-context-menu-button.left.svelte-1idfykj {
  text-align: left;
}
button.jse-context-menu-button.svelte-1idfykj svg {
  width: 16px;
}`);var fYA=pA('<button type="button" slot="defaultItem"><!> </button>');function jN(t,e){st(e,!1);var A=X(),i=k(e,"item",8),n=k(e,"className",8,void 0),o=k(e,"onRequestClose",8);fA(()=>(W(i()),W(o())),()=>{b(A,i().items.map(r=>Be(Be({},r),{},{onClick:s=>{o()(),r.onClick(s)}})))}),nn(),Rt(),function(r,s){st(s,!1);var a=X(void 0,!0),c=k(s,"items",25,()=>[]),l=k(s,"title",9,void 0),I=k(s,"width",9,"120px"),C=X(!1,!0);function d(){b(C,!1)}function B(y){A2(y)==="Escape"&&(y.preventDefault(),b(C,!1))}ls(()=>{document.addEventListener("click",d),document.addEventListener("keydown",B)}),Tc(()=>{document.removeEventListener("click",d),document.removeEventListener("keydown",B)}),fA(()=>W(c()),()=>{b(a,c().every(y=>y.disabled===!0))}),nn(),Rt(!0);var E=uYA(),Q=$(E);xo(Q,s,"defaultItem",{},null);var u,v=gA(Q,2);Si($(v),{data:k0});var L,x=gA(v,2);Fo($(x),5,c,Zo,(y,F)=>{var U=QYA(),T=$(U),N=$(T),K=j=>{Si(j,{get data(){return g(F).icon}})};MA(N,j=>{g(F).icon&&j(K)});var H=gA(N);Ee(()=>{var j;en(T,"title",g(F).title),T.disabled=g(F).disabled,xt(T,1,T1(g(F).className),"svelte-11rxb2m"),Et(H," ".concat((j=g(F).text)!==null&&j!==void 0?j:""))}),re("click",T,j=>g(F).onClick(j)),iA(y,U)}),Ee((y,F)=>{var U;en(E,"title",l()),u=xt(v,1,"jse-open-dropdown svelte-11rxb2m",null,u,y),v.disabled=g(a),L=xt(x,1,"jse-dropdown-items svelte-11rxb2m",null,L,F),vl(x,"width: ".concat((U=I())!==null&&U!==void 0?U:"",";"))},[()=>({"jse-visible":g(C)}),()=>({"jse-visible":g(C)})],PA),re("click",v,function(){var y=g(C);setTimeout(()=>b(C,!y))}),re("click",E,d),iA(r,E),at()}(t,{get width(){return i().width},get items(){return g(A)},$$slots:{defaultItem:(r,s)=>{var a=fYA(),c=$(a),l=C=>{Si(C,{get data(){return i().main.icon}})};MA(c,C=>{i().main.icon&&C(l)});var I=gA(c);Ee(C=>{var d;xt(a,1,C,"svelte-1idfykj"),en(a,"title",i().main.title),a.disabled=i().main.disabled||!1,Et(I," ".concat((d=i().main.text)!==null&&d!==void 0?d:""))},[()=>T1(lh("jse-context-menu-button",n(),i().main.className))],PA),re("click",a,C=>{o()(),i().main.onClick(C)}),iA(r,a)}}}),at()}vt(`/* over all fonts, sizes, and colors */
/* "consolas" for Windows, "menlo" for Mac with fallback to "monaco", 'Ubuntu Mono' for Ubuntu */
/* (at Mac this font looks too large at 14px, but 13px is too small for the font on Windows) */
/* main, menu, modal */
/* jsoneditor modal */
/* tooltip in text mode */
/* panels: navigation bar, gutter, search box */
/* navigation-bar */
/* context menu */
/* contents: json key and values */
/* contents: selected or hovered */
/* contents: section of collapsed items in an array */
/* contents: highlighting of search matches */
/* contents: inline tags inside the JSON document */
/* contents: table */
/* controls in modals: inputs, buttons, and \`a\` */
/* messages */
/* svelte-select */
/* color picker */
.jse-contextmenu.svelte-12z7bz1 {
  box-shadow: var(--jse-controls-box-shadow, 0 2px 6px 0 rgba(0, 0, 0, 0.24));
  font-family: var(--jse-font-family, -apple-system, BlinkMacSystemFont, "Segoe UI", Roboto, Oxygen-Sans, Ubuntu, Cantarell, "Helvetica Neue", sans-serif);
  font-size: var(--jse-font-size, 16px);
  background: var(--jse-context-menu-background, #656565);
  color: var(--jse-context-menu-color, var(--jse-text-color-inverse, #fff));
}
.jse-contextmenu.svelte-12z7bz1 .jse-row:where(.svelte-12z7bz1) {
  display: flex;
  flex-direction: row;
  align-items: flex-start;
  justify-content: stretch;
}
.jse-contextmenu.svelte-12z7bz1 .jse-row:where(.svelte-12z7bz1) div.jse-label:where(.svelte-12z7bz1) {
  flex: 1;
  white-space: nowrap;
  padding: var(--jse-padding, 10px);
  color: var(--jse-context-menu-color-disabled, #9d9d9d);
  line-height: normal;
}
.jse-contextmenu.svelte-12z7bz1 .jse-row:where(.svelte-12z7bz1) div.jse-tip:where(.svelte-12z7bz1) {
  flex: 1;
  background: var(--jse-context-menu-tip-background, rgba(255, 255, 255, 0.2));
  color: var(--context-menu-tip-color, inherit);
  margin: calc(0.5 * var(--jse-padding, 10px));
  padding: calc(0.5 * var(--jse-padding, 10px)) var(--jse-padding, 10px);
  font-size: 80%;
  line-height: 1.3em;
  display: flex;
  flex-direction: row;
  align-items: flex-start;
  gap: var(--jse-padding, 10px);
  border-radius: 3px;
}
.jse-contextmenu.svelte-12z7bz1 .jse-row:where(.svelte-12z7bz1) div.jse-tip:where(.svelte-12z7bz1) div.jse-tip-icon:where(.svelte-12z7bz1) {
  padding-top: calc(0.5 * var(--jse-padding, 10px));
}
.jse-contextmenu.svelte-12z7bz1 .jse-column:where(.svelte-12z7bz1) {
  flex: 1;
  display: flex;
  flex-direction: column;
  align-items: stretch;
}
.jse-contextmenu.svelte-12z7bz1 .jse-column:where(.svelte-12z7bz1):not(:last-child) {
  border-right: 1px solid var(--jse-context-menu-separator-color, #7a7a7a);
}
.jse-contextmenu.svelte-12z7bz1 .jse-separator:where(.svelte-12z7bz1) {
  width: 100%;
  height: 1px;
  background: var(--jse-context-menu-separator-color, #7a7a7a);
}`);var mYA=pA('<div class="jse-separator svelte-12z7bz1"></div>'),pYA=pA('<div class="jse-label svelte-12z7bz1"> </div>'),wYA=pA('<div class="jse-column svelte-12z7bz1"></div>'),DYA=pA('<div class="jse-separator svelte-12z7bz1"></div>'),yYA=pA('<div class="jse-row svelte-12z7bz1"></div>'),vYA=pA('<div class="jse-separator svelte-12z7bz1"></div>'),bYA=pA('<div class="jse-row svelte-12z7bz1"><div class="jse-tip svelte-12z7bz1"><div class="jse-tip-icon svelte-12z7bz1"><!></div> <div class="jse-tip-text"> </div></div></div>'),MYA=pA('<div role="menu" tabindex="-1" class="jse-contextmenu svelte-12z7bz1"><!> <!></div>');function gaA(t,e){st(e,!1);var A=k(e,"items",9),i=k(e,"onRequestClose",9),n=k(e,"tip",9),o=X(void 0,!0);ls(()=>{var C=Array.from(g(o).querySelectorAll("button")).find(d=>!d.disabled);C&&C.focus()});var r={ArrowUp:"Up",ArrowDown:"Down",ArrowLeft:"Left",ArrowRight:"Right"};function s(C){return console.error("Unknown type of context menu item",C),"???"}Rt(!0);var a=MYA(),c=$(a);Fo(c,1,A,Zo,(C,d)=>{var B=po(),E=Bt(B),Q=v=>{PN(v,{get item(){return g(d)},get onRequestClose(){return i()}})},u=(v,L)=>{var x=F=>{jN(F,{get item(){return g(d)},get onRequestClose(){return i()}})},y=(F,U)=>{var T=K=>{var H=yYA();Fo(H,5,()=>g(d).items,Zo,(j,IA)=>{var lA=po(),uA=Bt(lA),p=cA=>{PN(cA,{get item(){return g(IA)},get onRequestClose(){return i()}})},V=(cA,aA)=>{var jA=ce=>{jN(ce,{get item(){return g(IA)},get onRequestClose(){return i()}})},VA=(ce,EA)=>{var sA=Ke=>{var Re=wYA();Fo(Re,5,()=>g(IA).items,Zo,(hA,eA)=>{var RA=po(),oA=Bt(RA),ne=f=>{PN(f,{className:"left",get item(){return g(eA)},get onRequestClose(){return i()}})},h=(f,w)=>{var D=Z=>{jN(Z,{className:"left",get item(){return g(eA)},get onRequestClose(){return i()}})},O=(Z,q)=>{var CA=KA=>{iA(KA,mYA())},kA=(KA,Ie)=>{var GA=M=>{var G=pYA(),Y=$(G);Ee(()=>Et(Y,g(eA).text)),iA(M,G)},oe=M=>{var G=_r();Ee(Y=>Et(G,Y),[()=>s(g(eA))],PA),iA(M,G)};MA(KA,M=>{yGA(g(eA))?M(GA):M(oe,!1)},Ie)};MA(Z,KA=>{qD(g(eA))?KA(CA):KA(kA,!1)},q)};MA(f,Z=>{FN(g(eA))?Z(D):Z(O,!1)},w)};MA(oA,f=>{y3(g(eA))?f(ne):f(h,!1)}),iA(hA,RA)}),iA(Ke,Re)},TA=(Ke,Re)=>{var hA=RA=>{iA(RA,DYA())},eA=RA=>{var oA=_r();Ee(ne=>Et(oA,ne),[()=>s(g(IA))],PA),iA(RA,oA)};MA(Ke,RA=>{qD(g(IA))?RA(hA):RA(eA,!1)},Re)};MA(ce,Ke=>{bGA(g(IA))?Ke(sA):Ke(TA,!1)},EA)};MA(cA,ce=>{FN(g(IA))?ce(jA):ce(VA,!1)},aA)};MA(uA,cA=>{y3(g(IA))?cA(p):cA(V,!1)}),iA(j,lA)}),iA(K,H)},N=(K,H)=>{var j=lA=>{iA(lA,vYA())},IA=lA=>{var uA=_r();Ee(p=>Et(uA,p),[()=>s(g(d))],PA),iA(lA,uA)};MA(K,lA=>{qD(g(d))?lA(j):lA(IA,!1)},H)};MA(F,K=>{vGA(g(d))?K(T):K(N,!1)},U)};MA(v,F=>{FN(g(d))?F(x):F(y,!1)},L)};MA(E,v=>{y3(g(d))?v(Q):v(u,!1)}),iA(C,B)});var l=gA(c,2),I=C=>{var d=bYA(),B=$(d),E=$(B);Si($(E),{data:EW});var Q=$(gA(E,2));Ee(()=>Et(Q,n())),iA(C,d)};MA(l,C=>{n()&&C(I)}),to(a,C=>b(o,C),()=>g(o)),re("keydown",a,function(C){var d=A2(C),B=r[d];if(B&&C.target){C.preventDefault();var E=iGA({allElements:Array.from(g(o).querySelectorAll("button:not([disabled])")),currentElement:C.target,direction:B,hasPrio:Q=>Q.getAttribute("data-type")!=="jse-open-dropdown"});E&&E.focus()}}),iA(t,a),at()}vt(`/* over all fonts, sizes, and colors */
/* "consolas" for Windows, "menlo" for Mac with fallback to "monaco", 'Ubuntu Mono' for Ubuntu */
/* (at Mac this font looks too large at 14px, but 13px is too small for the font on Windows) */
/* main, menu, modal */
/* jsoneditor modal */
/* tooltip in text mode */
/* panels: navigation bar, gutter, search box */
/* navigation-bar */
/* context menu */
/* contents: json key and values */
/* contents: selected or hovered */
/* contents: section of collapsed items in an array */
/* contents: highlighting of search matches */
/* contents: inline tags inside the JSON document */
/* contents: table */
/* controls in modals: inputs, buttons, and \`a\` */
/* messages */
/* svelte-select */
/* color picker */
.jse-value.jse-string.svelte-6ttr41 {
  color: var(--jse-value-color-string, #008000);
}
.jse-value.jse-object.svelte-6ttr41, .jse-value.jse-array.svelte-6ttr41 {
  min-width: 16px;
  color: var(--jse-delimiter-color, rgba(0, 0, 0, 0.38));
}
.jse-value.jse-number.svelte-6ttr41 {
  color: var(--jse-value-color-number, #ee422e);
}
.jse-value.jse-boolean.svelte-6ttr41 {
  color: var(--jse-value-color-boolean, #ff8c00);
}
.jse-value.jse-null.svelte-6ttr41 {
  color: var(--jse-value-color-null, #004ed0);
}
.jse-value.jse-invalid.svelte-6ttr41 {
  color: var(--jse-text-color, #4d4d4d);
}
.jse-value.jse-url.svelte-6ttr41 {
  color: var(--jse-value-color-url, #008000);
  text-decoration: underline;
}

.jse-enum-value.svelte-6ttr41 {
  background: var(--jse-hover-background-color, rgba(0, 0, 0, 0.06));
  border: none;
  padding: 0;
  font-family: inherit;
  font-size: inherit;
  cursor: pointer;
  outline: none;
}
.jse-enum-value.jse-selected.svelte-6ttr41 {
  background: var(--jse-selection-background-color, #d3d3d3);
  color: inherit;
}
.jse-enum-value.jse-value.svelte-6ttr41:focus {
  color: var(--jse-text-color, #4d4d4d);
}`);var zpe=pA("<option> </option>"),Hpe=pA("<select></select>");var zD,HD;function OD(t,e){return zD||(HD=new WeakMap,zD=new ResizeObserver(A=>{for(var i of A){var n=HD.get(i.target);n&&n(i.target)}})),HD.set(t,e),zD.observe(t),{destroy:()=>{HD.delete(t),zD.unobserve(t)}}}vt(`/* over all fonts, sizes, and colors */
/* "consolas" for Windows, "menlo" for Mac with fallback to "monaco", 'Ubuntu Mono' for Ubuntu */
/* (at Mac this font looks too large at 14px, but 13px is too small for the font on Windows) */
/* main, menu, modal */
/* jsoneditor modal */
/* tooltip in text mode */
/* panels: navigation bar, gutter, search box */
/* navigation-bar */
/* context menu */
/* contents: json key and values */
/* contents: selected or hovered */
/* contents: section of collapsed items in an array */
/* contents: highlighting of search matches */
/* contents: inline tags inside the JSON document */
/* contents: table */
/* controls in modals: inputs, buttons, and \`a\` */
/* messages */
/* svelte-select */
/* color picker */
.jse-tree-mode.svelte-vrx1dr {
  flex: 1;
  display: flex;
  flex-direction: column;
  position: relative;
  background: var(--jse-background-color, #fff);
  min-width: 0;
  min-height: 0;
  font-family: var(--jse-font-family-mono, consolas, menlo, monaco, "Ubuntu Mono", "source-code-pro", monospace);
  font-size: var(--jse-font-size-mono, 14px);
  color: var(--jse-text-color, #4d4d4d);
  line-height: var(--jse-line-height, calc(1em + 4px));
}
.jse-tree-mode.svelte-vrx1dr .jse-hidden-input-label:where(.svelte-vrx1dr) .jse-hidden-input:where(.svelte-vrx1dr) {
  position: fixed;
  top: -10px;
  left: -10px;
  width: 1px;
  height: 1px;
  padding: 0;
  border: 0;
  outline: none;
}
.jse-tree-mode.no-main-menu.svelte-vrx1dr {
  border-top: var(--jse-main-border, 1px solid #d7d7d7);
}
.jse-tree-mode.svelte-vrx1dr .jse-search-box-container:where(.svelte-vrx1dr) {
  position: relative;
  height: 0;
  top: var(--jse-padding, 10px);
  margin-right: calc(var(--jse-padding, 10px) + 20px);
  margin-left: var(--jse-padding, 10px);
  text-align: right;
  z-index: 3;
}
.jse-tree-mode.svelte-vrx1dr .jse-contents:where(.svelte-vrx1dr) {
  flex: 1;
  overflow: auto;
  position: relative;
  padding: 2px;
  display: flex;
  flex-direction: column;
  border-left: var(--jse-main-border, 1px solid #d7d7d7);
  border-right: var(--jse-main-border, 1px solid #d7d7d7);
}
.jse-tree-mode.svelte-vrx1dr .jse-contents:where(.svelte-vrx1dr):last-child {
  border-bottom: var(--jse-main-border, 1px solid #d7d7d7);
}
.jse-tree-mode.svelte-vrx1dr .jse-contents:where(.svelte-vrx1dr) .jse-loading-space:where(.svelte-vrx1dr) {
  flex: 1;
}
.jse-tree-mode.svelte-vrx1dr .jse-contents:where(.svelte-vrx1dr) .jse-loading:where(.svelte-vrx1dr) {
  flex: 2;
  text-align: center;
  color: var(--jse-panel-color-readonly, #b2b2b2);
  box-sizing: border-box;
  font-family: var(--jse-font-family, -apple-system, BlinkMacSystemFont, "Segoe UI", Roboto, Oxygen-Sans, Ubuntu, Cantarell, "Helvetica Neue", sans-serif);
  font-size: var(--jse-font-size, 16px);
}
.jse-tree-mode.svelte-vrx1dr .jse-contents:where(.svelte-vrx1dr) .jse-search-box-background:where(.svelte-vrx1dr) {
  border: 50px solid var(--jse-modal-background, #f5f5f5);
  margin: -2px;
  margin-bottom: 2px;
  display: inline-block;
}`);var kYA=pA("<!> <!>",1),SYA=pA('<div class="jse-search-box-background svelte-vrx1dr"></div>'),RYA=pA('<div class="jse-search-box-container svelte-vrx1dr"><!></div> <div class="jse-contents svelte-vrx1dr"><!> <!></div> <!> <!> <!> <!>',1),LYA=pA('<label class="jse-hidden-input-label svelte-vrx1dr"><input type="text" tabindex="-1" class="jse-hidden-input svelte-vrx1dr"/></label> <!>',1),xYA=pA('<div class="jse-contents svelte-vrx1dr"><div class="jse-loading-space svelte-vrx1dr"></div> <div class="jse-loading svelte-vrx1dr">loading...</div></div>'),FYA=pA('<div role="tree" tabindex="-1"><!> <!> <!></div> <!> <!>',1);function M_(t,e){st(e,!1);var A=X(void 0,!0),i=wr("jsoneditor:TreeMode"),n=typeof window>"u";i("isSSR:",n);var o=n1(),r=n1(),{openAbsolutePopup:s,closeAbsolutePopup:a}=H1("absolute-popup"),c=X(void 0,!0),l=X(void 0,!0),I=X(void 0,!0),C=!1,d=ZsA(),B=k(e,"readOnly",9),E=k(e,"externalContent",9),Q=k(e,"externalSelection",9),u=k(e,"history",9),v=k(e,"truncateTextSize",9),L=k(e,"mainMenuBar",9),x=k(e,"navigationBar",9),y=k(e,"escapeControlCharacters",9),F=k(e,"escapeUnicodeCharacters",9),U=k(e,"parser",9),T=k(e,"parseMemoizeOne",9),N=k(e,"validator",9),K=k(e,"validationParser",9),H=k(e,"pathParser",9),j=k(e,"indentation",9),IA=k(e,"onError",9),lA=k(e,"onChange",9),uA=k(e,"onChangeMode",9),p=k(e,"onSelect",9),V=k(e,"onUndo",9),cA=k(e,"onRedo",9),aA=k(e,"onRenderValue",9),jA=k(e,"onRenderMenu",9),VA=k(e,"onRenderContextMenu",9),ce=k(e,"onClassName",9),EA=k(e,"onFocus",9),sA=k(e,"onBlur",9),TA=k(e,"onSortModal",9),Ke=k(e,"onTransformModal",9),Re=k(e,"onJSONEditorModal",9),hA=!1,eA=X(!1,!0),RA=X(void 0,!0);iG({onMount:ls,onDestroy:Tc,getWindow:()=>j3(g(I)),hasFocus:()=>hA&&document.hasFocus()||J_(g(I)),onFocus:()=>{C=!0,EA()&&EA()()},onBlur:()=>{C=!1,sA()&&sA()()}});var oA=X(void 0,!0),ne=X(void 0,!0),h=void 0,f=!1,w=X(I_({json:g(oA)}),!0),D=X(F3(Q())?Q():void 0,!0);function O(J){b(D,J)}ls(()=>{if(g(D)){var J=je(g(D));b(w,pl(g(oA),g(w),J,VD)),setTimeout(()=>ii(J))}});var Z,q=X(void 0,!0),CA=X(void 0,!0),kA=X(void 0,!0),KA=X(void 0,!0),Ie=X(!1,!0),GA=X(!1,!0);function oe(J){b(KA,(Z=J)?GsA(g(oA),Z.items):void 0)}function M(J,rA){return G.apply(this,arguments)}function G(){return(G=yt(function*(J,rA){b(w,pl(g(oA),g(w),J,VD));var JA=Tn(rA);yield $e(J,{element:JA})})).apply(this,arguments)}function Y(){b(Ie,!1),b(GA,!1),Xi()}function AA(J){i("select validation error",J),b(D,hi(J.path)),$e(J.path)}function dA(J){var rA=arguments.length>1&&arguments[1]!==void 0?arguments[1]:ZoA;i("expand"),b(w,pl(g(oA),g(w),J,rA))}function WA(J,rA){b(w,PoA(g(oA),g(w),J,rA)),g(D)&&function(JA,Se){return e2(je(JA),Se)&&(je(JA).length>Se.length||as(JA))}(g(D),J)&&b(D,void 0)}var Qe=X(!1,!0),yA=X([],!0),DA=X(void 0,!0),We=VB(WsA);function be(J,rA,JA,Se){OE(()=>{var pe;try{pe=We(J,rA,JA,Se)}catch(me){pe=[{path:[],message:"Failed to validate: "+me.message,severity:bl.warning}]}Ei(pe,g(yA))||(i("validationErrors changed:",pe),b(yA,pe),b(DA,function(me,ft){var mt;return ft.forEach(ci=>{mt=BrA(me,mt,ci.path,(rn,yi)=>Be(Be({},yi),{},{validationError:ci}))}),ft.forEach(ci=>{for(var rn=ci.path;rn.length>0;)rn=pi(rn),mt=BrA(me,mt,rn,(yi,Rn)=>Rn.validationError?Rn:Be(Be({},Rn),{},{validationError:{isChildError:!0,path:rn,message:"Contains invalid data",severity:bl.warning}}))}),mt}(J,g(yA))))},pe=>i("validationErrors updated in ".concat(pe," ms")))}function qA(){return i("validate"),h?{parseError:h,isRepairable:!1}:(be(g(oA),N(),U(),K()),sn(g(yA))?void 0:{validationErrors:g(yA)})}function It(){return g(oA)}function Vi(){return g(w)}function on(){return g(D)}function Hi(J){i("applyExternalContent",{updatedContent:J}),k3(J)?function(rA){if(rA!==void 0){var JA=!Ei(g(oA),rA);if(i("update external json",{isChanged:JA,currentlyText:g(oA)===void 0}),!!JA){var Se={documentState:g(w),selection:g(D),json:g(oA),text:g(ne),textIsRepaired:g(Qe)};b(oA,rA),b(w,cc(rA,g(w))),Ci(g(oA)),b(ne,void 0),b(Qe,!1),h=void 0,Zi(g(oA)),Qi(Se)}}}(J.json):M3(J)&&function(rA){if(!(rA===void 0||k3(E()))){var JA=rA!==g(ne);if(i("update external text",{isChanged:JA}),!!JA){var Se={documentState:g(w),selection:g(D),json:g(oA),text:g(ne),textIsRepaired:g(Qe)};try{b(oA,T()(rA)),b(w,cc(g(oA),g(w))),Ci(g(oA)),b(ne,rA),b(Qe,!1),h=void 0}catch(pe){try{b(oA,T()(yc(rA))),b(w,cc(g(oA),g(w))),Ci(g(oA)),b(ne,rA),b(Qe,!0),h=void 0,Zi(g(oA))}catch{b(oA,void 0),b(w,void 0),b(ne,E().text),b(Qe,!1),h=g(ne)!==void 0&&g(ne)!==""?XE(g(ne),pe.message||String(pe)):void 0}}Zi(g(oA)),Qi(Se)}}}(J.text)}function Ci(J){f||(f=!0,b(w,KC(J,g(w),[])))}function Zi(J){g(D)&&(Qs(J,SC(g(D)))&&Qs(J,je(g(D)))||(i("clearing selection: path does not exist anymore",g(D)),b(D,GE(J,g(w)))))}function Qi(J){if(J.json!==void 0||J.text!==void 0){var rA=g(oA)!==void 0&&J.json!==void 0;u().add({type:"tree",undo:{patch:rA?[{op:"replace",path:"",value:J.json}]:void 0,json:J.json,text:J.text,documentState:J.documentState,textIsRepaired:J.textIsRepaired,selection:Fg(J.selection),sortedColumn:void 0},redo:{patch:rA?[{op:"replace",path:"",value:g(oA)}]:void 0,json:g(oA),text:g(ne),documentState:g(w),textIsRepaired:g(Qe),selection:Fg(g(D)),sortedColumn:void 0}})}}function Ft(J,rA){var JA;if(i("patch",J,rA),g(oA)===void 0)throw new Error("Cannot apply patch: no JSON");var Se=g(oA),pe={json:void 0,text:g(ne),documentState:g(w),selection:Fg(g(D)),textIsRepaired:g(Qe),sortedColumn:void 0},me=_sA(g(oA),J),ft=DsA(g(oA),g(w),J),mt=(JA=Ah(g(oA),J))!==null&&JA!==void 0?JA:g(D),ci=typeof rA=="function"?rA(ft.json,ft.documentState,mt):void 0;return b(oA,ci?.json!==void 0?ci.json:ft.json),b(w,ci?.state!==void 0?ci.state:ft.documentState),b(D,ci?.selection!==void 0?ci.selection:mt),b(ne,void 0),b(Qe,!1),b(CA,void 0),b(kA,void 0),h=void 0,Zi(g(oA)),u().add({type:"tree",undo:Be({patch:me},pe),redo:{patch:J,json:void 0,text:g(ne),documentState:g(w),selection:Fg(g(D)),sortedColumn:void 0,textIsRepaired:g(Qe)}}),{json:g(oA),previousJson:Se,undo:me,redo:J}}function Tt(){!B()&&g(D)&&b(D,$_(je(g(D))))}function Ht(){if(!B()&&g(D)){var J=je(g(D)),rA=Fe(g(oA),J);zo(rA)?function(JA,Se){i("openJSONEditorModal",{path:JA,value:Se}),hA=!0,Re()({content:{json:Se},path:JA,onPatch:g(yn).onPatch,onClose:()=>{hA=!1,setTimeout(Xi)}})}(J,rA):b(D,sy(J))}}function zi(){if(!B()&&dn(g(D))){var J=je(g(D)),rA=nt(J),JA=Fe(g(oA),J),Se=!Z0(g(oA),g(w),J),pe=Se?String(JA):ah(String(JA),U());i("handleToggleEnforceString",{enforceString:Se,value:JA,updatedValue:pe}),dt([{op:"replace",path:rA,value:pe}],(me,ft)=>({state:by(g(oA),ft,J,{type:"value",enforceString:Se})}))}}function ui(){return g(Qe)&&g(oA)!==void 0&&zn(g(oA)),g(oA)!==void 0?{json:g(oA)}:{text:g(ne)||""}}function Ye(){return Ai.apply(this,arguments)}function Ai(){return Ai=yt(function*(){var J=!(arguments.length>0&&arguments[0]!==void 0)||arguments[0];yield oaA({json:g(oA),selection:g(D),indentation:J?j():void 0,readOnly:B(),parser:U(),onPatch:dt})}),Ai.apply(this,arguments)}function ei(){return Oi.apply(this,arguments)}function Oi(){return Oi=yt(function*(){var J=!(arguments.length>0&&arguments[0]!==void 0)||arguments[0];g(oA)!==void 0&&(yield raA({json:g(oA),selection:g(D),indentation:J?j():void 0,parser:U()}))}),Oi.apply(this,arguments)}function Yn(J){var rA;J.preventDefault(),Sn((rA=J.clipboardData)===null||rA===void 0?void 0:rA.getData("text/plain"))}function Dn(){return Ho.apply(this,arguments)}function Ho(){return(Ho=yt(function*(){try{Sn(yield navigator.clipboard.readText())}catch(J){console.error(J),b(eA,!0)}})).apply(this,arguments)}function Sn(J){J!==void 0&&saA({clipboardText:J,json:g(oA),selection:g(D),readOnly:B(),parser:U(),onPatch:dt,onChangeText:QA,onPasteMultilineText:Co,openRepairModal:io})}function io(J,rA){b(RA,{text:J,onParse:JA=>P3(JA,Se=>O3(Se,U())),onRepair:lsA,onApply:rA,onClose:Xi})}function Wo(){aaA({json:g(oA),text:g(ne),selection:g(D),keepSelection:!1,readOnly:B(),onChange:lA(),onPatch:dt})}function No(){!B()&&g(oA)!==void 0&&g(D)&&zE&&!sn(je(g(D)))&&(i("duplicate",{selection:g(D)}),dt(LsA(g(oA),z1(g(oA),g(D)))))}function Jn(){B()||!g(D)||!Ao(g(D))&&!dn(g(D))||sn(je(g(D)))||(i("extract",{selection:g(D)}),dt(xsA(g(oA),g(D)),(J,rA)=>{if(zo(J))return{state:_N(J,rA,[])}}))}function hn(J){Ey({insertType:J,selectInside:!0,initialValue:void 0,json:g(oA),selection:g(D),readOnly:B(),parser:U(),onPatch:dt,onReplaceJson:zn})}function wo(J){pr(g(D))&&b(D,hi(g(D).path)),g(D)||b(D,GE(g(oA),g(w))),hn(J)}function se(J){if(!B()&&g(D))if(KD(g(D)))try{var rA=SC(g(D)),JA=Fe(g(oA),rA),Se=function(me,ft,mt){if(ft==="array"){if(Array.isArray(me))return me;if(tn(me))return FoA(me);if(typeof me=="string")try{var ci=mt.parse(me);if(Array.isArray(ci))return ci;if(tn(ci))return FoA(ci)}catch{return[me]}return[me]}if(ft==="object"){if(Array.isArray(me))return xoA(me);if(tn(me))return me;if(typeof me=="string")try{var rn=mt.parse(me);if(tn(rn))return rn;if(Array.isArray(rn))return xoA(rn)}catch{return{value:me}}return{value:me}}if(ft==="value")return zo(me)?mt.stringify(me):me;throw new Error("Cannot convert ".concat(U_(me,mt)," to ").concat(ft))}(JA,J,U());if(Se===JA)return;var pe=[{op:"replace",path:nt(rA),value:Se}];i("handleConvert",{selection:g(D),path:rA,type:J,operations:pe}),dt(pe,(me,ft)=>({state:g(D)?KC(me,ft,je(g(D))):g(w)}))}catch(me){IA()(me)}else IA()(new Error("Cannot convert current selection to ".concat(J)))}function fi(){if(g(D)){var J=WoA(g(oA),g(w),g(D),!1),rA=pi(je(g(D)));J&&!sn(je(J))&&Ei(rA,pi(je(J)))?b(D,W0(je(J))):b(D,i2(rA)),i("insert before",{selection:g(D),selectionBefore:J,parentPath:rA}),go(),un()}}function bA(){if(g(D)){var J=Y1(g(oA),g(D));i("insert after",J),b(D,W0(J)),go(),un()}}function fe(J){return it.apply(this,arguments)}function it(){return(it=yt(function*(J){yield caA({char:J,selectInside:!0,json:g(oA),selection:g(D),readOnly:B(),parser:U(),onPatch:dt,onReplaceJson:zn,onSelect:O})})).apply(this,arguments)}function Gt(){if(!B()&&u().canUndo){var J=u().undo();if(oy(J)){var rA={json:g(oA),text:g(ne)};b(oA,J.undo.patch?Ba(g(oA),J.undo.patch):J.undo.json),b(w,J.undo.documentState),b(D,J.undo.selection),b(ne,J.undo.text),b(Qe,J.undo.textIsRepaired),h=void 0,i("undo",{item:J,json:g(oA),documentState:g(w),selection:g(D)}),Ri(rA,J.undo.patch&&J.redo.patch?{json:g(oA),previousJson:rA.json,redo:J.undo.patch,undo:J.redo.patch}:void 0),Xi(),g(D)&&$e(je(g(D)),{scrollToWhenVisible:!1})}else V()(J)}}function Xe(){if(!B()&&u().canRedo){var J=u().redo();if(oy(J)){var rA={json:g(oA),text:g(ne)};b(oA,J.redo.patch?Ba(g(oA),J.redo.patch):J.redo.json),b(w,J.redo.documentState),b(D,J.redo.selection),b(ne,J.redo.text),b(Qe,J.redo.textIsRepaired),h=void 0,i("redo",{item:J,json:g(oA),documentState:g(w),selection:g(D)}),Ri(rA,J.undo.patch&&J.redo.patch?{json:g(oA),previousJson:rA.json,redo:J.redo.patch,undo:J.undo.patch}:void 0),Xi(),g(D)&&$e(je(g(D)),{scrollToWhenVisible:!1})}else cA()(J)}}function Ot(J){var rA;B()||g(oA)===void 0||(hA=!0,TA()({id:o,json:g(oA),rootPath:J,onSort:(rA=yt(function*(JA){var{operations:Se}=JA;i("onSort",J,Se),dt(Se,(pe,me)=>({state:_N(pe,me,J),selection:hi(J)}))}),function(JA){return rA.apply(this,arguments)}),onClose:()=>{hA=!1,setTimeout(Xi)}}))}function Pi(){g(D)&&Ot($oA(g(oA),g(D)))}function Jt(){Ot([])}function Ki(J){if(g(oA)!==void 0){var{id:rA,onTransform:JA,onClose:Se}=J,pe=J.rootPath||[];hA=!0,Ke()({id:rA||r,json:g(oA),rootPath:pe,onTransform:me=>{JA?JA({operations:me,json:g(oA),transformedJson:Ba(g(oA),me)}):(i("onTransform",pe,me),dt(me,(ft,mt)=>({state:_N(ft,mt,pe),selection:hi(pe)})))},onClose:()=>{hA=!1,setTimeout(Xi),Se&&Se()}})}}function Ct(){g(D)&&Ki({rootPath:$oA(g(oA),g(D))})}function ti(){Ki({rootPath:[]})}function $e(J){return Nt.apply(this,arguments)}function Nt(){return Nt=yt(function*(J){var{scrollToWhenVisible:rA=!0,element:JA}=arguments.length>1&&arguments[1]!==void 0?arguments[1]:{};b(w,pl(g(oA),g(w),J,VD));var Se=JA??Wi(J);if(i("scrollTo",{path:J,elem:Se,refContents:g(c)}),!Se||!g(c))return Promise.resolve();var pe=g(c).getBoundingClientRect(),me=Se.getBoundingClientRect();if(!rA&&me.bottom>pe.top&&me.top<pe.bottom)return Promise.resolve();var ft=-pe.height/4;return new Promise(mt=>{d(Se,{container:g(c),offset:ft,duration:300,callback:()=>mt()})})}),Nt.apply(this,arguments)}function Wi(J){var rA,JA;return go(),(rA=(JA=g(c))===null||JA===void 0?void 0:JA.querySelector('div[data-path="'.concat(a_(J),'"]')))!==null&&rA!==void 0?rA:void 0}function Tn(J){var rA,JA;return go(),(rA=(JA=g(c))===null||JA===void 0?void 0:JA.querySelector('span[data-search-result-index="'.concat(J,'"]')))!==null&&rA!==void 0?rA:void 0}function ii(J){var rA=Wi(J);if(rA&&g(c)){var JA=g(c).getBoundingClientRect(),Se=rA.getBoundingClientRect(),pe=zo(Fe(g(oA),J))?20:Se.height;Se.top<JA.top+20?d(rA,{container:g(c),offset:-20,duration:0}):Se.top+pe>JA.bottom-20&&d(rA,{container:g(c),offset:-(JA.height-pe-20),duration:0})}}function Ri(J,rA){if(J.json!==void 0||J?.text!==void 0){if(g(ne)!==void 0){var JA,Se={text:g(ne),json:void 0};(JA=lA())===null||JA===void 0||JA(Se,J,{contentErrors:qA(),patchResult:rA})}else if(g(oA)!==void 0){var pe,me={text:void 0,json:g(oA)};(pe=lA())===null||pe===void 0||pe(me,J,{contentErrors:qA(),patchResult:rA})}}}function dt(J,rA){i("handlePatch",J,rA);var JA={json:g(oA),text:g(ne)},Se=Ft(J,rA);return Ri(JA,Se),Se}function zn(J,rA){var JA={json:g(oA),text:g(ne)},Se={documentState:g(w),selection:g(D),json:g(oA),text:g(ne),textIsRepaired:g(Qe)},pe=pl(g(oA),cc(J,g(w)),[],w3),me=typeof rA=="function"?rA(J,pe,g(D)):void 0;b(oA,me?.json!==void 0?me.json:J),b(w,me?.state!==void 0?me.state:pe),b(D,me?.selection!==void 0?me.selection:g(D)),b(ne,void 0),b(Qe,!1),h=void 0,Zi(g(oA)),Qi(Se),Ri(JA,void 0)}function QA(J,rA){i("handleChangeText");var JA={json:g(oA),text:g(ne)},Se={documentState:g(w),selection:g(D),json:g(oA),text:g(ne),textIsRepaired:g(Qe)};try{b(oA,T()(J)),b(w,pl(g(oA),cc(g(oA),g(w)),[],w3)),b(ne,void 0),b(Qe,!1),h=void 0}catch(me){try{b(oA,T()(yc(J))),b(w,pl(g(oA),cc(g(oA),g(w)),[],w3)),b(ne,J),b(Qe,!0),h=void 0}catch{b(oA,void 0),b(w,I_({json:g(oA),expand:w3})),b(ne,J),b(Qe,!1),h=g(ne)!==""?XE(g(ne),me.message||String(me)):void 0}}if(typeof rA=="function"){var pe=rA(g(oA),g(w),g(D));b(oA,pe?.json!==void 0?pe.json:g(oA)),b(w,pe?.state!==void 0?pe.state:g(w)),b(D,pe?.selection!==void 0?pe.selection:g(D))}Zi(g(oA)),Qi(Se),Ri(JA,void 0)}function _A(J,rA){var JA=arguments.length>2&&arguments[2]!==void 0&&arguments[2];i("handleExpand",{path:J,expanded:rA,recursive:JA}),rA?dA(J,JA?X_:ZoA):WA(J,JA),Xi()}function Ce(){_A([],!0,!0)}function Pt(){_A([],!1,!0)}function Li(J){i("openFind",{findAndReplace:J}),b(Ie,!1),b(GA,!1),go(),b(Ie,!0),b(GA,J)}function ai(J,rA){i("handleExpandSection",J,rA),b(w,function(JA,Se,pe,me){return $E(JA,Se,pe,(ft,mt)=>{if(!cs(mt))return mt;var ci=msA(mt.visibleSections.concat(me));return Be(Be({},mt),{},{visibleSections:ci})})}(g(oA),g(w),J,rA))}function Fn(J){i("pasted json as text",J),b(CA,J)}function Co(J){i("pasted multiline text",{pastedText:J}),b(kA,J)}function Qn(J){var rA,{anchor:JA,left:Se,top:pe,width:me,height:ft,offsetTop:mt,offsetLeft:ci,showTip:rn}=J,yi=function(mn){var{json:Hn,documentState:ji,selection:ht,readOnly:Fi,onEditKey:Qt,onEditValue:At,onToggleEnforceString:Ni,onCut:Oo,onCopy:Dr,onPaste:Eo,onRemove:Po,onDuplicate:Vr,onExtract:o2,onInsertBefore:xa,onInsert:Oc,onConvert:Gl,onInsertAfter:Pc,onSort:Ur,onTransform:Ss}=mn,Fa=Hn!==void 0,jg=!!ht,Na=!!ht&&sn(je(ht)),Do=ht?Fe(Hn,je(ht)):void 0,Go=Array.isArray(Do)?"Edit array":tn(Do)?"Edit object":"Edit value",jo=Fa&&(Ao(ht)||pr(ht)||dn(ht)),qg=ht&&!Na?Fe(Hn,pi(je(ht))):void 0,vh=!Fi&&Fa&&ry(ht)&&!Na&&!Array.isArray(qg),ed=!Fi&&Fa&&ht!==void 0&&ry(ht),bh=ed&&!zo(Do),td=!Fi&&jo,Mh=jo,p7=!Fi&&jg,w7=!Fi&&Fa&&jo&&!Na,D7=!Fi&&Fa&&ht!==void 0&&(Ao(ht)||dn(ht))&&!Na,Ul=jo,V1=Ul?"Convert to:":"Insert:",$o=!Fi&&(as(ht)&&Array.isArray(Do)||Yc(ht)&&Array.isArray(qg)),dc=!Fi&&(Ul?KD(ht)&&!tn(Do):jg),kh=!Fi&&(Ul?KD(ht)&&!Array.isArray(Do):jg),Sh=!Fi&&(Ul?KD(ht)&&zo(Do):jg),Z1=ht!==void 0&&Z0(Hn,ji,je(ht));function Zr(Rh){jo?Rh!=="structure"&&Gl(Rh):Oc(Rh)}return[{type:"row",items:[{type:"button",onClick:()=>Qt(),icon:ZI,text:"Edit key",title:"Edit the key (Double-click on the key)",disabled:!vh},{type:"dropdown-button",main:{type:"button",onClick:()=>At(),icon:ZI,text:Go,title:"Edit the value (Double-click on the value)",disabled:!ed},width:"11em",items:[{type:"button",icon:ZI,text:Go,title:"Edit the value (Double-click on the value)",onClick:()=>At(),disabled:!ed},{type:"button",icon:Z1?xS:NS,text:"Enforce string",title:"Enforce keeping the value as string when it contains a numeric value",onClick:()=>Ni(),disabled:!bh}]}]},{type:"separator"},{type:"row",items:[{type:"dropdown-button",main:{type:"button",onClick:()=>Oo(!0),icon:VI,text:"Cut",title:"Cut selected contents, formatted with indentation (Ctrl+X)",disabled:!td},width:"10em",items:[{type:"button",icon:VI,text:"Cut formatted",title:"Cut selected contents, formatted with indentation (Ctrl+X)",onClick:()=>Oo(!0),disabled:!td},{type:"button",icon:VI,text:"Cut compacted",title:"Cut selected contents, without indentation (Ctrl+Shift+X)",onClick:()=>Oo(!1),disabled:!td}]},{type:"dropdown-button",main:{type:"button",onClick:()=>Dr(!0),icon:S0,text:"Copy",title:"Copy selected contents, formatted with indentation (Ctrl+C)",disabled:!Mh},width:"12em",items:[{type:"button",icon:S0,text:"Copy formatted",title:"Copy selected contents, formatted with indentation (Ctrl+C)",onClick:()=>Dr(!0),disabled:!Mh},{type:"button",icon:S0,text:"Copy compacted",title:"Copy selected contents, without indentation (Ctrl+Shift+C)",onClick:()=>Dr(!1),disabled:!Mh}]},{type:"button",onClick:()=>Eo(),icon:LS,text:"Paste",title:"Paste clipboard contents (Ctrl+V)",disabled:!p7}]},{type:"separator"},{type:"row",items:[{type:"column",items:[{type:"button",onClick:()=>Vr(),icon:US,text:"Duplicate",title:"Duplicate selected contents (Ctrl+D)",disabled:!w7},{type:"button",onClick:()=>o2(),icon:bW,text:"Extract",title:"Extract selected contents",disabled:!D7},{type:"button",onClick:()=>Ur(),icon:Vu,text:"Sort",title:"Sort array or object contents",disabled:Fi||!jo},{type:"button",onClick:()=>Ss(),icon:Pu,text:"Transform",title:"Transform array or object contents (filter, sort, project)",disabled:Fi||!jo},{type:"button",onClick:()=>Po(),icon:o5,text:"Remove",title:"Remove selected contents (Delete)",disabled:Fi||!jo}]},{type:"column",items:[{type:"label",text:V1},{type:"button",onClick:()=>Zr("structure"),icon:Ul?qu:WI,text:"Structure",title:V1+" structure like the first item in the array",disabled:!$o},{type:"button",onClick:()=>Zr("object"),icon:Ul?qu:WI,text:"Object",title:V1+" object",disabled:!dc},{type:"button",onClick:()=>Zr("array"),icon:Ul?qu:WI,text:"Array",title:V1+" array",disabled:!kh},{type:"button",onClick:()=>Zr("value"),icon:Ul?qu:WI,text:"Value",title:V1+" value",disabled:!Sh}]}]},{type:"separator"},{type:"row",items:[{type:"button",onClick:()=>xa(),icon:DW,text:"Insert before",title:"Select area before current entry to insert or paste contents",disabled:Fi||!jo||Na},{type:"button",onClick:()=>Pc(),icon:fW,text:"Insert after",title:"Select area after current entry to insert or paste contents",disabled:Fi||!jo||Na}]}]}({json:g(oA),documentState:g(w),selection:g(D),readOnly:B(),onEditKey:Tt,onEditValue:Ht,onToggleEnforceString:zi,onCut:Ye,onCopy:ei,onPaste:Dn,onRemove:Wo,onDuplicate:No,onExtract:Jn,onInsertBefore:fi,onInsert:wo,onInsertAfter:bA,onConvert:se,onSort:Pi,onTransform:Ct}),Rn=(rA=VA()(yi))!==null&&rA!==void 0?rA:yi;if(Rn!==!1){var bt={left:Se,top:pe,offsetTop:mt,offsetLeft:ci,width:me,height:ft,anchor:JA,closeOnOuterClick:!0,onClose:()=>{hA=!1,Xi()}};hA=!0;var Bo=s(gaA,{tip:rn?"Tip: you can open this context menu via right-click or with Ctrl+Q":void 0,items:Rn,onRequestClose:()=>a(Bo)},bt)}}function un(J){if(!Ma(g(D)))if(J&&(J.stopPropagation(),J.preventDefault()),J&&J.type==="contextmenu"&&J.target!==g(l))Qn({left:J.clientX,top:J.clientY,width:O0,height:H0,showTip:!1});else{var rA,JA=(rA=g(c))===null||rA===void 0?void 0:rA.querySelector(".jse-context-menu-pointer.jse-selected");if(JA)Qn({anchor:JA,offsetTop:2,width:O0,height:H0,showTip:!1});else{var Se,pe=(Se=g(c))===null||Se===void 0?void 0:Se.getBoundingClientRect();pe&&Qn({top:pe.top+2,left:pe.left+2,width:O0,height:H0,showTip:!1})}}}function jt(J){Qn({anchor:usA(J.target,"BUTTON"),offsetTop:0,width:O0,height:H0,showTip:!0})}function Nn(){return ut.apply(this,arguments)}function ut(){return(ut=yt(function*(){if(i("apply pasted json",g(CA)),g(CA)){var{onPasteAsJson:J}=g(CA);b(CA,void 0),J(),setTimeout(Xi)}})).apply(this,arguments)}function Xo(){return Oe.apply(this,arguments)}function Oe(){return(Oe=yt(function*(){i("apply pasted multiline text",g(kA)),g(kA)&&(Sn(JSON.stringify(g(kA))),setTimeout(Xi))})).apply(this,arguments)}function ni(){i("clear pasted json"),b(CA,void 0),Xi()}function fn(){i("clear pasted multiline text"),b(kA,void 0),Xi()}function Yi(){uA()(tr.text)}function ir(J){b(D,J),Xi(),$e(je(J))}function Xi(){i("focus"),g(l)&&(g(l).focus(),g(l).select())}function ks(J){return function(rA,JA,Se){var pe=pi(Se),me=[ri(Se)],ft=Fe(rA,pe),mt=ft?NN(ft,JA,me):void 0;return mt?hi(pe.concat(mt)):W0(Se)}(g(oA),g(w),J)}function La(J){g(A)&&g(A).onDrag(J)}function _o(){g(A)&&g(A).onDragEnd()}var yn=X(void 0,!0);fA(()=>g(D),()=>{var J;J=g(D),Ei(J,Q())||(i("onSelect",J),p()(J))}),fA(()=>(W(y()),W(F())),()=>{b(q,K_({escapeControlCharacters:y(),escapeUnicodeCharacters:F()}))}),fA(()=>g(Ie),()=>{(function(J){g(c)&&J&&g(c).scrollTop===0&&(lc(c,g(c).style.overflowAnchor="none"),lc(c,g(c).scrollTop+=p3),setTimeout(()=>{g(c)&&lc(c,g(c).style.overflowAnchor="")}))})(g(Ie))}),fA(()=>W(E()),()=>{Hi(E())}),fA(()=>W(Q()),()=>{(function(J){Ei(g(D),J)||(i("applyExternalSelection",{selection:g(D),externalSelection:J}),F3(J)&&b(D,J))})(Q())}),fA(()=>(g(oA),W(N()),W(U()),W(K())),()=>{be(g(oA),N(),U(),K())}),fA(()=>(g(c),drA),()=>{b(A,g(c)?drA(g(c)):void 0)}),fA(()=>(W(B()),W(v()),W(U()),g(q),W(aA()),W(ce())),()=>{b(yn,{mode:tr.tree,readOnly:B(),truncateTextSize:v(),parser:U(),normalization:g(q),getJson:It,getDocumentState:Vi,getSelection:on,findElement:Wi,findNextInside:ks,focus:Xi,onPatch:dt,onInsert:hn,onExpand:_A,onSelect:O,onFind:Li,onExpandSection:ai,onPasteJson:Fn,onRenderValue:aA(),onContextMenu:Qn,onClassName:ce()||(()=>{}),onDrag:La,onDragEnd:_o})}),fA(()=>g(yn),()=>{i("context changed",g(yn))}),nn(),Rt(!0);var Gr=FYA();re("mousedown",q0,function(J){!ch(J.target,rA=>rA===g(I))&&Ma(g(D))&&(i("click outside the editor, exit edit mode"),b(D,Fg(g(D))),C&&g(l)&&(g(l).focus(),g(l).blur()),i("blur (outside editor)"),g(l)&&g(l).blur())});var z,wA=Bt(Gr),ee=$(wA),Me=J=>{(function(rA,JA){st(JA,!1);var Se=X(void 0,!0),pe=X(void 0,!0),me=X(void 0,!0),ft=k(JA,"json",9),mt=k(JA,"selection",9),ci=k(JA,"readOnly",9),rn=k(JA,"showSearch",13,!1),yi=k(JA,"history",9),Rn=k(JA,"onExpandAll",9),bt=k(JA,"onCollapseAll",9),Bo=k(JA,"onUndo",9),mn=k(JA,"onRedo",9),Hn=k(JA,"onSort",9),ji=k(JA,"onTransform",9),ht=k(JA,"onContextMenu",9),Fi=k(JA,"onCopy",9),Qt=k(JA,"onRenderMenu",9);function At(){rn(!rn())}var Ni=X(void 0,!0),Oo=X(void 0,!0),Dr=X(void 0,!0),Eo=X(void 0,!0);fA(()=>W(ft()),()=>{b(Se,ft()!==void 0)}),fA(()=>(g(Se),W(mt()),dn),()=>{b(pe,g(Se)&&(Ao(mt())||pr(mt())||dn(mt())))}),fA(()=>(W(Rn()),W(ft())),()=>{b(Ni,{type:"button",icon:JKA,title:"Expand all",className:"jse-expand-all",onClick:Rn(),disabled:!zo(ft())})}),fA(()=>(W(bt()),W(ft())),()=>{b(Oo,{type:"button",icon:TKA,title:"Collapse all",className:"jse-collapse-all",onClick:bt(),disabled:!zo(ft())})}),fA(()=>W(ft()),()=>{b(Dr,{type:"button",icon:Zu,title:"Search (Ctrl+F)",className:"jse-search",onClick:At,disabled:ft()===void 0})}),fA(()=>(W(ci()),g(Ni),g(Oo),W(Hn()),W(ft()),W(ji()),g(Dr),W(ht()),W(Bo()),W(yi()),W(mn()),W(Fi()),g(pe)),()=>{b(Eo,ci()?[g(Ni),g(Oo),{type:"separator"},{type:"button",icon:S0,title:"Copy (Ctrl+C)",className:"jse-copy",onClick:Fi(),disabled:!g(pe)},{type:"separator"},g(Dr),{type:"space"}]:[g(Ni),g(Oo),{type:"separator"},{type:"button",icon:Vu,title:"Sort",className:"jse-sort",onClick:Hn(),disabled:ci()||ft()===void 0},{type:"button",icon:Pu,title:"Transform contents (filter, sort, project)",className:"jse-transform",onClick:ji(),disabled:ci()||ft()===void 0},g(Dr),{type:"button",icon:_S,title:H_,className:"jse-contextmenu",onClick:ht()},{type:"separator"},{type:"button",icon:s5,title:"Undo (Ctrl+Z)",className:"jse-undo",onClick:Bo(),disabled:!yi().canUndo},{type:"button",icon:r5,title:"Redo (Ctrl+Shift+Z)",className:"jse-redo",onClick:mn(),disabled:!yi().canRedo},{type:"space"}])}),fA(()=>(W(Qt()),g(Eo)),()=>{b(me,Qt()(g(Eo))||g(Eo))}),nn(),Rt(!0),Ly(rA,{get items(){return g(me)}}),at()})(J,{get json(){return g(oA)},get selection(){return g(D)},get readOnly(){return B()},get history(){return u()},onExpandAll:Ce,onCollapseAll:Pt,onUndo:Gt,onRedo:Xe,onSort:Jt,onTransform:ti,onContextMenu:jt,onCopy:ei,get onRenderMenu(){return jA()},get showSearch(){return g(Ie)},set showSearch(rA){b(Ie,rA)},$$legacy:!0})};MA(ee,J=>{L()&&J(Me)});var ke=gA(ee,2),ze=J=>{sYA(J,{get json(){return g(oA)},get selection(){return g(D)},onSelect:ir,get onError(){return IA()},get pathParser(){return H()}})};MA(ke,J=>{x()&&J(ze)});var Pe=gA(ke,2),qe=J=>{var rA=LYA(),JA=Bt(rA),Se=$(JA);Se.readOnly=!0,to(Se,mt=>b(l,mt),()=>g(l));var pe=gA(JA,2),me=mt=>{var ci=po(),rn=Bt(ci),yi=bt=>{(function(Bo,mn){st(mn,!0);var Hn=qKA();Hn.__click=[PKA,mn];var ji=gA($(Hn),2),ht=gA($(ji),2),Fi=Qt=>{var At=jKA(),Ni=gA(Bt(At),2);en(Ni,"title","Create an empty JSON object (press '{')"),Ni.__click=[HKA,mn];var Oo=gA(Ni,2);en(Oo,"title","Create an empty JSON array (press '[')"),Oo.__click=[OKA,mn],iA(Qt,At)};MA(ht,Qt=>{mn.readOnly||Qt(Fi)}),iA(Bo,Hn),at()})(bt,{get readOnly(){return B()},onCreateObject:()=>{Xi(),fe("{")},onCreateArray:()=>{Xi(),fe("[")},onClick:()=>{Xi()}})},Rn=bt=>{var Bo=kYA(),mn=Bt(Bo),Hn=PA(()=>B()?[]:[{icon:ju,text:"Repair manually",title:'Open the document in "code" mode and repair it manually',onClick:Yi}]);Cc(mn,{type:"error",message:"The loaded JSON document is invalid and could not be repaired automatically.",get actions(){return g(Hn)}}),laA(gA(mn,2),{get text(){return g(ne)},get json(){return g(oA)},get indentation(){return j()},get parser(){return U()}}),iA(bt,Bo)};MA(rn,bt=>{g(ne)===""||g(ne)===void 0?bt(yi):bt(Rn,!1)}),iA(mt,ci)},ft=mt=>{var ci=RYA(),rn=Bt(ci);taA($(rn),{get json(){return g(oA)},get documentState(){return g(w)},get parser(){return U()},get showSearch(){return g(Ie)},get showReplace(){return g(GA)},get readOnly(){return B()},columns:void 0,onSearch:oe,onFocus:M,onPatch:dt,onClose:Y});var yi=gA(rn,2);en(yi,"data-jsoneditor-scrollable-contents",!0);var Rn=$(yi),bt=Qt=>{iA(Qt,SYA())};MA(Rn,Qt=>{g(Ie)&&Qt(bt)}),p_(gA(Rn,2),{get value(){return g(oA)},pointer:"",get state(){return g(w)},get validationErrors(){return g(DA)},get searchResults(){return g(KA)},get selection(){return g(D)},get context(){return g(yn)},onDragSelectionStart:Jo}),to(yi,Qt=>b(c,Qt),()=>g(c));var Bo=gA(yi,2),mn=Qt=>{var At=PA(()=>"You pasted a JSON ".concat(Array.isArray(g(CA).contents)?"array":"object"," as text"));Cc(Qt,{type:"info",get message(){return g(At)},actions:[{icon:M0,text:"Paste as JSON instead",title:"Replace the value with the pasted JSON",onMouseDown:Nn},{text:"Leave as is",title:"Keep the JSON embedded in the value",onClick:ni}]})};MA(Bo,Qt=>{g(CA)&&Qt(mn)});var Hn=gA(Bo,2),ji=Qt=>{Cc(Qt,{type:"info",message:"Multiline text was pasted as array",actions:[{icon:M0,text:"Paste as string instead",title:"Paste the clipboard data as a single string value instead of an array",onClick:Xo},{text:"Leave as is",title:"Keep the pasted array",onClick:fn}]})};MA(Hn,Qt=>{g(kA)&&Qt(ji)});var ht=gA(Hn,2),Fi=Qt=>{var At=PA(()=>B()?[]:[{icon:a5,text:"Ok",title:"Accept the repaired document",onClick:ui},{icon:ju,text:"Repair manually instead",title:"Leave the document unchanged and repair it manually instead",onClick:Yi}]);Cc(Qt,{type:"success",message:"The loaded JSON document was invalid but is successfully repaired.",get actions(){return g(At)},onClose:Xi})};MA(ht,Qt=>{g(Qe)&&Qt(Fi)}),nG(gA(ht,2),{get validationErrors(){return g(yA)},selectError:AA}),iA(mt,ci)};MA(pe,mt=>{g(oA)===void 0?mt(me):mt(ft,!1)}),re("paste",Se,Yn),iA(J,rA)},oi=J=>{iA(J,xYA())};MA(Pe,J=>{n?J(oi,!1):J(qe)}),to(wA,J=>b(I,J),()=>g(I));var xi=gA(wA,2),Di=J=>{XsA(J,{onClose:()=>b(eA,!1)})};MA(xi,J=>{g(eA)&&J(Di)});var cn=gA(xi,2),qr=J=>{$sA(J,U1(()=>g(RA),{onClose:()=>{var rA;(rA=g(RA))===null||rA===void 0||rA.onClose(),b(RA,void 0)}}))};return MA(cn,J=>{g(RA)&&J(qr)}),Ee(J=>z=xt(wA,1,"jse-tree-mode svelte-vrx1dr",null,z,J),[()=>({"no-main-menu":!L()})],PA),re("keydown",wA,function(J){var rA=A2(J),JA=J.shiftKey;if(i("keydown",{combo:rA,key:J.key}),rA==="Ctrl+X"&&(J.preventDefault(),Ye(!0)),rA==="Ctrl+Shift+X"&&(J.preventDefault(),Ye(!1)),rA==="Ctrl+C"&&(J.preventDefault(),ei(!0)),rA==="Ctrl+Shift+C"&&(J.preventDefault(),ei(!1)),rA==="Ctrl+D"&&(J.preventDefault(),No()),rA!=="Delete"&&rA!=="Backspace"||(J.preventDefault(),Wo()),rA==="Insert"&&(J.preventDefault(),hn("structure")),rA==="Ctrl+A"&&(J.preventDefault(),b(D,hi([]))),rA==="Ctrl+Q"&&un(J),rA==="ArrowUp"||rA==="Shift+ArrowUp"){J.preventDefault();var Se=g(D)?WoA(g(oA),g(w),g(D),JA)||g(D):GE(g(oA),g(w));b(D,Se),ii(je(Se))}if(rA==="ArrowDown"||rA==="Shift+ArrowDown"){J.preventDefault();var pe=g(D)?function(yi,Rn,bt){var Bo=arguments.length>3&&arguments[3]!==void 0&&arguments[3];if(bt){var mn=Bo?je(bt):Y1(yi,bt),Hn=zo(Fe(yi,mn))?PoA(yi,Rn,mn,!0):Rn,ji=NN(yi,Rn,mn),ht=NN(yi,Hn,mn);if(Bo)return as(bt)?ji!==void 0?ys(ji,ji):void 0:Yc(bt)?ht!==void 0?ys(ht,ht):void 0:ht!==void 0?ys(SC(bt),ht):void 0;if(Yc(bt))return ht!==void 0?hi(ht):void 0;if(as(bt)||dn(bt))return ji!==void 0?hi(ji):void 0;if(pr(bt)){if(ji===void 0||ji.length===0)return;var Fi=pi(ji),Qt=Fe(yi,Fi);return Array.isArray(Qt)?hi(ji):t2(ji)}return Ao(bt)?ht!==void 0?hi(ht):ji!==void 0?hi(ji):void 0:void 0}}(g(oA),g(w),g(D),JA)||g(D):GE(g(oA),g(w));b(D,pe),ii(je(pe))}if(rA==="ArrowLeft"||rA==="Shift+ArrowLeft"){J.preventDefault();var me=g(D)?function(yi,Rn,bt){var Bo=arguments.length>3&&arguments[3]!==void 0&&arguments[3],mn=!(arguments.length>4&&arguments[4]!==void 0)||arguments[4];if(bt){var{caret:Hn,previous:ji}=XoA(yi,Rn,bt,mn);if(Bo)return Ao(bt)?void 0:ys(bt.path,bt.path);if(Hn&&ji)return C_(ji);var ht=pi(je(bt)),Fi=Fe(yi,ht);return dn(bt)&&Array.isArray(Fi)?ys(bt.path,bt.path):Ao(bt)&&!Array.isArray(Fi)?t2(bt.focusPath):void 0}}(g(oA),g(w),g(D),JA,!B())||g(D):GE(g(oA),g(w));b(D,me),ii(je(me))}if(rA==="ArrowRight"||rA==="Shift+ArrowRight"){J.preventDefault();var ft=g(D)&&g(oA)!==void 0?function(yi,Rn,bt){var Bo=arguments.length>3&&arguments[3]!==void 0&&arguments[3],mn=!(arguments.length>4&&arguments[4]!==void 0)||arguments[4];if(bt){var{caret:Hn,next:ji}=XoA(yi,Rn,bt,mn);return Bo?Ao(bt)?void 0:ys(bt.path,bt.path):Hn&&ji?C_(ji):Ao(bt)?hi(bt.focusPath):void 0}}(g(oA),g(w),g(D),JA,!B())||g(D):GE(g(oA),g(w));b(D,ft),ii(je(ft))}if(rA==="Enter"&&g(D)){if(My(g(D))){var mt=g(D).focusPath,ci=Fe(g(oA),pi(mt));Array.isArray(ci)&&(J.preventDefault(),b(D,hi(mt)))}pr(g(D))&&(J.preventDefault(),b(D,Be(Be({},g(D)),{},{edit:!0}))),dn(g(D))&&(J.preventDefault(),zo(Fe(g(oA),g(D).path))?_A(g(D).path,!0):b(D,Be(Be({},g(D)),{},{edit:!0})))}if(rA.replace(/^Shift\+/,"").length===1&&g(D))return J.preventDefault(),void fe(J.key);if(rA==="Enter"&&(Yc(g(D))||as(g(D))))return J.preventDefault(),void fe("");if(rA==="Ctrl+Enter"&&dn(g(D))){var rn=Fe(g(oA),g(D).path);yy(rn)&&window.open(String(rn),"_blank")}rA==="Escape"&&g(D)&&(J.preventDefault(),b(D,void 0)),rA==="Ctrl+F"&&(J.preventDefault(),Li(!1)),rA==="Ctrl+H"&&(J.preventDefault(),Li(!0)),rA==="Ctrl+Z"&&(J.preventDefault(),Gt()),rA==="Ctrl+Shift+Z"&&(J.preventDefault(),Xe())}),re("mousedown",wA,function(J){i("handleMouseDown",J);var rA=J.target;QsA(rA,"BUTTON")||rA.isContentEditable||(Xi(),g(D)||g(oA)!==void 0||g(ne)!==""&&g(ne)!==void 0||(i("createDefaultSelection"),b(D,hi([]))))}),re("contextmenu",wA,un),iA(t,Gr),kt(e,"expand",dA),kt(e,"collapse",WA),kt(e,"validate",qA),kt(e,"getJson",It),kt(e,"patch",Ft),kt(e,"acceptAutoRepair",ui),kt(e,"openTransformModal",Ki),kt(e,"scrollTo",$e),kt(e,"findElement",Wi),kt(e,"findSearchResult",Tn),kt(e,"focus",Xi),at({expand:dA,collapse:WA,validate:qA,getJson:It,patch:Ft,acceptAutoRepair:ui,openTransformModal:Ki,scrollTo:$e,findElement:Wi,findSearchResult:Tn,focus:Xi})}function IaA(t){return typeof(e=t)!="object"||e===null?t:new Proxy(t,{get:(A,i,n)=>IaA(Reflect.get(A,i,n)),set:()=>!1,deleteProperty:()=>!1});var e}var PD=wr("jsoneditor:History");function CaA(){var t=arguments.length>0&&arguments[0]!==void 0?arguments[0]:{},e=t.maxItems||1e3,A=[],i=0;function n(){return i<A.length}function o(){return i>0}function r(){return{canUndo:n(),canRedo:o(),items:()=>A.slice().reverse(),add:a,undo:l,redo:I,clear:c}}function s(){t.onChange&&t.onChange(r())}function a(C){PD("add",C),A=[C].concat(A.slice(i)).slice(0,e),i=0,s()}function c(){PD("clear"),A=[],i=0,s()}function l(){if(n()){var C=A[i];return i+=1,PD("undo",C),s(),C}}function I(){if(o())return PD("redo",A[i-=1]),s(),A[i]}return{get:r}}vt(`/* over all fonts, sizes, and colors */
/* "consolas" for Windows, "menlo" for Mac with fallback to "monaco", 'Ubuntu Mono' for Ubuntu */
/* (at Mac this font looks too large at 14px, but 13px is too small for the font on Windows) */
/* main, menu, modal */
/* jsoneditor modal */
/* tooltip in text mode */
/* panels: navigation bar, gutter, search box */
/* navigation-bar */
/* context menu */
/* contents: json key and values */
/* contents: selected or hovered */
/* contents: section of collapsed items in an array */
/* contents: highlighting of search matches */
/* contents: inline tags inside the JSON document */
/* contents: table */
/* controls in modals: inputs, buttons, and \`a\` */
/* messages */
/* svelte-select */
/* color picker */
.jse-transform-modal-inner.svelte-rrrjnb {
  flex: 1;
  display: flex;
  flex-direction: column;
  min-width: 0;
  min-height: 0;
}
.jse-transform-modal-inner.svelte-rrrjnb .jse-modal-contents:where(.svelte-rrrjnb) {
  color: inherit;
  flex: 1;
  display: flex;
  flex-direction: column;
  padding: 0;
  overflow: auto;
  min-width: 0;
  min-height: 0;
}
.jse-transform-modal-inner.svelte-rrrjnb .jse-modal-contents:where(.svelte-rrrjnb) .jse-actions:where(.svelte-rrrjnb) {
  display: flex;
  flex-direction: row;
  justify-content: flex-end;
  padding-top: var(--jse-padding, 10px);
}
.jse-transform-modal-inner.svelte-rrrjnb .jse-modal-contents:where(.svelte-rrrjnb) .jse-actions:where(.svelte-rrrjnb) button.jse-primary:where(.svelte-rrrjnb) {
  border: none;
  background: transparent;
  color: inherit;
  cursor: pointer;
  font-family: var(--jse-font-family, -apple-system, BlinkMacSystemFont, "Segoe UI", Roboto, Oxygen-Sans, Ubuntu, Cantarell, "Helvetica Neue", sans-serif);
  font-size: var(--jse-font-size, 16px);
  padding: 5px;
  margin: 0;
  background: var(--jse-button-primary-background, var(--jse-theme-color, #3883fa));
  color: var(--jse-button-primary-color, #fff);
  padding: var(--jse-padding, 10px) calc(2 * var(--jse-padding, 10px));
  border-radius: 3px;
}
.jse-transform-modal-inner.svelte-rrrjnb .jse-modal-contents:where(.svelte-rrrjnb) .jse-actions:where(.svelte-rrrjnb) button.jse-primary:where(.svelte-rrrjnb):hover {
  background: var(--jse-button-primary-background-highlight, var(--jse-theme-color-highlight, #5f9dff));
}
.jse-transform-modal-inner.svelte-rrrjnb .jse-modal-contents:where(.svelte-rrrjnb) .jse-actions:where(.svelte-rrrjnb) button.jse-primary:where(.svelte-rrrjnb):disabled {
  background: var(--jse-button-primary-background-disabled, #9d9d9d);
}
.jse-transform-modal-inner.svelte-rrrjnb .jse-modal-contents:where(.svelte-rrrjnb) .jse-main-contents:where(.svelte-rrrjnb) {
  flex: 1;
  display: flex;
  gap: calc(2 * var(--jse-padding, 10px));
  min-height: 0;
  box-sizing: border-box;
  padding: 0 calc(2 * var(--jse-padding, 10px)) var(--jse-padding, 10px);
}
.jse-transform-modal-inner.svelte-rrrjnb .jse-modal-contents:where(.svelte-rrrjnb) .jse-main-contents:where(.svelte-rrrjnb) .jse-query-contents:where(.svelte-rrrjnb) {
  flex: 1;
  display: flex;
  flex-direction: column;
}
.jse-transform-modal-inner.svelte-rrrjnb .jse-modal-contents:where(.svelte-rrrjnb) .jse-main-contents:where(.svelte-rrrjnb) .jse-query-contents:where(.svelte-rrrjnb) .jse-description:where(.svelte-rrrjnb) p {
  margin: var(--jse-padding, 10px) 0;
}
.jse-transform-modal-inner.svelte-rrrjnb .jse-modal-contents:where(.svelte-rrrjnb) .jse-main-contents:where(.svelte-rrrjnb) .jse-query-contents:where(.svelte-rrrjnb) .jse-description:where(.svelte-rrrjnb) p:first-child {
  margin-top: 0;
}
.jse-transform-modal-inner.svelte-rrrjnb .jse-modal-contents:where(.svelte-rrrjnb) .jse-main-contents:where(.svelte-rrrjnb) .jse-query-contents:where(.svelte-rrrjnb) .jse-description:where(.svelte-rrrjnb) p:last-child {
  margin-bottom: 0;
}
.jse-transform-modal-inner.svelte-rrrjnb .jse-modal-contents:where(.svelte-rrrjnb) .jse-main-contents:where(.svelte-rrrjnb) .jse-query-contents:where(.svelte-rrrjnb) .jse-description:where(.svelte-rrrjnb) code {
  background: var(--jse-modal-code-background, rgba(0, 0, 0, 0.05));
  font-family: var(--jse-font-family-mono, consolas, menlo, monaco, "Ubuntu Mono", "source-code-pro", monospace);
  font-size: var(--jse-font-size-mono, 14px);
}
.jse-transform-modal-inner.svelte-rrrjnb .jse-modal-contents:where(.svelte-rrrjnb) .jse-main-contents:where(.svelte-rrrjnb) .jse-query-contents:where(.svelte-rrrjnb) .query-error:where(.svelte-rrrjnb) {
  color: var(--jse-error-color, #ee5341);
}
.jse-transform-modal-inner.svelte-rrrjnb .jse-modal-contents:where(.svelte-rrrjnb) .jse-main-contents:where(.svelte-rrrjnb) .jse-query-contents:where(.svelte-rrrjnb) textarea.jse-query:where(.svelte-rrrjnb) {
  flex: 1;
  outline: none;
  resize: vertical;
}
.jse-transform-modal-inner.svelte-rrrjnb .jse-modal-contents:where(.svelte-rrrjnb) .jse-main-contents:where(.svelte-rrrjnb) .jse-data-contents:where(.svelte-rrrjnb) {
  flex: 1;
  display: flex;
  flex-direction: column;
  gap: calc(2 * var(--jse-padding, 10px));
}
.jse-transform-modal-inner.svelte-rrrjnb .jse-modal-contents:where(.svelte-rrrjnb) .jse-main-contents:where(.svelte-rrrjnb) .jse-data-contents:where(.svelte-rrrjnb) .jse-original-data:where(.svelte-rrrjnb) {
  flex: 1;
  display: flex;
  flex-direction: column;
  min-height: 0;
  box-sizing: border-box;
}
.jse-transform-modal-inner.svelte-rrrjnb .jse-modal-contents:where(.svelte-rrrjnb) .jse-main-contents:where(.svelte-rrrjnb) .jse-data-contents:where(.svelte-rrrjnb) .jse-original-data.jse-hide:where(.svelte-rrrjnb) {
  flex: none;
}
.jse-transform-modal-inner.svelte-rrrjnb .jse-modal-contents:where(.svelte-rrrjnb) .jse-main-contents:where(.svelte-rrrjnb) .jse-data-contents:where(.svelte-rrrjnb) .jse-preview-data:where(.svelte-rrrjnb) {
  flex: 1;
  display: flex;
  flex-direction: column;
  min-height: 0;
  box-sizing: border-box;
}
.jse-transform-modal-inner.svelte-rrrjnb .jse-modal-contents:where(.svelte-rrrjnb) .jse-main-contents:where(.svelte-rrrjnb) .jse-data-contents.jse-hide-original-data:where(.svelte-rrrjnb) {
  flex-direction: column;
  gap: 0;
  margin-bottom: 0;
}
.jse-transform-modal-inner.svelte-rrrjnb .jse-modal-contents:where(.svelte-rrrjnb) .jse-actions:where(.svelte-rrrjnb) {
  padding: var(--jse-padding, 10px) calc(2 * var(--jse-padding, 10px)) calc(2 * var(--jse-padding, 10px));
}
@media screen and (max-width: 1200px) {
  .jse-transform-modal-inner.svelte-rrrjnb .jse-modal-contents:where(.svelte-rrrjnb) .jse-main-contents:where(.svelte-rrrjnb) {
    flex-direction: column;
    overflow: auto;
  }
  .jse-transform-modal-inner.svelte-rrrjnb .jse-modal-contents:where(.svelte-rrrjnb) .jse-main-contents:where(.svelte-rrrjnb) .jse-query-contents:where(.svelte-rrrjnb) textarea.jse-query:where(.svelte-rrrjnb) {
    min-height: 150px;
    flex: none;
  }
  .jse-transform-modal-inner.svelte-rrrjnb .jse-modal-contents:where(.svelte-rrrjnb) .jse-main-contents:where(.svelte-rrrjnb) .jse-data-contents:where(.svelte-rrrjnb) .jse-tree-mode {
    height: 300px;
    flex: none;
  }
}
.jse-transform-modal-inner.svelte-rrrjnb .jse-label:where(.svelte-rrrjnb) {
  font-weight: bold;
  display: block;
  box-sizing: border-box;
}
.jse-transform-modal-inner.svelte-rrrjnb .jse-label:where(.svelte-rrrjnb) .jse-label-inner:where(.svelte-rrrjnb) {
  margin-top: calc(2 * var(--jse-padding, 10px));
  margin-bottom: calc(0.5 * var(--jse-padding, 10px));
  box-sizing: border-box;
}
.jse-transform-modal-inner.svelte-rrrjnb .jse-label:where(.svelte-rrrjnb) .jse-label-inner:where(.svelte-rrrjnb) button:where(.svelte-rrrjnb) {
  border: none;
  background: transparent;
  color: inherit;
  cursor: pointer;
  font-family: var(--jse-font-family, -apple-system, BlinkMacSystemFont, "Segoe UI", Roboto, Oxygen-Sans, Ubuntu, Cantarell, "Helvetica Neue", sans-serif);
  font-size: var(--jse-font-size, 16px);
  padding: 5px;
  margin: 0;
  font-weight: bold;
  padding: 0;
}
.jse-transform-modal-inner.svelte-rrrjnb .jse-tree-mode {
  flex: 1;
  background: var(--jse-input-background-readonly, transparent);
  box-shadow: none;
  box-sizing: border-box;
  --jse-main-border: var(--jse-input-border, 1px solid #d8dbdf);
}
.jse-transform-modal-inner.svelte-rrrjnb input:where(.svelte-rrrjnb),
.jse-transform-modal-inner.svelte-rrrjnb textarea:where(.svelte-rrrjnb) {
  border: var(--jse-input-border, 1px solid #d8dbdf);
  outline: none;
  box-sizing: border-box;
  padding: calc(0.5 * var(--jse-padding, 10px));
  font-family: var(--jse-font-family-mono, consolas, menlo, monaco, "Ubuntu Mono", "source-code-pro", monospace);
  font-size: var(--jse-font-size-mono, 14px);
  color: inherit;
  background: var(--jse-input-background, var(--jse-background-color, #fff));
}
.jse-transform-modal-inner.svelte-rrrjnb input:where(.svelte-rrrjnb):focus,
.jse-transform-modal-inner.svelte-rrrjnb textarea:where(.svelte-rrrjnb):focus {
  border: var(--jse-input-border-focus, 1px solid var(--jse-input-border-focus, var(--jse-theme-color, #3883fa)));
}
.jse-transform-modal-inner.svelte-rrrjnb input:where(.svelte-rrrjnb):read-only,
.jse-transform-modal-inner.svelte-rrrjnb textarea:where(.svelte-rrrjnb):read-only {
  background: var(--jse-input-background-readonly, transparent);
}
.jse-transform-modal-inner.svelte-rrrjnb .jse-preview.jse-error:where(.svelte-rrrjnb) {
  flex: 1;
  background: var(--jse-input-background-readonly, transparent);
  border: var(--jse-input-border, 1px solid #d8dbdf);
  color: var(--jse-error-color, #ee5341);
  padding: calc(0.5 * var(--jse-padding, 10px));
}
.jse-transform-modal-inner.svelte-rrrjnb a {
  color: var(--jse-a-color, #156fc5);
}
.jse-transform-modal-inner.svelte-rrrjnb a:hover {
  color: var(--jse-a-color-highlight, #0f508d);
}`);var u3=Dy(()=>ZGA),UE=Dy(()=>WGA),NYA=pA('<div class="query-error svelte-rrrjnb"> </div>'),_YA=pA("<!> <!>",1),GYA=pA('<div class="jse-preview jse-error svelte-rrrjnb"> </div>'),UYA=pA('<!> <div class="jse-modal-contents svelte-rrrjnb"><div class="jse-main-contents svelte-rrrjnb"><div class="jse-query-contents svelte-rrrjnb"><div class="jse-label svelte-rrrjnb"><div class="jse-label-inner svelte-rrrjnb">Language</div></div> <div class="jse-description svelte-rrrjnb"><!></div> <div class="jse-label svelte-rrrjnb"><div class="jse-label-inner svelte-rrrjnb">Path</div></div> <input class="jse-path svelte-rrrjnb" type="text" readonly="" title="Selected path"/> <div class="jse-label svelte-rrrjnb"><div class="jse-label-inner svelte-rrrjnb"><button type="button" class="svelte-rrrjnb"><!> Wizard</button></div></div> <!> <div class="jse-label svelte-rrrjnb"><div class="jse-label-inner svelte-rrrjnb">Query</div></div> <textarea class="jse-query svelte-rrrjnb" spellcheck="false"></textarea></div> <div><div><div class="jse-label svelte-rrrjnb"><div class="jse-label-inner svelte-rrrjnb"><button type="button" class="svelte-rrrjnb"><!> Original</button></div></div> <!></div> <div class="jse-preview-data svelte-rrrjnb"><div class="jse-label svelte-rrrjnb"><div class="jse-label-inner svelte-rrrjnb">Preview</div></div> <!></div></div></div> <div class="jse-actions svelte-rrrjnb"><button type="button" class="jse-primary svelte-rrrjnb">Transform</button></div></div>',1),KYA=pA('<div class="jse-transform-modal-inner svelte-rrrjnb"><!></div>');function YYA(t,e){var A,i,n;st(e,!1);var o=wr("jsoneditor:TransformModal"),r=k(e,"id",25,()=>"transform-modal-"+TE()),s=k(e,"json",9),a=k(e,"rootPath",25,()=>[]),c=k(e,"indentation",9),l=k(e,"truncateTextSize",9),I=k(e,"escapeControlCharacters",9),C=k(e,"escapeUnicodeCharacters",9),d=k(e,"parser",9),B=k(e,"parseMemoizeOne",9),E=k(e,"validationParser",9),Q=k(e,"pathParser",9),u=k(e,"queryLanguages",9),v=k(e,"queryLanguageId",13),L=k(e,"onChangeQueryLanguage",9),x=k(e,"onRenderValue",9),y=k(e,"onRenderMenu",9),F=k(e,"onRenderContextMenu",9),U=k(e,"onClassName",9),T=k(e,"onTransform",9),N=k(e,"onClose",9),K=X(void 0,!0),H=X(CaA({onChange:w=>b(H,w)}).get(),!0),j=X(void 0,!0),IA=X(void 0,!0),lA=X(!1,!0),uA="".concat(r(),":").concat(nt(a())),p=(A=u3()[uA])!==null&&A!==void 0?A:{},V=X(UE().showWizard!==!1,!0),cA=X(UE().showOriginal!==!1,!0),aA=X((i=p.queryOptions)!==null&&i!==void 0?i:{},!0),jA=X(v()===p.queryLanguageId&&p.query?p.query:"",!0),VA=X((n=p.isManual)!==null&&n!==void 0&&n,!0),ce=X(void 0,!0),EA=X(void 0,!0),sA=X({text:""},!0);function TA(w){var D;return(D=u().find(O=>O.id===w))!==null&&D!==void 0?D:u()[0]}function Ke(w){try{b(aA,w),b(jA,TA(v()).createQuery(g(j),w)),b(ce,void 0),b(VA,!1),o("updateQueryByWizard",{queryOptions:g(aA),query:g(jA),isManual:g(VA)})}catch(D){b(ce,String(D))}}function Re(w){b(jA,w.target.value),b(VA,!0),o("handleChangeQuery",{query:g(jA),isManual:g(VA)})}g(VA)||Ke(g(aA)),ls(()=>{var w;(w=g(K))===null||w===void 0||w.focus()});var hA=PB(function(w,D){if(w===void 0)return b(sA,{text:""}),void b(EA,"Error: No JSON");if(D.trim()!=="")try{o("previewTransform",{query:D});var O=TA(v()).executeQuery(w,D,d());b(sA,{json:O}),b(EA,void 0)}catch(Z){b(sA,{text:""}),b(EA,String(Z))}else b(sA,{json:w})},300);function eA(){if(g(j)===void 0)return b(sA,{text:""}),void b(EA,"Error: No JSON");try{o("handleTransform",{query:g(jA)});var w=TA(v()).executeQuery(g(j),g(jA),d());T()([{op:"replace",path:nt(a()),value:w}]),N()()}catch(D){console.error(D),b(sA,{text:""}),b(EA,String(D))}}function RA(){b(V,!g(V)),UE(UE().showWizard=g(V))}function oA(){b(cA,!g(cA)),UE(UE().showOriginal=g(cA))}function ne(w){w.focus()}function h(w){o("handleChangeQueryLanguage",w),v(w),L()(w),Ke(g(aA))}function f(){g(lA)?b(lA,!g(lA)):N()()}fA(()=>(W(s()),W(a())),()=>{b(j,IaA(Fe(s(),a())))}),fA(()=>g(j),()=>{b(IA,g(j)?{json:g(j)}:{text:""})}),fA(()=>(g(j),g(jA)),()=>{hA(g(j),g(jA))}),fA(()=>(u3(),g(aA),g(jA),W(v()),g(VA)),()=>{u3(u3()[uA]={queryOptions:g(aA),query:g(jA),queryLanguageId:v(),isManual:g(VA)}),o("store state in memory",uA,u3()[uA])}),nn(),Rt(!0),U3(t,{get onClose(){return N()},className:"jse-transform-modal",get fullscreen(){return g(lA)},children:(w,D)=>{var O=KYA();c_($(O),{children:(Z,q)=>{var CA=UYA(),kA=Bt(CA);(function(Ye,Ai){st(Ai,!1);var ei,Oi=k(Ai,"queryLanguages",9),Yn=k(Ai,"queryLanguageId",9),Dn=k(Ai,"fullscreen",13),Ho=k(Ai,"onChangeQueryLanguage",9),Sn=k(Ai,"onClose",9),io=X(void 0,!0),{openAbsolutePopup:Wo,closeAbsolutePopup:No}=H1("absolute-popup");function Jn(){var hn={queryLanguages:Oi(),queryLanguageId:Yn(),onChangeQueryLanguage:wo=>{No(ei),Ho()(wo)}};ei=Wo(xUA,hn,{offsetTop:-2,offsetLeft:0,anchor:g(io),closeOnOuterClick:!0})}Rt(!0),dy(Ye,{title:"Transform",fullScreenButton:!0,get onClose(){return Sn()},get fullscreen(){return Dn()},set fullscreen(hn){Dn(hn)},$$slots:{actions:(hn,wo)=>{var se,fi=_UA();Si($(fi),{data:MW}),to(fi,bA=>b(io,bA),()=>g(io)),Ee(bA=>se=xt(fi,1,"jse-config svelte-1kpylsp",null,se,bA),[()=>({hide:Oi().length<=1})],PA),re("click",fi,Jn),iA(hn,fi)}},$$legacy:!0}),at()})(kA,{get queryLanguages(){return u()},get queryLanguageId(){return v()},onChangeQueryLanguage:h,get onClose(){return N()},get fullscreen(){return g(lA)},set fullscreen(Ye){b(lA,Ye)},$$legacy:!0});var KA=$(gA(kA,2)),Ie=$(KA),GA=gA($(Ie),2);AsA($(GA),()=>TA(v()).description);var oe=gA(GA,4),M=gA(oe,2),G=$(M),Y=$(G),AA=$(Y),dA=PA(()=>g(V)?k0:qB);Si(AA,{get data(){return g(dA)}});var WA=gA(M,2),Qe=Ye=>{var Ai=po(),ei=Bt(Ai),Oi=Dn=>{var Ho=_YA(),Sn=Bt(Ho);SUA(Sn,{get queryOptions(){return g(aA)},get json(){return g(j)},onChange:Ke});var io=gA(Sn,2),Wo=No=>{var Jn=NYA(),hn=$(Jn);Ee(()=>Et(hn,g(ce))),iA(No,Jn)};MA(io,No=>{g(ce)&&No(Wo)}),iA(Dn,Ho)},Yn=Dn=>{iA(Dn,_r("(Only available for arrays, not for objects)"))};MA(ei,Dn=>{Array.isArray(g(j))?Dn(Oi):Dn(Yn,!1)}),iA(Ye,Ai)};MA(WA,Ye=>{g(V)&&Ye(Qe)});var yA=gA(WA,4);to(yA,Ye=>b(K,Ye),()=>g(K));var DA,We,be=gA(Ie,2),qA=$(be),It=$(qA),Vi=$(It),on=$(Vi),Hi=$(on),Ci=PA(()=>g(cA)?k0:qB);Si(Hi,{get data(){return g(Ci)}});var Zi=gA(It,2),Qi=Ye=>{M_(Ye,{get externalContent(){return g(IA)},externalSelection:void 0,get history(){return g(H)},readOnly:!0,get truncateTextSize(){return l()},mainMenuBar:!1,navigationBar:!1,get indentation(){return c()},get escapeControlCharacters(){return I()},get escapeUnicodeCharacters(){return C()},get parser(){return d()},get parseMemoizeOne(){return B()},get onRenderValue(){return x()},get onRenderMenu(){return y()},get onRenderContextMenu(){return F()},onError:console.error,onChange:Jo,onChangeMode:Jo,onSelect:Jo,onUndo:Jo,onRedo:Jo,onFocus:Jo,onBlur:Jo,onSortModal:Jo,onTransformModal:Jo,onJSONEditorModal:Jo,get onClassName(){return U()},validator:void 0,get validationParser(){return E()},get pathParser(){return Q()}})};MA(Zi,Ye=>{g(cA)&&Ye(Qi)});var Ft=gA(qA,2),Tt=gA($(Ft),2),Ht=Ye=>{M_(Ye,{get externalContent(){return g(sA)},externalSelection:void 0,get history(){return g(H)},readOnly:!0,get truncateTextSize(){return l()},mainMenuBar:!1,navigationBar:!1,get indentation(){return c()},get escapeControlCharacters(){return I()},get escapeUnicodeCharacters(){return C()},get parser(){return d()},get parseMemoizeOne(){return B()},get onRenderValue(){return x()},get onRenderMenu(){return y()},get onRenderContextMenu(){return F()},onError:console.error,onChange:Jo,onChangeMode:Jo,onSelect:Jo,onUndo:Jo,onRedo:Jo,onFocus:Jo,onBlur:Jo,onSortModal:Jo,onTransformModal:Jo,onJSONEditorModal:Jo,get onClassName(){return U()},validator:void 0,get validationParser(){return E()},get pathParser(){return Q()}})},zi=Ye=>{var Ai=GYA(),ei=$(Ai);Ee(()=>Et(ei,g(EA))),iA(Ye,Ai)};MA(Tt,Ye=>{g(EA)?Ye(zi,!1):Ye(Ht)});var ui=$(gA(KA,2));Nr(()=>re("click",ui,eA)),bs(ui,Ye=>ne?.(Ye)),Ee((Ye,Ai,ei)=>{GC(oe,Ye),GC(yA,g(jA)),DA=xt(be,1,"jse-data-contents svelte-rrrjnb",null,DA,Ai),We=xt(qA,1,"jse-original-data svelte-rrrjnb",null,We,ei),ui.disabled=!!g(EA)},[()=>sn(a())?"(document root)":Dl(a()),()=>({"jse-hide-original-data":!g(cA)}),()=>({"jse-hide":!g(cA)})],PA),re("click",Y,RA),re("input",yA,Re),re("click",on,oA),iA(Z,CA)},$$slots:{default:!0}}),bs(O,(Z,q)=>By?.(Z,q),()=>f),iA(w,O)},$$slots:{default:!0}}),at()}function Kc(){}vt(`/* over all fonts, sizes, and colors */
/* "consolas" for Windows, "menlo" for Mac with fallback to "monaco", 'Ubuntu Mono' for Ubuntu */
/* (at Mac this font looks too large at 14px, but 13px is too small for the font on Windows) */
/* main, menu, modal */
/* jsoneditor modal */
/* tooltip in text mode */
/* panels: navigation bar, gutter, search box */
/* navigation-bar */
/* context menu */
/* contents: json key and values */
/* contents: selected or hovered */
/* contents: section of collapsed items in an array */
/* contents: highlighting of search matches */
/* contents: inline tags inside the JSON document */
/* contents: table */
/* controls in modals: inputs, buttons, and \`a\` */
/* messages */
/* svelte-select */
/* color picker */
.jse-status-bar.svelte-1ulj7zd {
  background: var(--jse-panel-background, #ebebeb);
  color: var(--jse-panel-color-readonly, #b2b2b2);
  font-family: var(--jse-font-family-mono, consolas, menlo, monaco, "Ubuntu Mono", "source-code-pro", monospace);
  font-size: var(--jse-font-size-mono, 14px);
  margin: 0;
  border-top: var(--jse-panel-border, var(--jse-main-border, 1px solid #d7d7d7));
  border-left: var(--jse-main-border, 1px solid #d7d7d7);
  border-right: var(--jse-main-border, 1px solid #d7d7d7);
  display: flex;
  gap: var(--jse-padding, 10px);
}
.jse-status-bar.svelte-1ulj7zd:last-child {
  border-bottom: var(--jse-main-border, 1px solid #d7d7d7);
}
.jse-status-bar.svelte-1ulj7zd .jse-status-bar-info:where(.svelte-1ulj7zd) {
  padding: 2px;
}`);var JYA=pA('<div class="jse-status-bar-info svelte-1ulj7zd"> </div>'),TYA=pA('<div class="jse-status-bar-info svelte-1ulj7zd"> </div>'),zYA=pA('<div class="jse-status-bar-info svelte-1ulj7zd"> </div>'),HYA=pA('<div class="jse-status-bar svelte-1ulj7zd"><!> <!> <!></div>'),rG=kE.define([{tag:we.propertyName,color:"var(--internal-key-color)"},{tag:we.number,color:"var(--internal-value-color-number)"},{tag:we.bool,color:"var(--internal-value-color-boolean)"},{tag:we.string,color:"var(--internal-value-color-string)"},{tag:we.keyword,color:"var(--internal-value-color-null)"}]),OYA=MF(rG),PYA=rG.style;rG.style=t=>PYA(t||[]);var jYA=[Xn.fromClass(class{constructor(t){this.view=t,this.indentUnit=ul(t.state),this.initialPaddingLeft=null,this.isChrome=window?.navigator.userAgent.includes("Chrome"),this.generate(t.state)}update(t){var e=ul(t.state);(e!==this.indentUnit||t.docChanged||t.viewportChanged)&&(this.indentUnit=e,this.generate(t.state))}generate(t){var e=new os;this.initialPaddingLeft?this.addStyleToBuilder(e,t,this.initialPaddingLeft):this.view.requestMeasure({read:A=>{var i=A.contentDOM.querySelector(".cm-line");i&&(this.initialPaddingLeft=window.getComputedStyle(i).getPropertyValue("padding-left"),this.addStyleToBuilder(e,A.state,this.initialPaddingLeft)),this.decorations=e.finish()}}),this.decorations=e.finish()}addStyleToBuilder(t,e,A){var i=this.getVisibleLines(e);for(var n of i){var{numColumns:o,containsTab:r}=this.numColumns(n.text,e.tabSize),s="calc(".concat(o+this.indentUnit,"ch + ").concat(A,")"),a=this.isChrome?"calc(-".concat(o+this.indentUnit,"ch - ").concat(r?1:0,"px)"):"-".concat(o+this.indentUnit,"ch");t.add(n.from,n.from,rt.line({attributes:{style:"padding-left: ".concat(s,"; text-indent: ").concat(a,";")}}))}}getVisibleLines(t){var e=new Set,A=null;for(var{from:i,to:n}of this.view.visibleRanges)for(var o=i;o<=n;){var r=t.doc.lineAt(o);A!==r&&(e.add(r),A=r),o=r.to+1}return e}numColumns(t,e){var A=0,i=!1;A:for(var n=0;n<t.length;n++)switch(t[n]){case" ":A+=1;continue A;case"	":A+=e-A%e,i=!0;continue A;case"\r":continue A;default:break A}return{numColumns:A,containsTab:i}}},{decorations:t=>t.decorations})];vt(`/* over all fonts, sizes, and colors */
/* "consolas" for Windows, "menlo" for Mac with fallback to "monaco", 'Ubuntu Mono' for Ubuntu */
/* (at Mac this font looks too large at 14px, but 13px is too small for the font on Windows) */
/* main, menu, modal */
/* jsoneditor modal */
/* tooltip in text mode */
/* panels: navigation bar, gutter, search box */
/* navigation-bar */
/* context menu */
/* contents: json key and values */
/* contents: selected or hovered */
/* contents: section of collapsed items in an array */
/* contents: highlighting of search matches */
/* contents: inline tags inside the JSON document */
/* contents: table */
/* controls in modals: inputs, buttons, and \`a\` */
/* messages */
/* svelte-select */
/* color picker */
.jse-text-mode.svelte-xt61xw {
  --internal-key-color: var(--jse-key-color, #1a1a1a);
  --internal-value-color-number: var(--jse-value-color-number, #ee422e);
  --internal-value-color-boolean: var(--jse-value-color-boolean, #ff8c00);
  --internal-value-color-string: var(--jse-value-color-string, #008000);
  --internal-value-color-null: var(--jse-value-color-null, #004ed0);
  flex: 1;
  box-sizing: border-box;
  display: flex;
  flex-direction: column;
  background: var(--jse-background-color, #fff);
}
.jse-text-mode.no-main-menu.svelte-xt61xw {
  border-top: var(--jse-main-border, 1px solid #d7d7d7);
}
.jse-text-mode.svelte-xt61xw .jse-contents:where(.svelte-xt61xw) {
  flex: 1;
  display: flex;
  position: relative;
  flex-direction: column;
  overflow: hidden;
  min-width: 0;
  min-height: 0;
  border-left: var(--jse-main-border, 1px solid #d7d7d7);
  border-right: var(--jse-main-border, 1px solid #d7d7d7);
}
.jse-text-mode.svelte-xt61xw .jse-contents:where(.svelte-xt61xw):last-child {
  border-bottom: var(--jse-main-border, 1px solid #d7d7d7);
}
.jse-text-mode.svelte-xt61xw .jse-contents.jse-hidden:where(.svelte-xt61xw) {
  visibility: hidden;
  position: absolute;
  top: 0;
  left: 0;
}
.jse-text-mode.svelte-xt61xw .jse-contents:where(.svelte-xt61xw) .cm-editor {
  flex: 1;
  overflow: hidden;
}
.jse-text-mode.svelte-xt61xw .jse-contents:where(.svelte-xt61xw) .cm-editor .cm-scroller {
  font-family: var(--jse-font-family-mono, consolas, menlo, monaco, "Ubuntu Mono", "source-code-pro", monospace);
  font-size: var(--jse-font-size-mono, 14px);
  line-height: var(--jse-line-height, calc(1em + 4px));
  color: var(--jse-delimiter-color, rgba(0, 0, 0, 0.38));
}
.jse-text-mode.svelte-xt61xw .jse-contents:where(.svelte-xt61xw) .cm-editor .cm-gutters {
  background: var(--jse-panel-background, #ebebeb);
  color: var(--jse-panel-color-readonly, #b2b2b2);
  border-right: var(--jse-panel-border, var(--jse-main-border, 1px solid #d7d7d7));
}
.jse-text-mode.svelte-xt61xw .jse-contents:where(.svelte-xt61xw) .cm-editor .cm-activeLine,
.jse-text-mode.svelte-xt61xw .jse-contents:where(.svelte-xt61xw) .cm-editor .cm-activeLineGutter {
  background: var(--jse-active-line-background-color, rgba(0, 0, 0, 0.06));
}
.jse-text-mode.svelte-xt61xw .jse-contents:where(.svelte-xt61xw) .cm-editor .cm-selectionBackground {
  background: var(--jse-selection-background-color, #d3d3d3);
}
.jse-text-mode.svelte-xt61xw .jse-contents:where(.svelte-xt61xw) .cm-editor .cm-searchMatch {
  background-color: var(--jse-search-match-color, #ffe665);
  outline: var(--jse-search-match-outline, none);
}
.jse-text-mode.svelte-xt61xw .jse-contents:where(.svelte-xt61xw) .cm-editor .cm-searchMatch.cm-searchMatch-selected {
  background-color: var(--jse-search-match-active-color, var(--jse-search-match-color, #ffe665));
  outline: var(--jse-search-match-outline, 2px solid #e0be00);
}
.jse-text-mode.svelte-xt61xw .jse-contents:where(.svelte-xt61xw) .cm-editor .cm-selectionMatch {
  background-color: var(--jse-search-match-background-color, rgba(153, 255, 119, 0.5019607843));
}
.jse-text-mode.svelte-xt61xw .jse-contents:where(.svelte-xt61xw) .cm-editor .cm-foldPlaceholder {
  background: var(--jse-tag-background, rgba(0, 0, 0, 0.2));
  color: var(--jse-tag-color, var(--jse-text-color-inverse, #fff));
  border: none;
  padding: 0 var(--jse-padding, 10px);
}
.jse-text-mode.svelte-xt61xw .jse-contents:where(.svelte-xt61xw) .cm-editor .cm-tooltip {
  font-size: var(--jse-font-size, 16px);
  font-family: var(--jse-font-family, -apple-system, BlinkMacSystemFont, "Segoe UI", Roboto, Oxygen-Sans, Ubuntu, Cantarell, "Helvetica Neue", sans-serif);
  color: var(--jse-tooltip-color, var(--jse-text-color, #4d4d4d));
  background: var(--jse-tooltip-background, var(--jse-modal-background, #f5f5f5));
  border: var(--jse-tooltip-border, var(--jse-main-border, 1px solid #d7d7d7));
}
.jse-text-mode.svelte-xt61xw .jse-contents:where(.svelte-xt61xw) .cm-editor .cm-diagnosticAction {
  background: var(--jse-tooltip-action-button-color, var(--jse-text-color-inverse, #fff));
  background: var(--jse-tooltip-action-button-background, #4d4d4d);
}
.jse-text-mode.svelte-xt61xw .jse-contents:where(.svelte-xt61xw) .cm-editor .cm-panels {
  border-bottom: var(--jse-panel-border, var(--jse-main-border, 1px solid #d7d7d7));
}
.jse-text-mode.svelte-xt61xw .jse-contents:where(.svelte-xt61xw) .cm-editor .cm-search {
  background: var(--jse-panel-background, #ebebeb);
  color: var(--jse-panel-color, var(--jse-text-color, #4d4d4d));
  font-family: var(--jse-font-family, -apple-system, BlinkMacSystemFont, "Segoe UI", Roboto, Oxygen-Sans, Ubuntu, Cantarell, "Helvetica Neue", sans-serif);
  font-size: var(--jse-font-size, 16px);
}
.jse-text-mode.svelte-xt61xw .jse-contents:where(.svelte-xt61xw) .cm-editor .cm-search input {
  font-family: var(--jse-font-family, -apple-system, BlinkMacSystemFont, "Segoe UI", Roboto, Oxygen-Sans, Ubuntu, Cantarell, "Helvetica Neue", sans-serif);
  font-size: var(--jse-font-size-text-mode-search, 80%);
  color: var(--jse-input-color, var(--jse-text-color, #4d4d4d));
  border: var(--jse-input-border, 1px solid #d8dbdf);
  background: var(--jse-input-background, var(--jse-background-color, #fff));
  margin-right: 2px;
}
.jse-text-mode.svelte-xt61xw .jse-contents:where(.svelte-xt61xw) .cm-editor .cm-search button {
  font-family: var(--jse-font-family, -apple-system, BlinkMacSystemFont, "Segoe UI", Roboto, Oxygen-Sans, Ubuntu, Cantarell, "Helvetica Neue", sans-serif);
  font-size: var(--jse-font-size-text-mode-search, 80%);
  color: var(--jse-panel-button-color, inherit);
  background: var(--jse-panel-button-background, transparent);
  border: none;
  cursor: pointer;
  text-transform: capitalize;
  padding: calc(0.5 * var(--jse-padding, 10px)) var(--jse-padding, 10px);
  margin: 0;
}
.jse-text-mode.svelte-xt61xw .jse-contents:where(.svelte-xt61xw) .cm-editor .cm-search button:hover {
  color: var(--panel-button-color-highlight, var(--jse-text-color, #4d4d4d));
  background: var(--jse-panel-button-background-highlight, #e0e0e0);
}
.jse-text-mode.svelte-xt61xw .jse-contents:where(.svelte-xt61xw) .cm-editor .cm-search label {
  font-family: var(--jse-font-family, -apple-system, BlinkMacSystemFont, "Segoe UI", Roboto, Oxygen-Sans, Ubuntu, Cantarell, "Helvetica Neue", sans-serif);
  font-size: var(--jse-font-size-text-mode-search, 80%);
  padding-left: var(--jse-padding, 10px);
}
.jse-text-mode.svelte-xt61xw .jse-contents:where(.svelte-xt61xw) .cm-editor .cm-search label input {
  margin-right: 2px;
}
.jse-text-mode.svelte-xt61xw .jse-contents:where(.svelte-xt61xw) .cm-editor .cm-search button[name="close"] {
  width: 32px;
  height: 32px;
  font-size: 24px;
  line-height: 24px;
  padding: 0;
  right: 0;
  top: -4px;
}
.jse-text-mode.svelte-xt61xw .jse-contents:where(.svelte-xt61xw) .cm-editor .cm-cursor-primary {
  border-color: var(--jse-text-color, #4d4d4d);
}
.jse-text-mode.svelte-xt61xw .jse-contents:where(.svelte-xt61xw) .jse-loading-space:where(.svelte-xt61xw) {
  flex: 1;
}
.jse-text-mode.svelte-xt61xw .jse-contents:where(.svelte-xt61xw) .jse-loading:where(.svelte-xt61xw) {
  flex: 2;
  text-align: center;
  color: var(--jse-panel-color-readonly, #b2b2b2);
  box-sizing: border-box;
  font-family: var(--jse-font-family, -apple-system, BlinkMacSystemFont, "Segoe UI", Roboto, Oxygen-Sans, Ubuntu, Cantarell, "Helvetica Neue", sans-serif);
  font-size: var(--jse-font-size, 16px);
}
.jse-text-mode.svelte-xt61xw .jse-contents.jse-preview:where(.svelte-xt61xw) {
  flex: 1;
  font-family: var(--jse-font-family-mono, consolas, menlo, monaco, "Ubuntu Mono", "source-code-pro", monospace);
  font-size: var(--jse-font-size-mono, 14px);
  color: var(--jse-panel-color-readonly, #b2b2b2);
  overflow: auto;
  white-space: pre-wrap;
  word-break: break-word;
  padding: 2px;
}`);var qYA=pA('<!> <div class="jse-contents jse-preview svelte-xt61xw"> </div>',1),VYA=pA("<!> <!> <!> <!>",1),ZYA=pA("<div></div> <!> <!>",1),WYA=pA('<div class="jse-contents svelte-xt61xw"><div class="jse-loading-space svelte-xt61xw"></div> <div class="jse-loading svelte-xt61xw">loading...</div></div>'),XYA=pA("<div><!> <!></div>");function $YA(t,e){st(e,!1);var A=X(void 0,!0),i=X(void 0,!0),n=k(e,"readOnly",9),o=k(e,"mainMenuBar",9),r=k(e,"statusBar",9),s=k(e,"askToFormat",9),a=k(e,"externalContent",9),c=k(e,"externalSelection",9),l=k(e,"history",9),I=k(e,"indentation",9),C=k(e,"tabSize",9),d=k(e,"escapeUnicodeCharacters",9),B=k(e,"parser",9),E=k(e,"validator",9),Q=k(e,"validationParser",9),u=k(e,"onChange",9),v=k(e,"onChangeMode",9),L=k(e,"onSelect",9),x=k(e,"onUndo",9),y=k(e,"onRedo",9),F=k(e,"onError",9),U=k(e,"onFocus",9),T=k(e,"onBlur",9),N=k(e,"onRenderMenu",9),K=k(e,"onSortModal",9),H=k(e,"onTransformModal",9),j=wr("jsoneditor:TextMode"),IA={key:"Mod-i",run:q,shift:CA,preventDefault:!0},lA=typeof window>"u";j("isSSR:",lA);var uA,p=X(void 0,!0),V=X(void 0,!0),cA=X(void 0,!0),aA=X(!1,!0),jA=X(s(),!0),VA=X([],!0),ce=new ug,EA=new ug,sA=new ug,TA=new ug,Ke=new ug,Re=a(),hA=X(s_(Re,I(),B()),!0),eA=wa.define(),RA=null;function oA(){if(!RA||RA.length===0)return!1;var bA=RA[0].startState,fe=RA[RA.length-1].state,it=RA.map(Xe=>Xe.changes).reduce((Xe,Ot)=>Xe.compose(Ot)),Gt={type:"text",undo:{changes:it.invert(bA.doc).toJSON(),selection:Ye(bA.selection)},redo:{changes:it.toJSON(),selection:Ye(fe.selection)}};return j("add history item",Gt),l().add(Gt),RA=null,!0}var ne=X(d(),!0);ls(yt(function*(){if(!lA)try{uA=function(bA){var{target:fe,initialText:it,readOnly:Gt,indentation:Xe}=bA;j("Create CodeMirror editor",{readOnly:Gt,indentation:Xe});var Ot=function(Jt,Ki){return GN(Jt)?Jt.ranges.every(Ct=>Ct.anchor<Ki.length&&Ct.head<Ki.length):!1}(c(),it)?on(c()):void 0,Pi=Ir.create({doc:it,selection:Ot,extensions:[wE.of([CnA,IA]),ce.of(DA()),vnA(),ZtA(),WtA(),ztA(),DiA(),KtA(),TtA(),Ir.allowMultipleSelections.of(!0),BiA(),MF(viA,{fallback:!0}),SiA(),ooA(),loA(),OtA(),PtA(),HtA(),JnA(),wE.of([...aoA,...InA,...OnA,{key:"Mod-z",run:M,preventDefault:!0},{key:"Mod-y",mac:"Mod-Shift-z",run:G,preventDefault:!0},{key:"Ctrl-Shift-z",run:G,preventDefault:!0},...miA,...EN,...unA]),OYA,IoA({hideFirstIndent:!0}),St.domEventHandlers({dblclick:yA}),St.updateListener.of(Jt=>{b(cA,Jt.state),Jt.docChanged&&(Jt.transactions.some(Ki=>!!Ki.annotation(eA))||(RA=[...RA??[],Jt]),Tt()),Jt.selectionSet&&ui()}),FnA(),TnA({top:!0}),St.lineWrapping,EA.of(Ir.readOnly.of(Gt)),TA.of(Ir.tabSize.of(C())),sA.of(Ft(Xe)),Ke.of(St.theme({},{dark:We()}))]});return uA=new St({state:Pi,parent:fe}),Ot&&uA.dispatch(uA.state.update({selection:Ot.main,scrollIntoView:!0})),uA}({target:g(p),initialText:Ai(g(hA),g(aA))?"":g(A).escapeValue(g(hA)),readOnly:n(),indentation:I()})}catch(bA){console.error(bA)}})),Tc(()=>{Ht(),uA&&(j("Destroy CodeMirror editor"),uA.destroy())});var h=n1(),f=n1();function w(){uA&&(j("focus"),uA.focus())}var D=!1;function O(bA){return Z(bA,!1)}function Z(bA,fe){j("handlePatch",bA,fe);var it=B().parse(g(hA)),Gt=Ba(it,bA),Xe=f8(it,bA);return Vi({text:B().stringify(Gt,null,I())},fe,!1),{json:Gt,previousJson:it,undo:Xe,redo:bA}}function q(){if(j("format"),n())return!1;try{var bA=B().parse(g(hA));return Vi({text:B().stringify(bA,null,I())},!0,!1),b(jA,s()),!0}catch(fe){F()(fe)}return!1}function CA(){if(j("compact"),n())return!1;try{var bA=B().parse(g(hA));return Vi({text:B().stringify(bA)},!0,!1),b(jA,!1),!0}catch(fe){F()(fe)}return!1}function kA(){if(j("repair"),!n())try{Vi({text:yc(g(hA))},!0,!1),b(ei,xN),b(Oi,void 0)}catch(bA){F()(bA)}}function KA(){var bA;if(!n())try{var fe=B().parse(g(hA));D=!0,K()({id:h,json:fe,rootPath:[],onSort:(bA=yt(function*(it){var{operations:Gt}=it;j("onSort",Gt),Z(Gt,!0)}),function(it){return bA.apply(this,arguments)}),onClose:()=>{D=!1,w()}})}catch(it){F()(it)}}function Ie(bA){var{id:fe,rootPath:it,onTransform:Gt,onClose:Xe}=bA;try{var Ot=B().parse(g(hA));D=!0,H()({id:fe||f,json:Ot,rootPath:it||[],onTransform:Pi=>{Gt?Gt({operations:Pi,json:Ot,transformedJson:Ba(Ot,Pi)}):(j("onTransform",Pi),Z(Pi,!0))},onClose:()=>{D=!1,w(),Xe&&Xe()}})}catch(Pi){F()(Pi)}}function GA(){n()||Ie({rootPath:[]})}function oe(){uA&&(g(p)&&g(p).querySelector(".cm-search")?yD(uA):DD(uA))}function M(){if(n())return!1;Ht();var bA=l().undo();return j("undo",bA),HoA(bA)?(uA.dispatch({annotations:eA.of("undo"),changes:ns.fromJSON(bA.undo.changes),selection:ie.fromJSON(bA.undo.selection),scrollIntoView:!0}),!0):(x()(bA),!1)}function G(){if(n())return!1;Ht();var bA=l().redo();return j("redo",bA),HoA(bA)?(uA.dispatch({annotations:eA.of("redo"),changes:ns.fromJSON(bA.redo.changes),selection:ie.fromJSON(bA.redo.selection),scrollIntoView:!0}),!0):(y()(bA),!1)}function Y(){b(aA,!0),Vi(a(),!0,!0)}function AA(){v()(tr.tree)}function dA(){Zi()}function WA(bA){j("select validation error",bA);var{from:fe,to:it}=be(bA);fe!==void 0&&it!==void 0&&(Qe(fe,it),w())}function Qe(bA,fe){j("setSelection",{anchor:bA,head:fe}),uA&&uA.dispatch(uA.state.update({selection:{anchor:bA,head:fe},scrollIntoView:!0}))}function yA(bA,fe){if(fe.state.selection.ranges.length===1){var it=fe.state.selection.ranges[0],Gt=g(hA).slice(it.from,it.to);if(Gt==="{"||Gt==="["){var Xe=qN.default.parse(g(hA)),Ot=Object.keys(Xe.pointers).find(Jt=>{var Ki;return((Ki=Xe.pointers[Jt].value)===null||Ki===void 0?void 0:Ki.pos)===it.from}),Pi=Xe.pointers[Ot];Ot&&Pi&&Pi.value&&Pi.valueEnd&&(j("pointer found, selecting inner contents of path:",Ot,Pi),Qe(Pi.value.pos+1,Pi.valueEnd.pos-1))}}}function DA(){return fnA(Yn,{delay:300})}function We(){return!!g(p)&&getComputedStyle(g(p)).getPropertyValue("--jse-theme").includes("dark")}function be(bA){var{path:fe,message:it,severity:Gt}=bA,{line:Xe,column:Ot,from:Pi,to:Jt}=function(Ki,Ct){try{var ti=qN.default.parse(Ki),$e=nt(Ct),Nt=ti.pointers[$e];if(Nt)return{path:Ct,line:Nt.key?Nt.key.line:Nt.value?Nt.value.line:0,column:Nt.key?Nt.key.column:Nt.value?Nt.value.column:0,from:Nt.key?Nt.key.pos:Nt.value?Nt.value.pos:0,to:Nt.keyEnd?Nt.keyEnd.pos:Nt.valueEnd?Nt.valueEnd.pos:0}}catch(Wi){console.error(Wi)}return{path:Ct,line:0,column:0,from:0,to:0}}(g(A).escapeValue(g(hA)),fe);return{path:fe,line:Xe,column:Ot,from:Pi,to:Jt,message:it,severity:Gt,actions:[]}}function qA(bA,fe){var{line:it,column:Gt,position:Xe,message:Ot}=bA;return{path:[],line:it,column:Gt,from:Xe,to:Xe,severity:bl.error,message:Ot,actions:fe&&!n()?[{name:"Auto repair",apply:()=>kA()}]:void 0}}function It(bA){return{from:bA.from||0,to:bA.to||0,message:bA.message||"",actions:bA.actions,severity:bA.severity}}function Vi(bA,fe,it){var Gt=s_(bA,I(),B()),Xe=!Ei(bA,Re),Ot=Re;j("setCodeMirrorContent",{isChanged:Xe,emitChange:fe,forceUpdate:it}),uA&&(Xe||it)&&(Re=bA,b(hA,Gt),Ai(g(hA),g(aA))||uA.dispatch({changes:{from:0,to:uA.state.doc.length,insert:g(A).escapeValue(g(hA))}}),oA(),Xe&&fe&&zi(Re,Ot))}function on(bA){return GN(bA)?ie.fromJSON(bA):void 0}function Hi(){return Ci.apply(this,arguments)}function Ci(){return Ci=yt(function*(){j("refresh"),yield function(){return Qi.apply(this,arguments)}()}),Ci.apply(this,arguments)}function Zi(){if(uA){var bA=uA?g(A).unescapeValue(uA.state.doc.toString()):"",fe=bA!==g(hA);if(j("onChangeCodeMirrorValue",{isChanged:fe}),fe){var it=Re;b(hA,bA),Re={text:g(hA)},oA(),zi(Re,it),go(),ui()}}}function Qi(){return(Qi=yt(function*(){if(go(),uA){var bA=We();return j("updateTheme",{dark:bA}),uA.dispatch({effects:[Ke.reconfigure(St.theme({},{dark:bA}))]}),new Promise(fe=>setTimeout(fe))}return Promise.resolve()})).apply(this,arguments)}function Ft(bA){var fe=fC.of(typeof bA=="number"?" ".repeat(bA):bA);return bA==="	"?[fe]:[fe,jYA]}iG({onMount:ls,onDestroy:Tc,getWindow:()=>j3(g(V)),hasFocus:()=>D&&document.hasFocus()||J_(g(V)),onFocus:U(),onBlur:()=>{Ht(),T()()}});var Tt=PB(Zi,300);function Ht(){Tt.flush()}function zi(bA,fe){u()&&u()(bA,fe,{contentErrors:Dn(),patchResult:void 0})}function ui(){L()(Ye(g(cA).selection))}function Ye(bA){return Be({type:wn.text},bA.toJSON())}function Ai(bA,fe){return!!bA&&bA.length>UoA&&!fe}var ei=X(xN,!0),Oi=X(void 0,!0);function Yn(){if(Ai(g(hA),g(aA)))return[];var bA=Dn();if(ToA(bA)){var{parseError:fe,isRepairable:it}=bA;return[It(qA(fe,it))]}return MGA(bA)?bA.validationErrors.map(be).map(It):[]}function Dn(){j("validate:start"),Ht();var bA=Ho(g(A).escapeValue(g(hA)),E(),B(),Q());return ToA(bA)?(b(ei,bA.isRepairable?YoA:"invalid"),b(Oi,bA.parseError),b(VA,[])):(b(ei,xN),b(Oi,void 0),b(VA,bA?.validationErrors||[])),j("validate:end"),bA}var Ho=VB(KUA);function Sn(){g(Oi)&&function(bA){j("select parse error",bA);var fe=qA(bA,!1);Qe(fe.from!=null?fe.from:0,fe.to!=null?fe.to:0),w()}(g(Oi))}var io={icon:vW,text:"Show me",title:"Move to the parse error location",onClick:Sn};fA(()=>W(d()),()=>{b(A,K_({escapeControlCharacters:!1,escapeUnicodeCharacters:d()}))}),fA(()=>W(a()),()=>{Vi(a(),!1,!1)}),fA(()=>W(c()),()=>{(function(bA){if(GN(bA)){var fe=on(bA);!uA||!fe||g(cA)&&g(cA).selection.eq(fe)||(j("applyExternalSelection",fe),uA.dispatch({selection:fe}))}})(c())}),fA(()=>W(E()),()=>{(function(bA){j("updateLinter",bA),uA&&uA.dispatch({effects:ce.reconfigure(DA())})})(E())}),fA(()=>W(I()),()=>{(function(bA){uA&&(j("updateIndentation",bA),uA.dispatch({effects:sA.reconfigure(Ft(bA))}))})(I())}),fA(()=>W(C()),()=>{(function(bA){uA&&(j("updateTabSize",bA),uA.dispatch({effects:TA.reconfigure(Ir.tabSize.of(bA))}))})(C())}),fA(()=>W(n()),()=>{(function(bA){uA&&(j("updateReadOnly",bA),uA.dispatch({effects:[EA.reconfigure(Ir.readOnly.of(bA))]}))})(n())}),fA(()=>(g(ne),W(d())),()=>{g(ne)!==d()&&(b(ne,d()),j("forceUpdateText",{escapeUnicodeCharacters:d()}),uA&&uA.dispatch({changes:{from:0,to:uA.state.doc.length,insert:g(A).escapeValue(g(hA))}}))}),fA(()=>(g(ei),W(n()),M0),()=>{b(i,g(ei)!==YoA||n()?[io]:[{icon:M0,text:"Auto repair",title:"Automatically repair JSON",onClick:kA},io])}),nn(),Rt(!0);var Wo,No=XYA(),Jn=$(No),hn=bA=>{var fe=PA(()=>g(hA).length===0),it=PA(()=>!g(fe)),Gt=PA(()=>!g(fe)),Xe=PA(()=>!g(fe)),Ot=PA(()=>!g(fe));(function(Pi,Jt){st(Jt,!1);var Ki=X(void 0,!0),Ct=k(Jt,"readOnly",9,!1),ti=k(Jt,"onFormat",9),$e=k(Jt,"onCompact",9),Nt=k(Jt,"onSort",9),Wi=k(Jt,"onTransform",9),Tn=k(Jt,"onToggleSearch",9),ii=k(Jt,"onUndo",9),Ri=k(Jt,"onRedo",9),dt=k(Jt,"canUndo",9),zn=k(Jt,"canRedo",9),QA=k(Jt,"canFormat",9),_A=k(Jt,"canCompact",9),Ce=k(Jt,"canSort",9),Pt=k(Jt,"canTransform",9),Li=k(Jt,"onRenderMenu",9),ai={type:"button",icon:Zu,title:"Search (Ctrl+F)",className:"jse-search",onClick:Tn()},Fn=X(void 0,!0);fA(()=>(W(Ct()),W(ti()),W(QA()),W($e()),W(_A()),W(Nt()),W(Ce()),W(Wi()),W(Pt()),W(ii()),W(dt()),W(Ri()),W(zn())),()=>{b(Fn,Ct()?[ai,{type:"space"}]:[{type:"button",icon:ErA,title:"Format JSON: add proper indentation and new lines (Ctrl+I)",className:"jse-format",onClick:ti(),disabled:Ct()||!QA()},{type:"button",icon:zKA,title:"Compact JSON: remove all white spacing and new lines (Ctrl+Shift+I)",className:"jse-compact",onClick:$e(),disabled:Ct()||!_A()},{type:"separator"},{type:"button",icon:Vu,title:"Sort",className:"jse-sort",onClick:Nt(),disabled:Ct()||!Ce()},{type:"button",icon:Pu,title:"Transform contents (filter, sort, project)",className:"jse-transform",onClick:Wi(),disabled:Ct()||!Pt()},ai,{type:"separator"},{type:"button",icon:s5,title:"Undo (Ctrl+Z)",className:"jse-undo",onClick:ii(),disabled:!dt()},{type:"button",icon:r5,title:"Redo (Ctrl+Shift+Z)",className:"jse-redo",onClick:Ri(),disabled:!zn()},{type:"space"}])}),fA(()=>(W(Li()),g(Fn)),()=>{b(Ki,Li()(g(Fn))||g(Fn))}),nn(),Rt(!0),Ly(Pi,{get items(){return g(Ki)}}),at()})(bA,{get readOnly(){return n()},onFormat:q,onCompact:CA,onSort:KA,onTransform:GA,onToggleSearch:oe,onUndo:M,onRedo:G,get canFormat(){return g(it)},get canCompact(){return g(Gt)},get canSort(){return g(Xe)},get canTransform(){return g(Ot)},get canUndo(){return l().canUndo},get canRedo(){return l().canRedo},get onRenderMenu(){return N()}})};MA(Jn,bA=>{o()&&bA(hn)});var wo=gA(Jn,2),se=bA=>{var fe,it=ZYA(),Gt=PA(()=>Ai(g(hA),g(aA))),Xe=Bt(it);to(Xe,Ct=>b(p,Ct),()=>g(p));var Ot=gA(Xe,2),Pi=Ct=>{var ti=qYA(),$e=Bt(ti),Nt=PA(()=>"The JSON document is larger than ".concat(h_(UoA),", ")+"and may crash your browser when loading it in text mode. Actual size: ".concat(h_(g(hA).length),"."));Cc($e,{icon:r1,type:"error",get message(){return g(Nt)},actions:[{text:"Open anyway",title:"Open the document in text mode. This may freeze or crash your browser.",onClick:Y},{text:"Open in tree mode",title:"Open the document in tree mode. Tree mode can handle large documents.",onClick:AA},{text:"Cancel",title:"Cancel opening this large document.",onClick:dA}],onClose:w});var Wi=$(gA($e,2));Ee(Tn=>Et(Wi,Tn),[()=>S3(g(hA)||"",l_)],PA),iA(Ct,ti)};MA(Ot,Ct=>{g(Gt)&&Ct(Pi)});var Jt=gA(Ot,2),Ki=Ct=>{var ti=VYA(),$e=Bt(ti),Nt=dt=>{(function(zn,QA){st(QA,!1);var _A=k(QA,"editorState",8),Ce=X(),Pt=X(),Li=X(),ai=X(),Fn=X();fA(()=>W(_A()),()=>{var Oe;b(Ce,(Oe=_A())===null||Oe===void 0||(Oe=Oe.selection)===null||Oe===void 0||(Oe=Oe.main)===null||Oe===void 0?void 0:Oe.head)}),fA(()=>(g(Ce),W(_A())),()=>{var Oe;b(Pt,g(Ce)!==void 0?(Oe=_A())===null||Oe===void 0||(Oe=Oe.doc)===null||Oe===void 0?void 0:Oe.lineAt(g(Ce)):void 0)}),fA(()=>g(Pt),()=>{b(Li,g(Pt)!==void 0?g(Pt).number:void 0)}),fA(()=>(g(Pt),g(Ce)),()=>{b(ai,g(Pt)!==void 0&&g(Ce)!==void 0?g(Ce)-g(Pt).from+1:void 0)}),fA(()=>W(_A()),()=>{var Oe;b(Fn,(Oe=_A())===null||Oe===void 0||(Oe=Oe.selection)===null||Oe===void 0||(Oe=Oe.ranges)===null||Oe===void 0?void 0:Oe.reduce((ni,fn)=>ni+fn.to-fn.from,0))}),nn(),Rt();var Co=HYA(),Qn=$(Co),un=Oe=>{var ni=JYA(),fn=$(ni);Ee(()=>{var Yi;return Et(fn,"Line: ".concat((Yi=g(Li))!==null&&Yi!==void 0?Yi:""))}),iA(Oe,ni)};MA(Qn,Oe=>{g(Li)!==void 0&&Oe(un)});var jt=gA(Qn,2),Nn=Oe=>{var ni=TYA(),fn=$(ni);Ee(()=>{var Yi;return Et(fn,"Column: ".concat((Yi=g(ai))!==null&&Yi!==void 0?Yi:""))}),iA(Oe,ni)};MA(jt,Oe=>{g(ai)!==void 0&&Oe(Nn)});var ut=gA(jt,2),Xo=Oe=>{var ni=zYA(),fn=$(ni);Ee(()=>{var Yi;return Et(fn,"Selection: ".concat((Yi=g(Fn))!==null&&Yi!==void 0?Yi:""," characters"))}),iA(Oe,ni)};MA(ut,Oe=>{g(Fn)!==void 0&&g(Fn)>0&&Oe(Xo)}),iA(zn,Co),at()})(dt,{get editorState(){return g(cA)}})};MA($e,dt=>{r()&&dt(Nt)});var Wi=gA($e,2),Tn=dt=>{Cc(dt,{type:"error",icon:r1,get message(){return g(Oi).message},get actions(){return g(i)},onClick:Sn,onClose:w})};MA(Wi,dt=>{g(Oi)&&dt(Tn)});var ii=gA(Wi,2),Ri=dt=>{Cc(dt,{type:"success",message:"Do you want to format the JSON?",actions:[{icon:ErA,text:"Format",title:"Format JSON: add proper indentation and new lines (Ctrl+I)",onClick:q},{icon:Wu,text:"No thanks",title:"Close this message",onClick:()=>b(jA,!1)}],onClose:w})};MA(ii,dt=>{var zn,QA;!g(Oi)&&g(jA)&&(zn=g(hA),!(QA=zn.substring(0,999).trim()).includes(`
`)&&W_A.test(QA))&&dt(Ri)}),nG(gA(ii,2),{get validationErrors(){return g(VA)},selectError:WA}),iA(Ct,ti)};MA(Jt,Ct=>{g(Gt)||Ct(Ki)}),Ee(Ct=>fe=xt(Xe,1,"jse-contents svelte-xt61xw",null,fe,Ct),[()=>({"jse-hidden":g(Gt)})],PA),iA(bA,it)},fi=bA=>{iA(bA,WYA())};return MA(wo,bA=>{lA?bA(fi,!1):bA(se)}),to(No,bA=>b(V,bA),()=>g(V)),Ee(bA=>Wo=xt(No,1,"jse-text-mode svelte-xt61xw",null,Wo,bA),[()=>({"no-main-menu":!o()})],PA),iA(t,No),kt(e,"focus",w),kt(e,"patch",O),kt(e,"handlePatch",Z),kt(e,"openTransformModal",Ie),kt(e,"refresh",Hi),kt(e,"flush",Ht),kt(e,"validate",Dn),at({focus:w,patch:O,handlePatch:Z,openTransformModal:Ie,refresh:Hi,flush:Ht,validate:Dn})}vt(`/* over all fonts, sizes, and colors */
/* "consolas" for Windows, "menlo" for Mac with fallback to "monaco", 'Ubuntu Mono' for Ubuntu */
/* (at Mac this font looks too large at 14px, but 13px is too small for the font on Windows) */
/* main, menu, modal */
/* jsoneditor modal */
/* tooltip in text mode */
/* panels: navigation bar, gutter, search box */
/* navigation-bar */
/* context menu */
/* contents: json key and values */
/* contents: selected or hovered */
/* contents: section of collapsed items in an array */
/* contents: highlighting of search matches */
/* contents: inline tags inside the JSON document */
/* contents: table */
/* controls in modals: inputs, buttons, and \`a\` */
/* messages */
/* svelte-select */
/* color picker */
.jse-inline-value.svelte-h57m0p {
  font-family: var(--jse-font-family-mono, consolas, menlo, monaco, "Ubuntu Mono", "source-code-pro", monospace);
  font-size: var(--jse-font-size-mono, 14px);
  line-height: var(--jse-line-height, calc(1em + 4px));
  border: none;
  padding: 0 calc(0.5 * var(--jse-padding, 10px));
  background: transparent;
  color: inherit;
  cursor: inherit;
}
.jse-inline-value.jse-highlight.svelte-h57m0p {
  background-color: var(--jse-search-match-color, #ffe665);
  outline: var(--jse-search-match-outline, none);
}
.jse-inline-value.jse-highlight.jse-active.svelte-h57m0p {
  background-color: var(--jse-search-match-active-color, var(--jse-search-match-color, #ffe665));
  outline: var(--jse-search-match-outline, 2px solid #e0be00);
}`);var AJA=pA('<button type="button"> </button>');vt(`/* over all fonts, sizes, and colors */
/* "consolas" for Windows, "menlo" for Mac with fallback to "monaco", 'Ubuntu Mono' for Ubuntu */
/* (at Mac this font looks too large at 14px, but 13px is too small for the font on Windows) */
/* main, menu, modal */
/* jsoneditor modal */
/* tooltip in text mode */
/* panels: navigation bar, gutter, search box */
/* navigation-bar */
/* context menu */
/* contents: json key and values */
/* contents: selected or hovered */
/* contents: section of collapsed items in an array */
/* contents: highlighting of search matches */
/* contents: inline tags inside the JSON document */
/* contents: table */
/* controls in modals: inputs, buttons, and \`a\` */
/* messages */
/* svelte-select */
/* color picker */
.jse-column-header.svelte-2i3vdx {
  background: none;
  border: none;
  font-family: inherit;
  font-size: inherit;
  color: inherit;
  display: flex;
  gap: var(--jse-padding, 10px);
  padding: calc(0.5 * var(--jse-padding, 10px)) var(--jse-padding, 10px) calc(0.5 * var(--jse-padding, 10px)) calc(0.5 * var(--jse-padding, 10px));
  width: 100%;
}
.jse-column-header.svelte-2i3vdx:hover {
  background: var(--jse-table-header-background-highlight, #e8e8e8);
}
.jse-column-header.svelte-2i3vdx:not(.jse-column-header.jse-readonly) {
  cursor: pointer;
}
.jse-column-header.svelte-2i3vdx span.jse-column-sort-icon:where(.svelte-2i3vdx) {
  height: 1em;
}`);var eJA=pA('<span class="jse-column-sort-icon svelte-2i3vdx"><!></span>'),tJA=pA('<button type="button"><span class="jse-column-name"> </span> <!></button>');vt(`/* over all fonts, sizes, and colors */
/* "consolas" for Windows, "menlo" for Mac with fallback to "monaco", 'Ubuntu Mono' for Ubuntu */
/* (at Mac this font looks too large at 14px, but 13px is too small for the font on Windows) */
/* main, menu, modal */
/* jsoneditor modal */
/* tooltip in text mode */
/* panels: navigation bar, gutter, search box */
/* navigation-bar */
/* context menu */
/* contents: json key and values */
/* contents: selected or hovered */
/* contents: section of collapsed items in an array */
/* contents: highlighting of search matches */
/* contents: inline tags inside the JSON document */
/* contents: table */
/* controls in modals: inputs, buttons, and \`a\` */
/* messages */
/* svelte-select */
/* color picker */
.jse-table-mode-welcome.svelte-17xl1jx {
  flex: 1;
  display: flex;
  flex-direction: column;
  overflow: auto;
  align-items: center;
  border-left: var(--jse-main-border, 1px solid #d7d7d7);
  border-right: var(--jse-main-border, 1px solid #d7d7d7);
}
.jse-table-mode-welcome.svelte-17xl1jx:last-child {
  border-bottom: var(--jse-main-border, 1px solid #d7d7d7);
}
.jse-table-mode-welcome.svelte-17xl1jx .jse-space.jse-before:where(.svelte-17xl1jx) {
  flex: 1;
}
.jse-table-mode-welcome.svelte-17xl1jx .jse-nested-arrays:where(.svelte-17xl1jx) {
  display: flex;
  flex-direction: column;
  gap: var(--jse-padding, 10px);
  max-width: 400px;
  margin: 2em var(--jse-padding, 10px);
  font-family: var(--jse-font-family, -apple-system, BlinkMacSystemFont, "Segoe UI", Roboto, Oxygen-Sans, Ubuntu, Cantarell, "Helvetica Neue", sans-serif);
  font-size: var(--jse-font-size, 16px);
}
.jse-table-mode-welcome.svelte-17xl1jx .jse-nested-arrays:where(.svelte-17xl1jx) .jse-nested-arrays-info:where(.svelte-17xl1jx) {
  color: var(--jse-panel-color-readonly, #b2b2b2);
}
.jse-table-mode-welcome.svelte-17xl1jx .jse-nested-arrays:where(.svelte-17xl1jx) .jse-nested-property:where(.svelte-17xl1jx) {
  display: flex;
  align-items: center;
  gap: var(--jse-padding, 10px);
}
.jse-table-mode-welcome.svelte-17xl1jx .jse-nested-arrays:where(.svelte-17xl1jx) .jse-nested-property:where(.svelte-17xl1jx) .jse-nested-property-path:where(.svelte-17xl1jx) {
  flex: 1;
}
.jse-table-mode-welcome.svelte-17xl1jx .jse-nested-arrays:where(.svelte-17xl1jx) .jse-nested-property:where(.svelte-17xl1jx) .jse-nested-property-path:where(.svelte-17xl1jx) .jse-nested-property-count:where(.svelte-17xl1jx) {
  opacity: 0.5;
  white-space: nowrap;
}
.jse-table-mode-welcome.svelte-17xl1jx .jse-nested-arrays:where(.svelte-17xl1jx) button.jse-nested-array-action:where(.svelte-17xl1jx) {
  text-align: left;
  border: none;
  background: transparent;
  color: inherit;
  cursor: pointer;
  font-family: var(--jse-font-family, -apple-system, BlinkMacSystemFont, "Segoe UI", Roboto, Oxygen-Sans, Ubuntu, Cantarell, "Helvetica Neue", sans-serif);
  font-size: var(--jse-font-size, 16px);
  padding: 5px;
  margin: 0;
  background: var(--jse-button-primary-background, var(--jse-theme-color, #3883fa));
  color: var(--jse-button-primary-color, #fff);
  padding: var(--jse-padding, 10px) calc(2 * var(--jse-padding, 10px));
  border-radius: 3px;
}
.jse-table-mode-welcome.svelte-17xl1jx .jse-nested-arrays:where(.svelte-17xl1jx) button.jse-nested-array-action:where(.svelte-17xl1jx):hover {
  background: var(--jse-button-primary-background-highlight, var(--jse-theme-color-highlight, #5f9dff));
}
.jse-table-mode-welcome.svelte-17xl1jx .jse-nested-arrays:where(.svelte-17xl1jx) button.jse-nested-array-action:where(.svelte-17xl1jx):disabled {
  background: var(--jse-button-primary-background-disabled, #9d9d9d);
}
.jse-table-mode-welcome.svelte-17xl1jx .jse-space.jse-after:where(.svelte-17xl1jx) {
  flex: 2;
}`);var iJA=(t,e)=>e.onClick(),nJA=pA(`An empty document cannot be opened in table mode. You can go to tree mode instead, or paste
        a JSON Array using <b>Ctrl+V</b>.`,1),oJA=(t,e,A)=>e.openJSONEditorModal(g(A)),rJA=(t,e,A)=>e.extractPath(g(A)),sJA=pA('<button type="button" class="jse-nested-array-action svelte-17xl1jx">Extract</button>'),aJA=pA('<div class="jse-nested-property svelte-17xl1jx"><div class="jse-nested-property-path svelte-17xl1jx"> <span class="jse-nested-property-count svelte-17xl1jx"> </span></div> <button type="button" class="jse-nested-array-action svelte-17xl1jx"> </button> <!></div>'),cJA=(t,e)=>e.onChangeMode(tr.tree),lJA=pA('<div class="jse-table-mode-welcome svelte-17xl1jx" role="none"><div class="jse-space jse-before svelte-17xl1jx"></div> <div class="jse-nested-arrays svelte-17xl1jx"><div class="jse-nested-arrays-title"> </div> <div class="jse-nested-arrays-info svelte-17xl1jx"><!></div> <!> <button type="button" class="jse-nested-array-action svelte-17xl1jx">Switch to tree mode</button></div> <div class="jse-space jse-after svelte-17xl1jx"></div></div>');function gJA(t,e){st(e,!0);var A=ba(()=>e.json?function(E){var Q=arguments.length>1&&arguments[1]!==void 0?arguments[1]:2,u=[];return function v(L,x){Mo(L)&&x.length<Q&&Object.keys(L).forEach(y=>{v(L[y],x.concat(y))}),ao(L)&&u.push(x)}(E,[]),u}(e.json).slice(0,99).filter(E=>E.length>0):[]),i=ba(()=>!sn(g(A))),n=ba(()=>e.json===void 0&&(e.text===""||e.text===void 0)),o=ba(()=>g(i)?"Object with nested arrays":g(n)?"An empty document":Mo(e.json)?"An object":ao(e.json)?"An empty array":"A ".concat(U_(e.json,e.parser))),r=lJA();r.__click=[iJA,e];var s=gA($(r),2),a=$(s),c=$(a),l=gA(a,2),I=$(l),C=E=>{iA(E,_r(`An object cannot be opened in table mode. You can open a nested array instead, or open the
        document in tree mode.`))},d=(E,Q)=>{var u=L=>{iA(L,nJA())},v=L=>{var x=_r();Ee(()=>{var y;return Et(x,"".concat((y=g(o))!==null&&y!==void 0?y:""," cannot be opened in table mode. You can open the document in tree mode instead."))}),iA(L,x)};MA(E,L=>{g(n)&&!e.readOnly?L(u):L(v,!1)},Q)};MA(I,E=>{g(i)?E(C):E(d,!1)});var B=gA(l,2);Fo(B,17,()=>g(A),Zo,(E,Q)=>{var u=aJA(),v=ba(()=>function(K){return Fe(e.json,K).length}(g(Q))),L=$(u),x=$(L),y=$(gA(x)),F=gA(L,2);F.__click=[oJA,e,Q];var U=$(F),T=gA(F,2),N=K=>{var H=sJA();H.__click=[rJA,e,Q],iA(K,H)};MA(T,K=>{e.readOnly||K(N)}),Ee(K=>{var H;Et(x,'"'.concat(K??"",'" ')),Et(y,"(".concat((H=g(v))!==null&&H!==void 0?H:""," ").concat(g(v)!==1?"items":"item",")")),Et(U,e.readOnly?"View":"Edit")},[()=>Dl(g(Q))]),iA(E,u)}),gA(B,2).__click=[cJA,e],Ee(()=>Et(c,g(o))),iA(t,r),at()}H3(["click"]);vt(`/* over all fonts, sizes, and colors */
/* "consolas" for Windows, "menlo" for Mac with fallback to "monaco", 'Ubuntu Mono' for Ubuntu */
/* (at Mac this font looks too large at 14px, but 13px is too small for the font on Windows) */
/* main, menu, modal */
/* jsoneditor modal */
/* tooltip in text mode */
/* panels: navigation bar, gutter, search box */
/* navigation-bar */
/* context menu */
/* contents: json key and values */
/* contents: selected or hovered */
/* contents: section of collapsed items in an array */
/* contents: highlighting of search matches */
/* contents: inline tags inside the JSON document */
/* contents: table */
/* controls in modals: inputs, buttons, and \`a\` */
/* messages */
/* svelte-select */
/* color picker */
.jse-column-header.svelte-fzj761 {
  background: none;
  border: none;
  font-family: inherit;
  font-size: inherit;
  color: inherit;
  display: flex;
  gap: var(--jse-padding, 10px);
  padding: calc(0.5 * var(--jse-padding, 10px)) var(--jse-padding, 10px) calc(0.5 * var(--jse-padding, 10px)) calc(0.5 * var(--jse-padding, 10px));
  width: 100%;
}
.jse-column-header.svelte-fzj761:hover {
  background: var(--jse-table-header-background-highlight, #e8e8e8);
}
.jse-column-header.svelte-fzj761:not(.jse-column-header.jse-readonly) {
  cursor: pointer;
}`);var IJA=pA('<button type="button"><!></button>');vt(`/* over all fonts, sizes, and colors */
/* "consolas" for Windows, "menlo" for Mac with fallback to "monaco", 'Ubuntu Mono' for Ubuntu */
/* (at Mac this font looks too large at 14px, but 13px is too small for the font on Windows) */
/* main, menu, modal */
/* jsoneditor modal */
/* tooltip in text mode */
/* panels: navigation bar, gutter, search box */
/* navigation-bar */
/* context menu */
/* contents: json key and values */
/* contents: selected or hovered */
/* contents: section of collapsed items in an array */
/* contents: highlighting of search matches */
/* contents: inline tags inside the JSON document */
/* contents: table */
/* controls in modals: inputs, buttons, and \`a\` */
/* messages */
/* svelte-select */
/* color picker */
.jse-table-mode.svelte-u14cgx {
  flex: 1;
  display: flex;
  flex-direction: column;
  position: relative;
  background: var(--jse-background-color, #fff);
  min-width: 0;
  min-height: 0;
  font-family: var(--jse-font-family-mono, consolas, menlo, monaco, "Ubuntu Mono", "source-code-pro", monospace);
  font-size: var(--jse-font-size-mono, 14px);
  color: var(--jse-text-color, #4d4d4d);
  line-height: var(--jse-line-height, calc(1em + 4px));
}
.jse-table-mode.no-main-menu.svelte-u14cgx {
  border-top: var(--jse-main-border, 1px solid #d7d7d7);
}
.jse-table-mode.svelte-u14cgx .jse-search-box-container:where(.svelte-u14cgx) {
  position: relative;
  height: 0;
  top: calc(var(--jse-line-height, calc(1em + 4px)) + 2 * var(--jse-padding, 10px));
  margin-right: calc(var(--jse-padding, 10px) + 20px);
  margin-left: var(--jse-padding, 10px);
  text-align: right;
  z-index: 3;
}
.jse-table-mode.svelte-u14cgx .jse-hidden-input-label:where(.svelte-u14cgx) {
  position: fixed;
  right: 0;
  top: 0;
  width: 0;
  height: 0;
}
.jse-table-mode.svelte-u14cgx .jse-hidden-input-label:where(.svelte-u14cgx) .jse-hidden-input:where(.svelte-u14cgx) {
  width: 0;
  height: 0;
  padding: 0;
  border: 0;
  outline: none;
}
.jse-table-mode.svelte-u14cgx .jse-contents:where(.svelte-u14cgx) {
  flex: 1;
  align-items: flex-start;
  flex-direction: column;
  display: flex;
  overflow: auto;
  overflow-anchor: none;
  scrollbar-gutter: stable;
  border-left: var(--jse-main-border, 1px solid #d7d7d7);
  border-right: var(--jse-main-border, 1px solid #d7d7d7);
}
.jse-table-mode.svelte-u14cgx .jse-contents:where(.svelte-u14cgx):last-child {
  border-bottom: var(--jse-main-border, 1px solid #d7d7d7);
}
.jse-table-mode.svelte-u14cgx .jse-contents:where(.svelte-u14cgx) table.jse-table-main:where(.svelte-u14cgx) {
  border-collapse: collapse;
  border-spacing: 0;
}
.jse-table-mode.svelte-u14cgx .jse-contents:where(.svelte-u14cgx) table.jse-table-main:where(.svelte-u14cgx) .jse-table-invisible-start-section:where(.svelte-u14cgx) td:where(.svelte-u14cgx),
.jse-table-mode.svelte-u14cgx .jse-contents:where(.svelte-u14cgx) table.jse-table-main:where(.svelte-u14cgx) .jse-table-invisible-end-section:where(.svelte-u14cgx) td:where(.svelte-u14cgx) {
  margin: 0;
  padding: 0;
}
.jse-table-mode.svelte-u14cgx .jse-contents:where(.svelte-u14cgx) table.jse-table-main:where(.svelte-u14cgx) .jse-search-box-background:where(.svelte-u14cgx) {
  background: var(--jse-table-header-background, #f5f5f5);
}
.jse-table-mode.svelte-u14cgx .jse-contents:where(.svelte-u14cgx) table.jse-table-main:where(.svelte-u14cgx) .jse-table-invisible-end-section:where(.svelte-u14cgx) td:where(.svelte-u14cgx) {
  padding-bottom: var(--jse-padding, 10px);
}
.jse-table-mode.svelte-u14cgx .jse-contents:where(.svelte-u14cgx) table.jse-table-main:where(.svelte-u14cgx) .jse-table-row:where(.svelte-u14cgx):hover {
  background-color: var(--jse-table-row-odd-background, rgba(0, 0, 0, 0.05));
}
.jse-table-mode.svelte-u14cgx .jse-contents:where(.svelte-u14cgx) table.jse-table-main:where(.svelte-u14cgx) .jse-table-row:where(.svelte-u14cgx) .jse-table-cell:where(.svelte-u14cgx) {
  padding: 0 var(--jse-padding, 10px) 0 0;
  vertical-align: top;
  white-space: nowrap;
  height: var(--jse-line-height, calc(1em + 4px));
}
.jse-table-mode.svelte-u14cgx .jse-contents:where(.svelte-u14cgx) table.jse-table-main:where(.svelte-u14cgx) .jse-table-row:where(.svelte-u14cgx) .jse-table-cell.jse-table-cell-header:where(.svelte-u14cgx), .jse-table-mode.svelte-u14cgx .jse-contents:where(.svelte-u14cgx) table.jse-table-main:where(.svelte-u14cgx) .jse-table-row:where(.svelte-u14cgx) .jse-table-cell.jse-table-cell-gutter:where(.svelte-u14cgx) {
  font-weight: normal;
  text-align: left;
  color: var(--jse-text-readonly, #8d8d8d);
  background: var(--jse-table-header-background, #f5f5f5);
}
.jse-table-mode.svelte-u14cgx .jse-contents:where(.svelte-u14cgx) table.jse-table-main:where(.svelte-u14cgx) .jse-table-row:where(.svelte-u14cgx) .jse-table-cell.jse-table-cell-header:where(.svelte-u14cgx) {
  padding: 0;
  position: sticky;
  top: 0;
}
.jse-table-mode.svelte-u14cgx .jse-contents:where(.svelte-u14cgx) table.jse-table-main:where(.svelte-u14cgx) .jse-table-row:where(.svelte-u14cgx) .jse-table-cell.jse-table-cell-header:where(.svelte-u14cgx) .jse-table-root-error:where(.svelte-u14cgx) {
  padding: calc(0.5 * var(--jse-padding, 10px)) var(--jse-padding, 10px) calc(0.5 * var(--jse-padding, 10px)) calc(0.5 * var(--jse-padding, 10px));
}
.jse-table-mode.svelte-u14cgx .jse-contents:where(.svelte-u14cgx) table.jse-table-main:where(.svelte-u14cgx) .jse-table-row:where(.svelte-u14cgx) .jse-table-cell.jse-table-cell-gutter:where(.svelte-u14cgx) {
  padding: 0 var(--jse-padding, 10px) 0 calc(0.5 * var(--jse-padding, 10px));
}
.jse-table-mode.svelte-u14cgx .jse-contents:where(.svelte-u14cgx) table.jse-table-main:where(.svelte-u14cgx) .jse-table-row:where(.svelte-u14cgx) .jse-table-cell:where(.svelte-u14cgx) .jse-value-outer:where(.svelte-u14cgx) {
  display: inline-block;
  cursor: var(--jse-contents-cursor, pointer);
}
.jse-table-mode.svelte-u14cgx .jse-contents:where(.svelte-u14cgx) table.jse-table-main:where(.svelte-u14cgx) .jse-table-row:where(.svelte-u14cgx) .jse-table-cell:where(.svelte-u14cgx) .jse-value-outer:where(.svelte-u14cgx):hover {
  background: var(--jse-hover-background-color, rgba(0, 0, 0, 0.06));
}
.jse-table-mode.svelte-u14cgx .jse-contents:where(.svelte-u14cgx) table.jse-table-main:where(.svelte-u14cgx) .jse-table-row:where(.svelte-u14cgx) .jse-table-cell:where(.svelte-u14cgx) .jse-value-outer.jse-selected-value:where(.svelte-u14cgx) {
  background: var(--jse-selection-background-color, #d3d3d3);
}
.jse-table-mode.svelte-u14cgx .jse-contents:where(.svelte-u14cgx) table.jse-table-main:where(.svelte-u14cgx) .jse-table-row:where(.svelte-u14cgx) .jse-table-cell:where(.svelte-u14cgx) .jse-context-menu-anchor:where(.svelte-u14cgx) {
  display: inline-flex;
  position: relative;
  vertical-align: top;
}
.jse-table-mode.svelte-u14cgx .jse-contents.jse-contents-loading:where(.svelte-u14cgx) {
  align-items: unset;
}
.jse-table-mode.svelte-u14cgx .jse-contents.jse-contents-loading:where(.svelte-u14cgx) .jse-loading-space:where(.svelte-u14cgx) {
  flex: 1;
}
.jse-table-mode.svelte-u14cgx .jse-contents.jse-contents-loading:where(.svelte-u14cgx) .jse-loading:where(.svelte-u14cgx) {
  flex: 2;
  text-align: center;
  color: var(--jse-panel-color-readonly, #b2b2b2);
  box-sizing: border-box;
  font-family: var(--jse-font-family, -apple-system, BlinkMacSystemFont, "Segoe UI", Roboto, Oxygen-Sans, Ubuntu, Cantarell, "Helvetica Neue", sans-serif);
  font-size: var(--jse-font-size, 16px);
}`);var CJA=pA('<div class="jse-table-root-error svelte-u14cgx"><!></div>'),dJA=pA('<th class="jse-table-cell jse-table-cell-header svelte-u14cgx"><!></th>'),BJA=pA('<th class="jse-table-cell jse-table-cell-header svelte-u14cgx"><!></th>'),EJA=pA('<th class="jse-table-cell jse-table-cell-gutter svelte-u14cgx"> <!></th>'),hJA=pA('<div class="jse-context-menu-anchor svelte-u14cgx"><!></div>'),QJA=pA('<td class="jse-table-cell svelte-u14cgx"><div><!><!></div> <!></td>'),uJA=pA('<td class="jse-table-cell svelte-u14cgx"></td>'),fJA=pA('<tr class="jse-table-row svelte-u14cgx"><!><!><!></tr>'),mJA=pA('<div class="jse-search-box-container svelte-u14cgx"><!></div> <div class="jse-contents svelte-u14cgx"><table class="jse-table-main svelte-u14cgx"><tbody><tr class="jse-table-row jse-table-row-header svelte-u14cgx"><th class="jse-table-cell jse-table-cell-header svelte-u14cgx"><!></th><!><!></tr><tr><td class="svelte-u14cgx"></td></tr><!><tr class="jse-table-invisible-end-section svelte-u14cgx"><td class="svelte-u14cgx"></td></tr></tbody></table></div> <!> <!> <!> <!>',1),pJA=pA("<!> <!>",1),wJA=pA('<label class="jse-hidden-input-label svelte-u14cgx"><input type="text" tabindex="-1" class="jse-hidden-input svelte-u14cgx"/></label> <!>',1),DJA=pA('<div class="jse-contents jse-contents-loading svelte-u14cgx"><div class="jse-loading-space svelte-u14cgx"></div> <div class="jse-loading svelte-u14cgx">loading...</div></div>'),yJA=pA('<div role="table"><!> <!></div> <!> <!>',1);function vJA(t,e){st(e,!1);var A=X(void 0,!0),i=X(void 0,!0),n=X(void 0,!0),o=wr("jsoneditor:TableMode"),{openAbsolutePopup:r,closeAbsolutePopup:s}=H1("absolute-popup"),a=ZsA(),c=n1(),l=n1(),I=typeof window>"u";o("isSSR:",I);var C=k(e,"readOnly",9),d=k(e,"externalContent",9),B=k(e,"externalSelection",9),E=k(e,"history",9),Q=k(e,"truncateTextSize",9),u=k(e,"mainMenuBar",9),v=k(e,"escapeControlCharacters",9),L=k(e,"escapeUnicodeCharacters",9),x=k(e,"flattenColumns",9),y=k(e,"parser",9),F=k(e,"parseMemoizeOne",9),U=k(e,"validator",9),T=k(e,"validationParser",9),N=k(e,"indentation",9),K=k(e,"onChange",9),H=k(e,"onChangeMode",9),j=k(e,"onSelect",9),IA=k(e,"onUndo",9),lA=k(e,"onRedo",9),uA=k(e,"onRenderValue",9),p=k(e,"onRenderMenu",9),V=k(e,"onRenderContextMenu",9),cA=k(e,"onFocus",9),aA=k(e,"onBlur",9),jA=k(e,"onSortModal",9),VA=k(e,"onTransformModal",9),ce=k(e,"onJSONEditorModal",9),EA=X(void 0,!0),sA=X(void 0,!0),TA=X(void 0,!0),Ke=X(void 0,!0),Re=X(void 0,!0);iG({onMount:ls,onDestroy:Tc,getWindow:()=>j3(g(sA)),hasFocus:()=>GA&&document.hasFocus()||J_(g(sA)),onFocus:()=>{oe=!0,cA()&&cA()()},onBlur:()=>{oe=!1,aA()&&aA()()}});var hA,eA=X(void 0,!0),RA=X(void 0,!0),oA=X(void 0,!0),ne=X(void 0,!0),h=X(void 0,!0),f=X(void 0,!0),w=X(!1,!0),D=X(!1,!0);function O(z){b(f,(hA=z)?GsA(g(eA),hA.items):void 0)}function Z(z){return q.apply(this,arguments)}function q(){return(q=yt(function*(z){b(DA,void 0),yield Yn(z)})).apply(this,arguments)}function CA(){b(w,!1),b(D,!1),Ye()}var kA=X(1e4,!0),KA=X([],!0),Ie=X(void 0,!0),GA=!1,oe=!1,M=X(!1,!0),G=X({},!0),Y=X(600,!0),AA=X(0,!0),dA=18;function WA(z){b(DA,z)}function Qe(z){g(DA)&&z!==void 0&&(Qs(z,SC(g(DA)))&&Qs(z,je(g(DA)))||(o("clearing selection: path does not exist anymore",g(DA)),b(DA,void 0)))}var yA=X(g(eA)!==void 0?I_({json:g(eA)}):void 0,!0),DA=X(F3(B())?B():void 0,!0),We=X(void 0,!0),be=X(!1,!0);function qA(z){if(!C()){o("onSortByHeader",z);var wA=z.sortDirection===ml.desc?-1:1;Ft(eaA(g(eA),[],z.path,wA),(ee,Me)=>({state:Me,sortedColumn:z}))}}ls(()=>{g(DA)&&Ho(je(g(DA)))});var It=X(void 0,!0);function Vi(z){if(z.json!==void 0||z.text!==void 0){var wA=g(eA)!==void 0&&z.json!==void 0;E().add({type:"tree",undo:{patch:wA?[{op:"replace",path:"",value:z.json}]:void 0,json:z.json,text:z.text,documentState:z.documentState,textIsRepaired:z.textIsRepaired,selection:Fg(z.selection),sortedColumn:z.sortedColumn},redo:{patch:wA?[{op:"replace",path:"",value:g(eA)}]:void 0,json:g(eA),text:g(RA),documentState:g(yA),textIsRepaired:g(be),selection:Fg(g(DA)),sortedColumn:g(We)}})}}var on=X([],!0),Hi=VB(WsA);function Ci(z,wA,ee,Me){OE(()=>{var ke;try{ke=Hi(z,wA,ee,Me)}catch(ze){ke=[{path:[],message:"Failed to validate: "+ze.message,severity:bl.warning}]}Ei(ke,g(on))||(o("validationErrors changed:",ke),b(on,ke))},ke=>o("validationErrors updated in ".concat(ke," ms")))}function Zi(){return o("validate"),g(oA)?{parseError:g(oA),isRepairable:!1}:(Ci(g(eA),U(),y(),T()),sn(g(on))?void 0:{validationErrors:g(on)})}function Qi(z,wA){if(o("patch",z,wA),g(eA)===void 0)throw new Error("Cannot apply patch: no JSON");var ee=g(eA),Me={json:void 0,text:g(RA),documentState:g(yA),selection:Fg(g(DA)),sortedColumn:g(We),textIsRepaired:g(be)},ke=_sA(g(eA),z),ze=DsA(g(eA),g(yA),z),Pe=BYA(g(We),z,g(KA)),qe=typeof wA=="function"?wA(ze.json,ze.documentState,g(DA)):void 0;return b(eA,qe?.json!==void 0?qe.json:ze.json),b(yA,qe?.state!==void 0?qe.state:ze.documentState),b(DA,qe?.selection!==void 0?qe.selection:g(DA)),b(We,qe?.sortedColumn!==void 0?qe.sortedColumn:Pe),b(RA,void 0),b(be,!1),b(ne,void 0),b(h,void 0),b(oA,void 0),E().add({type:"tree",undo:Be({patch:ke},Me),redo:{patch:z,json:void 0,text:void 0,documentState:g(yA),selection:Fg(g(DA)),sortedColumn:g(We),textIsRepaired:g(be)}}),{json:g(eA),previousJson:ee,undo:ke,redo:z}}function Ft(z,wA){o("handlePatch",z,wA);var ee={json:g(eA),text:g(RA)},Me=Qi(z,wA);return Tt(ee,Me),Me}function Tt(z,wA){if((z.json!==void 0||z?.text!==void 0)&&K()){if(g(RA)!==void 0){var ee={text:g(RA),json:void 0};K()(ee,z,{contentErrors:Zi(),patchResult:wA})}else if(g(eA)!==void 0){var Me={text:void 0,json:g(eA)};K()(Me,z,{contentErrors:Zi(),patchResult:wA})}}}function Ht(z){o("pasted json as text",z),b(ne,z)}function zi(z){o("pasted multiline text",{pastedText:z}),b(h,z)}function ui(z){var wA=parseInt(z[0],10),ee=[String(wA+1),...z.slice(1)];return Qs(g(eA),ee)?hi(ee):hi(z)}function Ye(){o("focus"),g(Ke)&&(g(Ke).focus(),g(Ke).select())}function Ai(z){b(AA,z.target.scrollTop)}function ei(){g(DA)||b(DA,function(){if(ao(g(eA))&&!sn(g(eA))&&!sn(g(KA)))return hi(["0",...g(KA)[0]])}())}function Oi(){if(g(be)&&g(eA)!==void 0){var z={json:g(eA),text:g(RA)},wA={json:g(eA),documentState:g(yA),selection:g(DA),sortedColumn:g(We),text:g(RA),textIsRepaired:g(be)};b(RA,void 0),b(be,!1),Qe(g(eA)),Vi(wA),Tt(z,void 0)}return{json:g(eA),text:g(RA)}}function Yn(z){var{scrollToWhenVisible:wA=!0}=arguments.length>1&&arguments[1]!==void 0?arguments[1]:{},ee=g(w)?p3:0,Me=QrA(z,g(KA),G,dA),ke=Me-g(AA)+ee+dA,ze=Sn(z);if(o("scrollTo",{path:z,top:Me,scrollTop:g(AA),elem:ze}),!g(TA))return Promise.resolve();var Pe=g(TA).getBoundingClientRect();if(ze&&!wA){var qe=ze.getBoundingClientRect();if(qe.bottom>Pe.top&&qe.top<Pe.bottom)return Promise.resolve()}var oi=-Math.max(ee+2*dA,Pe.height/4);return new Promise(ze?xi=>{a(ze,{container:g(TA),offset:oi,duration:300,callback:()=>{Dn(z),xi()}})}:xi=>{a(ke,{container:g(TA),offset:oi,duration:300,callback:()=>{go(),Dn(z),xi()}})})}function Dn(z){var wA=Sn(z);if(wA&&g(TA)){var ee=g(TA).getBoundingClientRect(),Me=wA.getBoundingClientRect();if(Me.right>ee.right){var ke=Me.right-ee.right;lc(TA,g(TA).scrollLeft+=ke)}if(Me.left<ee.left){var ze=ee.left-Me.left;lc(TA,g(TA).scrollLeft-=ze)}}}function Ho(z){(function(wA){if(g(TA)){var{rowIndex:ee}=Uc(wA,g(KA)),Me=QrA(wA,g(KA),G,dA),ke=Me+(G[ee]||dA),ze=dA,Pe=g(TA).getBoundingClientRect(),qe=g(AA),oi=g(AA)+Pe.height-ze;if(ke>oi){var xi=ke-oi;lc(TA,g(TA).scrollTop+=xi)}if(Me<qe){var Di=qe-Me;lc(TA,g(TA).scrollTop-=Di)}}})(z),Dn(z)}function Sn(z){var wA,ee,Me=g(KA).find(ze=>e2(z.slice(1),ze)),ke=Me?z.slice(0,1).concat(Me):z;return(wA=(ee=g(TA))===null||ee===void 0?void 0:ee.querySelector('td[data-path="'.concat(a_(ke),'"]')))!==null&&wA!==void 0?wA:void 0}function io(z){var wA,{anchor:ee,left:Me,top:ke,width:ze,height:Pe,offsetTop:qe,offsetLeft:oi,showTip:xi}=z,Di=function(rA){var{json:JA,documentState:Se,selection:pe,readOnly:me,onEditValue:ft,onEditRow:mt,onToggleEnforceString:ci,onCut:rn,onCopy:yi,onPaste:Rn,onRemove:bt,onDuplicateRow:Bo,onInsertBeforeRow:mn,onInsertAfterRow:Hn,onRemoveRow:ji}=rA,ht=JA!==void 0,Fi=!!pe,Qt=JA!==void 0&&pe?Fe(JA,je(pe)):void 0,At=ht&&(Ao(pe)||pr(pe)||dn(pe)),Ni=!me&&ht&&pe!==void 0&&ry(pe),Oo=Ni&&!zo(Qt),Dr=!me&&At,Eo=pe!==void 0&&Z0(JA,Se,je(pe));return[{type:"separator"},{type:"row",items:[{type:"column",items:[{type:"label",text:"Table cell:"},{type:"dropdown-button",main:{type:"button",onClick:()=>ft(),icon:ZI,text:"Edit",title:"Edit the value (Double-click on the value)",disabled:!Ni},width:"11em",items:[{type:"button",icon:ZI,text:"Edit",title:"Edit the value (Double-click on the value)",onClick:()=>ft(),disabled:!Ni},{type:"button",icon:Eo?xS:NS,text:"Enforce string",title:"Enforce keeping the value as string when it contains a numeric value",onClick:()=>ci(),disabled:!Oo}]},{type:"dropdown-button",main:{type:"button",onClick:()=>rn(!0),icon:VI,text:"Cut",title:"Cut selected contents, formatted with indentation (Ctrl+X)",disabled:!Dr},width:"10em",items:[{type:"button",icon:VI,text:"Cut formatted",title:"Cut selected contents, formatted with indentation (Ctrl+X)",onClick:()=>rn(!0),disabled:me||!At},{type:"button",icon:VI,text:"Cut compacted",title:"Cut selected contents, without indentation (Ctrl+Shift+X)",onClick:()=>rn(!1),disabled:me||!At}]},{type:"dropdown-button",main:{type:"button",onClick:()=>yi(!0),icon:S0,text:"Copy",title:"Copy selected contents, formatted with indentation (Ctrl+C)",disabled:!At},width:"12em",items:[{type:"button",icon:S0,text:"Copy formatted",title:"Copy selected contents, formatted with indentation (Ctrl+C)",onClick:()=>yi(!1),disabled:!At},{type:"button",icon:S0,text:"Copy compacted",title:"Copy selected contents, without indentation (Ctrl+Shift+C)",onClick:()=>yi(!1),disabled:!At}]},{type:"button",onClick:()=>Rn(),icon:LS,text:"Paste",title:"Paste clipboard contents (Ctrl+V)",disabled:me||!Fi},{type:"button",onClick:()=>bt(),icon:o5,text:"Remove",title:"Remove selected contents (Delete)",disabled:me||!At}]},{type:"column",items:[{type:"label",text:"Table row:"},{type:"button",onClick:()=>mt(),icon:ZI,text:"Edit row",title:"Edit the current row",disabled:me||!Fi||!ht},{type:"button",onClick:()=>Bo(),icon:US,text:"Duplicate row",title:"Duplicate the current row (Ctrl+D)",disabled:me||!Fi||!ht},{type:"button",onClick:()=>mn(),icon:WI,text:"Insert before",title:"Insert a row before the current row",disabled:me||!Fi||!ht},{type:"button",onClick:()=>Hn(),icon:WI,text:"Insert after",title:"Insert a row after the current row",disabled:me||!Fi||!ht},{type:"button",onClick:()=>ji(),icon:o5,text:"Remove row",title:"Remove current row",disabled:me||!Fi||!ht}]}]}]}({json:g(eA),documentState:g(yA),selection:g(DA),readOnly:C(),onEditValue:Jn,onEditRow:hn,onToggleEnforceString:wo,onCut:Jt,onCopy:Ct,onPaste:bA,onRemove:$e,onDuplicateRow:Wi,onInsertBeforeRow:Tn,onInsertAfterRow:ii,onRemoveRow:Ri}),cn=(wA=V()(Di))!==null&&wA!==void 0?wA:Di;if(cn!==!1){var qr={left:Me,top:ke,offsetTop:qe,offsetLeft:oi,width:ze,height:Pe,anchor:ee,closeOnOuterClick:!0,onClose:()=>{GA=!1,Ye()}};GA=!0;var J=r(gaA,{tip:xi?"Tip: you can open this context menu via right-click or with Ctrl+Q":void 0,items:cn,onRequestClose(){s(J),Ye()}},qr)}}function Wo(z){if(!Ma(g(DA)))if(z&&(z.stopPropagation(),z.preventDefault()),z&&z.type==="contextmenu"&&z.target!==g(Ke))io({left:z.clientX,top:z.clientY,width:O0,height:H0,showTip:!1});else{var wA,ee=(wA=g(TA))===null||wA===void 0?void 0:wA.querySelector(".jse-table-cell.jse-selected-value");if(ee)io({anchor:ee,offsetTop:2,width:O0,height:H0,showTip:!1});else{var Me,ke=(Me=g(TA))===null||Me===void 0?void 0:Me.getBoundingClientRect();ke&&io({top:ke.top+2,left:ke.left+2,width:O0,height:H0,showTip:!1})}}}function No(z){io({anchor:usA(z.target,"BUTTON"),offsetTop:0,width:O0,height:H0,showTip:!0})}function Jn(){if(!C()&&g(DA)){var z=je(g(DA));zo(Fe(g(eA),z))?ai(z):b(DA,hi(z))}}function hn(){!C()&&g(DA)&&ai(je(g(DA)).slice(0,1))}function wo(){if(!C()&&dn(g(DA))){var z=g(DA).path,wA=nt(z),ee=Fe(g(eA),z),Me=!Z0(g(eA),g(yA),z),ke=Me?String(ee):ah(String(ee),y());o("handleToggleEnforceString",{enforceString:Me,value:ee,updatedValue:ke}),Ft([{op:"replace",path:wA,value:ke}],(ze,Pe)=>({state:by(g(eA),Pe,z,{type:"value",enforceString:Me})}))}}function se(){return fi.apply(this,arguments)}function fi(){return(fi=yt(function*(){if(o("apply pasted json",g(ne)),g(ne)){var{onPasteAsJson:z}=g(ne);z(),setTimeout(Ye)}})).apply(this,arguments)}function bA(){return fe.apply(this,arguments)}function fe(){return(fe=yt(function*(){try{QA(yield navigator.clipboard.readText())}catch(z){console.error(z),b(M,!0)}})).apply(this,arguments)}function it(){return Gt.apply(this,arguments)}function Gt(){return(Gt=yt(function*(){o("apply pasted multiline text",g(h)),g(h)&&(QA(JSON.stringify(g(h))),setTimeout(Ye))})).apply(this,arguments)}function Xe(){o("clear pasted json"),b(ne,void 0),Ye()}function Ot(){o("clear pasted multiline text"),b(h,void 0),Ye()}function Pi(){H()(tr.text)}function Jt(z){return Ki.apply(this,arguments)}function Ki(){return(Ki=yt(function*(z){yield oaA({json:g(eA),selection:g(DA),indentation:z?N():void 0,readOnly:C(),parser:y(),onPatch:Ft})})).apply(this,arguments)}function Ct(){return ti.apply(this,arguments)}function ti(){return ti=yt(function*(){var z=!(arguments.length>0&&arguments[0]!==void 0)||arguments[0];g(eA)!==void 0&&(yield raA({json:g(eA),selection:g(DA),indentation:z?N():void 0,parser:y()}))}),ti.apply(this,arguments)}function $e(){aaA({json:g(eA),text:g(RA),selection:g(DA),keepSelection:!0,readOnly:C(),onChange:K(),onPatch:Ft})}function Nt(z){C()||(o("extract",{path:z}),Ft(xsA(g(eA),hi(z))))}function Wi(){(function(z){var{json:wA,selection:ee,columns:Me,readOnly:ke,onPatch:ze}=z;if(!ke&&wA!==void 0&&ee&&zE(ee)){var{rowIndex:Pe,columnIndex:qe}=Uc(je(ee),Me);vs("duplicate row",{rowIndex:Pe});var oi=[String(Pe)];ze(LsA(wA,[oi]),(xi,Di)=>({state:Di,selection:hi(yC({rowIndex:Pe<wA.length?Pe+1:Pe,columnIndex:qe},Me))}))}})({json:g(eA),selection:g(DA),columns:g(KA),readOnly:C(),onPatch:Ft})}function Tn(){(function(z){var{json:wA,selection:ee,columns:Me,readOnly:ke,onPatch:ze}=z;if(!ke&&wA!==void 0&&ee&&zE(ee)){var{rowIndex:Pe}=Uc(je(ee),Me);vs("insert before row",{rowIndex:Pe}),ze(HE(wA,[String(Pe)],[{key:"",value:Mo(wA[0])?{}:""}]))}})({json:g(eA),selection:g(DA),columns:g(KA),readOnly:C(),onPatch:Ft})}function ii(){(function(z){var{json:wA,selection:ee,columns:Me,readOnly:ke,onPatch:ze}=z;if(!ke&&wA!==void 0&&ee&&zE(ee)){var{rowIndex:Pe,columnIndex:qe}=Uc(je(ee),Me);vs("insert after row",{rowIndex:Pe});var oi=Pe+1,xi=[String(oi)],Di=[{key:"",value:Mo(wA[0])?{}:""}];ze(oi<wA.length?HE(wA,xi,Di):d_(wA,[],Di),(cn,qr)=>({state:qr,selection:hi(yC({rowIndex:oi,columnIndex:qe},Me))}))}})({json:g(eA),selection:g(DA),columns:g(KA),readOnly:C(),onPatch:Ft})}function Ri(){(function(z){var{json:wA,selection:ee,columns:Me,readOnly:ke,onPatch:ze}=z;if(!ke&&wA!==void 0&&ee&&zE(ee)){var{rowIndex:Pe,columnIndex:qe}=Uc(je(ee),Me);vs("remove row",{rowIndex:Pe}),ze(ay([[String(Pe)]]),(oi,xi)=>{var Di=Pe<oi.length?Pe:Pe>0?Pe-1:void 0,cn=Di!==void 0?hi(yC({rowIndex:Di,columnIndex:qe},Me)):void 0;return vs("remove row new selection",{rowIndex:Pe,newRowIndex:Di,newSelection:cn}),{state:xi,selection:cn}})}})({json:g(eA),selection:g(DA),columns:g(KA),readOnly:C(),onPatch:Ft})}function dt(){return(dt=yt(function*(z){yield caA({char:z,selectInside:!1,json:g(eA),selection:g(DA),readOnly:C(),parser:y(),onPatch:Ft,onReplaceJson:_A,onSelect:WA})})).apply(this,arguments)}function zn(z){var wA;z.preventDefault(),QA((wA=z.clipboardData)===null||wA===void 0?void 0:wA.getData("text/plain"))}function QA(z){z!==void 0&&saA({clipboardText:z,json:g(eA),selection:g(DA),readOnly:C(),parser:y(),onPatch:Ft,onChangeText:Ce,onPasteMultilineText:zi,openRepairModal:Fn})}function _A(z,wA){var ee={json:g(eA),text:g(RA)},Me={json:g(eA),documentState:g(yA),selection:g(DA),sortedColumn:g(We),text:g(RA),textIsRepaired:g(be)},ke=cc(z,g(yA)),ze=typeof wA=="function"?wA(z,ke,g(DA)):void 0;b(eA,ze?.json!==void 0?ze.json:z),b(yA,ze?.state!==void 0?ze.state:ke),b(DA,ze?.selection!==void 0?ze.selection:g(DA)),b(We,void 0),b(RA,void 0),b(be,!1),b(oA,void 0),Qe(g(eA)),Vi(Me),Tt(ee,void 0)}function Ce(z,wA){o("handleChangeText");var ee={json:g(eA),text:g(RA)},Me={json:g(eA),documentState:g(yA),selection:g(DA),sortedColumn:g(We),text:g(RA),textIsRepaired:g(be)};try{b(eA,F()(z)),b(yA,cc(g(eA),g(yA))),b(RA,void 0),b(be,!1),b(oA,void 0)}catch(ze){try{b(eA,F()(yc(z))),b(yA,cc(g(eA),g(yA))),b(RA,z),b(be,!0),b(oA,void 0)}catch{b(eA,void 0),b(yA,void 0),b(RA,z),b(be,!1),b(oA,g(RA)!==""?XE(g(RA),ze.message||String(ze)):void 0)}}if(typeof wA=="function"){var ke=wA(g(eA),g(yA),g(DA));b(eA,ke?.json!==void 0?ke.json:g(eA)),b(yA,ke?.state!==void 0?ke.state:g(yA)),b(DA,ke?.selection!==void 0?ke.selection:g(DA))}Qe(g(eA)),Vi(Me),Tt(ee,void 0)}function Pt(z){o("select validation error",z),b(DA,hi(z.path)),Yn(z.path)}function Li(z){if(g(eA)!==void 0){var{id:wA,onTransform:ee,onClose:Me}=z,ke=z.rootPath||[];GA=!0,VA()({id:wA||l,json:g(eA),rootPath:ke||[],onTransform:ze=>{ee?ee({operations:ze,json:g(eA),transformedJson:Ba(g(eA),ze)}):(o("onTransform",ke,ze),Ft(ze))},onClose:()=>{GA=!1,setTimeout(Ye),Me&&Me()}})}}function ai(z){o("openJSONEditorModal",{path:z}),GA=!0,ce()({content:{json:Fe(g(eA),z)},path:z,onPatch:Ft,onClose:()=>{GA=!1,setTimeout(Ye)}})}function Fn(z,wA){b(Re,{text:z,onParse:ee=>P3(ee,Me=>O3(Me,y())),onRepair:lsA,onApply:wA,onClose:Ye})}function Co(){(function(z){C()||g(eA)===void 0||(GA=!0,jA()({id:c,json:g(eA),rootPath:z,onSort:wA=>{var{operations:ee,itemPath:Me,direction:ke}=wA;o("onSort",ee,z,Me,ke),Ft(ee,(ze,Pe)=>({state:Pe,sortedColumn:{path:Me,sortDirection:ke===-1?ml.desc:ml.asc}}))},onClose:()=>{GA=!1,setTimeout(Ye)}}))})([])}function Qn(){Li({rootPath:[]})}function un(z){o("openFind",{findAndReplace:z}),b(w,!1),b(D,!1),go(),b(w,!0),b(D,z)}function jt(){if(!C()&&E().canUndo){var z=E().undo();if(oy(z)){var wA={json:g(eA),text:g(RA)};b(eA,z.undo.patch?Ba(g(eA),z.undo.patch):z.undo.json),b(yA,z.undo.documentState),b(DA,z.undo.selection),b(We,z.undo.sortedColumn),b(RA,z.undo.text),b(be,z.undo.textIsRepaired),b(oA,void 0),o("undo",{item:z,json:g(eA)}),Tt(wA,z.undo.patch&&z.redo.patch?{json:g(eA),previousJson:wA.json,redo:z.undo.patch,undo:z.redo.patch}:void 0),Ye(),g(DA)&&Yn(je(g(DA)),{scrollToWhenVisible:!1})}else IA()(z)}}function Nn(){if(!C()&&E().canRedo){var z=E().redo();if(oy(z)){var wA={json:g(eA),text:g(RA)};b(eA,z.redo.patch?Ba(g(eA),z.redo.patch):z.redo.json),b(yA,z.redo.documentState),b(DA,z.redo.selection),b(We,z.redo.sortedColumn),b(RA,z.redo.text),b(be,z.redo.textIsRepaired),b(oA,void 0),o("redo",{item:z,json:g(eA)}),Tt(wA,z.undo.patch&&z.redo.patch?{json:g(eA),previousJson:wA.json,redo:z.redo.patch,undo:z.undo.patch}:void 0),Ye(),g(DA)&&Yn(je(g(DA)),{scrollToWhenVisible:!1})}else lA()(z)}}function ut(z){b(Y,z.getBoundingClientRect().height)}fA(()=>(W(v()),W(L())),()=>{b(EA,K_({escapeControlCharacters:v(),escapeUnicodeCharacters:L()}))}),fA(()=>g(w),()=>{(function(z){if(g(TA)){var wA=z?p3:-100;g(TA).scrollTo({top:lc(TA,g(TA).scrollTop+=wA),left:g(TA).scrollLeft})}})(g(w))}),fA(()=>W(d()),()=>{(function(z){var wA={json:g(eA)},ee=M3(z)?z.text!==g(RA):!Ei(wA.json,z.json);if(o("update external content",{isChanged:ee}),ee){var Me={json:g(eA),documentState:g(yA),selection:g(DA),sortedColumn:g(We),text:g(RA),textIsRepaired:g(be)};if(M3(z))try{b(eA,F()(z.text)),b(yA,cc(g(eA),g(yA))),b(RA,z.text),b(be,!1),b(oA,void 0)}catch(ke){try{b(eA,F()(yc(z.text))),b(yA,cc(g(eA),g(yA))),b(RA,z.text),b(be,!0),b(oA,void 0)}catch{b(eA,void 0),b(yA,void 0),b(RA,z.text),b(be,!1),b(oA,g(RA)!==""?XE(g(RA),ke.message||String(ke)):void 0)}}else b(eA,z.json),b(yA,cc(g(eA),g(yA))),b(RA,void 0),b(be,!1),b(oA,void 0);Qe(g(eA)),b(We,void 0),Vi(Me)}})(d())}),fA(()=>W(B()),()=>{(function(z){Ei(g(DA),z)||(o("applyExternalSelection",{selection:g(DA),externalSelection:z}),F3(z)&&b(DA,z))})(B())}),fA(()=>(g(KA),g(eA),W(x()),g(kA)),()=>{b(KA,ao(g(eA))?function(z,wA){var ee=new Set(wA.map(nt)),Me=new Set(z.map(nt));for(var ke of ee)Me.has(ke)||ee.delete(ke);for(var ze of Me)ee.has(ze)||ee.add(ze);return[...ee].map(da)}(gYA(g(eA),x(),g(kA)),g(KA)):[])}),fA(()=>(g(eA),g(KA)),()=>{b(Ie,!(!g(eA)||sn(g(KA))))}),fA(()=>(g(eA),g(kA)),()=>{b(A,Array.isArray(g(eA))&&g(eA).length>g(kA))}),fA(()=>(g(AA),g(Y),g(eA),g(w),p3),()=>{b(i,IYA(g(AA),g(Y),g(eA),G,dA,g(w)?p3:0))}),fA(()=>g(eA),()=>{g(eA),g(TA)&&g(TA).scrollTo({top:g(TA).scrollTop,left:g(TA).scrollLeft})}),fA(()=>g(DA),()=>{var z;z=g(DA),Ei(z,B())||(o("onSelect",z),j()(z))}),fA(()=>(W(C()),W(Q()),W(y()),g(EA),g(eA),g(yA),W(uA())),()=>{b(It,{mode:tr.table,readOnly:C(),truncateTextSize:Q(),parser:y(),normalization:g(EA),getJson:()=>g(eA),getDocumentState:()=>g(yA),findElement:Sn,findNextInside:ui,focus:Ye,onPatch:(z,wA)=>Ft(function(ee,Me){return ee.flatMap(ke=>{if(Q8(ke)){var ze=da(ke.path);if(ze.length>0){for(var Pe=[ke],qe=pi(ze);qe.length>0&&!Qs(Me,qe);)Pe.unshift({op:"add",path:nt(qe),value:{}}),qe=pi(qe);return Pe}}return ke})}(z,g(eA)),wA),onSelect:WA,onFind:un,onPasteJson:Ht,onRenderValue:uA()})}),fA(()=>(g(eA),W(U()),W(y()),W(T())),()=>{Ci(g(eA),U(),y(),T())}),fA(()=>(g(on),g(KA)),()=>{b(n,CYA(g(on),g(KA)))}),nn(),Rt(!0);var Xo=yJA();re("mousedown",q0,function(z){!ch(z.target,wA=>wA===g(sA))&&Ma(g(DA))&&(o("click outside the editor, exit edit mode"),b(DA,Fg(g(DA))),oe&&g(Ke)&&(g(Ke).focus(),g(Ke).blur()),o("blur (outside editor)"),g(Ke)&&g(Ke).blur())});var Oe,ni=Bt(Xo),fn=$(ni),Yi=z=>{(function(wA,ee){st(ee,!1);var Me=k(ee,"containsValidArray",9),ke=k(ee,"readOnly",9),ze=k(ee,"showSearch",13,!1),Pe=k(ee,"history",9),qe=k(ee,"onSort",9),oi=k(ee,"onTransform",9),xi=k(ee,"onContextMenu",9),Di=k(ee,"onUndo",9),cn=k(ee,"onRedo",9),qr=k(ee,"onRenderMenu",9);function J(){ze(!ze())}var rA=X(void 0,!0),JA=X(void 0,!0);fA(()=>(W(ke()),W(qe()),W(Me()),W(oi()),W(xi()),W(Di()),W(Pe()),W(cn())),()=>{b(rA,ke()?[{type:"space"}]:[{type:"button",icon:Vu,title:"Sort",className:"jse-sort",onClick:qe(),disabled:ke()||!Me()},{type:"button",icon:Pu,title:"Transform contents (filter, sort, project)",className:"jse-transform",onClick:oi(),disabled:ke()||!Me()},{type:"button",icon:Zu,title:"Search (Ctrl+F)",className:"jse-search",onClick:J,disabled:!Me()},{type:"button",icon:_S,title:H_,className:"jse-contextmenu",onClick:xi()},{type:"separator"},{type:"button",icon:s5,title:"Undo (Ctrl+Z)",className:"jse-undo",onClick:Di(),disabled:!Pe().canUndo},{type:"button",icon:r5,title:"Redo (Ctrl+Shift+Z)",className:"jse-redo",onClick:cn(),disabled:!Pe().canRedo},{type:"space"}])}),fA(()=>(W(qr()),g(rA)),()=>{b(JA,qr()(g(rA))||g(rA))}),nn(),Rt(!0),Ly(wA,{get items(){return g(JA)}}),at()})(z,{get containsValidArray(){return g(Ie)},get readOnly(){return C()},get history(){return E()},onSort:Co,onTransform:Qn,onUndo:jt,onRedo:Nn,onContextMenu:No,get onRenderMenu(){return p()},get showSearch(){return g(w)},set showSearch(wA){b(w,wA)},$$legacy:!0})};MA(fn,z=>{u()&&z(Yi)});var ir=gA(fn,2),Xi=z=>{var wA=wJA(),ee=Bt(wA),Me=$(ee);Me.readOnly=!0,to(Me,qe=>b(Ke,qe),()=>g(Ke));var ke=gA(ee,2),ze=qe=>{var oi=mJA(),xi=Bt(oi);taA($(xi),{get json(){return g(eA)},get documentState(){return g(yA)},get parser(){return y()},get showSearch(){return g(w)},get showReplace(){return g(D)},get readOnly(){return C()},get columns(){return g(KA)},onSearch:O,onFocus:Z,onPatch:Ft,onClose:CA});var Di=gA(xi,2),cn=$(Di),qr=$(cn),J=$(qr),rA=$(J),JA=$(rA),Se=At=>{var Ni=po(),Oo=PA(()=>{var Po;return ON([],(Po=g(n))===null||Po===void 0?void 0:Po.root)}),Dr=Bt(Ni),Eo=Po=>{var Vr=CJA();VE($(Vr),{get validationError(){return g(Oo)},onExpand:Kc}),iA(Po,Vr)};MA(Dr,Po=>{g(Oo)&&Po(Eo)}),iA(At,Ni)};MA(JA,At=>{var Ni;sn((Ni=g(n))===null||Ni===void 0?void 0:Ni.root)||At(Se)});var pe=gA(rA);Fo(pe,1,()=>g(KA),Zo,(At,Ni)=>{var Oo=dJA();(function(Dr,Eo){st(Eo,!1);var Po=X(void 0,!0),Vr=X(void 0,!0),o2=X(void 0,!0),xa=k(Eo,"path",9),Oc=k(Eo,"sortedColumn",9),Gl=k(Eo,"readOnly",9),Pc=k(Eo,"onSort",9);fA(()=>(W(xa()),Dl),()=>{b(Po,sn(xa())?"values":Dl(xa()))}),fA(()=>(W(Oc()),W(xa())),()=>{var Go;b(Vr,Oc()&&Ei(xa(),(Go=Oc())===null||Go===void 0?void 0:Go.path)?Oc().sortDirection:void 0)}),fA(()=>(g(Vr),JoA),()=>{b(o2,g(Vr)?JoA[g(Vr)]:void 0)}),nn(),Rt(!0);var Ur,Ss=tJA(),Fa=$(Ss),jg=$(Fa),Na=gA(Fa,2),Do=Go=>{var jo=eJA(),qg=$(jo),vh=PA(()=>g(Vr)===ml.asc?k0:yW);Si(qg,{get data(){return g(vh)}}),Ee(()=>en(jo,"title","Currently sorted in ".concat(g(o2)," order"))),iA(Go,jo)};MA(Na,Go=>{g(Vr)!==void 0&&Go(Do)}),Ee((Go,jo)=>{Ur=xt(Ss,1,"jse-column-header svelte-2i3vdx",null,Ur,Go),en(Ss,"title",Gl()?g(Po):g(Po)+" (Click to sort the data by this column)"),Et(jg,jo)},[()=>({"jse-readonly":Gl()}),()=>S3(g(Po),50)],PA),re("click",Ss,function(){Gl()||Pc()({path:xa(),sortDirection:g(Vr)===ml.asc?ml.desc:ml.asc})}),iA(Dr,Ss),at()})($(Oo),{get path(){return g(Ni)},get sortedColumn(){return g(We)},get readOnly(){return C()},onSort:qA}),iA(At,Oo)});var me=gA(pe),ft=At=>{var Ni=BJA(),Oo=$(Ni),Dr=PA(()=>Array.isArray(g(eA))?g(eA).length:0);(function(Eo,Po){st(Po,!1);var Vr=k(Po,"count",9),o2=k(Po,"maxSampleCount",9),xa=k(Po,"readOnly",9),Oc=k(Po,"onRefresh",9);Rt(!0);var Gl,Pc=IJA();Si($(Pc),{data:xW}),Ee(Ur=>{Gl=xt(Pc,1,"jse-column-header svelte-fzj761",null,Gl,Ur),en(Pc,"title","The Columns are created by sampling ".concat(o2()," items out of ").concat(Vr(),". ")+"If you're missing a column, click here to sample all of the items instead of a subset. This is slower.")},[()=>({"jse-readonly":xa()})],PA),re("click",Pc,()=>Oc()()),iA(Eo,Pc),at()})(Oo,{get count(){return g(Dr)},get maxSampleCount(){return g(kA)},get readOnly(){return C()},onRefresh:()=>b(kA,1/0)}),iA(At,Ni)};MA(me,At=>{g(A)&&At(ft)});var mt,ci,rn=gA(J),yi=$(rn),Rn=gA(rn);Fo(Rn,1,()=>g(i).visibleItems,Zo,(At,Ni,Oo)=>{var Dr=fJA(),Eo=PA(()=>g(i).startIndex+Oo),Po=PA(()=>g(n).rows[g(Eo)]),Vr=PA(()=>{var Ur;return ON([String(g(Eo))],(Ur=g(Po))===null||Ur===void 0?void 0:Ur.row)}),o2=PA(()=>kC(g(eA),g(f),[String(g(Eo))])),xa=$(Dr);$rA(xa,()=>g(Eo),Ur=>{var Ss=EJA(),Fa=$(Ss),jg=gA(Fa),Na=Do=>{VE(Do,{get validationError(){return g(Vr)},onExpand:Kc})};MA(jg,Do=>{g(Vr)&&Do(Na)}),bs(Ss,(Do,Go)=>OD?.(Do,Go),()=>Do=>function(Go,jo){G[jo]=Go.getBoundingClientRect().height}(Do,g(Eo))),Ee(()=>{var Do;return Et(Fa,"".concat((Do=g(Eo))!==null&&Do!==void 0?Do:""," "))}),iA(Ur,Ss)});var Oc=gA(xa);Fo(Oc,1,()=>g(KA),Zo,(Ur,Ss,Fa,jg)=>{var Na,Do=QJA(),Go=PA(()=>[String(g(Eo))].concat(g(Ss))),jo=PA(()=>Fe(g(Ni),g(Ss))),qg=PA(()=>dn(g(DA))&&e2(g(DA).path,g(Go))),vh=PA(()=>{var $o;return($o=g(Po))===null||$o===void 0?void 0:$o.columns[Fa]}),ed=PA(()=>ON(g(Go),g(vh))),bh=$(Do),td=$(bh),Mh=$o=>{var dc=PA(()=>E_(kC(g(Ni),g(o2),g(Ss)))),kh=PA(()=>!!g(dc)&&g(dc).some(Z1=>Z1.active)),Sh=PA(()=>!sn(g(dc)));(function(Z1,Zr){st(Zr,!1);var Rh=k(Zr,"path",9),tgA=k(Zr,"value",9),igA=k(Zr,"parser",9),ngA=k(Zr,"isSelected",9),ogA=k(Zr,"containsSearchResult",9),rgA=k(Zr,"containsActiveSearchResult",9),sgA=k(Zr,"onEdit",9);Rt(!0);var SU,kf=AJA(),agA=$(kf);Ee((Lh,cgA)=>{SU=xt(kf,1,"jse-inline-value svelte-h57m0p",null,SU,Lh),Et(agA,cgA)},[()=>({"jse-selected":ngA(),"jse-highlight":ogA(),"jse-active":rgA()}),()=>{var Lh;return S3((Lh=igA().stringify(tgA()))!==null&&Lh!==void 0?Lh:"",50)}],PA),re("dblclick",kf,()=>sgA()(Rh())),iA(Z1,kf),at()})($o,{get path(){return g(Go)},get value(){return g(jo)},get parser(){return y()},get isSelected(){return g(qg)},get containsSearchResult(){return g(Sh)},get containsActiveSearchResult(){return g(kh)},onEdit:ai})},p7=$o=>{var dc=PA(()=>{var Zr;return(Zr=kC(g(eA),g(f),g(Go)))===null||Zr===void 0?void 0:Zr.searchResults}),kh=PA(()=>g(jo)!==void 0?g(jo):""),Sh=PA(()=>Z0(g(eA),g(yA),g(Go))),Z1=PA(()=>g(qg)?g(DA):void 0);AaA($o,{get path(){return g(Go)},get value(){return g(kh)},get enforceString(){return g(Sh)},get selection(){return g(Z1)},get searchResultItems(){return g(dc)},get context(){return g(It)}})};MA(td,$o=>{zo(g(jo))?$o(Mh):$o(p7,!1)});var w7=gA(td),D7=$o=>{var dc=hJA();R1($(dc),{selected:!0,onContextMenu:io}),iA($o,dc)};MA(w7,$o=>{C()||!g(qg)||Ma(g(DA))||$o(D7)});var Ul=gA(bh,2),V1=$o=>{VE($o,{get validationError(){return g(ed)},onExpand:Kc})};MA(Ul,$o=>{g(ed)&&$o(V1)}),Ee(($o,dc)=>{en(Do,"data-path",$o),Na=xt(bh,1,"jse-value-outer svelte-u14cgx",null,Na,dc)},[()=>a_(g(Go)),()=>({"jse-selected-value":g(qg)})],PA),iA(Ur,Do)});var Gl=gA(Oc),Pc=Ur=>{iA(Ur,uJA())};MA(Gl,Ur=>{g(A)&&Ur(Pc)}),iA(At,Dr)});var bt,Bo=$(gA(Rn));to(Di,At=>b(TA,At),()=>g(TA)),bs(Di,(At,Ni)=>OD?.(At,Ni),()=>ut),Nr(()=>re("scroll",Di,Ai));var mn=gA(Di,2),Hn=At=>{var Ni=PA(()=>"You pasted a JSON ".concat(Array.isArray(g(ne).contents)?"array":"object"," as text"));Cc(At,{type:"info",get message(){return g(Ni)},actions:[{icon:M0,text:"Paste as JSON instead",title:"Paste the text as JSON instead of a single value",onMouseDown:se},{text:"Leave as is",title:"Keep the pasted content as a single value",onClick:Xe}]})};MA(mn,At=>{g(ne)&&At(Hn)});var ji=gA(mn,2),ht=At=>{Cc(At,{type:"info",message:"Multiline text was pasted as array",actions:[{icon:M0,text:"Paste as string instead",title:"Paste the clipboard data as a single string value instead of an array",onClick:it},{text:"Leave as is",title:"Keep the pasted array",onClick:Ot}]})};MA(ji,At=>{g(h)&&At(ht)});var Fi=gA(ji,2),Qt=At=>{var Ni=PA(()=>C()?[]:[{icon:a5,text:"Ok",title:"Accept the repaired document",onClick:Oi},{icon:ju,text:"Repair manually instead",title:"Leave the document unchanged and repair it manually instead",onClick:Pi}]);Cc(At,{type:"success",message:"The loaded JSON document was invalid but is successfully repaired.",get actions(){return g(Ni)},onClose:Ye})};MA(Fi,At=>{g(be)&&At(Qt)}),nG(gA(Fi,2),{get validationErrors(){return g(on)},selectError:Pt}),Ee(At=>{mt=xt(rn,1,"jse-table-invisible-start-section svelte-u14cgx",null,mt,At),en(yi,"colspan",g(KA).length),ci=vl(yi,"",ci,{height:g(i).startHeight+"px"}),en(Bo,"colspan",g(KA).length),bt=vl(Bo,"",bt,{height:g(i).endHeight+"px"})},[()=>({"jse-search-box-background":g(w)})],PA),iA(qe,oi)},Pe=(qe,oi)=>{var xi=cn=>{var qr=pJA(),J=Bt(qr),rA=PA(()=>C()?[]:[{icon:ju,text:"Repair manually",title:'Open the document in "code" mode and repair it manually',onClick:Pi}]);Cc(J,{type:"error",message:"The loaded JSON document is invalid and could not be repaired automatically.",get actions(){return g(rA)}}),laA(gA(J,2),{get text(){return g(RA)},get json(){return g(eA)},get indentation(){return N()},get parser(){return y()}}),iA(cn,qr)},Di=cn=>{gJA(cn,{get text(){return g(RA)},get json(){return g(eA)},get readOnly(){return C()},get parser(){return y()},openJSONEditorModal:ai,extractPath:Nt,get onChangeMode(){return H()},onClick:()=>{Ye()}})};MA(qe,cn=>{g(oA)&&g(RA)!==void 0&&g(RA)!==""?cn(xi):cn(Di,!1)},oi)};MA(ke,qe=>{g(Ie)?qe(ze):qe(Pe,!1)}),re("paste",Me,zn),iA(z,wA)},ks=z=>{iA(z,DJA())};MA(ir,z=>{I?z(ks,!1):z(Xi)}),to(ni,z=>b(sA,z),()=>g(sA));var La=gA(ni,2),_o=z=>{XsA(z,{onClose:()=>b(M,!1)})};MA(La,z=>{g(M)&&z(_o)});var yn=gA(La,2),Gr=z=>{$sA(z,U1(()=>g(Re),{onClose:()=>{var wA;(wA=g(Re))===null||wA===void 0||wA.onClose(),b(Re,void 0)}}))};return MA(yn,z=>{g(Re)&&z(Gr)}),Ee(z=>Oe=xt(ni,1,"jse-table-mode svelte-u14cgx",null,Oe,z),[()=>({"no-main-menu":!u()})],PA),re("mousedown",ni,function(z){if(z.buttons===1||z.buttons===2){var wA=z.target;wA.isContentEditable||Ye();var ee=fsA(wA);if(ee){if(Ma(g(DA))&&N3(g(eA),g(DA),ee))return;b(DA,hi(ee)),z.preventDefault()}}}),re("keydown",ni,function(z){var wA=A2(z);if(o("keydown",{combo:wA,key:z.key}),wA==="Ctrl+X"&&(z.preventDefault(),Jt(!0)),wA==="Ctrl+Shift+X"&&(z.preventDefault(),Jt(!1)),wA==="Ctrl+C"&&(z.preventDefault(),Ct(!0)),wA==="Ctrl+Shift+C"&&(z.preventDefault(),Ct(!1)),wA==="Ctrl+D"&&(z.preventDefault(),Wi()),wA!=="Delete"&&wA!=="Backspace"||(z.preventDefault(),$e()),wA==="Insert"&&z.preventDefault(),wA==="Ctrl+A"&&z.preventDefault(),wA==="Ctrl+Q"&&Wo(z),wA==="ArrowLeft"&&(z.preventDefault(),ei(),g(DA))){var ee=function(oi,xi){var{rowIndex:Di,columnIndex:cn}=Uc(je(xi),oi);return cn>0?hi(yC({rowIndex:Di,columnIndex:cn-1},oi)):xi}(g(KA),g(DA));b(DA,ee),Ho(je(ee))}if(wA==="ArrowRight"&&(z.preventDefault(),ei(),g(DA))){var Me=function(oi,xi){var{rowIndex:Di,columnIndex:cn}=Uc(je(xi),oi);return cn<oi.length-1?hi(yC({rowIndex:Di,columnIndex:cn+1},oi)):xi}(g(KA),g(DA));b(DA,Me),Ho(je(Me))}if(wA==="ArrowUp"&&(z.preventDefault(),ei(),g(DA))){var ke=function(oi,xi){var{rowIndex:Di,columnIndex:cn}=Uc(je(xi),oi);return Di>0?hi(yC({rowIndex:Di-1,columnIndex:cn},oi)):xi}(g(KA),g(DA));b(DA,ke),Ho(je(ke))}if(wA==="ArrowDown"&&(z.preventDefault(),ei(),g(DA))){var ze=function(oi,xi,Di){var{rowIndex:cn,columnIndex:qr}=Uc(je(Di),xi);return cn<oi.length-1?hi(yC({rowIndex:cn+1,columnIndex:qr},xi)):Di}(g(eA),g(KA),g(DA));b(DA,ze),Ho(je(ze))}if(wA==="Enter"&&g(DA)&&dn(g(DA))){z.preventDefault();var Pe=g(DA).path;zo(Fe(g(eA),Pe))?ai(Pe):C()||b(DA,Be(Be({},g(DA)),{},{edit:!0}))}if(wA.replace(/^Shift\+/,"").length===1&&g(DA))return z.preventDefault(),void function(oi){dt.apply(this,arguments)}(z.key);if(wA==="Ctrl+Enter"&&dn(g(DA))){z.preventDefault();var qe=Fe(g(eA),g(DA).path);yy(qe)&&window.open(String(qe),"_blank")}wA==="Escape"&&g(DA)&&(z.preventDefault(),b(DA,void 0)),wA==="Ctrl+F"&&(z.preventDefault(),un(!1)),wA==="Ctrl+H"&&(z.preventDefault(),un(!0)),wA==="Ctrl+Z"&&(z.preventDefault(),jt()),wA==="Ctrl+Shift+Z"&&(z.preventDefault(),Nn())}),re("contextmenu",ni,Wo),iA(t,Xo),kt(e,"validate",Zi),kt(e,"patch",Qi),kt(e,"focus",Ye),kt(e,"acceptAutoRepair",Oi),kt(e,"scrollTo",Yn),kt(e,"findElement",Sn),kt(e,"openTransformModal",Li),at({validate:Zi,patch:Qi,focus:Ye,acceptAutoRepair:Oi,scrollTo:Yn,findElement:Sn,openTransformModal:Li})}function urA(t,e){st(e,!1);var A=k(e,"content",8),i=k(e,"selection",12),n=k(e,"readOnly",8),o=k(e,"indentation",8),r=k(e,"tabSize",8),s=k(e,"truncateTextSize",8),a=k(e,"externalMode",8),c=k(e,"mainMenuBar",8),l=k(e,"navigationBar",8),I=k(e,"statusBar",8),C=k(e,"askToFormat",8),d=k(e,"escapeControlCharacters",8),B=k(e,"escapeUnicodeCharacters",8),E=k(e,"flattenColumns",8),Q=k(e,"parser",8),u=k(e,"parseMemoizeOne",8),v=k(e,"validator",8),L=k(e,"validationParser",8),x=k(e,"pathParser",8),y=k(e,"insideModal",8),F=k(e,"onChange",8),U=k(e,"onChangeMode",8),T=k(e,"onSelect",8),N=k(e,"onRenderValue",8),K=k(e,"onClassName",8),H=k(e,"onRenderMenu",8),j=k(e,"onRenderContextMenu",8),IA=k(e,"onError",8),lA=k(e,"onFocus",8),uA=k(e,"onBlur",8),p=k(e,"onSortModal",8),V=k(e,"onTransformModal",8),cA=k(e,"onJSONEditorModal",8),aA=X(),jA=X(),VA=X(),ce=wr("jsoneditor:JSONEditorRoot"),EA=X(CaA({onChange:M=>b(EA,M)}).get()),sA=X(a());function TA(M){if(OoA(M)){b(sA,M.undo.mode);var G=g(EA).items(),Y=G.findIndex(dA=>dA===M),AA=Y!==-1?G[Y-1]:void 0;ce("handleUndo",{index:Y,item:M,items:G,prevItem:AA}),AA&&i(AA.redo.selection),U()(g(sA))}}function Ke(M){if(OoA(M)){b(sA,M.redo.mode);var G=g(EA).items(),Y=G.findIndex(dA=>dA===M),AA=Y!==-1?G[Y+1]:void 0;ce("handleRedo",{index:Y,item:M,items:G,nextItem:AA}),AA&&i(AA.undo.selection),U()(g(sA))}}var Re=X(),hA={type:"separator"},eA=X(),RA=X();function oA(M){if(g(aA))return g(aA).patch(M);if(g(jA))return g(jA).patch(M);if(g(VA))return g(VA).patch(M);throw new Error('Method patch is not available in mode "'.concat(g(sA),'"'))}function ne(M,G){if(g(aA))return g(aA).expand(M,G);throw new Error('Method expand is not available in mode "'.concat(g(sA),'"'))}function h(M,G){if(g(aA))return g(aA).collapse(M,G);throw new Error('Method collapse is not available in mode "'.concat(g(sA),'"'))}function f(M){if(g(VA))g(VA).openTransformModal(M);else if(g(aA))g(aA).openTransformModal(M);else{if(!g(jA))throw new Error('Method transform is not available in mode "'.concat(g(sA),'"'));g(jA).openTransformModal(M)}}function w(){if(g(VA))return g(VA).validate();if(g(aA))return g(aA).validate();if(g(jA))return g(jA).validate();throw new Error('Method validate is not available in mode "'.concat(g(sA),'"'))}function D(){return g(aA)?g(aA).acceptAutoRepair():A()}function O(M){if(g(aA))return g(aA).scrollTo(M);if(g(jA))return g(jA).scrollTo(M);throw new Error('Method scrollTo is not available in mode "'.concat(g(sA),'"'))}function Z(M){if(g(aA))return g(aA).findElement(M);if(g(jA))return g(jA).findElement(M);throw new Error('Method findElement is not available in mode "'.concat(g(sA),'"'))}function q(){g(VA)?g(VA).focus():g(aA)?g(aA).focus():g(jA)&&g(jA).focus()}function CA(){return kA.apply(this,arguments)}function kA(){return(kA=yt(function*(){g(VA)&&(yield g(VA).refresh())})).apply(this,arguments)}fA(()=>W(a()),()=>{(function(M){if(M!==g(sA)){var G={type:"mode",undo:{mode:g(sA),selection:void 0},redo:{mode:M,selection:void 0}};g(sA)==="text"&&g(VA)&&g(VA).flush(),ce("add history item",G),g(EA).add(G),b(sA,M)}})(a())}),fA(()=>(g(sA),W(U())),()=>{b(Re,[{type:"button",text:"text",title:"Switch to text mode (current mode: ".concat(g(sA),")"),className:"jse-group-button jse-first"+(g(sA)===tr.text?" jse-selected":""),onClick:()=>U()(tr.text)},{type:"button",text:"tree",title:"Switch to tree mode (current mode: ".concat(g(sA),")"),className:"jse-group-button "+(g(sA)===tr.tree?" jse-selected":""),onClick:()=>U()(tr.tree)},{type:"button",text:"table",title:"Switch to table mode (current mode: ".concat(g(sA),")"),className:"jse-group-button jse-last"+(g(sA)===tr.table?" jse-selected":""),onClick:()=>U()(tr.table)}])}),fA(()=>(g(Re),W(H()),g(sA),W(y()),W(n())),()=>{b(eA,M=>{var G=psA(M[0])?g(Re).concat(M):g(Re).concat(hA,M),Y=Tu(G);return H()(G,{mode:g(sA),modal:y(),readOnly:n()})||Y})}),fA(()=>(W(j()),g(sA),W(y()),W(n()),W(i())),()=>{b(RA,M=>{var G,Y=Tu(M);return(G=j()(M,{mode:g(sA),modal:y(),readOnly:n(),selection:i()}))!==null&&G!==void 0?G:!n()&&Y})}),nn(),Rt();var KA=po(),Ie=Bt(KA),GA=M=>{to($YA(M,{get externalContent(){return A()},get externalSelection(){return i()},get history(){return g(EA)},get readOnly(){return n()},get indentation(){return o()},get tabSize(){return r()},get mainMenuBar(){return c()},get statusBar(){return I()},get askToFormat(){return C()},get escapeUnicodeCharacters(){return B()},get parser(){return Q()},get validator(){return v()},get validationParser(){return L()},get onChange(){return F()},get onChangeMode(){return U()},get onSelect(){return T()},onUndo:TA,onRedo:Ke,get onError(){return IA()},get onFocus(){return lA()},get onBlur(){return uA()},get onRenderMenu(){return g(eA)},get onSortModal(){return p()},get onTransformModal(){return V()},$$legacy:!0}),G=>b(VA,G),()=>g(VA))},oe=(M,G)=>{var Y=dA=>{to(vJA(dA,{get externalContent(){return A()},get externalSelection(){return i()},get history(){return g(EA)},get readOnly(){return n()},get truncateTextSize(){return s()},get mainMenuBar(){return c()},get escapeControlCharacters(){return d()},get escapeUnicodeCharacters(){return B()},get flattenColumns(){return E()},get parser(){return Q()},get parseMemoizeOne(){return u()},get validator(){return v()},get validationParser(){return L()},get indentation(){return o()},get onChange(){return F()},get onChangeMode(){return U()},get onSelect(){return T()},onUndo:TA,onRedo:Ke,get onRenderValue(){return N()},get onFocus(){return lA()},get onBlur(){return uA()},get onRenderMenu(){return g(eA)},get onRenderContextMenu(){return g(RA)},get onSortModal(){return p()},get onTransformModal(){return V()},get onJSONEditorModal(){return cA()},$$legacy:!0}),WA=>b(jA,WA),()=>g(jA))},AA=dA=>{to(M_(dA,{get externalContent(){return A()},get externalSelection(){return i()},get history(){return g(EA)},get readOnly(){return n()},get indentation(){return o()},get truncateTextSize(){return s()},get mainMenuBar(){return c()},get navigationBar(){return l()},get escapeControlCharacters(){return d()},get escapeUnicodeCharacters(){return B()},get parser(){return Q()},get parseMemoizeOne(){return u()},get validator(){return v()},get validationParser(){return L()},get pathParser(){return x()},get onError(){return IA()},get onChange(){return F()},get onChangeMode(){return U()},get onSelect(){return T()},onUndo:TA,onRedo:Ke,get onRenderValue(){return N()},get onClassName(){return K()},get onFocus(){return lA()},get onBlur(){return uA()},get onRenderMenu(){return g(eA)},get onRenderContextMenu(){return g(RA)},get onSortModal(){return p()},get onTransformModal(){return V()},get onJSONEditorModal(){return cA()},$$legacy:!0}),WA=>b(aA,WA),()=>g(aA))};MA(M,dA=>{g(sA)===tr.table?dA(Y):dA(AA,!1)},G)};return MA(Ie,M=>{g(sA)===tr.text||String(g(sA))==="code"?M(GA):M(oe,!1)}),iA(t,KA),kt(e,"patch",oA),kt(e,"expand",ne),kt(e,"collapse",h),kt(e,"transform",f),kt(e,"validate",w),kt(e,"acceptAutoRepair",D),kt(e,"scrollTo",O),kt(e,"findElement",Z),kt(e,"focus",q),kt(e,"refresh",CA),at({patch:oA,expand:ne,collapse:h,transform:f,validate:w,acceptAutoRepair:D,scrollTo:O,findElement:Z,focus:q,refresh:CA})}vt(`/* over all fonts, sizes, and colors */
/* "consolas" for Windows, "menlo" for Mac with fallback to "monaco", 'Ubuntu Mono' for Ubuntu */
/* (at Mac this font looks too large at 14px, but 13px is too small for the font on Windows) */
/* main, menu, modal */
/* jsoneditor modal */
/* tooltip in text mode */
/* panels: navigation bar, gutter, search box */
/* navigation-bar */
/* context menu */
/* contents: json key and values */
/* contents: selected or hovered */
/* contents: section of collapsed items in an array */
/* contents: highlighting of search matches */
/* contents: inline tags inside the JSON document */
/* contents: table */
/* controls in modals: inputs, buttons, and \`a\` */
/* messages */
/* svelte-select */
/* color picker */
.jse-modal-wrapper.svelte-v0el4e {
  flex: 1;
  display: flex;
  min-width: 0;
  min-height: 0;
  flex-direction: column;
}
.jse-modal-wrapper.svelte-v0el4e .jse-modal-contents:where(.svelte-v0el4e) {
  flex: 1;
  display: flex;
  flex-direction: column;
  padding: 20px;
  overflow: auto;
  min-width: 0;
  min-height: 0;
}
.jse-modal-wrapper.svelte-v0el4e .jse-modal-contents:where(.svelte-v0el4e) .jse-actions:where(.svelte-v0el4e) {
  display: flex;
  flex-direction: row;
  justify-content: flex-end;
  padding-top: var(--jse-padding, 10px);
}
.jse-modal-wrapper.svelte-v0el4e .jse-modal-contents:where(.svelte-v0el4e) .jse-actions:where(.svelte-v0el4e) button.jse-primary:where(.svelte-v0el4e) {
  border: none;
  background: transparent;
  color: inherit;
  cursor: pointer;
  font-family: var(--jse-font-family, -apple-system, BlinkMacSystemFont, "Segoe UI", Roboto, Oxygen-Sans, Ubuntu, Cantarell, "Helvetica Neue", sans-serif);
  font-size: var(--jse-font-size, 16px);
  padding: 5px;
  margin: 0;
  background: var(--jse-button-primary-background, var(--jse-theme-color, #3883fa));
  color: var(--jse-button-primary-color, #fff);
  padding: var(--jse-padding, 10px) calc(2 * var(--jse-padding, 10px));
  border-radius: 3px;
}
.jse-modal-wrapper.svelte-v0el4e .jse-modal-contents:where(.svelte-v0el4e) .jse-actions:where(.svelte-v0el4e) button.jse-primary:where(.svelte-v0el4e):hover {
  background: var(--jse-button-primary-background-highlight, var(--jse-theme-color-highlight, #5f9dff));
}
.jse-modal-wrapper.svelte-v0el4e .jse-modal-contents:where(.svelte-v0el4e) .jse-actions:where(.svelte-v0el4e) button.jse-primary:where(.svelte-v0el4e):disabled {
  background: var(--jse-button-primary-background-disabled, #9d9d9d);
}
.jse-modal-wrapper.svelte-v0el4e .jse-modal-contents:where(.svelte-v0el4e) .jse-label:where(.svelte-v0el4e) {
  font-weight: bold;
  display: block;
  box-sizing: border-box;
}
.jse-modal-wrapper.svelte-v0el4e .jse-modal-contents:where(.svelte-v0el4e) .jse-label:where(.svelte-v0el4e) .jse-label-inner:where(.svelte-v0el4e) {
  margin-top: calc(2 * var(--jse-padding, 10px));
  margin-bottom: calc(0.5 * var(--jse-padding, 10px));
  box-sizing: border-box;
}
.jse-modal-wrapper.svelte-v0el4e .jse-modal-contents:where(.svelte-v0el4e) .jse-modal-inline-editor:where(.svelte-v0el4e) {
  flex: 1;
  min-height: 150px;
  min-width: 0;
  max-width: 100%;
  display: flex;
  --jse-theme-color: var(--jse-modal-editor-theme-color, #707070);
  --jse-theme-color-highlight: var(--jse-modal-editor-theme-color-highlight, #646464);
}
.jse-modal-wrapper.svelte-v0el4e .jse-actions:where(.svelte-v0el4e) {
  gap: var(--jse-padding, 10px);
  align-items: center;
}
.jse-modal-wrapper.svelte-v0el4e .jse-actions:where(.svelte-v0el4e) .jse-error:where(.svelte-v0el4e) {
  flex: 1;
  color: var(--jse-error-color, #ee5341);
}
.jse-modal-wrapper.svelte-v0el4e .jse-actions:where(.svelte-v0el4e) button.jse-secondary:where(.svelte-v0el4e) {
  border: none;
  background: transparent;
  color: inherit;
  cursor: pointer;
  font-family: var(--jse-font-family, -apple-system, BlinkMacSystemFont, "Segoe UI", Roboto, Oxygen-Sans, Ubuntu, Cantarell, "Helvetica Neue", sans-serif);
  font-size: var(--jse-font-size, 16px);
  padding: 5px;
  margin: 0;
  background: var(--jse-button-secondary-background, #d3d3d3);
  color: var(--jse-button-secondary-color, var(--jse-text-color, #4d4d4d));
  padding: var(--jse-padding, 10px) calc(2 * var(--jse-padding, 10px));
  border-radius: 3px;
}
.jse-modal-wrapper.svelte-v0el4e .jse-actions:where(.svelte-v0el4e) button.jse-secondary:where(.svelte-v0el4e):hover {
  background: var(--jse-button-secondary-background-highlight, #e1e1e1);
}
.jse-modal-wrapper.svelte-v0el4e .jse-actions:where(.svelte-v0el4e) button.jse-secondary:where(.svelte-v0el4e):disabled {
  background: var(--jse-button-secondary-background-disabled, #9d9d9d);
}
.jse-modal-wrapper.svelte-v0el4e input:where(.svelte-v0el4e) {
  border: var(--jse-input-border, 1px solid #d8dbdf);
  outline: none;
  box-sizing: border-box;
  padding: calc(0.5 * var(--jse-padding, 10px));
  font-family: var(--jse-font-family-mono, consolas, menlo, monaco, "Ubuntu Mono", "source-code-pro", monospace);
  font-size: var(--jse-font-size-mono, 14px);
  color: inherit;
  background: var(--jse-input-background, var(--jse-background-color, #fff));
}
.jse-modal-wrapper.svelte-v0el4e input:where(.svelte-v0el4e):focus {
  border: var(--jse-input-border-focus, 1px solid var(--jse-input-border-focus, var(--jse-theme-color, #3883fa)));
}
.jse-modal-wrapper.svelte-v0el4e input:where(.svelte-v0el4e):read-only {
  background: var(--jse-input-background-readonly, transparent);
}`);var bJA=pA('<div class="jse-error svelte-v0el4e"> </div>'),MJA=pA('<button type="button" class="jse-secondary svelte-v0el4e"><!> Back</button>'),kJA=pA('<button type="button" class="jse-primary svelte-v0el4e">Apply</button>'),SJA=pA('<button type="button" class="jse-primary svelte-v0el4e">Close</button>'),RJA=pA('<!> <div class="jse-modal-contents svelte-v0el4e"><div class="jse-label svelte-v0el4e"><div class="jse-label-inner svelte-v0el4e">Path</div></div> <input class="jse-path svelte-v0el4e" type="text" readonly="" title="Selected path"/> <div class="jse-label svelte-v0el4e"><div class="jse-label-inner svelte-v0el4e">Contents</div></div> <div class="jse-modal-inline-editor svelte-v0el4e"><!></div> <div class="jse-actions svelte-v0el4e"><!> <!> <!></div></div>',1),LJA=pA('<div class="jse-modal-wrapper svelte-v0el4e"><!></div>'),xJA={};vt(`/* over all fonts, sizes, and colors */
/* "consolas" for Windows, "menlo" for Mac with fallback to "monaco", 'Ubuntu Mono' for Ubuntu */
/* (at Mac this font looks too large at 14px, but 13px is too small for the font on Windows) */
/* main, menu, modal */
/* jsoneditor modal */
/* tooltip in text mode */
/* panels: navigation bar, gutter, search box */
/* navigation-bar */
/* context menu */
/* contents: json key and values */
/* contents: selected or hovered */
/* contents: section of collapsed items in an array */
/* contents: highlighting of search matches */
/* contents: inline tags inside the JSON document */
/* contents: table */
/* controls in modals: inputs, buttons, and \`a\` */
/* messages */
/* svelte-select */
/* color picker */
.jse-modal-contents.svelte-1v9c92j {
  flex: 1;
  display: flex;
  flex-direction: column;
  padding: 20px;
  overflow: auto;
  min-width: 0;
  min-height: 0;
}
.jse-modal-contents.svelte-1v9c92j .jse-actions:where(.svelte-1v9c92j) {
  display: flex;
  flex-direction: row;
  justify-content: flex-end;
  padding-top: var(--jse-padding, 10px);
}
.jse-modal-contents.svelte-1v9c92j .jse-actions:where(.svelte-1v9c92j) button.jse-primary:where(.svelte-1v9c92j) {
  border: none;
  background: transparent;
  color: inherit;
  cursor: pointer;
  font-family: var(--jse-font-family, -apple-system, BlinkMacSystemFont, "Segoe UI", Roboto, Oxygen-Sans, Ubuntu, Cantarell, "Helvetica Neue", sans-serif);
  font-size: var(--jse-font-size, 16px);
  padding: 5px;
  margin: 0;
  background: var(--jse-button-primary-background, var(--jse-theme-color, #3883fa));
  color: var(--jse-button-primary-color, #fff);
  padding: var(--jse-padding, 10px) calc(2 * var(--jse-padding, 10px));
  border-radius: 3px;
}
.jse-modal-contents.svelte-1v9c92j .jse-actions:where(.svelte-1v9c92j) button.jse-primary:where(.svelte-1v9c92j):hover {
  background: var(--jse-button-primary-background-highlight, var(--jse-theme-color-highlight, #5f9dff));
}
.jse-modal-contents.svelte-1v9c92j .jse-actions:where(.svelte-1v9c92j) button.jse-primary:where(.svelte-1v9c92j):disabled {
  background: var(--jse-button-primary-background-disabled, #9d9d9d);
}
.jse-modal-contents.svelte-1v9c92j table:where(.svelte-1v9c92j) {
  width: 100%;
  border-collapse: collapse;
  border-spacing: 0;
}
.jse-modal-contents.svelte-1v9c92j table:where(.svelte-1v9c92j) th:where(.svelte-1v9c92j),
.jse-modal-contents.svelte-1v9c92j table:where(.svelte-1v9c92j) td:where(.svelte-1v9c92j) {
  text-align: left;
  vertical-align: middle;
  font-weight: normal;
  padding-bottom: var(--jse-padding, 10px);
}
.jse-modal-contents.svelte-1v9c92j input.jse-path:where(.svelte-1v9c92j) {
  width: 100%;
  box-sizing: border-box;
  padding: 5px 10px;
  border: var(--jse-input-border, 1px solid #d8dbdf);
  border-radius: var(--jse-input-radius, 3px);
  font-family: inherit;
  font-size: inherit;
  background: inherit;
  background: var(--jse-input-background-readonly, transparent);
  color: inherit;
  outline: none;
}
.jse-modal-contents.svelte-1v9c92j .svelte-select input {
  box-sizing: border-box;
}
.jse-modal-contents.svelte-1v9c92j .jse-space:where(.svelte-1v9c92j) {
  height: 200px;
}
.jse-modal-contents.svelte-1v9c92j .jse-space:where(.svelte-1v9c92j) .jse-error:where(.svelte-1v9c92j) {
  color: var(--jse-error-color, #ee5341);
}`);var KE=Dy(()=>xJA),FJA=pA('<tr><th class="svelte-1v9c92j">Property</th><td class="svelte-1v9c92j"><!></td></tr>'),NJA=pA('<div class="jse-error svelte-1v9c92j"> </div>'),_JA=pA('<!> <div class="jse-modal-contents svelte-1v9c92j"><table class="svelte-1v9c92j"><colgroup><col width="25%"/><col width="75%"/></colgroup><tbody><tr><th class="svelte-1v9c92j">Path</th><td class="svelte-1v9c92j"><input class="jse-path svelte-1v9c92j" type="text" readonly="" title="Selected path"/></td></tr><!><tr><th class="svelte-1v9c92j">Direction</th><td class="svelte-1v9c92j"><!></td></tr></tbody></table> <div class="jse-space svelte-1v9c92j"><!></div> <div class="jse-actions svelte-1v9c92j"><button type="button" class="jse-primary svelte-1v9c92j">Sort</button></div></div>',1);vt(`/* over all fonts, sizes, and colors */
/* "consolas" for Windows, "menlo" for Mac with fallback to "monaco", 'Ubuntu Mono' for Ubuntu */
/* (at Mac this font looks too large at 14px, but 13px is too small for the font on Windows) */
/* main, menu, modal */
/* jsoneditor modal */
/* tooltip in text mode */
/* panels: navigation bar, gutter, search box */
/* navigation-bar */
/* context menu */
/* contents: json key and values */
/* contents: selected or hovered */
/* contents: section of collapsed items in an array */
/* contents: highlighting of search matches */
/* contents: inline tags inside the JSON document */
/* contents: table */
/* controls in modals: inputs, buttons, and \`a\` */
/* messages */
/* svelte-select */
/* color picker */
.jse-main.svelte-57bmz4 {
  width: 100%;
  height: 100%;
  min-width: 0;
  min-height: 150px;
  font-family: var(--jse-font-family, -apple-system, BlinkMacSystemFont, "Segoe UI", Roboto, Oxygen-Sans, Ubuntu, Cantarell, "Helvetica Neue", sans-serif);
  font-size: var(--jse-font-size, 16px);
  line-height: normal;
  position: relative;
  display: flex;
  flex-direction: row;
}
.jse-main.svelte-57bmz4:not(.jse-focus) {
  --jse-selection-background-color: var(--jse-selection-background-inactive-color, #e8e8e8);
  --jse-context-menu-pointer-background: var(--jse-context-menu-pointer-hover-background, #b2b2b2);
}`);var GJA=pA('<div role="none"><!></div> <!> <!> <!>',1);function UJA(t,e){st(e,!1);var A=X(void 0,!0),i=wr("jsoneditor:JSONEditor"),n={text:""},o=void 0,r=!1,s=tr.tree,a=!0,c=!0,l=!0,I=!0,C=!1,d=!1,B=!0,E=JSON,Q=void 0,u=JSON,v={parse:qGA,stringify:Dl},L=[lGA],x=L[0].id,y=Kc,F=void 0,U=void 0,T=jGA,N=Kc,K=Kc,H=Kc,j=Kc,IA=se=>{console.error(se),alert(se.toString())},lA=Kc,uA=Kc,p=k(e,"content",13,n),V=k(e,"selection",13,o),cA=k(e,"readOnly",13,r),aA=k(e,"indentation",13,2),jA=k(e,"tabSize",13,4),VA=k(e,"truncateTextSize",13,1e3),ce=k(e,"mode",13,s),EA=k(e,"mainMenuBar",13,a),sA=k(e,"navigationBar",13,c),TA=k(e,"statusBar",13,l),Ke=k(e,"askToFormat",13,I),Re=k(e,"escapeControlCharacters",13,C),hA=k(e,"escapeUnicodeCharacters",13,d),eA=k(e,"flattenColumns",13,B),RA=k(e,"parser",13,E),oA=k(e,"validator",13,Q),ne=k(e,"validationParser",13,u),h=k(e,"pathParser",13,v),f=k(e,"queryLanguages",13,L),w=k(e,"queryLanguageId",13,x),D=k(e,"onChangeQueryLanguage",13,y),O=k(e,"onChange",13,F),Z=k(e,"onSelect",13,U),q=k(e,"onRenderValue",13,T),CA=k(e,"onClassName",13,N),kA=k(e,"onRenderMenu",13,K),KA=k(e,"onRenderContextMenu",13,H),Ie=k(e,"onChangeMode",13,j),GA=k(e,"onError",13,IA),oe=k(e,"onFocus",13,lA),M=k(e,"onBlur",13,uA),G=X(TE(),!0),Y=X(!1,!0),AA=X(void 0,!0),dA=X(void 0,!0),WA=X(void 0,!0),Qe=X(void 0,!0),yA=X(RA(),!0);function DA(){return p()}function We(se){i("set");var fi=MN(se);if(fi)throw new Error(fi);b(G,TE()),p(se),go()}function be(se){i("update");var fi=MN(se);if(fi)throw new Error(fi);p(se),go()}function qA(se){var fi=g(AA).patch(se);return go(),fi}function It(se){V(se),go()}function Vi(se,fi){g(AA).expand(se,fi),go()}function on(se){var fi=arguments.length>1&&arguments[1]!==void 0&&arguments[1];g(AA).collapse(se,fi),go()}function Hi(){var se=arguments.length>0&&arguments[0]!==void 0?arguments[0]:{};g(AA).transform(se),go()}function Ci(){return g(AA).validate()}function Zi(){var se=g(AA).acceptAutoRepair();return go(),se}function Qi(se){return Ft.apply(this,arguments)}function Ft(){return(Ft=yt(function*(se){yield g(AA).scrollTo(se)})).apply(this,arguments)}function Tt(se){return g(AA).findElement(se)}function Ht(){g(AA).focus(),go()}function zi(){return ui.apply(this,arguments)}function ui(){return(ui=yt(function*(){yield g(AA).refresh()})).apply(this,arguments)}function Ye(se){var fi,bA,fe,it,Gt,Xe,Ot,Pi,Jt,Ki,Ct,ti,$e,Nt,Wi,Tn,ii,Ri,dt,zn,QA,_A,Ce,Pt,Li,ai,Fn,Co,Qn,un,jt,Nn=Object.keys(se);for(var ut of Nn)switch(ut){case"content":p((fi=se[ut])!==null&&fi!==void 0?fi:n);break;case"selection":V((bA=se[ut])!==null&&bA!==void 0?bA:o);break;case"readOnly":cA((fe=se[ut])!==null&&fe!==void 0?fe:r);break;case"indentation":aA((it=se[ut])!==null&&it!==void 0?it:2);break;case"tabSize":jA((Gt=se[ut])!==null&&Gt!==void 0?Gt:4);break;case"truncateTextSize":VA((Xe=se[ut])!==null&&Xe!==void 0?Xe:1e3);break;case"mode":ce((Ot=se[ut])!==null&&Ot!==void 0?Ot:s);break;case"mainMenuBar":EA((Pi=se[ut])!==null&&Pi!==void 0?Pi:a);break;case"navigationBar":sA((Jt=se[ut])!==null&&Jt!==void 0?Jt:c);break;case"statusBar":TA((Ki=se[ut])!==null&&Ki!==void 0?Ki:l);break;case"askToFormat":Ke((Ct=se[ut])!==null&&Ct!==void 0?Ct:I);break;case"escapeControlCharacters":Re((ti=se[ut])!==null&&ti!==void 0?ti:C);break;case"escapeUnicodeCharacters":hA(($e=se[ut])!==null&&$e!==void 0?$e:d);break;case"flattenColumns":eA((Nt=se[ut])!==null&&Nt!==void 0?Nt:B);break;case"parser":RA((Wi=se[ut])!==null&&Wi!==void 0?Wi:E);break;case"validator":oA((Tn=se[ut])!==null&&Tn!==void 0?Tn:Q);break;case"validationParser":ne((ii=se[ut])!==null&&ii!==void 0?ii:u);break;case"pathParser":h((Ri=se[ut])!==null&&Ri!==void 0?Ri:v);break;case"queryLanguages":f((dt=se[ut])!==null&&dt!==void 0?dt:L);break;case"queryLanguageId":w((zn=se[ut])!==null&&zn!==void 0?zn:x);break;case"onChangeQueryLanguage":D((QA=se[ut])!==null&&QA!==void 0?QA:y);break;case"onChange":O((_A=se[ut])!==null&&_A!==void 0?_A:F);break;case"onRenderValue":q((Ce=se[ut])!==null&&Ce!==void 0?Ce:T);break;case"onClassName":CA((Pt=se[ut])!==null&&Pt!==void 0?Pt:N);break;case"onRenderMenu":kA((Li=se[ut])!==null&&Li!==void 0?Li:K);break;case"onRenderContextMenu":KA((ai=se[ut])!==null&&ai!==void 0?ai:H);break;case"onChangeMode":Ie((Fn=se[ut])!==null&&Fn!==void 0?Fn:j);break;case"onSelect":Z((Co=se[ut])!==null&&Co!==void 0?Co:U);break;case"onError":GA((Qn=se[ut])!==null&&Qn!==void 0?Qn:IA);break;case"onFocus":oe((un=se[ut])!==null&&un!==void 0?un:lA);break;case"onBlur":M((jt=se[ut])!==null&&jt!==void 0?jt:uA);break;default:Xo(ut)}function Xo(Oe){i('Unknown property "'.concat(Oe,'"'))}f().some(Oe=>Oe.id===w())||w(f()[0].id),go()}function Ai(){return ei.apply(this,arguments)}function ei(){return(ei=yt(function*(){throw new Error("class method destroy() is deprecated. It is replaced with a method destroy() in the vanilla library.")})).apply(this,arguments)}function Oi(se,fi,bA){p(se),O()&&O()(se,fi,bA)}function Yn(se){V(se),Z()&&Z()(Tu(se))}function Dn(){b(Y,!0),oe()&&oe()()}function Ho(){b(Y,!1),M()&&M()()}function Sn(se){return io.apply(this,arguments)}function io(){return(io=yt(function*(se){ce()!==se&&(ce(se),go(),Ht(),Ie()(se))})).apply(this,arguments)}function Wo(se){i("handleChangeQueryLanguage",se),w(se),D()(se)}function No(se){var{id:fi,json:bA,rootPath:fe,onTransform:it,onClose:Gt}=se;cA()||b(Qe,{id:fi,json:bA,rootPath:fe,indentation:aA(),truncateTextSize:VA(),escapeControlCharacters:Re(),escapeUnicodeCharacters:hA(),parser:RA(),parseMemoizeOne:g(A),validationParser:ne(),pathParser:h(),queryLanguages:f(),queryLanguageId:w(),onChangeQueryLanguage:Wo,onRenderValue:q(),onRenderMenu:Xe=>kA()(Xe,{mode:ce(),modal:!0,readOnly:cA()}),onRenderContextMenu:Xe=>KA()(Xe,{mode:ce(),modal:!0,readOnly:cA(),selection:V()}),onClassName:CA(),onTransform:it,onClose:Gt})}function Jn(se){cA()||b(WA,se)}function hn(se){var{content:fi,path:bA,onPatch:fe,onClose:it}=se;i("onJSONEditorModal",{content:fi,path:bA}),b(dA,{content:fi,path:bA,onPatch:fe,readOnly:cA(),indentation:aA(),tabSize:jA(),truncateTextSize:VA(),mainMenuBar:EA(),navigationBar:sA(),statusBar:TA(),askToFormat:Ke(),escapeControlCharacters:Re(),escapeUnicodeCharacters:hA(),flattenColumns:eA(),parser:RA(),validator:void 0,validationParser:ne(),pathParser:h(),onRenderValue:q(),onClassName:CA(),onRenderMenu:kA(),onRenderContextMenu:KA(),onSortModal:Jn,onTransformModal:No,onClose:it})}function wo(se){se.stopPropagation()}return fA(()=>(W(RA()),g(yA),W(p()),TE),()=>{if(!IsA(RA(),g(yA))){if(i("parser changed, recreate editor"),k3(p())){var se=g(yA).stringify(p().json);p({json:se!==void 0?RA().parse(se):void 0})}b(yA,RA()),b(G,TE())}}),fA(()=>W(p()),()=>{var se=MN(p());se&&console.error("Error: "+se)}),fA(()=>W(V()),()=>{V()===null&&console.warn("selection is invalid: it is null but should be undefined")}),fA(()=>W(RA()),()=>{b(A,VB(RA().parse))}),fA(()=>W(ce()),()=>{i("mode changed to",ce())}),nn(),Rt(!0),c_(t,{children:(se,fi)=>{var bA,fe=GJA(),it=Bt(fe);$rA($(it),()=>g(G),Ct=>{to(urA(Ct,{get externalMode(){return ce()},get content(){return p()},get selection(){return V()},get readOnly(){return cA()},get indentation(){return aA()},get tabSize(){return jA()},get truncateTextSize(){return VA()},get statusBar(){return TA()},get askToFormat(){return Ke()},get mainMenuBar(){return EA()},get navigationBar(){return sA()},get escapeControlCharacters(){return Re()},get escapeUnicodeCharacters(){return hA()},get flattenColumns(){return eA()},get parser(){return RA()},get parseMemoizeOne(){return g(A)},get validator(){return oA()},get validationParser(){return ne()},get pathParser(){return h()},insideModal:!1,get onError(){return GA()},onChange:Oi,onChangeMode:Sn,onSelect:Yn,get onRenderValue(){return q()},get onClassName(){return CA()},onFocus:Dn,onBlur:Ho,get onRenderMenu(){return kA()},get onRenderContextMenu(){return KA()},onSortModal:Jn,onTransformModal:No,onJSONEditorModal:hn,$$legacy:!0}),ti=>b(AA,ti),()=>g(AA))});var Gt=gA(it,2),Xe=Ct=>{(function(ti,$e){var Nt,Wi;st($e,!1);var Tn=X(void 0,!0),ii=X(void 0,!0),Ri=X(void 0,!0),dt=X(void 0,!0),zn=wr("jsoneditor:SortModal"),QA=k($e,"id",9),_A=k($e,"json",9),Ce=k($e,"rootPath",9),Pt=k($e,"onSort",9),Li=k($e,"onClose",9),ai={value:1,label:"ascending"},Fn=[ai,{value:-1,label:"descending"}],Co="".concat(QA(),":").concat(nt(Ce())),Qn=X((Nt=KE()[Co])===null||Nt===void 0?void 0:Nt.selectedProperty,!0),un=X(((Wi=KE()[Co])===null||Wi===void 0?void 0:Wi.selectedDirection)||ai,!0),jt=X(void 0,!0);function Nn(){try{var Xo,Oe,ni;b(jt,void 0);var fn=((Xo=g(Qn))===null||Xo===void 0?void 0:Xo.value)||((Oe=g(dt))===null||Oe===void 0||(Oe=Oe[0])===null||Oe===void 0?void 0:Oe.value)||[],Yi=(ni=g(un))===null||ni===void 0?void 0:ni.value,ir=eaA(_A(),Ce(),fn,Yi);Pt()!==void 0&&Ce()!==void 0&&Pt()({operations:ir,rootPath:Ce(),itemPath:fn,direction:Yi}),Li()()}catch(Xi){b(jt,String(Xi))}}function ut(Xo){Xo.focus()}fA(()=>(W(_A()),W(Ce())),()=>{b(Tn,Fe(_A(),Ce()))}),fA(()=>g(Tn),()=>{b(ii,Array.isArray(g(Tn)))}),fA(()=>(g(ii),g(Tn)),()=>{b(Ri,g(ii)?r_(g(Tn)):void 0)}),fA(()=>(g(Ri),L1),()=>{b(dt,g(Ri)?g(Ri).map(L1):void 0)}),fA(()=>(KE(),g(Qn),g(un)),()=>{KE(KE()[Co]={selectedProperty:g(Qn),selectedDirection:g(un)}),zn("store state in memory",Co,KE()[Co])}),nn(),Rt(!0),U3(ti,{get onClose(){return Li()},className:"jse-sort-modal",children:(Xo,Oe)=>{var ni=_JA(),fn=Bt(ni),Yi=PA(()=>g(ii)?"Sort array items":"Sort object keys");dy(fn,{get title(){return g(Yi)},get onClose(){return Li()}});var ir=$(gA(fn,2)),Xi=gA($(ir)),ks=$(Xi),La=gA($(ks)),_o=$(La),yn=gA(ks),Gr=Pe=>{var qe=FJA(),oi=gA($(qe));bC($(oi),{showChevron:!0,get items(){return g(dt)},get value(){return g(Qn)},set value(xi){b(Qn,xi)},$$legacy:!0}),iA(Pe,qe)};MA(yn,Pe=>{var qe;g(ii)&&g(dt)&&((qe=g(dt))===null||qe===void 0?void 0:qe.length)>1&&Pe(Gr)});var z=gA(yn),wA=gA($(z));bC($(wA),{showChevron:!0,clearable:!1,items:Fn,get value(){return g(un)},set value(Pe){b(un,Pe)},$$legacy:!0});var ee=gA(ir,2),Me=$(ee),ke=Pe=>{var qe=NJA(),oi=$(qe);Ee(()=>Et(oi,g(jt))),iA(Pe,qe)};MA(Me,Pe=>{g(jt)&&Pe(ke)});var ze=$(gA(ee,2));Nr(()=>re("click",ze,Nn)),bs(ze,Pe=>ut?.(Pe)),Ee(Pe=>{var qe;GC(_o,Pe),ze.disabled=!!(g(ii)&&g(dt)&&((qe=g(dt))===null||qe===void 0?void 0:qe.length)>1)&&!g(Qn)},[()=>Ce()&&!sn(Ce())?Dl(Ce()):"(document root)"],PA),iA(Xo,ni)},$$slots:{default:!0}}),at()})(Ct,U1(()=>g(WA),{onClose:()=>{var ti;(ti=g(WA))===null||ti===void 0||ti.onClose(),b(WA,void 0)}}))};MA(Gt,Ct=>{g(WA)&&Ct(Xe)});var Ot=gA(Gt,2),Pi=Ct=>{YYA(Ct,U1(()=>g(Qe),{onClose:()=>{var ti;(ti=g(Qe))===null||ti===void 0||ti.onClose(),b(Qe,void 0)}}))};MA(Ot,Ct=>{g(Qe)&&Ct(Pi)});var Jt=gA(Ot,2),Ki=Ct=>{(function(ti,$e){st($e,!1);var Nt=X(void 0,!0),Wi=X(void 0,!0),Tn=X(void 0,!0),ii=X(void 0,!0),Ri=wr("jsoneditor:JSONEditorModal"),dt=k($e,"content",9),zn=k($e,"path",9),QA=k($e,"onPatch",9),_A=k($e,"readOnly",9),Ce=k($e,"indentation",9),Pt=k($e,"tabSize",9),Li=k($e,"truncateTextSize",9),ai=k($e,"mainMenuBar",9),Fn=k($e,"navigationBar",9),Co=k($e,"statusBar",9),Qn=k($e,"askToFormat",9),un=k($e,"escapeControlCharacters",9),jt=k($e,"escapeUnicodeCharacters",9),Nn=k($e,"flattenColumns",9),ut=k($e,"parser",9),Xo=k($e,"validator",9),Oe=k($e,"validationParser",9),ni=k($e,"pathParser",9),fn=k($e,"onRenderValue",9),Yi=k($e,"onClassName",9),ir=k($e,"onRenderMenu",9),Xi=k($e,"onRenderContextMenu",9),ks=k($e,"onSortModal",9),La=k($e,"onTransformModal",9),_o=k($e,"onClose",9),yn=X(void 0,!0),Gr=X(void 0,!0),z={mode:Me(dt()),content:dt(),selection:void 0,relativePath:zn()},wA=X([z],!0),ee=X(void 0,!0);function Me(rA){return k3(rA)&&ao(rA.json)?tr.table:tr.tree}function ke(){var rA,JA=(rA=ri(g(wA)))===null||rA===void 0?void 0:rA.selection;F3(JA)&&g(yn).scrollTo(je(JA))}function ze(){if(Ri("handleApply"),!_A())try{b(ee,void 0);var rA=g(Nt).relativePath,JA=g(Nt).content,Se=[{op:"replace",path:nt(rA),value:_oA(JA,ut()).json}];if(g(wA).length>1){var pe=_oA(g(wA)[g(wA).length-2].content,ut()).json,me={json:Ba(pe,Se)},ft=Be(Be({},g(wA)[g(wA).length-2]||z),{},{content:me});b(wA,[...g(wA).slice(0,g(wA).length-2),ft]),go(),ke()}else QA()(Se),_o()()}catch(mt){b(ee,String(mt))}}function Pe(){if(Ri("handleClose"),g(Gr))b(Gr,!1);else if(g(wA).length>1){var rA;b(wA,pi(g(wA))),go(),(rA=g(yn))===null||rA===void 0||rA.focus(),ke(),b(ee,void 0)}else _o()()}function qe(rA){Ri("handleChange",rA),Di(JA=>Be(Be({},JA),{},{content:rA}))}function oi(rA){Ri("handleChangeSelection",rA),Di(JA=>Be(Be({},JA),{},{selection:rA}))}function xi(rA){Ri("handleChangeMode",rA),Di(JA=>Be(Be({},JA),{},{mode:rA}))}function Di(rA){var JA=rA(ri(g(wA)));b(wA,[...pi(g(wA)),JA])}function cn(rA){b(ee,rA.toString()),console.error(rA)}function qr(rA){var JA,{content:Se,path:pe}=rA;Ri("handleJSONEditorModal",{content:Se,path:pe});var me={mode:Me(Se),content:Se,selection:void 0,relativePath:pe};b(wA,[...g(wA),me]),go(),(JA=g(yn))===null||JA===void 0||JA.focus()}function J(rA){rA.focus()}ls(()=>{var rA;(rA=g(yn))===null||rA===void 0||rA.focus()}),fA(()=>g(wA),()=>{b(Nt,ri(g(wA))||z)}),fA(()=>g(wA),()=>{b(Wi,g(wA).flatMap(rA=>rA.relativePath))}),fA(()=>(g(Wi),Dl),()=>{b(Tn,sn(g(Wi))?"(document root)":Dl(g(Wi)))}),fA(()=>W(ut()),()=>{b(ii,VB(ut().parse))}),nn(),Rt(!0),U3(ti,{onClose:Pe,className:"jse-jsoneditor-modal",get fullscreen(){return g(Gr)},children:(rA,JA)=>{var Se=LJA();c_($(Se),{children:(pe,me)=>{var ft=RJA(),mt=Bt(ft),ci=PA(()=>g(wA).length>1?" (".concat(g(wA).length,")"):"");dy(mt,{get title(){var Qt;return"Edit nested content ".concat((Qt=g(ci))!==null&&Qt!==void 0?Qt:"")},fullScreenButton:!0,onClose:Pe,get fullscreen(){return g(Gr)},set fullscreen(Qt){b(Gr,Qt)},$$legacy:!0});var rn=gA(mt,2),yi=gA($(rn),2),Rn=gA(yi,4);to(urA($(Rn),{get externalMode(){return g(Nt).mode},get content(){return g(Nt).content},get selection(){return g(Nt).selection},get readOnly(){return _A()},get indentation(){return Ce()},get tabSize(){return Pt()},get truncateTextSize(){return Li()},get statusBar(){return Co()},get askToFormat(){return Qn()},get mainMenuBar(){return ai()},get navigationBar(){return Fn()},get escapeControlCharacters(){return un()},get escapeUnicodeCharacters(){return jt()},get flattenColumns(){return Nn()},get parser(){return ut()},get parseMemoizeOne(){return g(ii)},get validator(){return Xo()},get validationParser(){return Oe()},get pathParser(){return ni()},insideModal:!0,onError:cn,onChange:qe,onChangeMode:xi,onSelect:oi,get onRenderValue(){return fn()},get onClassName(){return Yi()},onFocus:Kc,onBlur:Kc,get onRenderMenu(){return ir()},get onRenderContextMenu(){return Xi()},get onSortModal(){return ks()},get onTransformModal(){return La()},onJSONEditorModal:qr,$$legacy:!0}),Qt=>b(yn,Qt),()=>g(yn));var bt=$(gA(Rn,2)),Bo=Qt=>{var At=bJA(),Ni=$(At);Ee(()=>Et(Ni,g(ee))),iA(Qt,At)};MA(bt,Qt=>{g(ee)&&Qt(Bo)});var mn=gA(bt,2),Hn=Qt=>{var At=MJA();Si($(At),{data:mW}),re("click",At,Pe),iA(Qt,At)};MA(mn,Qt=>{g(wA).length>1&&Qt(Hn)});var ji=gA(mn,2),ht=Qt=>{var At=kJA();Nr(()=>re("click",At,ze)),bs(At,Ni=>J?.(Ni)),iA(Qt,At)},Fi=Qt=>{var At=SJA();re("click",At,Pe),iA(Qt,At)};MA(ji,Qt=>{_A()?Qt(Fi,!1):Qt(ht)}),Ee(()=>GC(yi,g(Tn))),iA(pe,ft)},$$slots:{default:!0}}),iA(rA,Se)},$$slots:{default:!0}}),at()})(Ct,U1(()=>g(dA),{onClose:()=>{var ti;(ti=g(dA))===null||ti===void 0||ti.onClose(),b(dA,void 0)}}))};MA(Jt,Ct=>{g(dA)&&Ct(Ki)}),Ee(Ct=>bA=xt(it,1,"jse-main svelte-57bmz4",null,bA,Ct),[()=>({"jse-focus":g(Y)})],PA),re("keydown",it,wo),iA(se,fe)},$$slots:{default:!0}}),kt(e,"get",DA),kt(e,"set",We),kt(e,"update",be),kt(e,"patch",qA),kt(e,"select",It),kt(e,"expand",Vi),kt(e,"collapse",on),kt(e,"transform",Hi),kt(e,"validate",Ci),kt(e,"acceptAutoRepair",Zi),kt(e,"scrollTo",Qi),kt(e,"findElement",Tt),kt(e,"focus",Ht),kt(e,"refresh",zi),kt(e,"updateProps",Ye),kt(e,"destroy",Ai),at({get:DA,set:We,update:be,patch:qA,select:It,expand:Vi,collapse:on,transform:Hi,validate:Ci,acceptAutoRepair:Zi,scrollTo:Qi,findElement:Tt,focus:Ht,refresh:zi,updateProps:Ye,destroy:Ai})}function daA(t){var{target:e,props:A}=t,i=R_A(UJA,{target:e,props:A});return i.destroy=yt(function*(){return function(n,o){var r=n_.get(n);return r?(n_.delete(n),r(o)):Promise.resolve()}(i)}),go(),i}var HC=class t{constructor(e){this.el=e}jsonString;editor=null;ngAfterViewInit(){let e={text:this.jsonString};this.editor=daA({target:document.getElementById("json-editor"),props:{content:e,mode:tr.text,mainMenuBar:!1}})}getJsonString(){return this.editor?.get().text}static \u0275fac=function(A){return new(A||t)(zA(te))};static \u0275cmp=YA({type:t,selectors:[["app-json-editor"]],inputs:{jsonString:"jsonString"},standalone:!1,decls:1,vars:0,consts:[["id","json-editor",1,"json-editor-container","jse-theme-dark"]],template:function(A,i){A&1&&UA(0,"div",0)},styles:[".jse-theme-dark[_ngcontent-%COMP%]{--jse-theme: dark;--jse-theme-color: #2f6dd0;--jse-theme-color-highlight: #467cd2;--jse-background-color: #1e1e1e;--jse-text-color: #d4d4d4;--jse-text-color-inverse: #4d4d4d;--jse-main-border: 1px solid #4f4f4f;--jse-menu-color: #fff;--jse-modal-background: #2f2f2f;--jse-modal-overlay-background: rgba(0, 0, 0, .5);--jse-modal-code-background: #2f2f2f;--jse-tooltip-color: var(--jse-text-color);--jse-tooltip-background: #4b4b4b;--jse-tooltip-border: 1px solid #737373;--jse-tooltip-action-button-color: inherit;--jse-tooltip-action-button-background: #737373;--jse-panel-background: #333333;--jse-panel-background-border: 1px solid #464646;--jse-panel-color: var(--jse-text-color);--jse-panel-color-readonly: #737373;--jse-panel-border: 1px solid #3c3c3c;--jse-panel-button-color-highlight: #e5e5e5;--jse-panel-button-background-highlight: #464646;--jse-navigation-bar-background: #656565;--jse-navigation-bar-background-highlight: #7e7e7e;--jse-navigation-bar-dropdown-color: var(--jse-text-color);--jse-context-menu-background: #4b4b4b;--jse-context-menu-background-highlight: #595959;--jse-context-menu-separator-color: #595959;--jse-context-menu-color: var(--jse-text-color);--jse-context-menu-pointer-background: #737373;--jse-context-menu-pointer-background-highlight: #818181;--jse-context-menu-pointer-color: var(--jse-context-menu-color);--jse-key-color: #9cdcfe;--jse-value-color: var(--jse-text-color);--jse-value-color-number: #b5cea8;--jse-value-color-boolean: #569cd6;--jse-value-color-null: #569cd6;--jse-value-color-string: #ce9178;--jse-value-color-url: #ce9178;--jse-delimiter-color: #949494;--jse-edit-outline: 2px solid var(--jse-text-color);--jse-selection-background-color: #464646;--jse-selection-background-inactive-color: #333333;--jse-hover-background-color: #343434;--jse-active-line-background-color: rgba(255, 255, 255, .06);--jse-search-match-background-color: #343434;--jse-collapsed-items-background-color: #333333;--jse-collapsed-items-selected-background-color: #565656;--jse-collapsed-items-link-color: #b2b2b2;--jse-collapsed-items-link-color-highlight: #ec8477;--jse-search-match-color: #724c27;--jse-search-match-outline: 1px solid #966535;--jse-search-match-active-color: #9f6c39;--jse-search-match-active-outline: 1px solid #bb7f43;--jse-tag-background: #444444;--jse-tag-color: #bdbdbd;--jse-table-header-background: #333333;--jse-table-header-background-highlight: #424242;--jse-table-row-odd-background: rgba(255, 255, 255, .1);--jse-input-background: #3d3d3d;--jse-input-border: var(--jse-main-border);--jse-button-background: #808080;--jse-button-background-highlight: #7a7a7a;--jse-button-color: #e0e0e0;--jse-button-secondary-background: #494949;--jse-button-secondary-background-highlight: #5d5d5d;--jse-button-secondary-background-disabled: #9d9d9d;--jse-button-secondary-color: var(--jse-text-color);--jse-a-color: #55abff;--jse-a-color-highlight: #4387c9;--jse-svelte-select-background: #3d3d3d;--jse-svelte-select-border: 1px solid #4f4f4f;--list-background: #3d3d3d;--item-hover-bg: #505050;--multi-item-bg: #5b5b5b;--input-color: #d4d4d4;--multi-clear-bg: #8a8a8a;--multi-item-clear-icon-color: #d4d4d4;--multi-item-outline: 1px solid #696969;--list-shadow: 0 2px 8px 0 rgba(0, 0, 0, .4);--jse-color-picker-background: #656565;--jse-color-picker-border-box-shadow: #8c8c8c 0 0 0 1px}.json-editor-container[_ngcontent-%COMP%]{height:300px;max-height:300px}"]})};var W3=class t{constructor(e,A){this.dialogRef=e;this.data=A;this.toolArgs=JSON.stringify(A.args,null,2),this.functionName=A.functionName}jsonEditorComponent;toolArgs="";functionName="";ngOnInit(){}onSave(){try{this.toolArgs=this.jsonEditorComponent.getJsonString();let e=JSON.parse(this.toolArgs);this.dialogRef.close(e)}catch(e){alert("Invalid JSON: "+e)}}onCancel(){this.dialogRef.close(null)}static \u0275fac=function(A){return new(A||t)(zA(cr),zA($r))};static \u0275cmp=YA({type:t,selectors:[["app-edit-function-args-dialog"]],viewQuery:function(A,i){if(A&1&&Ge(HC,5),A&2){let n;$A(n=Ae())&&(i.jsonEditorComponent=n.first)}},standalone:!1,decls:11,vars:2,consts:[[1,"dialog-container"],["mat-dialog-title",""],[3,"jsonString"],["align","end"],["mat-button","","mat-dialog-close",""],["mat-button","","cdkFocusInitial","",3,"click"]],template:function(A,i){A&1&&(S(0,"div",0)(1,"h2",1),tA(2,"Edit function arguments"),R(),S(3,"mat-dialog-content"),tA(4),UA(5,"app-json-editor",2),R(),S(6,"mat-dialog-actions",3)(7,"button",4),tA(8,"Cancel"),R(),S(9,"button",5),mA("click",function(){return i.onSave()}),tA(10,"Save"),R()()()),A&2&&(_(4),ot(" ",i.functionName," "),_(),vA("jsonString",i.toolArgs))},dependencies:[ur,hs,ga,Ia,gg,HC],styles:[".dialog-container[_ngcontent-%COMP%]{border-radius:12px;padding:18px;width:500px;box-shadow:0 8px 16px #0006}.editor[_ngcontent-%COMP%]{padding-top:12px}"]})};var JJA=["input"],TJA=["label"],zJA=["*"],HJA=new BA("mat-checkbox-default-options",{providedIn:"root",factory:EaA});function EaA(){return{color:"accent",clickAction:"check-indeterminate",disabledInteractive:!1}}var Ms=function(t){return t[t.Init=0]="Init",t[t.Checked=1]="Checked",t[t.Unchecked=2]="Unchecked",t[t.Indeterminate=3]="Indeterminate",t}(Ms||{}),OJA={provide:uc,useExisting:nr(()=>gh),multi:!0},sG=class{source;checked},BaA=EaA(),gh=(()=>{class t{_elementRef=m(te);_changeDetectorRef=m(lt);_ngZone=m(de);_animationMode=m(mi,{optional:!0});_options=m(HJA,{optional:!0});focus(){this._inputElement.nativeElement.focus()}_createChangeEvent(A){let i=new sG;return i.source=this,i.checked=A,i}_getAnimationTargetElement(){return this._inputElement?.nativeElement}_animationClasses={uncheckedToChecked:"mdc-checkbox--anim-unchecked-checked",uncheckedToIndeterminate:"mdc-checkbox--anim-unchecked-indeterminate",checkedToUnchecked:"mdc-checkbox--anim-checked-unchecked",checkedToIndeterminate:"mdc-checkbox--anim-checked-indeterminate",indeterminateToChecked:"mdc-checkbox--anim-indeterminate-checked",indeterminateToUnchecked:"mdc-checkbox--anim-indeterminate-unchecked"};ariaLabel="";ariaLabelledby=null;ariaDescribedby;ariaExpanded;ariaControls;ariaOwns;_uniqueId;id;get inputId(){return`${this.id||this._uniqueId}-input`}required;labelPosition="after";name=null;change=new XA;indeterminateChange=new XA;value;disableRipple;_inputElement;_labelElement;tabIndex;color;disabledInteractive;_onTouched=()=>{};_currentAnimationClass="";_currentCheckState=Ms.Init;_controlValueAccessorChangeFn=()=>{};_validatorChangeFn=()=>{};constructor(){m(Ln).load(Qr);let A=m(new Er("tabindex"),{optional:!0});this._options=this._options||BaA,this.color=this._options.color||BaA.color,this.tabIndex=A==null?0:parseInt(A)||0,this.id=this._uniqueId=m($i).getId("mat-mdc-checkbox-"),this.disabledInteractive=this._options?.disabledInteractive??!1}ngOnChanges(A){A.required&&this._validatorChangeFn()}ngAfterViewInit(){this._syncIndeterminate(this._indeterminate)}get checked(){return this._checked}set checked(A){A!=this.checked&&(this._checked=A,this._changeDetectorRef.markForCheck())}_checked=!1;get disabled(){return this._disabled}set disabled(A){A!==this.disabled&&(this._disabled=A,this._changeDetectorRef.markForCheck())}_disabled=!1;get indeterminate(){return this._indeterminate}set indeterminate(A){let i=A!=this._indeterminate;this._indeterminate=A,i&&(this._indeterminate?this._transitionCheckState(Ms.Indeterminate):this._transitionCheckState(this.checked?Ms.Checked:Ms.Unchecked),this.indeterminateChange.emit(this._indeterminate)),this._syncIndeterminate(this._indeterminate)}_indeterminate=!1;_isRippleDisabled(){return this.disableRipple||this.disabled}_onLabelTextChange(){this._changeDetectorRef.detectChanges()}writeValue(A){this.checked=!!A}registerOnChange(A){this._controlValueAccessorChangeFn=A}registerOnTouched(A){this._onTouched=A}setDisabledState(A){this.disabled=A}validate(A){return this.required&&A.value!==!0?{required:!0}:null}registerOnValidatorChange(A){this._validatorChangeFn=A}_transitionCheckState(A){let i=this._currentCheckState,n=this._getAnimationTargetElement();if(!(i===A||!n)&&(this._currentAnimationClass&&n.classList.remove(this._currentAnimationClass),this._currentAnimationClass=this._getAnimationClassForCheckStateTransition(i,A),this._currentCheckState=A,this._currentAnimationClass.length>0)){n.classList.add(this._currentAnimationClass);let o=this._currentAnimationClass;this._ngZone.runOutsideAngular(()=>{setTimeout(()=>{n.classList.remove(o)},1e3)})}}_emitChangeEvent(){this._controlValueAccessorChangeFn(this.checked),this.change.emit(this._createChangeEvent(this.checked)),this._inputElement&&(this._inputElement.nativeElement.checked=this.checked)}toggle(){this.checked=!this.checked,this._controlValueAccessorChangeFn(this.checked)}_handleInputClick(){let A=this._options?.clickAction;!this.disabled&&A!=="noop"?(this.indeterminate&&A!=="check"&&Promise.resolve().then(()=>{this._indeterminate=!1,this.indeterminateChange.emit(this._indeterminate)}),this._checked=!this._checked,this._transitionCheckState(this._checked?Ms.Checked:Ms.Unchecked),this._emitChangeEvent()):(this.disabled&&this.disabledInteractive||!this.disabled&&A==="noop")&&(this._inputElement.nativeElement.checked=this.checked,this._inputElement.nativeElement.indeterminate=this.indeterminate)}_onInteractionEvent(A){A.stopPropagation()}_onBlur(){Promise.resolve().then(()=>{this._onTouched(),this._changeDetectorRef.markForCheck()})}_getAnimationClassForCheckStateTransition(A,i){if(this._animationMode==="NoopAnimations")return"";switch(A){case Ms.Init:if(i===Ms.Checked)return this._animationClasses.uncheckedToChecked;if(i==Ms.Indeterminate)return this._checked?this._animationClasses.checkedToIndeterminate:this._animationClasses.uncheckedToIndeterminate;break;case Ms.Unchecked:return i===Ms.Checked?this._animationClasses.uncheckedToChecked:this._animationClasses.uncheckedToIndeterminate;case Ms.Checked:return i===Ms.Unchecked?this._animationClasses.checkedToUnchecked:this._animationClasses.checkedToIndeterminate;case Ms.Indeterminate:return i===Ms.Checked?this._animationClasses.indeterminateToChecked:this._animationClasses.indeterminateToUnchecked}return""}_syncIndeterminate(A){let i=this._inputElement;i&&(i.nativeElement.indeterminate=A)}_onInputClick(){this._handleInputClick()}_onTouchTargetClick(){this._handleInputClick(),this.disabled||this._inputElement.nativeElement.focus()}_preventBubblingFromLabel(A){A.target&&this._labelElement.nativeElement.contains(A.target)&&A.stopPropagation()}static \u0275fac=function(i){return new(i||t)};static \u0275cmp=YA({type:t,selectors:[["mat-checkbox"]],viewQuery:function(i,n){if(i&1&&(Ge(JJA,5),Ge(TJA,5)),i&2){let o;$A(o=Ae())&&(n._inputElement=o.first),$A(o=Ae())&&(n._labelElement=o.first)}},hostAttrs:[1,"mat-mdc-checkbox"],hostVars:16,hostBindings:function(i,n){i&2&&(Fs("id",n.id),_e("tabindex",null)("aria-label",null)("aria-labelledby",null),vo(n.color?"mat-"+n.color:"mat-accent"),ue("_mat-animation-noopable",n._animationMode==="NoopAnimations")("mdc-checkbox--disabled",n.disabled)("mat-mdc-checkbox-disabled",n.disabled)("mat-mdc-checkbox-checked",n.checked)("mat-mdc-checkbox-disabled-interactive",n.disabledInteractive))},inputs:{ariaLabel:[0,"aria-label","ariaLabel"],ariaLabelledby:[0,"aria-labelledby","ariaLabelledby"],ariaDescribedby:[0,"aria-describedby","ariaDescribedby"],ariaExpanded:[2,"aria-expanded","ariaExpanded",ae],ariaControls:[0,"aria-controls","ariaControls"],ariaOwns:[0,"aria-owns","ariaOwns"],id:"id",required:[2,"required","required",ae],labelPosition:"labelPosition",name:"name",value:"value",disableRipple:[2,"disableRipple","disableRipple",ae],tabIndex:[2,"tabIndex","tabIndex",A=>A==null?void 0:Mi(A)],color:"color",disabledInteractive:[2,"disabledInteractive","disabledInteractive",ae],checked:[2,"checked","checked",ae],disabled:[2,"disabled","disabled",ae],indeterminate:[2,"indeterminate","indeterminate",ae]},outputs:{change:"change",indeterminateChange:"indeterminateChange"},exportAs:["matCheckbox"],features:[ct([OJA,{provide:d0,useExisting:t,multi:!0}]),Kt],ngContentSelectors:zJA,decls:15,vars:23,consts:[["checkbox",""],["input",""],["label",""],["mat-internal-form-field","",3,"click","labelPosition"],[1,"mdc-checkbox"],[1,"mat-mdc-checkbox-touch-target",3,"click"],["type","checkbox",1,"mdc-checkbox__native-control",3,"blur","click","change","checked","indeterminate","disabled","id","required","tabIndex"],[1,"mdc-checkbox__ripple"],[1,"mdc-checkbox__background"],["focusable","false","viewBox","0 0 24 24","aria-hidden","true",1,"mdc-checkbox__checkmark"],["fill","none","d","M1.73,12.91 8.1,19.28 22.79,4.59",1,"mdc-checkbox__checkmark-path"],[1,"mdc-checkbox__mixedmark"],["mat-ripple","",1,"mat-mdc-checkbox-ripple","mat-focus-indicator",3,"matRippleTrigger","matRippleDisabled","matRippleCentered"],[1,"mdc-label",3,"for"]],template:function(i,n){if(i&1){let o=De();Yt(),S(0,"div",3),mA("click",function(s){return LA(o),xA(n._preventBubblingFromLabel(s))}),S(1,"div",4,0)(3,"div",5),mA("click",function(){return LA(o),xA(n._onTouchTargetClick())}),R(),S(4,"input",6,1),mA("blur",function(){return LA(o),xA(n._onBlur())})("click",function(){return LA(o),xA(n._onInputClick())})("change",function(s){return LA(o),xA(n._onInteractionEvent(s))}),R(),UA(6,"div",7),S(7,"div",8),hr(),S(8,"svg",9),UA(9,"path",10),R(),uI(),UA(10,"div",11),R(),UA(11,"div",12),R(),S(12,"label",13,2),xe(14),R()()}if(i&2){let o=or(2);vA("labelPosition",n.labelPosition),_(4),ue("mdc-checkbox--selected",n.checked),vA("checked",n.checked)("indeterminate",n.indeterminate)("disabled",n.disabled&&!n.disabledInteractive)("id",n.inputId)("required",n.required)("tabIndex",n.disabled&&!n.disabledInteractive?-1:n.tabIndex),_e("aria-label",n.ariaLabel||null)("aria-labelledby",n.ariaLabelledby)("aria-describedby",n.ariaDescribedby)("aria-checked",n.indeterminate?"mixed":null)("aria-controls",n.ariaControls)("aria-disabled",n.disabled&&n.disabledInteractive?!0:null)("aria-expanded",n.ariaExpanded)("aria-owns",n.ariaOwns)("name",n.name)("value",n.value),_(7),vA("matRippleTrigger",o)("matRippleDisabled",n.disableRipple||n.disabled)("matRippleCentered",!0),_(),vA("for",n.inputId)}},dependencies:[Gs,BB],styles:['.mdc-checkbox{display:inline-block;position:relative;flex:0 0 18px;box-sizing:content-box;width:18px;height:18px;line-height:0;white-space:nowrap;cursor:pointer;vertical-align:bottom;padding:calc((var(--mdc-checkbox-state-layer-size, 40px) - 18px)/2);margin:calc((var(--mdc-checkbox-state-layer-size, 40px) - var(--mdc-checkbox-state-layer-size, 40px))/2)}.mdc-checkbox:hover>.mdc-checkbox__ripple{opacity:var(--mdc-checkbox-unselected-hover-state-layer-opacity, var(--mat-sys-hover-state-layer-opacity));background-color:var(--mdc-checkbox-unselected-hover-state-layer-color, var(--mat-sys-on-surface))}.mdc-checkbox:hover>.mat-mdc-checkbox-ripple>.mat-ripple-element{background-color:var(--mdc-checkbox-unselected-hover-state-layer-color, var(--mat-sys-on-surface))}.mdc-checkbox .mdc-checkbox__native-control:focus+.mdc-checkbox__ripple{opacity:var(--mdc-checkbox-unselected-focus-state-layer-opacity, var(--mat-sys-focus-state-layer-opacity));background-color:var(--mdc-checkbox-unselected-focus-state-layer-color, var(--mat-sys-on-surface))}.mdc-checkbox .mdc-checkbox__native-control:focus~.mat-mdc-checkbox-ripple .mat-ripple-element{background-color:var(--mdc-checkbox-unselected-focus-state-layer-color, var(--mat-sys-on-surface))}.mdc-checkbox:active>.mdc-checkbox__native-control+.mdc-checkbox__ripple{opacity:var(--mdc-checkbox-unselected-pressed-state-layer-opacity, var(--mat-sys-pressed-state-layer-opacity));background-color:var(--mdc-checkbox-unselected-pressed-state-layer-color, var(--mat-sys-primary))}.mdc-checkbox:active>.mdc-checkbox__native-control~.mat-mdc-checkbox-ripple .mat-ripple-element{background-color:var(--mdc-checkbox-unselected-pressed-state-layer-color, var(--mat-sys-primary))}.mdc-checkbox:hover .mdc-checkbox__native-control:checked+.mdc-checkbox__ripple{opacity:var(--mdc-checkbox-selected-hover-state-layer-opacity, var(--mat-sys-hover-state-layer-opacity));background-color:var(--mdc-checkbox-selected-hover-state-layer-color, var(--mat-sys-primary))}.mdc-checkbox:hover .mdc-checkbox__native-control:checked~.mat-mdc-checkbox-ripple .mat-ripple-element{background-color:var(--mdc-checkbox-selected-hover-state-layer-color, var(--mat-sys-primary))}.mdc-checkbox .mdc-checkbox__native-control:focus:checked+.mdc-checkbox__ripple{opacity:var(--mdc-checkbox-selected-focus-state-layer-opacity, var(--mat-sys-focus-state-layer-opacity));background-color:var(--mdc-checkbox-selected-focus-state-layer-color, var(--mat-sys-primary))}.mdc-checkbox .mdc-checkbox__native-control:focus:checked~.mat-mdc-checkbox-ripple .mat-ripple-element{background-color:var(--mdc-checkbox-selected-focus-state-layer-color, var(--mat-sys-primary))}.mdc-checkbox:active>.mdc-checkbox__native-control:checked+.mdc-checkbox__ripple{opacity:var(--mdc-checkbox-selected-pressed-state-layer-opacity, var(--mat-sys-pressed-state-layer-opacity));background-color:var(--mdc-checkbox-selected-pressed-state-layer-color, var(--mat-sys-on-surface))}.mdc-checkbox:active>.mdc-checkbox__native-control:checked~.mat-mdc-checkbox-ripple .mat-ripple-element{background-color:var(--mdc-checkbox-selected-pressed-state-layer-color, var(--mat-sys-on-surface))}.mdc-checkbox--disabled.mat-mdc-checkbox-disabled-interactive .mdc-checkbox .mdc-checkbox__native-control~.mat-mdc-checkbox-ripple .mat-ripple-element,.mdc-checkbox--disabled.mat-mdc-checkbox-disabled-interactive .mdc-checkbox .mdc-checkbox__native-control+.mdc-checkbox__ripple{background-color:var(--mdc-checkbox-unselected-hover-state-layer-color, var(--mat-sys-on-surface))}.mdc-checkbox .mdc-checkbox__native-control{position:absolute;margin:0;padding:0;opacity:0;cursor:inherit;width:var(--mdc-checkbox-state-layer-size, 40px);height:var(--mdc-checkbox-state-layer-size, 40px);top:calc((var(--mdc-checkbox-state-layer-size, 40px) - var(--mdc-checkbox-state-layer-size, 40px))/2);right:calc((var(--mdc-checkbox-state-layer-size, 40px) - var(--mdc-checkbox-state-layer-size, 40px))/2);left:calc((var(--mdc-checkbox-state-layer-size, 40px) - var(--mdc-checkbox-state-layer-size, 40px))/2)}.mdc-checkbox--disabled{cursor:default;pointer-events:none}@media(forced-colors: active){.mdc-checkbox--disabled{opacity:.5}}.mdc-checkbox__background{display:inline-flex;position:absolute;align-items:center;justify-content:center;box-sizing:border-box;width:18px;height:18px;border:2px solid currentColor;border-radius:2px;background-color:rgba(0,0,0,0);pointer-events:none;will-change:background-color,border-color;transition:background-color 90ms cubic-bezier(0.4, 0, 0.6, 1),border-color 90ms cubic-bezier(0.4, 0, 0.6, 1);-webkit-print-color-adjust:exact;color-adjust:exact;border-color:var(--mdc-checkbox-unselected-icon-color, var(--mat-sys-on-surface-variant));top:calc((var(--mdc-checkbox-state-layer-size, 40px) - 18px)/2);left:calc((var(--mdc-checkbox-state-layer-size, 40px) - 18px)/2)}.mdc-checkbox__native-control:enabled:checked~.mdc-checkbox__background,.mdc-checkbox__native-control:enabled:indeterminate~.mdc-checkbox__background{border-color:var(--mdc-checkbox-selected-icon-color, var(--mat-sys-primary));background-color:var(--mdc-checkbox-selected-icon-color, var(--mat-sys-primary))}.mdc-checkbox--disabled .mdc-checkbox__background{border-color:var(--mdc-checkbox-disabled-unselected-icon-color, color-mix(in srgb, var(--mat-sys-on-surface) 38%, transparent))}.mdc-checkbox__native-control:disabled:checked~.mdc-checkbox__background,.mdc-checkbox__native-control:disabled:indeterminate~.mdc-checkbox__background{background-color:var(--mdc-checkbox-disabled-selected-icon-color, color-mix(in srgb, var(--mat-sys-on-surface) 38%, transparent));border-color:rgba(0,0,0,0)}.mdc-checkbox:hover>.mdc-checkbox__native-control:not(:checked)~.mdc-checkbox__background,.mdc-checkbox:hover>.mdc-checkbox__native-control:not(:indeterminate)~.mdc-checkbox__background{border-color:var(--mdc-checkbox-unselected-hover-icon-color, var(--mat-sys-on-surface));background-color:rgba(0,0,0,0)}.mdc-checkbox:hover>.mdc-checkbox__native-control:checked~.mdc-checkbox__background,.mdc-checkbox:hover>.mdc-checkbox__native-control:indeterminate~.mdc-checkbox__background{border-color:var(--mdc-checkbox-selected-hover-icon-color, var(--mat-sys-primary));background-color:var(--mdc-checkbox-selected-hover-icon-color, var(--mat-sys-primary))}.mdc-checkbox__native-control:focus:focus:not(:checked)~.mdc-checkbox__background,.mdc-checkbox__native-control:focus:focus:not(:indeterminate)~.mdc-checkbox__background{border-color:var(--mdc-checkbox-unselected-focus-icon-color, var(--mat-sys-on-surface))}.mdc-checkbox__native-control:focus:focus:checked~.mdc-checkbox__background,.mdc-checkbox__native-control:focus:focus:indeterminate~.mdc-checkbox__background{border-color:var(--mdc-checkbox-selected-focus-icon-color, var(--mat-sys-primary));background-color:var(--mdc-checkbox-selected-focus-icon-color, var(--mat-sys-primary))}.mdc-checkbox--disabled.mat-mdc-checkbox-disabled-interactive .mdc-checkbox:hover>.mdc-checkbox__native-control~.mdc-checkbox__background,.mdc-checkbox--disabled.mat-mdc-checkbox-disabled-interactive .mdc-checkbox .mdc-checkbox__native-control:focus~.mdc-checkbox__background,.mdc-checkbox--disabled.mat-mdc-checkbox-disabled-interactive .mdc-checkbox__background{border-color:var(--mdc-checkbox-disabled-unselected-icon-color, color-mix(in srgb, var(--mat-sys-on-surface) 38%, transparent))}.mdc-checkbox--disabled.mat-mdc-checkbox-disabled-interactive .mdc-checkbox__native-control:checked~.mdc-checkbox__background,.mdc-checkbox--disabled.mat-mdc-checkbox-disabled-interactive .mdc-checkbox__native-control:indeterminate~.mdc-checkbox__background{background-color:var(--mdc-checkbox-disabled-selected-icon-color, color-mix(in srgb, var(--mat-sys-on-surface) 38%, transparent));border-color:rgba(0,0,0,0)}.mdc-checkbox__checkmark{position:absolute;top:0;right:0;bottom:0;left:0;width:100%;opacity:0;transition:opacity 180ms cubic-bezier(0.4, 0, 0.6, 1);color:var(--mdc-checkbox-selected-checkmark-color, var(--mat-sys-on-primary))}@media(forced-colors: active){.mdc-checkbox__checkmark{color:CanvasText}}.mdc-checkbox--disabled .mdc-checkbox__checkmark,.mdc-checkbox--disabled.mat-mdc-checkbox-disabled-interactive .mdc-checkbox__checkmark{color:var(--mdc-checkbox-disabled-selected-checkmark-color, var(--mat-sys-surface))}@media(forced-colors: active){.mdc-checkbox--disabled .mdc-checkbox__checkmark,.mdc-checkbox--disabled.mat-mdc-checkbox-disabled-interactive .mdc-checkbox__checkmark{color:CanvasText}}.mdc-checkbox__checkmark-path{transition:stroke-dashoffset 180ms cubic-bezier(0.4, 0, 0.6, 1);stroke:currentColor;stroke-width:3.12px;stroke-dashoffset:29.7833385;stroke-dasharray:29.7833385}.mdc-checkbox__mixedmark{width:100%;height:0;transform:scaleX(0) rotate(0deg);border-width:1px;border-style:solid;opacity:0;transition:opacity 90ms cubic-bezier(0.4, 0, 0.6, 1),transform 90ms cubic-bezier(0.4, 0, 0.6, 1);border-color:var(--mdc-checkbox-selected-checkmark-color, var(--mat-sys-on-primary))}@media(forced-colors: active){.mdc-checkbox__mixedmark{margin:0 1px}}.mdc-checkbox--disabled .mdc-checkbox__mixedmark,.mdc-checkbox--disabled.mat-mdc-checkbox-disabled-interactive .mdc-checkbox__mixedmark{border-color:var(--mdc-checkbox-disabled-selected-checkmark-color, var(--mat-sys-surface))}.mdc-checkbox--anim-unchecked-checked .mdc-checkbox__background,.mdc-checkbox--anim-unchecked-indeterminate .mdc-checkbox__background,.mdc-checkbox--anim-checked-unchecked .mdc-checkbox__background,.mdc-checkbox--anim-indeterminate-unchecked .mdc-checkbox__background{animation-duration:180ms;animation-timing-function:linear}.mdc-checkbox--anim-unchecked-checked .mdc-checkbox__checkmark-path{animation:mdc-checkbox-unchecked-checked-checkmark-path 180ms linear;transition:none}.mdc-checkbox--anim-unchecked-indeterminate .mdc-checkbox__mixedmark{animation:mdc-checkbox-unchecked-indeterminate-mixedmark 90ms linear;transition:none}.mdc-checkbox--anim-checked-unchecked .mdc-checkbox__checkmark-path{animation:mdc-checkbox-checked-unchecked-checkmark-path 90ms linear;transition:none}.mdc-checkbox--anim-checked-indeterminate .mdc-checkbox__checkmark{animation:mdc-checkbox-checked-indeterminate-checkmark 90ms linear;transition:none}.mdc-checkbox--anim-checked-indeterminate .mdc-checkbox__mixedmark{animation:mdc-checkbox-checked-indeterminate-mixedmark 90ms linear;transition:none}.mdc-checkbox--anim-indeterminate-checked .mdc-checkbox__checkmark{animation:mdc-checkbox-indeterminate-checked-checkmark 500ms linear;transition:none}.mdc-checkbox--anim-indeterminate-checked .mdc-checkbox__mixedmark{animation:mdc-checkbox-indeterminate-checked-mixedmark 500ms linear;transition:none}.mdc-checkbox--anim-indeterminate-unchecked .mdc-checkbox__mixedmark{animation:mdc-checkbox-indeterminate-unchecked-mixedmark 300ms linear;transition:none}.mdc-checkbox__native-control:checked~.mdc-checkbox__background,.mdc-checkbox__native-control:indeterminate~.mdc-checkbox__background{transition:border-color 90ms cubic-bezier(0, 0, 0.2, 1),background-color 90ms cubic-bezier(0, 0, 0.2, 1)}.mdc-checkbox__native-control:checked~.mdc-checkbox__background>.mdc-checkbox__checkmark>.mdc-checkbox__checkmark-path,.mdc-checkbox__native-control:indeterminate~.mdc-checkbox__background>.mdc-checkbox__checkmark>.mdc-checkbox__checkmark-path{stroke-dashoffset:0}.mdc-checkbox__native-control:checked~.mdc-checkbox__background>.mdc-checkbox__checkmark{transition:opacity 180ms cubic-bezier(0, 0, 0.2, 1),transform 180ms cubic-bezier(0, 0, 0.2, 1);opacity:1}.mdc-checkbox__native-control:checked~.mdc-checkbox__background>.mdc-checkbox__mixedmark{transform:scaleX(1) rotate(-45deg)}.mdc-checkbox__native-control:indeterminate~.mdc-checkbox__background>.mdc-checkbox__checkmark{transform:rotate(45deg);opacity:0;transition:opacity 90ms cubic-bezier(0.4, 0, 0.6, 1),transform 90ms cubic-bezier(0.4, 0, 0.6, 1)}.mdc-checkbox__native-control:indeterminate~.mdc-checkbox__background>.mdc-checkbox__mixedmark{transform:scaleX(1) rotate(0deg);opacity:1}@keyframes mdc-checkbox-unchecked-checked-checkmark-path{0%,50%{stroke-dashoffset:29.7833385}50%{animation-timing-function:cubic-bezier(0, 0, 0.2, 1)}100%{stroke-dashoffset:0}}@keyframes mdc-checkbox-unchecked-indeterminate-mixedmark{0%,68.2%{transform:scaleX(0)}68.2%{animation-timing-function:cubic-bezier(0, 0, 0, 1)}100%{transform:scaleX(1)}}@keyframes mdc-checkbox-checked-unchecked-checkmark-path{from{animation-timing-function:cubic-bezier(0.4, 0, 1, 1);opacity:1;stroke-dashoffset:0}to{opacity:0;stroke-dashoffset:-29.7833385}}@keyframes mdc-checkbox-checked-indeterminate-checkmark{from{animation-timing-function:cubic-bezier(0, 0, 0.2, 1);transform:rotate(0deg);opacity:1}to{transform:rotate(45deg);opacity:0}}@keyframes mdc-checkbox-indeterminate-checked-checkmark{from{animation-timing-function:cubic-bezier(0.14, 0, 0, 1);transform:rotate(45deg);opacity:0}to{transform:rotate(360deg);opacity:1}}@keyframes mdc-checkbox-checked-indeterminate-mixedmark{from{animation-timing-function:cubic-bezier(0, 0, 0.2, 1);transform:rotate(-45deg);opacity:0}to{transform:rotate(0deg);opacity:1}}@keyframes mdc-checkbox-indeterminate-checked-mixedmark{from{animation-timing-function:cubic-bezier(0.14, 0, 0, 1);transform:rotate(0deg);opacity:1}to{transform:rotate(315deg);opacity:0}}@keyframes mdc-checkbox-indeterminate-unchecked-mixedmark{0%{animation-timing-function:linear;transform:scaleX(1);opacity:1}32.8%,100%{transform:scaleX(0);opacity:0}}.mat-mdc-checkbox{display:inline-block;position:relative;-webkit-tap-highlight-color:rgba(0,0,0,0)}.mat-mdc-checkbox._mat-animation-noopable>.mat-internal-form-field>.mdc-checkbox>.mat-mdc-checkbox-touch-target,.mat-mdc-checkbox._mat-animation-noopable>.mat-internal-form-field>.mdc-checkbox>.mdc-checkbox__native-control,.mat-mdc-checkbox._mat-animation-noopable>.mat-internal-form-field>.mdc-checkbox>.mdc-checkbox__ripple,.mat-mdc-checkbox._mat-animation-noopable>.mat-internal-form-field>.mdc-checkbox>.mat-mdc-checkbox-ripple::before,.mat-mdc-checkbox._mat-animation-noopable>.mat-internal-form-field>.mdc-checkbox>.mdc-checkbox__background,.mat-mdc-checkbox._mat-animation-noopable>.mat-internal-form-field>.mdc-checkbox>.mdc-checkbox__background>.mdc-checkbox__checkmark,.mat-mdc-checkbox._mat-animation-noopable>.mat-internal-form-field>.mdc-checkbox>.mdc-checkbox__background>.mdc-checkbox__checkmark>.mdc-checkbox__checkmark-path,.mat-mdc-checkbox._mat-animation-noopable>.mat-internal-form-field>.mdc-checkbox>.mdc-checkbox__background>.mdc-checkbox__mixedmark{transition:none !important;animation:none !important}.mat-mdc-checkbox label{cursor:pointer}.mat-mdc-checkbox .mat-internal-form-field{color:var(--mat-checkbox-label-text-color, var(--mat-sys-on-surface));font-family:var(--mat-checkbox-label-text-font, var(--mat-sys-body-medium-font));line-height:var(--mat-checkbox-label-text-line-height, var(--mat-sys-body-medium-line-height));font-size:var(--mat-checkbox-label-text-size, var(--mat-sys-body-medium-size));letter-spacing:var(--mat-checkbox-label-text-tracking, var(--mat-sys-body-medium-tracking));font-weight:var(--mat-checkbox-label-text-weight, var(--mat-sys-body-medium-weight))}.mat-mdc-checkbox.mat-mdc-checkbox-disabled.mat-mdc-checkbox-disabled-interactive{pointer-events:auto}.mat-mdc-checkbox.mat-mdc-checkbox-disabled.mat-mdc-checkbox-disabled-interactive input{cursor:default}.mat-mdc-checkbox.mat-mdc-checkbox-disabled label{cursor:default;color:var(--mat-checkbox-disabled-label-color, color-mix(in srgb, var(--mat-sys-on-surface) 38%, transparent))}.mat-mdc-checkbox label:empty{display:none}.mat-mdc-checkbox .mdc-checkbox__ripple{opacity:0}.mat-mdc-checkbox .mat-mdc-checkbox-ripple,.mdc-checkbox__ripple{top:0;left:0;right:0;bottom:0;position:absolute;border-radius:50%;pointer-events:none}.mat-mdc-checkbox .mat-mdc-checkbox-ripple:not(:empty),.mdc-checkbox__ripple:not(:empty){transform:translateZ(0)}.mat-mdc-checkbox-ripple .mat-ripple-element{opacity:.1}.mat-mdc-checkbox-touch-target{position:absolute;top:50%;left:50%;height:48px;width:48px;transform:translate(-50%, -50%);display:var(--mat-checkbox-touch-target-display, block)}.mat-mdc-checkbox .mat-mdc-checkbox-ripple::before{border-radius:50%}.mdc-checkbox__native-control:focus~.mat-focus-indicator::before{content:""}'],encapsulation:2,changeDetection:0})}return t})();var haA=(()=>{class t{static \u0275fac=function(i){return new(i||t)};static \u0275mod=ge({type:t});static \u0275inj=le({imports:[gh,Ve,Ve]})}return t})();var qJA=[[["caption"]],[["colgroup"],["col"]],"*"],VJA=["caption","colgroup, col","*"];function ZJA(t,e){t&1&&xe(0,2)}function WJA(t,e){t&1&&(S(0,"thead",0),Mr(1,1),R(),S(2,"tbody",0),Mr(3,2)(4,3),R(),S(5,"tfoot",0),Mr(6,4),R())}function XJA(t,e){t&1&&Mr(0,1)(1,2)(2,3)(3,4)}var Ll=new BA("CDK_TABLE");var Uy=(()=>{class t{template=m(vn);constructor(){}static \u0275fac=function(i){return new(i||t)};static \u0275dir=OA({type:t,selectors:[["","cdkCellDef",""]]})}return t})(),Ky=(()=>{class t{template=m(vn);constructor(){}static \u0275fac=function(i){return new(i||t)};static \u0275dir=OA({type:t,selectors:[["","cdkHeaderCellDef",""]]})}return t})(),faA=(()=>{class t{template=m(vn);constructor(){}static \u0275fac=function(i){return new(i||t)};static \u0275dir=OA({type:t,selectors:[["","cdkFooterCellDef",""]]})}return t})(),Ih=(()=>{class t{_table=m(Ll,{optional:!0});_hasStickyChanged=!1;get name(){return this._name}set name(A){this._setNameInput(A)}_name;get sticky(){return this._sticky}set sticky(A){A!==this._sticky&&(this._sticky=A,this._hasStickyChanged=!0)}_sticky=!1;get stickyEnd(){return this._stickyEnd}set stickyEnd(A){A!==this._stickyEnd&&(this._stickyEnd=A,this._hasStickyChanged=!0)}_stickyEnd=!1;cell;headerCell;footerCell;cssClassFriendlyName;_columnCssClassName;constructor(){}hasStickyChanged(){let A=this._hasStickyChanged;return this.resetStickyChanged(),A}resetStickyChanged(){this._hasStickyChanged=!1}_updateColumnCssClassName(){this._columnCssClassName=[`cdk-column-${this.cssClassFriendlyName}`]}_setNameInput(A){A&&(this._name=A,this.cssClassFriendlyName=A.replace(/[^a-z0-9_-]/gi,"-"),this._updateColumnCssClassName())}static \u0275fac=function(i){return new(i||t)};static \u0275dir=OA({type:t,selectors:[["","cdkColumnDef",""]],contentQueries:function(i,n,o){if(i&1&&(Ii(o,Uy,5),Ii(o,Ky,5),Ii(o,faA,5)),i&2){let r;$A(r=Ae())&&(n.cell=r.first),$A(r=Ae())&&(n.headerCell=r.first),$A(r=Ae())&&(n.footerCell=r.first)}},inputs:{name:[0,"cdkColumnDef","name"],sticky:[2,"sticky","sticky",ae],stickyEnd:[2,"stickyEnd","stickyEnd",ae]},features:[ct([{provide:"MAT_SORT_HEADER_COLUMN_DEF",useExisting:t}])]})}return t})(),Fy=class{constructor(e,A){A.nativeElement.classList.add(...e._columnCssClassName)}},maA=(()=>{class t extends Fy{constructor(){super(m(Ih),m(te))}static \u0275fac=function(i){return new(i||t)};static \u0275dir=OA({type:t,selectors:[["cdk-header-cell"],["th","cdk-header-cell",""]],hostAttrs:["role","columnheader",1,"cdk-header-cell"],features:[et]})}return t})();var paA=(()=>{class t extends Fy{constructor(){let A=m(Ih),i=m(te);super(A,i);let n=A._table?._getCellRole();n&&i.nativeElement.setAttribute("role",n)}static \u0275fac=function(i){return new(i||t)};static \u0275dir=OA({type:t,selectors:[["cdk-cell"],["td","cdk-cell",""]],hostAttrs:[1,"cdk-cell"],features:[et]})}return t})(),Ny=class{tasks=[];endTasks=[]},_y=new BA("_COALESCED_STYLE_SCHEDULER"),cG=(()=>{class t{_currentSchedule=null;_ngZone=m(de);constructor(){}schedule(A){this._createScheduleIfNeeded(),this._currentSchedule.tasks.push(A)}scheduleEnd(A){this._createScheduleIfNeeded(),this._currentSchedule.endTasks.push(A)}_createScheduleIfNeeded(){this._currentSchedule||(this._currentSchedule=new Ny,this._ngZone.runOutsideAngular(()=>queueMicrotask(()=>{for(;this._currentSchedule.tasks.length||this._currentSchedule.endTasks.length;){let A=this._currentSchedule;this._currentSchedule=new Ny;for(let i of A.tasks)i();for(let i of A.endTasks)i()}this._currentSchedule=null})))}static \u0275fac=function(i){return new(i||t)};static \u0275prov=SA({token:t,factory:t.\u0275fac})}return t})();var lG=(()=>{class t{template=m(vn);_differs=m(Xl);columns;_columnsDiffer;constructor(){}ngOnChanges(A){if(!this._columnsDiffer){let i=A.columns&&A.columns.currentValue||[];this._columnsDiffer=this._differs.find(i).create(),this._columnsDiffer.diff(i)}}getColumnsDiff(){return this._columnsDiffer.diff(this.columns)}extractCellTemplate(A){return this instanceof X3?A.headerCell.template:this instanceof gG?A.footerCell.template:A.cell.template}static \u0275fac=function(i){return new(i||t)};static \u0275dir=OA({type:t,features:[Kt]})}return t})(),X3=(()=>{class t extends lG{_table=m(Ll,{optional:!0});_hasStickyChanged=!1;get sticky(){return this._sticky}set sticky(A){A!==this._sticky&&(this._sticky=A,this._hasStickyChanged=!0)}_sticky=!1;constructor(){super(m(vn),m(Xl))}ngOnChanges(A){super.ngOnChanges(A)}hasStickyChanged(){let A=this._hasStickyChanged;return this.resetStickyChanged(),A}resetStickyChanged(){this._hasStickyChanged=!1}static \u0275fac=function(i){return new(i||t)};static \u0275dir=OA({type:t,selectors:[["","cdkHeaderRowDef",""]],inputs:{columns:[0,"cdkHeaderRowDef","columns"],sticky:[2,"cdkHeaderRowDefSticky","sticky",ae]},features:[et,Kt]})}return t})(),gG=(()=>{class t extends lG{_table=m(Ll,{optional:!0});_hasStickyChanged=!1;get sticky(){return this._sticky}set sticky(A){A!==this._sticky&&(this._sticky=A,this._hasStickyChanged=!0)}_sticky=!1;constructor(){super(m(vn),m(Xl))}ngOnChanges(A){super.ngOnChanges(A)}hasStickyChanged(){let A=this._hasStickyChanged;return this.resetStickyChanged(),A}resetStickyChanged(){this._hasStickyChanged=!1}static \u0275fac=function(i){return new(i||t)};static \u0275dir=OA({type:t,selectors:[["","cdkFooterRowDef",""]],inputs:{columns:[0,"cdkFooterRowDef","columns"],sticky:[2,"cdkFooterRowDefSticky","sticky",ae]},features:[et,Kt]})}return t})(),Yy=(()=>{class t extends lG{_table=m(Ll,{optional:!0});when;constructor(){super(m(vn),m(Xl))}static \u0275fac=function(i){return new(i||t)};static \u0275dir=OA({type:t,selectors:[["","cdkRowDef",""]],inputs:{columns:[0,"cdkRowDefColumns","columns"],when:[0,"cdkRowDefWhen","when"]},features:[et]})}return t})(),OC=(()=>{class t{_viewContainer=m(Un);cells;context;static mostRecentCellOutlet=null;constructor(){t.mostRecentCellOutlet=this}ngOnDestroy(){t.mostRecentCellOutlet===this&&(t.mostRecentCellOutlet=null)}static \u0275fac=function(i){return new(i||t)};static \u0275dir=OA({type:t,selectors:[["","cdkCellOutlet",""]]})}return t})(),IG=(()=>{class t{static \u0275fac=function(i){return new(i||t)};static \u0275cmp=YA({type:t,selectors:[["cdk-header-row"],["tr","cdk-header-row",""]],hostAttrs:["role","row",1,"cdk-header-row"],decls:1,vars:0,consts:[["cdkCellOutlet",""]],template:function(i,n){i&1&&Mr(0,0)},dependencies:[OC],encapsulation:2})}return t})();var CG=(()=>{class t{static \u0275fac=function(i){return new(i||t)};static \u0275cmp=YA({type:t,selectors:[["cdk-row"],["tr","cdk-row",""]],hostAttrs:["role","row",1,"cdk-row"],decls:1,vars:0,consts:[["cdkCellOutlet",""]],template:function(i,n){i&1&&Mr(0,0)},dependencies:[OC],encapsulation:2})}return t})(),waA=(()=>{class t{templateRef=m(vn);_contentClassName="cdk-no-data-row";constructor(){}static \u0275fac=function(i){return new(i||t)};static \u0275dir=OA({type:t,selectors:[["ng-template","cdkNoDataRow",""]]})}return t})(),QaA=["top","bottom","left","right"],aG=class{_isNativeHtmlTable;_stickCellCss;direction;_coalescedStyleScheduler;_isBrowser;_needsPositionStickyOnElement;_positionListener;_tableInjector;_elemSizeCache=new WeakMap;_resizeObserver=globalThis?.ResizeObserver?new globalThis.ResizeObserver(e=>this._updateCachedSizes(e)):null;_updatedStickyColumnsParamsToReplay=[];_stickyColumnsReplayTimeout=null;_cachedCellWidths=[];_borderCellCss;_destroyed=!1;constructor(e,A,i,n,o=!0,r=!0,s,a){this._isNativeHtmlTable=e,this._stickCellCss=A,this.direction=i,this._coalescedStyleScheduler=n,this._isBrowser=o,this._needsPositionStickyOnElement=r,this._positionListener=s,this._tableInjector=a,this._borderCellCss={top:`${A}-border-elem-top`,bottom:`${A}-border-elem-bottom`,left:`${A}-border-elem-left`,right:`${A}-border-elem-right`}}clearStickyPositioning(e,A){(A.includes("left")||A.includes("right"))&&this._removeFromStickyColumnReplayQueue(e);let i=[];for(let n of e)n.nodeType===n.ELEMENT_NODE&&i.push(n,...Array.from(n.children));this._afterNextRender({write:()=>{for(let n of i)this._removeStickyStyle(n,A)}})}updateStickyColumns(e,A,i,n=!0,o=!0){if(!e.length||!this._isBrowser||!(A.some(Q=>Q)||i.some(Q=>Q))){this._positionListener?.stickyColumnsUpdated({sizes:[]}),this._positionListener?.stickyEndColumnsUpdated({sizes:[]});return}let r=e[0],s=r.children.length,a=this.direction==="rtl",c=a?"right":"left",l=a?"left":"right",I=A.lastIndexOf(!0),C=i.indexOf(!0),d,B,E;o&&this._updateStickyColumnReplayQueue({rows:[...e],stickyStartStates:[...A],stickyEndStates:[...i]}),this._afterNextRender({earlyRead:()=>{d=this._getCellWidths(r,n),B=this._getStickyStartColumnPositions(d,A),E=this._getStickyEndColumnPositions(d,i)},write:()=>{for(let Q of e)for(let u=0;u<s;u++){let v=Q.children[u];A[u]&&this._addStickyStyle(v,c,B[u],u===I),i[u]&&this._addStickyStyle(v,l,E[u],u===C)}this._positionListener&&d.some(Q=>!!Q)&&(this._positionListener.stickyColumnsUpdated({sizes:I===-1?[]:d.slice(0,I+1).map((Q,u)=>A[u]?Q:null)}),this._positionListener.stickyEndColumnsUpdated({sizes:C===-1?[]:d.slice(C).map((Q,u)=>i[u+C]?Q:null).reverse()}))}})}stickRows(e,A,i){if(!this._isBrowser)return;let n=i==="bottom"?e.slice().reverse():e,o=i==="bottom"?A.slice().reverse():A,r=[],s=[],a=[];this._afterNextRender({earlyRead:()=>{for(let c=0,l=0;c<n.length;c++){if(!o[c])continue;r[c]=l;let I=n[c];a[c]=this._isNativeHtmlTable?Array.from(I.children):[I];let C=this._retrieveElementSize(I).height;l+=C,s[c]=C}},write:()=>{let c=o.lastIndexOf(!0);for(let l=0;l<n.length;l++){if(!o[l])continue;let I=r[l],C=l===c;for(let d of a[l])this._addStickyStyle(d,i,I,C)}i==="top"?this._positionListener?.stickyHeaderRowsUpdated({sizes:s,offsets:r,elements:a}):this._positionListener?.stickyFooterRowsUpdated({sizes:s,offsets:r,elements:a})}})}updateStickyFooterContainer(e,A){this._isNativeHtmlTable&&this._afterNextRender({write:()=>{let i=e.querySelector("tfoot");i&&(A.some(n=>!n)?this._removeStickyStyle(i,["bottom"]):this._addStickyStyle(i,"bottom",0,!1))}})}destroy(){this._stickyColumnsReplayTimeout&&clearTimeout(this._stickyColumnsReplayTimeout),this._resizeObserver?.disconnect(),this._destroyed=!0}_removeStickyStyle(e,A){for(let n of A)e.style[n]="",e.classList.remove(this._borderCellCss[n]);QaA.some(n=>A.indexOf(n)===-1&&e.style[n])?e.style.zIndex=this._getCalculatedZIndex(e):(e.style.zIndex="",this._needsPositionStickyOnElement&&(e.style.position=""),e.classList.remove(this._stickCellCss))}_addStickyStyle(e,A,i,n){e.classList.add(this._stickCellCss),n&&e.classList.add(this._borderCellCss[A]),e.style[A]=`${i}px`,e.style.zIndex=this._getCalculatedZIndex(e),this._needsPositionStickyOnElement&&(e.style.cssText+="position: -webkit-sticky; position: sticky; ")}_getCalculatedZIndex(e){let A={top:100,bottom:10,left:1,right:1},i=0;for(let n of QaA)e.style[n]&&(i+=A[n]);return i?`${i}`:""}_getCellWidths(e,A=!0){if(!A&&this._cachedCellWidths.length)return this._cachedCellWidths;let i=[],n=e.children;for(let o=0;o<n.length;o++){let r=n[o];i.push(this._retrieveElementSize(r).width)}return this._cachedCellWidths=i,i}_getStickyStartColumnPositions(e,A){let i=[],n=0;for(let o=0;o<e.length;o++)A[o]&&(i[o]=n,n+=e[o]);return i}_getStickyEndColumnPositions(e,A){let i=[],n=0;for(let o=e.length;o>0;o--)A[o]&&(i[o]=n,n+=e[o]);return i}_retrieveElementSize(e){let A=this._elemSizeCache.get(e);if(A)return A;let i=e.getBoundingClientRect(),n={width:i.width,height:i.height};return this._resizeObserver&&(this._elemSizeCache.set(e,n),this._resizeObserver.observe(e,{box:"border-box"})),n}_updateStickyColumnReplayQueue(e){this._removeFromStickyColumnReplayQueue(e.rows),this._stickyColumnsReplayTimeout||this._updatedStickyColumnsParamsToReplay.push(e)}_removeFromStickyColumnReplayQueue(e){let A=new Set(e);for(let i of this._updatedStickyColumnsParamsToReplay)i.rows=i.rows.filter(n=>!A.has(n));this._updatedStickyColumnsParamsToReplay=this._updatedStickyColumnsParamsToReplay.filter(i=>!!i.rows.length)}_updateCachedSizes(e){let A=!1;for(let i of e){let n=i.borderBoxSize?.length?{width:i.borderBoxSize[0].inlineSize,height:i.borderBoxSize[0].blockSize}:{width:i.contentRect.width,height:i.contentRect.height};n.width!==this._elemSizeCache.get(i.target)?.width&&$JA(i.target)&&(A=!0),this._elemSizeCache.set(i.target,n)}A&&this._updatedStickyColumnsParamsToReplay.length&&(this._stickyColumnsReplayTimeout&&clearTimeout(this._stickyColumnsReplayTimeout),this._stickyColumnsReplayTimeout=setTimeout(()=>{if(!this._destroyed){for(let i of this._updatedStickyColumnsParamsToReplay)this.updateStickyColumns(i.rows,i.stickyStartStates,i.stickyEndStates,!0,!1);this._updatedStickyColumnsParamsToReplay=[],this._stickyColumnsReplayTimeout=null}},0))}_afterNextRender(e){this._tableInjector?Vo(e,{injector:this._tableInjector}):this._coalescedStyleScheduler.schedule(()=>{e.earlyRead?.(),e.write()})}};function $JA(t){return["cdk-cell","cdk-header-cell","cdk-footer-cell"].some(e=>t.classList.contains(e))}var Gy=new BA("CDK_SPL");var dG=(()=>{class t{viewContainer=m(Un);elementRef=m(te);constructor(){let A=m(Ll);A._rowOutlet=this,A._outletAssigned()}static \u0275fac=function(i){return new(i||t)};static \u0275dir=OA({type:t,selectors:[["","rowOutlet",""]]})}return t})(),BG=(()=>{class t{viewContainer=m(Un);elementRef=m(te);constructor(){let A=m(Ll);A._headerRowOutlet=this,A._outletAssigned()}static \u0275fac=function(i){return new(i||t)};static \u0275dir=OA({type:t,selectors:[["","headerRowOutlet",""]]})}return t})(),EG=(()=>{class t{viewContainer=m(Un);elementRef=m(te);constructor(){let A=m(Ll);A._footerRowOutlet=this,A._outletAssigned()}static \u0275fac=function(i){return new(i||t)};static \u0275dir=OA({type:t,selectors:[["","footerRowOutlet",""]]})}return t})(),hG=(()=>{class t{viewContainer=m(Un);elementRef=m(te);constructor(){let A=m(Ll);A._noDataRowOutlet=this,A._outletAssigned()}static \u0275fac=function(i){return new(i||t)};static \u0275dir=OA({type:t,selectors:[["","noDataRowOutlet",""]]})}return t})();var QG=(()=>{class t{_differs=m(Xl);_changeDetectorRef=m(lt);_elementRef=m(te);_dir=m(bo,{optional:!0});_platform=m(Zt);_viewRepeater=m(Qu);_coalescedStyleScheduler=m(_y);_viewportRuler=m(mc);_stickyPositioningListener=m(Gy,{optional:!0,skipSelf:!0});_document=m(tt);_data;_onDestroy=new HA;_renderRows;_renderChangeSubscription;_columnDefsByName=new Map;_rowDefs;_headerRowDefs;_footerRowDefs;_dataDiffer;_defaultRowDef;_customColumnDefs=new Set;_customRowDefs=new Set;_customHeaderRowDefs=new Set;_customFooterRowDefs=new Set;_customNoDataRow;_headerRowDefChanged=!0;_footerRowDefChanged=!0;_stickyColumnStylesNeedReset=!0;_forceRecalculateCellWidths=!0;_cachedRenderRowsMap=new Map;_isNativeHtmlTable;_stickyStyler;stickyCssClass="cdk-table-sticky";needsPositionStickyOnElement=!0;_isServer;_isShowingNoDataRow=!1;_hasAllOutlets=!1;_hasInitialized=!1;_getCellRole(){if(this._cellRoleInternal===void 0){let A=this._elementRef.nativeElement.getAttribute("role");return A==="grid"||A==="treegrid"?"gridcell":"cell"}return this._cellRoleInternal}_cellRoleInternal=void 0;get trackBy(){return this._trackByFn}set trackBy(A){this._trackByFn=A}_trackByFn;get dataSource(){return this._dataSource}set dataSource(A){this._dataSource!==A&&this._switchDataSource(A)}_dataSource;get multiTemplateDataRows(){return this._multiTemplateDataRows}set multiTemplateDataRows(A){this._multiTemplateDataRows=A,this._rowOutlet&&this._rowOutlet.viewContainer.length&&(this._forceRenderDataRows(),this.updateStickyColumnStyles())}_multiTemplateDataRows=!1;get fixedLayout(){return this._fixedLayout}set fixedLayout(A){this._fixedLayout=A,this._forceRecalculateCellWidths=!0,this._stickyColumnStylesNeedReset=!0}_fixedLayout=!1;contentChanged=new XA;viewChange=new li({start:0,end:Number.MAX_VALUE});_rowOutlet;_headerRowOutlet;_footerRowOutlet;_noDataRowOutlet;_contentColumnDefs;_contentRowDefs;_contentHeaderRowDefs;_contentFooterRowDefs;_noDataRow;_injector=m(Dt);constructor(){m(new Er("role"),{optional:!0})||this._elementRef.nativeElement.setAttribute("role","table"),this._isServer=!this._platform.isBrowser,this._isNativeHtmlTable=this._elementRef.nativeElement.nodeName==="TABLE"}ngOnInit(){this._setupStickyStyler(),this._dataDiffer=this._differs.find([]).create((A,i)=>this.trackBy?this.trackBy(i.dataIndex,i.data):i),this._viewportRuler.change().pipe(wt(this._onDestroy)).subscribe(()=>{this._forceRecalculateCellWidths=!0})}ngAfterContentInit(){this._hasInitialized=!0}ngAfterContentChecked(){this._canRender()&&this._render()}ngOnDestroy(){this._stickyStyler?.destroy(),[this._rowOutlet?.viewContainer,this._headerRowOutlet?.viewContainer,this._footerRowOutlet?.viewContainer,this._cachedRenderRowsMap,this._customColumnDefs,this._customRowDefs,this._customHeaderRowDefs,this._customFooterRowDefs,this._columnDefsByName].forEach(A=>{A?.clear()}),this._headerRowDefs=[],this._footerRowDefs=[],this._defaultRowDef=null,this._onDestroy.next(),this._onDestroy.complete(),A8(this.dataSource)&&this.dataSource.disconnect(this)}renderRows(){this._renderRows=this._getAllRenderRows();let A=this._dataDiffer.diff(this._renderRows);if(!A){this._updateNoDataRow(),this.contentChanged.next();return}let i=this._rowOutlet.viewContainer;this._viewRepeater.applyChanges(A,i,(n,o,r)=>this._getEmbeddedViewArgs(n.item,r),n=>n.item.data,n=>{n.operation===hB.INSERTED&&n.context&&this._renderCellTemplateForItem(n.record.item.rowDef,n.context)}),this._updateRowIndexContext(),A.forEachIdentityChange(n=>{let o=i.get(n.currentIndex);o.context.$implicit=n.item.data}),this._updateNoDataRow(),this.contentChanged.next(),this.updateStickyColumnStyles()}addColumnDef(A){this._customColumnDefs.add(A)}removeColumnDef(A){this._customColumnDefs.delete(A)}addRowDef(A){this._customRowDefs.add(A)}removeRowDef(A){this._customRowDefs.delete(A)}addHeaderRowDef(A){this._customHeaderRowDefs.add(A),this._headerRowDefChanged=!0}removeHeaderRowDef(A){this._customHeaderRowDefs.delete(A),this._headerRowDefChanged=!0}addFooterRowDef(A){this._customFooterRowDefs.add(A),this._footerRowDefChanged=!0}removeFooterRowDef(A){this._customFooterRowDefs.delete(A),this._footerRowDefChanged=!0}setNoDataRow(A){this._customNoDataRow=A}updateStickyHeaderRowStyles(){let A=this._getRenderedRows(this._headerRowOutlet);if(this._isNativeHtmlTable){let n=uaA(this._headerRowOutlet,"thead");n&&(n.style.display=A.length?"":"none")}let i=this._headerRowDefs.map(n=>n.sticky);this._stickyStyler.clearStickyPositioning(A,["top"]),this._stickyStyler.stickRows(A,i,"top"),this._headerRowDefs.forEach(n=>n.resetStickyChanged())}updateStickyFooterRowStyles(){let A=this._getRenderedRows(this._footerRowOutlet);if(this._isNativeHtmlTable){let n=uaA(this._footerRowOutlet,"tfoot");n&&(n.style.display=A.length?"":"none")}let i=this._footerRowDefs.map(n=>n.sticky);this._stickyStyler.clearStickyPositioning(A,["bottom"]),this._stickyStyler.stickRows(A,i,"bottom"),this._stickyStyler.updateStickyFooterContainer(this._elementRef.nativeElement,i),this._footerRowDefs.forEach(n=>n.resetStickyChanged())}updateStickyColumnStyles(){let A=this._getRenderedRows(this._headerRowOutlet),i=this._getRenderedRows(this._rowOutlet),n=this._getRenderedRows(this._footerRowOutlet);(this._isNativeHtmlTable&&!this._fixedLayout||this._stickyColumnStylesNeedReset)&&(this._stickyStyler.clearStickyPositioning([...A,...i,...n],["left","right"]),this._stickyColumnStylesNeedReset=!1),A.forEach((o,r)=>{this._addStickyColumnStyles([o],this._headerRowDefs[r])}),this._rowDefs.forEach(o=>{let r=[];for(let s=0;s<i.length;s++)this._renderRows[s].rowDef===o&&r.push(i[s]);this._addStickyColumnStyles(r,o)}),n.forEach((o,r)=>{this._addStickyColumnStyles([o],this._footerRowDefs[r])}),Array.from(this._columnDefsByName.values()).forEach(o=>o.resetStickyChanged())}_outletAssigned(){!this._hasAllOutlets&&this._rowOutlet&&this._headerRowOutlet&&this._footerRowOutlet&&this._noDataRowOutlet&&(this._hasAllOutlets=!0,this._canRender()&&this._render())}_canRender(){return this._hasAllOutlets&&this._hasInitialized}_render(){this._cacheRowDefs(),this._cacheColumnDefs(),!this._headerRowDefs.length&&!this._footerRowDefs.length&&this._rowDefs.length;let i=this._renderUpdatedColumns()||this._headerRowDefChanged||this._footerRowDefChanged;this._stickyColumnStylesNeedReset=this._stickyColumnStylesNeedReset||i,this._forceRecalculateCellWidths=i,this._headerRowDefChanged&&(this._forceRenderHeaderRows(),this._headerRowDefChanged=!1),this._footerRowDefChanged&&(this._forceRenderFooterRows(),this._footerRowDefChanged=!1),this.dataSource&&this._rowDefs.length>0&&!this._renderChangeSubscription?this._observeRenderChanges():this._stickyColumnStylesNeedReset&&this.updateStickyColumnStyles(),this._checkStickyStates()}_getAllRenderRows(){let A=[],i=this._cachedRenderRowsMap;this._cachedRenderRowsMap=new Map;for(let n=0;n<this._data.length;n++){let o=this._data[n],r=this._getRenderRowsForData(o,n,i.get(o));this._cachedRenderRowsMap.has(o)||this._cachedRenderRowsMap.set(o,new WeakMap);for(let s=0;s<r.length;s++){let a=r[s],c=this._cachedRenderRowsMap.get(a.data);c.has(a.rowDef)?c.get(a.rowDef).push(a):c.set(a.rowDef,[a]),A.push(a)}}return A}_getRenderRowsForData(A,i,n){return this._getRowDefs(A,i).map(r=>{let s=n&&n.has(r)?n.get(r):[];if(s.length){let a=s.shift();return a.dataIndex=i,a}else return{data:A,rowDef:r,dataIndex:i}})}_cacheColumnDefs(){this._columnDefsByName.clear(),xy(this._getOwnDefs(this._contentColumnDefs),this._customColumnDefs).forEach(i=>{this._columnDefsByName.has(i.name),this._columnDefsByName.set(i.name,i)})}_cacheRowDefs(){this._headerRowDefs=xy(this._getOwnDefs(this._contentHeaderRowDefs),this._customHeaderRowDefs),this._footerRowDefs=xy(this._getOwnDefs(this._contentFooterRowDefs),this._customFooterRowDefs),this._rowDefs=xy(this._getOwnDefs(this._contentRowDefs),this._customRowDefs);let A=this._rowDefs.filter(i=>!i.when);!this.multiTemplateDataRows&&A.length>1,this._defaultRowDef=A[0]}_renderUpdatedColumns(){let A=(r,s)=>{let a=!!s.getColumnsDiff();return r||a},i=this._rowDefs.reduce(A,!1);i&&this._forceRenderDataRows();let n=this._headerRowDefs.reduce(A,!1);n&&this._forceRenderHeaderRows();let o=this._footerRowDefs.reduce(A,!1);return o&&this._forceRenderFooterRows(),i||n||o}_switchDataSource(A){this._data=[],A8(this.dataSource)&&this.dataSource.disconnect(this),this._renderChangeSubscription&&(this._renderChangeSubscription.unsubscribe(),this._renderChangeSubscription=null),A||(this._dataDiffer&&this._dataDiffer.diff([]),this._rowOutlet&&this._rowOutlet.viewContainer.clear()),this._dataSource=A}_observeRenderChanges(){if(!this.dataSource)return;let A;A8(this.dataSource)?A=this.dataSource.connect(this):a2(this.dataSource)?A=this.dataSource:Array.isArray(this.dataSource)&&(A=ve(this.dataSource)),this._renderChangeSubscription=A.pipe(wt(this._onDestroy)).subscribe(i=>{this._data=i||[],this.renderRows()})}_forceRenderHeaderRows(){this._headerRowOutlet.viewContainer.length>0&&this._headerRowOutlet.viewContainer.clear(),this._headerRowDefs.forEach((A,i)=>this._renderRow(this._headerRowOutlet,A,i)),this.updateStickyHeaderRowStyles()}_forceRenderFooterRows(){this._footerRowOutlet.viewContainer.length>0&&this._footerRowOutlet.viewContainer.clear(),this._footerRowDefs.forEach((A,i)=>this._renderRow(this._footerRowOutlet,A,i)),this.updateStickyFooterRowStyles()}_addStickyColumnStyles(A,i){let n=Array.from(i?.columns||[]).map(s=>{let a=this._columnDefsByName.get(s);return a}),o=n.map(s=>s.sticky),r=n.map(s=>s.stickyEnd);this._stickyStyler.updateStickyColumns(A,o,r,!this._fixedLayout||this._forceRecalculateCellWidths)}_getRenderedRows(A){let i=[];for(let n=0;n<A.viewContainer.length;n++){let o=A.viewContainer.get(n);i.push(o.rootNodes[0])}return i}_getRowDefs(A,i){if(this._rowDefs.length==1)return[this._rowDefs[0]];let n=[];if(this.multiTemplateDataRows)n=this._rowDefs.filter(o=>!o.when||o.when(i,A));else{let o=this._rowDefs.find(r=>r.when&&r.when(i,A))||this._defaultRowDef;o&&n.push(o)}return n.length,n}_getEmbeddedViewArgs(A,i){let n=A.rowDef,o={$implicit:A.data};return{templateRef:n.template,context:o,index:i}}_renderRow(A,i,n,o={}){let r=A.viewContainer.createEmbeddedView(i.template,o,n);return this._renderCellTemplateForItem(i,o),r}_renderCellTemplateForItem(A,i){for(let n of this._getCellTemplates(A))OC.mostRecentCellOutlet&&OC.mostRecentCellOutlet._viewContainer.createEmbeddedView(n,i);this._changeDetectorRef.markForCheck()}_updateRowIndexContext(){let A=this._rowOutlet.viewContainer;for(let i=0,n=A.length;i<n;i++){let r=A.get(i).context;r.count=n,r.first=i===0,r.last=i===n-1,r.even=i%2===0,r.odd=!r.even,this.multiTemplateDataRows?(r.dataIndex=this._renderRows[i].dataIndex,r.renderIndex=i):r.index=this._renderRows[i].dataIndex}}_getCellTemplates(A){return!A||!A.columns?[]:Array.from(A.columns,i=>{let n=this._columnDefsByName.get(i);return A.extractCellTemplate(n)})}_forceRenderDataRows(){this._dataDiffer.diff([]),this._rowOutlet.viewContainer.clear(),this.renderRows()}_checkStickyStates(){let A=(i,n)=>i||n.hasStickyChanged();this._headerRowDefs.reduce(A,!1)&&this.updateStickyHeaderRowStyles(),this._footerRowDefs.reduce(A,!1)&&this.updateStickyFooterRowStyles(),Array.from(this._columnDefsByName.values()).reduce(A,!1)&&(this._stickyColumnStylesNeedReset=!0,this.updateStickyColumnStyles())}_setupStickyStyler(){let A=this._dir?this._dir.value:"ltr";this._stickyStyler=new aG(this._isNativeHtmlTable,this.stickyCssClass,A,this._coalescedStyleScheduler,this._platform.isBrowser,this.needsPositionStickyOnElement,this._stickyPositioningListener,this._injector),(this._dir?this._dir.change:ve()).pipe(wt(this._onDestroy)).subscribe(i=>{this._stickyStyler.direction=i,this.updateStickyColumnStyles()})}_getOwnDefs(A){return A.filter(i=>!i._table||i._table===this)}_updateNoDataRow(){let A=this._customNoDataRow||this._noDataRow;if(!A)return;let i=this._rowOutlet.viewContainer.length===0;if(i===this._isShowingNoDataRow)return;let n=this._noDataRowOutlet.viewContainer;if(i){let o=n.createEmbeddedView(A.templateRef),r=o.rootNodes[0];o.rootNodes.length===1&&r?.nodeType===this._document.ELEMENT_NODE&&(r.setAttribute("role","row"),r.classList.add(A._contentClassName))}else n.clear();this._isShowingNoDataRow=i,this._changeDetectorRef.markForCheck()}static \u0275fac=function(i){return new(i||t)};static \u0275cmp=YA({type:t,selectors:[["cdk-table"],["table","cdk-table",""]],contentQueries:function(i,n,o){if(i&1&&(Ii(o,waA,5),Ii(o,Ih,5),Ii(o,Yy,5),Ii(o,X3,5),Ii(o,gG,5)),i&2){let r;$A(r=Ae())&&(n._noDataRow=r.first),$A(r=Ae())&&(n._contentColumnDefs=r),$A(r=Ae())&&(n._contentRowDefs=r),$A(r=Ae())&&(n._contentHeaderRowDefs=r),$A(r=Ae())&&(n._contentFooterRowDefs=r)}},hostAttrs:[1,"cdk-table"],hostVars:2,hostBindings:function(i,n){i&2&&ue("cdk-table-fixed-layout",n.fixedLayout)},inputs:{trackBy:"trackBy",dataSource:"dataSource",multiTemplateDataRows:[2,"multiTemplateDataRows","multiTemplateDataRows",ae],fixedLayout:[2,"fixedLayout","fixedLayout",ae]},outputs:{contentChanged:"contentChanged"},exportAs:["cdkTable"],features:[ct([{provide:Ll,useExisting:t},{provide:Qu,useClass:QB},{provide:_y,useClass:cG},{provide:Gy,useValue:null}])],ngContentSelectors:VJA,decls:5,vars:2,consts:[["role","rowgroup"],["headerRowOutlet",""],["rowOutlet",""],["noDataRowOutlet",""],["footerRowOutlet",""]],template:function(i,n){i&1&&(Yt(qJA),xe(0),xe(1,1),NA(2,ZJA,1,0)(3,WJA,7,0)(4,XJA,4,0)),i&2&&(_(2),FA(n._isServer?2:-1),_(),FA(n._isNativeHtmlTable?3:4))},dependencies:[BG,dG,hG,EG],styles:[".cdk-table-fixed-layout{table-layout:fixed}"],encapsulation:2})}return t})();function xy(t,e){return t.concat(Array.from(e))}function uaA(t,e){let A=e.toUpperCase(),i=t.viewContainer.element.nativeElement;for(;i;){let n=i.nodeType===1?i.nodeName:null;if(n===A)return i;if(n==="TABLE")break;i=i.parentNode}return null}var DaA=(()=>{class t{static \u0275fac=function(i){return new(i||t)};static \u0275mod=ge({type:t});static \u0275inj=le({imports:[uu]})}return t})();var ATA=[[["caption"]],[["colgroup"],["col"]],"*"],eTA=["caption","colgroup, col","*"];function tTA(t,e){t&1&&xe(0,2)}function iTA(t,e){t&1&&(S(0,"thead",0),Mr(1,1),R(),S(2,"tbody",2),Mr(3,3)(4,4),R(),S(5,"tfoot",0),Mr(6,5),R())}function nTA(t,e){t&1&&Mr(0,1)(1,3)(2,4)(3,5)}var yaA=(()=>{class t extends QG{stickyCssClass="mat-mdc-table-sticky";needsPositionStickyOnElement=!1;static \u0275fac=(()=>{let A;return function(n){return(A||(A=bi(t)))(n||t)}})();static \u0275cmp=YA({type:t,selectors:[["mat-table"],["table","mat-table",""]],hostAttrs:[1,"mat-mdc-table","mdc-data-table__table"],hostVars:2,hostBindings:function(i,n){i&2&&ue("mdc-table-fixed-layout",n.fixedLayout)},exportAs:["matTable"],features:[ct([{provide:QG,useExisting:t},{provide:Ll,useExisting:t},{provide:_y,useClass:cG},{provide:Qu,useClass:QB},{provide:Gy,useValue:null}]),et],ngContentSelectors:eTA,decls:5,vars:2,consts:[["role","rowgroup"],["headerRowOutlet",""],["role","rowgroup",1,"mdc-data-table__content"],["rowOutlet",""],["noDataRowOutlet",""],["footerRowOutlet",""]],template:function(i,n){i&1&&(Yt(ATA),xe(0),xe(1,1),NA(2,tTA,1,0)(3,iTA,7,0)(4,nTA,4,0)),i&2&&(_(2),FA(n._isServer?2:-1),_(),FA(n._isNativeHtmlTable?3:4))},dependencies:[BG,dG,hG,EG],styles:[".mat-mdc-table-sticky{position:sticky !important}mat-table{display:block}mat-header-row{min-height:56px}mat-row,mat-footer-row{min-height:48px}mat-row,mat-header-row,mat-footer-row{display:flex;border-width:0;border-bottom-width:1px;border-style:solid;align-items:center;box-sizing:border-box}mat-cell:first-of-type,mat-header-cell:first-of-type,mat-footer-cell:first-of-type{padding-left:24px}[dir=rtl] mat-cell:first-of-type:not(:only-of-type),[dir=rtl] mat-header-cell:first-of-type:not(:only-of-type),[dir=rtl] mat-footer-cell:first-of-type:not(:only-of-type){padding-left:0;padding-right:24px}mat-cell:last-of-type,mat-header-cell:last-of-type,mat-footer-cell:last-of-type{padding-right:24px}[dir=rtl] mat-cell:last-of-type:not(:only-of-type),[dir=rtl] mat-header-cell:last-of-type:not(:only-of-type),[dir=rtl] mat-footer-cell:last-of-type:not(:only-of-type){padding-right:0;padding-left:24px}mat-cell,mat-header-cell,mat-footer-cell{flex:1;display:flex;align-items:center;overflow:hidden;word-wrap:break-word;min-height:inherit}.mat-mdc-table{min-width:100%;border:0;border-spacing:0;table-layout:auto;white-space:normal;background-color:var(--mat-table-background-color, var(--mat-sys-surface))}.mdc-data-table__cell{box-sizing:border-box;overflow:hidden;text-align:left;text-overflow:ellipsis}[dir=rtl] .mdc-data-table__cell{text-align:right}.mdc-data-table__cell,.mdc-data-table__header-cell{padding:0 16px}.mat-mdc-header-row{-moz-osx-font-smoothing:grayscale;-webkit-font-smoothing:antialiased;height:var(--mat-table-header-container-height, 56px);color:var(--mat-table-header-headline-color, var(--mat-sys-on-surface, rgba(0, 0, 0, 0.87)));font-family:var(--mat-table-header-headline-font, var(--mat-sys-title-small-font, Roboto, sans-serif));line-height:var(--mat-table-header-headline-line-height, var(--mat-sys-title-small-line-height));font-size:var(--mat-table-header-headline-size, var(--mat-sys-title-small-size, 14px));font-weight:var(--mat-table-header-headline-weight, var(--mat-sys-title-small-weight, 500))}.mat-mdc-row{height:var(--mat-table-row-item-container-height, 52px);color:var(--mat-table-row-item-label-text-color, var(--mat-sys-on-surface, rgba(0, 0, 0, 0.87)))}.mat-mdc-row,.mdc-data-table__content{-moz-osx-font-smoothing:grayscale;-webkit-font-smoothing:antialiased;font-family:var(--mat-table-row-item-label-text-font, var(--mat-sys-body-medium-font, Roboto, sans-serif));line-height:var(--mat-table-row-item-label-text-line-height, var(--mat-sys-body-medium-line-height));font-size:var(--mat-table-row-item-label-text-size, var(--mat-sys-body-medium-size, 14px));font-weight:var(--mat-table-row-item-label-text-weight, var(--mat-sys-body-medium-weight))}.mat-mdc-footer-row{-moz-osx-font-smoothing:grayscale;-webkit-font-smoothing:antialiased;height:var(--mat-table-footer-container-height, 52px);color:var(--mat-table-row-item-label-text-color, var(--mat-sys-on-surface, rgba(0, 0, 0, 0.87)));font-family:var(--mat-table-footer-supporting-text-font, var(--mat-sys-body-medium-font, Roboto, sans-serif));line-height:var(--mat-table-footer-supporting-text-line-height, var(--mat-sys-body-medium-line-height));font-size:var(--mat-table-footer-supporting-text-size, var(--mat-sys-body-medium-size, 14px));font-weight:var(--mat-table-footer-supporting-text-weight, var(--mat-sys-body-medium-weight));letter-spacing:var(--mat-table-footer-supporting-text-tracking, var(--mat-sys-body-medium-tracking))}.mat-mdc-header-cell{border-bottom-color:var(--mat-table-row-item-outline-color, var(--mat-sys-outline, rgba(0, 0, 0, 0.12)));border-bottom-width:var(--mat-table-row-item-outline-width, 1px);border-bottom-style:solid;letter-spacing:var(--mat-table-header-headline-tracking, var(--mat-sys-title-small-tracking));font-weight:inherit;line-height:inherit;box-sizing:border-box;text-overflow:ellipsis;overflow:hidden;outline:none;text-align:left}[dir=rtl] .mat-mdc-header-cell{text-align:right}.mdc-data-table__row:last-child>.mat-mdc-header-cell{border-bottom:none}.mat-mdc-cell{border-bottom-color:var(--mat-table-row-item-outline-color, var(--mat-sys-outline, rgba(0, 0, 0, 0.12)));border-bottom-width:var(--mat-table-row-item-outline-width, 1px);border-bottom-style:solid;letter-spacing:var(--mat-table-row-item-label-text-tracking, var(--mat-sys-body-medium-tracking));line-height:inherit}.mdc-data-table__row:last-child>.mat-mdc-cell{border-bottom:none}.mat-mdc-footer-cell{letter-spacing:var(--mat-table-row-item-label-text-tracking, var(--mat-sys-body-medium-tracking))}mat-row.mat-mdc-row,mat-header-row.mat-mdc-header-row,mat-footer-row.mat-mdc-footer-row{border-bottom:none}.mat-mdc-table tbody,.mat-mdc-table tfoot,.mat-mdc-table thead,.mat-mdc-cell,.mat-mdc-footer-cell,.mat-mdc-header-row,.mat-mdc-row,.mat-mdc-footer-row,.mat-mdc-table .mat-mdc-header-cell{background:inherit}.mat-mdc-table mat-header-row.mat-mdc-header-row,.mat-mdc-table mat-row.mat-mdc-row,.mat-mdc-table mat-footer-row.mat-mdc-footer-cell{height:unset}mat-header-cell.mat-mdc-header-cell,mat-cell.mat-mdc-cell,mat-footer-cell.mat-mdc-footer-cell{align-self:stretch}"],encapsulation:2})}return t})(),vaA=(()=>{class t extends Uy{static \u0275fac=(()=>{let A;return function(n){return(A||(A=bi(t)))(n||t)}})();static \u0275dir=OA({type:t,selectors:[["","matCellDef",""]],features:[ct([{provide:Uy,useExisting:t}]),et]})}return t})(),baA=(()=>{class t extends Ky{static \u0275fac=(()=>{let A;return function(n){return(A||(A=bi(t)))(n||t)}})();static \u0275dir=OA({type:t,selectors:[["","matHeaderCellDef",""]],features:[ct([{provide:Ky,useExisting:t}]),et]})}return t})();var MaA=(()=>{class t extends Ih{get name(){return this._name}set name(A){this._setNameInput(A)}_updateColumnCssClassName(){super._updateColumnCssClassName(),this._columnCssClassName.push(`mat-column-${this.cssClassFriendlyName}`)}static \u0275fac=(()=>{let A;return function(n){return(A||(A=bi(t)))(n||t)}})();static \u0275dir=OA({type:t,selectors:[["","matColumnDef",""]],inputs:{name:[0,"matColumnDef","name"]},features:[ct([{provide:Ih,useExisting:t},{provide:"MAT_SORT_HEADER_COLUMN_DEF",useExisting:t}]),et]})}return t})(),kaA=(()=>{class t extends maA{static \u0275fac=(()=>{let A;return function(n){return(A||(A=bi(t)))(n||t)}})();static \u0275dir=OA({type:t,selectors:[["mat-header-cell"],["th","mat-header-cell",""]],hostAttrs:["role","columnheader",1,"mat-mdc-header-cell","mdc-data-table__header-cell"],features:[et]})}return t})();var SaA=(()=>{class t extends paA{static \u0275fac=(()=>{let A;return function(n){return(A||(A=bi(t)))(n||t)}})();static \u0275dir=OA({type:t,selectors:[["mat-cell"],["td","mat-cell",""]],hostAttrs:[1,"mat-mdc-cell","mdc-data-table__cell"],features:[et]})}return t})();var RaA=(()=>{class t extends X3{static \u0275fac=(()=>{let A;return function(n){return(A||(A=bi(t)))(n||t)}})();static \u0275dir=OA({type:t,selectors:[["","matHeaderRowDef",""]],inputs:{columns:[0,"matHeaderRowDef","columns"],sticky:[2,"matHeaderRowDefSticky","sticky",ae]},features:[ct([{provide:X3,useExisting:t}]),et]})}return t})();var LaA=(()=>{class t extends Yy{static \u0275fac=(()=>{let A;return function(n){return(A||(A=bi(t)))(n||t)}})();static \u0275dir=OA({type:t,selectors:[["","matRowDef",""]],inputs:{columns:[0,"matRowDefColumns","columns"],when:[0,"matRowDefWhen","when"]},features:[ct([{provide:Yy,useExisting:t}]),et]})}return t})(),xaA=(()=>{class t extends IG{static \u0275fac=(()=>{let A;return function(n){return(A||(A=bi(t)))(n||t)}})();static \u0275cmp=YA({type:t,selectors:[["mat-header-row"],["tr","mat-header-row",""]],hostAttrs:["role","row",1,"mat-mdc-header-row","mdc-data-table__header-row"],exportAs:["matHeaderRow"],features:[ct([{provide:IG,useExisting:t}]),et],decls:1,vars:0,consts:[["cdkCellOutlet",""]],template:function(i,n){i&1&&Mr(0,0)},dependencies:[OC],encapsulation:2})}return t})();var FaA=(()=>{class t extends CG{static \u0275fac=(()=>{let A;return function(n){return(A||(A=bi(t)))(n||t)}})();static \u0275cmp=YA({type:t,selectors:[["mat-row"],["tr","mat-row",""]],hostAttrs:["role","row",1,"mat-mdc-row","mdc-data-table__row"],exportAs:["matRow"],features:[ct([{provide:CG,useExisting:t}]),et],decls:1,vars:0,consts:[["cdkCellOutlet",""]],template:function(i,n){i&1&&Mr(0,0)},dependencies:[OC],encapsulation:2})}return t})();var NaA=(()=>{class t{static \u0275fac=function(i){return new(i||t)};static \u0275mod=ge({type:t});static \u0275inj=le({imports:[Ve,DaA,Ve]})}return t})(),oTA=9007199254740991,$3=class extends $6{_data;_renderData=new li([]);_filter=new li("");_internalPageChanges=new HA;_renderChangesSubscription=null;filteredData;get data(){return this._data.value}set data(e){e=Array.isArray(e)?e:[],this._data.next(e),this._renderChangesSubscription||this._filterData(e)}get filter(){return this._filter.value}set filter(e){this._filter.next(e),this._renderChangesSubscription||this._filterData(this.data)}get sort(){return this._sort}set sort(e){this._sort=e,this._updateChangeSubscription()}_sort;get paginator(){return this._paginator}set paginator(e){this._paginator=e,this._updateChangeSubscription()}_paginator;sortingDataAccessor=(e,A)=>{let i=e[A];if(OM(i)){let n=Number(i);return n<oTA?n:i}return i};sortData=(e,A)=>{let i=A.active,n=A.direction;return!i||n==""?e:e.sort((o,r)=>{let s=this.sortingDataAccessor(o,i),a=this.sortingDataAccessor(r,i),c=typeof s,l=typeof a;c!==l&&(c==="number"&&(s+=""),l==="number"&&(a+=""));let I=0;return s!=null&&a!=null?s>a?I=1:s<a&&(I=-1):s!=null?I=1:a!=null&&(I=-1),I*(n=="asc"?1:-1)})};filterPredicate=(e,A)=>{let i=A.trim().toLowerCase();return Object.values(e).some(n=>`${n}`.toLowerCase().includes(i))};constructor(e=[]){super(),this._data=new li(e),this._updateChangeSubscription()}_updateChangeSubscription(){let e=this._sort?ho(this._sort.sortChange,this._sort.initialized):ve(null),A=this._paginator?ho(this._paginator.page,this._internalPageChanges,this._paginator.initialized):ve(null),i=this._data,n=Ls([i,this._filter]).pipe(Je(([s])=>this._filterData(s))),o=Ls([n,e]).pipe(Je(([s])=>this._orderData(s))),r=Ls([o,A]).pipe(Je(([s])=>this._pageData(s)));this._renderChangesSubscription?.unsubscribe(),this._renderChangesSubscription=r.subscribe(s=>this._renderData.next(s))}_filterData(e){return this.filteredData=this.filter==null||this.filter===""?e:e.filter(A=>this.filterPredicate(A,this.filter)),this.paginator&&this._updatePaginator(this.filteredData.length),this.filteredData}_orderData(e){return this.sort?this.sortData(e.slice(),this.sort):e}_pageData(e){if(!this.paginator)return e;let A=this.paginator.pageIndex*this.paginator.pageSize;return e.slice(A,A+this.paginator.pageSize)}_updatePaginator(e){Promise.resolve().then(()=>{let A=this.paginator;if(A&&(A.length=e,A.pageIndex>0)){let i=Math.ceil(A.length/A.pageSize)-1||0,n=Math.min(A.pageIndex,i);n!==A.pageIndex&&(A.pageIndex=n,this._internalPageChanges.next())}})}connect(){return this._renderChangesSubscription||this._updateChangeSubscription(),this._renderData}disconnect(){this._renderChangesSubscription?.unsubscribe(),this._renderChangesSubscription=null}};var _aA=[{metricName:"tool_trajectory_avg_score",threshold:1},{metricName:"response_match_score",threshold:.7}];var gs=[];for(let t=0;t<256;++t)gs.push((t+256).toString(16).slice(1));function GaA(t,e=0){return(gs[t[e+0]]+gs[t[e+1]]+gs[t[e+2]]+gs[t[e+3]]+"-"+gs[t[e+4]]+gs[t[e+5]]+"-"+gs[t[e+6]]+gs[t[e+7]]+"-"+gs[t[e+8]]+gs[t[e+9]]+"-"+gs[t[e+10]]+gs[t[e+11]]+gs[t[e+12]]+gs[t[e+13]]+gs[t[e+14]]+gs[t[e+15]]).toLowerCase()}var uG,sTA=new Uint8Array(16);function fG(){if(!uG){if(typeof crypto>"u"||!crypto.getRandomValues)throw new Error("crypto.getRandomValues() not supported. See https://github.com/uuidjs/uuid#getrandomvalues-not-supported");uG=crypto.getRandomValues.bind(crypto)}return uG(sTA)}var aTA=typeof crypto<"u"&&crypto.randomUUID&&crypto.randomUUID.bind(crypto),mG={randomUUID:aTA};function cTA(t,e,A){if(mG.randomUUID&&!e&&!t)return mG.randomUUID();t=t||{};let i=t.random??t.rng?.()??fG();if(i.length<16)throw new Error("Random bytes length must be >= 16");if(i[6]=i[6]&15|64,i[8]=i[8]&63|128,e){if(A=A||0,A<0||A+16>e.length)throw new RangeError(`UUID byte range ${A}:${A+15} is out of buffer bounds`);for(let n=0;n<16;++n)e[A+n]=i[n];return e}return GaA(i)}var Af=cTA;var zc=class t{constructor(e){this.http=e}apiServerDomain=Es.getApiServerBaseUrl();getEvalSets(e){if(this.apiServerDomain!=null){let A=this.apiServerDomain+`/apps/${e}/eval_sets`;return this.http.get(A)}return new Ze}createNewEvalSet(e,A){if(this.apiServerDomain!=null){let i=this.apiServerDomain+`/apps/${e}/eval_sets/${A}`;return this.http.post(i,{})}return new Ze}listEvalCases(e,A){if(this.apiServerDomain!=null){let i=this.apiServerDomain+`/apps/${e}/eval_sets/${A}/evals`;return this.http.get(i,{})}return new Ze}addCurrentSession(e,A,i,n,o){let r=this.apiServerDomain+`/apps/${e}/eval_sets/${A}/add_session`;return this.http.post(r,{evalId:i,sessionId:n,userId:o})}runEval(e,A,i,n){let o=this.apiServerDomain+`/apps/${e}/eval_sets/${A}/run_eval`;return this.http.post(o,{evalIds:i,evalMetrics:n})}listEvalResults(e){if(this.apiServerDomain!=null){let A=this.apiServerDomain+`/apps/${e}/eval_results`;return this.http.get(A,{})}return new Ze}getEvalResult(e,A){if(this.apiServerDomain!=null){let i=this.apiServerDomain+`/apps/${e}/eval_results/${A}`;return this.http.get(i,{})}return new Ze}getEvalCase(e,A,i){if(this.apiServerDomain!=null){let n=this.apiServerDomain+`/apps/${e}/eval_sets/${A}/evals/${i}`;return this.http.get(n,{})}return new Ze}updateEvalCase(e,A,i,n){let o=this.apiServerDomain+`/apps/${e}/eval_sets/${A}/evals/${i}`;return this.http.put(o,{evalId:i,conversation:n.conversation,sessionInput:n.sessionInput,creationTimestamp:n.creationTimestamp})}deleteEvalCase(e,A,i){let n=this.apiServerDomain+`/apps/${e}/eval_sets/${A}/evals/${i}`;return this.http.delete(n,{})}static \u0275fac=function(A){return new(A||t)(he(Bs))};static \u0275prov=SA({token:t,factory:t.\u0275fac,providedIn:"root"})};var KaA=(()=>{class t{static \u0275fac=function(i){return new(i||t)};static \u0275cmp=YA({type:t,selectors:[["ng-component"]],hostAttrs:["cdk-text-field-style-loader",""],decls:0,vars:0,template:function(i,n){},styles:["textarea.cdk-textarea-autosize{resize:none}textarea.cdk-textarea-autosize-measuring{padding:2px 0 !important;box-sizing:content-box !important;height:auto !important;overflow:hidden !important}textarea.cdk-textarea-autosize-measuring-firefox{padding:2px 0 !important;box-sizing:content-box !important;height:0 !important}@keyframes cdk-text-field-autofill-start{/*!*/}@keyframes cdk-text-field-autofill-end{/*!*/}.cdk-text-field-autofill-monitored:-webkit-autofill{animation:cdk-text-field-autofill-start 0s 1ms}.cdk-text-field-autofill-monitored:not(:-webkit-autofill){animation:cdk-text-field-autofill-end 0s 1ms}"],encapsulation:2,changeDetection:0})}return t})(),UaA=og({passive:!0}),YaA=(()=>{class t{_platform=m(Zt);_ngZone=m(de);_styleLoader=m(Ln);_monitoredElements=new Map;constructor(){}monitor(A){if(!this._platform.isBrowser)return Ar;this._styleLoader.load(KaA);let i=sa(A),n=this._monitoredElements.get(i);if(n)return n.subject;let o=new HA,r="cdk-text-field-autofilled",s=a=>{a.animationName==="cdk-text-field-autofill-start"&&!i.classList.contains(r)?(i.classList.add(r),this._ngZone.run(()=>o.next({target:a.target,isAutofilled:!0}))):a.animationName==="cdk-text-field-autofill-end"&&i.classList.contains(r)&&(i.classList.remove(r),this._ngZone.run(()=>o.next({target:a.target,isAutofilled:!1})))};return this._ngZone.runOutsideAngular(()=>{i.addEventListener("animationstart",s,UaA),i.classList.add("cdk-text-field-autofill-monitored")}),this._monitoredElements.set(i,{subject:o,unlisten:()=>{i.removeEventListener("animationstart",s,UaA)}}),o}stopMonitoring(A){let i=sa(A),n=this._monitoredElements.get(i);n&&(n.unlisten(),n.subject.complete(),i.classList.remove("cdk-text-field-autofill-monitored"),i.classList.remove("cdk-text-field-autofilled"),this._monitoredElements.delete(i))}ngOnDestroy(){this._monitoredElements.forEach((A,i)=>this.stopMonitoring(i))}static \u0275fac=function(i){return new(i||t)};static \u0275prov=SA({token:t,factory:t.\u0275fac,providedIn:"root"})}return t})();var JaA=(()=>{class t{_elementRef=m(te);_platform=m(Zt);_ngZone=m(de);_renderer=m(Gi);_resizeEvents=new HA;_previousValue;_initialHeight;_destroyed=new HA;_listenerCleanups;_minRows;_maxRows;_enabled=!0;_previousMinRows=-1;_textareaElement;get minRows(){return this._minRows}set minRows(A){this._minRows=Ns(A),this._setMinHeight()}get maxRows(){return this._maxRows}set maxRows(A){this._maxRows=Ns(A),this._setMaxHeight()}get enabled(){return this._enabled}set enabled(A){this._enabled!==A&&((this._enabled=A)?this.resizeToFitContent(!0):this.reset())}get placeholder(){return this._textareaElement.placeholder}set placeholder(A){this._cachedPlaceholderHeight=void 0,A?this._textareaElement.setAttribute("placeholder",A):this._textareaElement.removeAttribute("placeholder"),this._cacheTextareaPlaceholderHeight()}_cachedLineHeight;_cachedPlaceholderHeight;_document=m(tt,{optional:!0});_hasFocus;_isViewInited=!1;constructor(){m(Ln).load(KaA),this._textareaElement=this._elementRef.nativeElement}_setMinHeight(){let A=this.minRows&&this._cachedLineHeight?`${this.minRows*this._cachedLineHeight}px`:null;A&&(this._textareaElement.style.minHeight=A)}_setMaxHeight(){let A=this.maxRows&&this._cachedLineHeight?`${this.maxRows*this._cachedLineHeight}px`:null;A&&(this._textareaElement.style.maxHeight=A)}ngAfterViewInit(){this._platform.isBrowser&&(this._initialHeight=this._textareaElement.style.height,this.resizeToFitContent(),this._ngZone.runOutsideAngular(()=>{this._listenerCleanups=[this._renderer.listen("window","resize",()=>this._resizeEvents.next()),this._renderer.listen(this._textareaElement,"focus",this._handleFocusEvent),this._renderer.listen(this._textareaElement,"blur",this._handleFocusEvent)],this._resizeEvents.pipe(Cd(16)).subscribe(()=>{this._cachedLineHeight=this._cachedPlaceholderHeight=void 0,this.resizeToFitContent(!0)})}),this._isViewInited=!0,this.resizeToFitContent(!0))}ngOnDestroy(){this._listenerCleanups?.forEach(A=>A()),this._resizeEvents.complete(),this._destroyed.next(),this._destroyed.complete()}_cacheTextareaLineHeight(){if(this._cachedLineHeight)return;let A=this._textareaElement.cloneNode(!1),i=A.style;A.rows=1,i.position="absolute",i.visibility="hidden",i.border="none",i.padding="0",i.height="",i.minHeight="",i.maxHeight="",i.top=i.bottom=i.left=i.right="auto",i.overflow="hidden",this._textareaElement.parentNode.appendChild(A),this._cachedLineHeight=A.clientHeight,A.remove(),this._setMinHeight(),this._setMaxHeight()}_measureScrollHeight(){let A=this._textareaElement,i=A.style.marginBottom||"",n=this._platform.FIREFOX,o=n&&this._hasFocus,r=n?"cdk-textarea-autosize-measuring-firefox":"cdk-textarea-autosize-measuring";o&&(A.style.marginBottom=`${A.clientHeight}px`),A.classList.add(r);let s=A.scrollHeight-4;return A.classList.remove(r),o&&(A.style.marginBottom=i),s}_cacheTextareaPlaceholderHeight(){if(!this._isViewInited||this._cachedPlaceholderHeight!=null)return;if(!this.placeholder){this._cachedPlaceholderHeight=0;return}let A=this._textareaElement.value;this._textareaElement.value=this._textareaElement.placeholder,this._cachedPlaceholderHeight=this._measureScrollHeight(),this._textareaElement.value=A}_handleFocusEvent=A=>{this._hasFocus=A.type==="focus"};ngDoCheck(){this._platform.isBrowser&&this.resizeToFitContent()}resizeToFitContent(A=!1){if(!this._enabled||(this._cacheTextareaLineHeight(),this._cacheTextareaPlaceholderHeight(),!this._cachedLineHeight))return;let i=this._elementRef.nativeElement,n=i.value;if(!A&&this._minRows===this._previousMinRows&&n===this._previousValue)return;let o=this._measureScrollHeight(),r=Math.max(o,this._cachedPlaceholderHeight||0);i.style.height=`${r}px`,this._ngZone.runOutsideAngular(()=>{typeof requestAnimationFrame<"u"?requestAnimationFrame(()=>this._scrollToCaretPosition(i)):setTimeout(()=>this._scrollToCaretPosition(i))}),this._previousValue=n,this._previousMinRows=this._minRows}reset(){this._initialHeight!==void 0&&(this._textareaElement.style.height=this._initialHeight)}_noopInputHandler(){}_scrollToCaretPosition(A){let{selectionStart:i,selectionEnd:n}=A;!this._destroyed.isStopped&&this._hasFocus&&A.setSelectionRange(i,n)}static \u0275fac=function(i){return new(i||t)};static \u0275dir=OA({type:t,selectors:[["textarea","cdkTextareaAutosize",""]],hostAttrs:["rows","1",1,"cdk-textarea-autosize"],hostBindings:function(i,n){i&1&&mA("input",function(){return n._noopInputHandler()})},inputs:{minRows:[0,"cdkAutosizeMinRows","minRows"],maxRows:[0,"cdkAutosizeMaxRows","maxRows"],enabled:[2,"cdkTextareaAutosize","enabled",ae],placeholder:"placeholder"},exportAs:["cdkTextareaAutosize"]})}return t})(),TaA=(()=>{class t{static \u0275fac=function(i){return new(i||t)};static \u0275mod=ge({type:t});static \u0275inj=le({})}return t})();var gTA=new BA("MAT_INPUT_VALUE_ACCESSOR"),ITA=["button","checkbox","file","hidden","image","radio","range","reset","submit"],CTA=new BA("MAT_INPUT_CONFIG"),P1=(()=>{class t{_elementRef=m(te);_platform=m(Zt);ngControl=m(Pa,{optional:!0,self:!0});_autofillMonitor=m(YaA);_ngZone=m(de);_formField=m(wu,{optional:!0});_renderer=m(Gi);_uid=m($i).getId("mat-input-");_previousNativeValue;_inputValueAccessor;_signalBasedValueAccessor;_previousPlaceholder;_errorStateTracker;_config=m(CTA,{optional:!0});_cleanupIosKeyup;_cleanupWebkitWheel;_formFieldDescribedBy;_isServer;_isNativeSelect;_isTextarea;_isInFormField;focused=!1;stateChanges=new HA;controlType="mat-input";autofilled=!1;get disabled(){return this._disabled}set disabled(A){this._disabled=Yo(A),this.focused&&(this.focused=!1,this.stateChanges.next())}_disabled=!1;get id(){return this._id}set id(A){this._id=A||this._uid}_id;placeholder;name;get required(){return this._required??this.ngControl?.control?.hasValidator(Oa.required)??!1}set required(A){this._required=Yo(A)}_required;get type(){return this._type}set type(A){let i=this._type;this._type=A||"text",this._validateType(),!this._isTextarea&&TM().has(this._type)&&(this._elementRef.nativeElement.type=this._type),this._type!==i&&this._ensureWheelDefaultBehavior()}_type="text";get errorStateMatcher(){return this._errorStateTracker.matcher}set errorStateMatcher(A){this._errorStateTracker.matcher=A}userAriaDescribedBy;get value(){return this._signalBasedValueAccessor?this._signalBasedValueAccessor.value():this._inputValueAccessor.value}set value(A){A!==this.value&&(this._signalBasedValueAccessor?this._signalBasedValueAccessor.value.set(A):this._inputValueAccessor.value=A,this.stateChanges.next())}get readonly(){return this._readonly}set readonly(A){this._readonly=Yo(A)}_readonly=!1;disabledInteractive;get errorState(){return this._errorStateTracker.errorState}set errorState(A){this._errorStateTracker.errorState=A}_neverEmptyInputTypes=["date","datetime","datetime-local","month","time","week"].filter(A=>TM().has(A));constructor(){let A=m(jQ,{optional:!0}),i=m(bI,{optional:!0}),n=m(dB),o=m(gTA,{optional:!0,self:!0}),r=this._elementRef.nativeElement,s=r.nodeName.toLowerCase();o?h2(o.value)?this._signalBasedValueAccessor=o:this._inputValueAccessor=o:this._inputValueAccessor=r,this._previousNativeValue=this.value,this.id=this.id,this._platform.IOS&&this._ngZone.runOutsideAngular(()=>{this._cleanupIosKeyup=this._renderer.listen(r,"keyup",this._iOSKeyupListener)}),this._errorStateTracker=new UI(n,this.ngControl,i,A,this.stateChanges),this._isServer=!this._platform.isBrowser,this._isNativeSelect=s==="select",this._isTextarea=s==="textarea",this._isInFormField=!!this._formField,this.disabledInteractive=this._config?.disabledInteractive||!1,this._isNativeSelect&&(this.controlType=r.multiple?"mat-native-select-multiple":"mat-native-select"),this._signalBasedValueAccessor&&mQ(()=>{this._signalBasedValueAccessor.value(),this.stateChanges.next()})}ngAfterViewInit(){this._platform.isBrowser&&this._autofillMonitor.monitor(this._elementRef.nativeElement).subscribe(A=>{this.autofilled=A.isAutofilled,this.stateChanges.next()})}ngOnChanges(){this.stateChanges.next()}ngOnDestroy(){this.stateChanges.complete(),this._platform.isBrowser&&this._autofillMonitor.stopMonitoring(this._elementRef.nativeElement),this._cleanupIosKeyup?.(),this._cleanupWebkitWheel?.()}ngDoCheck(){this.ngControl&&(this.updateErrorState(),this.ngControl.disabled!==null&&this.ngControl.disabled!==this.disabled&&(this.disabled=this.ngControl.disabled,this.stateChanges.next())),this._dirtyCheckNativeValue(),this._dirtyCheckPlaceholder()}focus(A){this._elementRef.nativeElement.focus(A)}updateErrorState(){this._errorStateTracker.updateErrorState()}_focusChanged(A){if(A!==this.focused){if(!this._isNativeSelect&&A&&this.disabled&&this.disabledInteractive){let i=this._elementRef.nativeElement;i.type==="number"?(i.type="text",i.setSelectionRange(0,0),i.type="number"):i.setSelectionRange(0,0)}this.focused=A,this.stateChanges.next()}}_onInput(){}_dirtyCheckNativeValue(){let A=this._elementRef.nativeElement.value;this._previousNativeValue!==A&&(this._previousNativeValue=A,this.stateChanges.next())}_dirtyCheckPlaceholder(){let A=this._getPlaceholder();if(A!==this._previousPlaceholder){let i=this._elementRef.nativeElement;this._previousPlaceholder=A,A?i.setAttribute("placeholder",A):i.removeAttribute("placeholder")}}_getPlaceholder(){return this.placeholder||null}_validateType(){ITA.indexOf(this._type)>-1}_isNeverEmpty(){return this._neverEmptyInputTypes.indexOf(this._type)>-1}_isBadInput(){let A=this._elementRef.nativeElement.validity;return A&&A.badInput}get empty(){return!this._isNeverEmpty()&&!this._elementRef.nativeElement.value&&!this._isBadInput()&&!this.autofilled}get shouldLabelFloat(){if(this._isNativeSelect){let A=this._elementRef.nativeElement,i=A.options[0];return this.focused||A.multiple||!this.empty||!!(A.selectedIndex>-1&&i&&i.label)}else return this.focused&&!this.disabled||!this.empty}setDescribedByIds(A){let i=this._elementRef.nativeElement,n=i.getAttribute("aria-describedby"),o;if(n){let r=this._formFieldDescribedBy||A;o=A.concat(n.split(" ").filter(s=>s&&!r.includes(s)))}else o=A;this._formFieldDescribedBy=A,o.length?i.setAttribute("aria-describedby",o.join(" ")):i.removeAttribute("aria-describedby")}onContainerClick(){this.focused||this.focus()}_isInlineSelect(){let A=this._elementRef.nativeElement;return this._isNativeSelect&&(A.multiple||A.size>1)}_iOSKeyupListener=A=>{let i=A.target;!i.value&&i.selectionStart===0&&i.selectionEnd===0&&(i.setSelectionRange(1,1),i.setSelectionRange(0,0))};_webkitBlinkWheelListener=()=>{};_ensureWheelDefaultBehavior(){this._cleanupWebkitWheel?.(),this._type==="number"&&(this._platform.BLINK||this._platform.WEBKIT)&&(this._cleanupWebkitWheel=this._renderer.listen(this._elementRef.nativeElement,"wheel",this._webkitBlinkWheelListener))}_getReadonlyAttribute(){return this._isNativeSelect?null:this.readonly||this.disabled&&this.disabledInteractive?"true":null}static \u0275fac=function(i){return new(i||t)};static \u0275dir=OA({type:t,selectors:[["input","matInput",""],["textarea","matInput",""],["select","matNativeControl",""],["input","matNativeControl",""],["textarea","matNativeControl",""]],hostAttrs:[1,"mat-mdc-input-element"],hostVars:21,hostBindings:function(i,n){i&1&&mA("focus",function(){return n._focusChanged(!0)})("blur",function(){return n._focusChanged(!1)})("input",function(){return n._onInput()}),i&2&&(Fs("id",n.id)("disabled",n.disabled&&!n.disabledInteractive)("required",n.required),_e("name",n.name||null)("readonly",n._getReadonlyAttribute())("aria-disabled",n.disabled&&n.disabledInteractive?"true":null)("aria-invalid",n.empty&&n.required?null:n.errorState)("aria-required",n.required)("id",n.id),ue("mat-input-server",n._isServer)("mat-mdc-form-field-textarea-control",n._isInFormField&&n._isTextarea)("mat-mdc-form-field-input-control",n._isInFormField)("mat-mdc-input-disabled-interactive",n.disabledInteractive)("mdc-text-field__input",n._isInFormField)("mat-mdc-native-select-inline",n._isInlineSelect()))},inputs:{disabled:"disabled",id:"id",placeholder:"placeholder",name:"name",required:"required",type:"type",errorStateMatcher:"errorStateMatcher",userAriaDescribedBy:[0,"aria-describedby","userAriaDescribedBy"],value:"value",readonly:"readonly",disabledInteractive:[2,"disabledInteractive","disabledInteractive",ae]},exportAs:["matInput"],features:[ct([{provide:pu,useExisting:t}]),Kt]})}return t})(),Ty=(()=>{class t{static \u0275fac=function(i){return new(i||t)};static \u0275mod=ge({type:t});static \u0275inj=le({imports:[Ve,f0,f0,TaA,Ve]})}return t})();var ef=class t{constructor(e,A,i){this.evalService=e;this.data=A;this.dialogRef=i}newCaseId="case"+Af().slice(0,6);createNewEvalCase(){!this.newCaseId||this.newCaseId==""?alert("Cannot create eval set with empty id!"):this.evalService.addCurrentSession(this.data.appName,this.data.evalSetId,this.newCaseId,this.data.sessionId,this.data.userId).subscribe(e=>{this.dialogRef.close(!0)})}static \u0275fac=function(A){return new(A||t)(zA(zc),zA($r),zA(cr))};static \u0275cmp=YA({type:t,selectors:[["app-add-eval-session-dialog"]],standalone:!1,decls:11,vars:1,consts:[["mat-dialog-title",""],[2,"padding-left","20px","padding-right","24px"],["matInput","",3,"ngModelChange","keydown.enter","ngModel"],["align","end"],["mat-button","","mat-dialog-close",""],["mat-button","","cdkFocusInitial","",3,"click"]],template:function(A,i){A&1&&(S(0,"h2",0),tA(1,"Add Current Session To Eval Set"),R(),S(2,"mat-dialog-content"),tA(3,` Please enter the eval case name
`),R(),S(4,"mat-form-field",1)(5,"input",2),ta("ngModelChange",function(o){return Ja(i.newCaseId,o)||(i.newCaseId=o),o}),mA("keydown.enter",function(){return i.createNewEvalCase()}),R()(),S(6,"mat-dialog-actions",3)(7,"button",4),tA(8,"Cancel"),R(),S(9,"button",5),mA("click",function(){return i.createNewEvalCase()}),tA(10,"Create"),R()()),A&2&&(_(5),ea("ngModel",i.newCaseId))},dependencies:[fc,na,ja,lg,P1,ur,hs,ga,Ia,gg],encapsulation:2})};var tf=class t{constructor(e,A,i){this.evalService=e;this.data=A;this.dialogRef=i}newSetId="evalset"+Af().slice(0,6);createNewEvalSet(){!this.newSetId||this.newSetId==""?alert("Cannot create eval set with empty id!"):this.evalService.createNewEvalSet(this.data.appName,this.newSetId).subscribe(e=>{this.dialogRef.close(!0)})}static \u0275fac=function(A){return new(A||t)(zA(zc),zA($r),zA(cr))};static \u0275cmp=YA({type:t,selectors:[["app-new-eval-set-dialog-component"]],standalone:!1,decls:11,vars:1,consts:[["mat-dialog-title",""],[2,"padding-left","20px","padding-right","24px"],["matInput","",3,"ngModelChange","keydown.enter","ngModel"],["align","end"],["mat-button","","mat-dialog-close",""],["mat-button","","cdkFocusInitial","",3,"click"]],template:function(A,i){A&1&&(S(0,"h2",0),tA(1,"Create New Eval Set"),R(),S(2,"mat-dialog-content"),tA(3,` Please enter the eval set name
`),R(),S(4,"mat-form-field",1)(5,"input",2),ta("ngModelChange",function(o){return Ja(i.newSetId,o)||(i.newSetId=o),o}),mA("keydown.enter",function(){return i.createNewEvalSet()}),R()(),S(6,"mat-dialog-actions",3)(7,"button",4),tA(8,"Cancel"),R(),S(9,"button",5),mA("click",function(){return i.createNewEvalSet()}),tA(10,"Create"),R()()),A&2&&(_(5),ea("ngModel",i.newSetId))},dependencies:[fc,na,ja,lg,P1,ur,hs,ga,Ia,gg],encapsulation:2})};var dTA=["knob"],BTA=["valueIndicatorContainer"];function ETA(t,e){if(t&1&&(S(0,"div",2,1)(2,"div",5)(3,"span",6),tA(4),R()()()),t&2){let A=P();_(4),Mt(A.valueIndicatorText)}}var hTA=["trackActive"],QTA=["*"];function uTA(t,e){if(t&1&&UA(0,"div"),t&2){let A=e.$implicit,i=e.$index,n=P(3);vo(A===0?"mdc-slider__tick-mark--active":"mdc-slider__tick-mark--inactive"),so("transform",n._calcTickMarkTransform(i))}}function fTA(t,e){if(t&1&&ln(0,uTA,1,4,"div",8,Kd),t&2){let A=P(2);gn(A._tickMarks)}}function mTA(t,e){if(t&1&&(S(0,"div",6,1),NA(2,fTA,2,0),R()),t&2){let A=P();_(2),FA(A._cachedWidth?2:-1)}}function pTA(t,e){if(t&1&&UA(0,"mat-slider-visual-thumb",7),t&2){let A=P();vA("discrete",A.discrete)("thumbPosition",1)("valueIndicatorText",A.startValueIndicatorText)}}var $t=function(t){return t[t.START=1]="START",t[t.END=2]="END",t}($t||{}),Ch=function(t){return t[t.ACTIVE=0]="ACTIVE",t[t.INACTIVE=1]="INACTIVE",t}(Ch||{}),pG=new BA("_MatSlider"),zaA=new BA("_MatSliderThumb"),wTA=new BA("_MatSliderRangeThumb"),HaA=new BA("_MatSliderVisualThumb");var DTA=(()=>{class t{_cdr=m(lt);_ngZone=m(de);_slider=m(pG);_renderer=m(Gi);_listenerCleanups;discrete;thumbPosition;valueIndicatorText;_ripple;_knob;_valueIndicatorContainer;_sliderInput;_sliderInputEl;_hoverRippleRef;_focusRippleRef;_activeRippleRef;_isHovered=!1;_isActive=!1;_isValueIndicatorVisible=!1;_hostElement=m(te).nativeElement;_platform=m(Zt);constructor(){}ngAfterViewInit(){let A=this._slider._getInput(this.thumbPosition);A&&(this._ripple.radius=24,this._sliderInput=A,this._sliderInputEl=this._sliderInput._hostElement,this._ngZone.runOutsideAngular(()=>{let i=this._sliderInputEl,n=this._renderer;this._listenerCleanups=[n.listen(i,"pointermove",this._onPointerMove),n.listen(i,"pointerdown",this._onDragStart),n.listen(i,"pointerup",this._onDragEnd),n.listen(i,"pointerleave",this._onMouseLeave),n.listen(i,"focus",this._onFocus),n.listen(i,"blur",this._onBlur)]}))}ngOnDestroy(){this._listenerCleanups?.forEach(A=>A())}_onPointerMove=A=>{if(this._sliderInput._isFocused)return;let i=this._hostElement.getBoundingClientRect(),n=this._slider._isCursorOnSliderThumb(A,i);this._isHovered=n,n?this._showHoverRipple():this._hideRipple(this._hoverRippleRef)};_onMouseLeave=()=>{this._isHovered=!1,this._hideRipple(this._hoverRippleRef)};_onFocus=()=>{this._hideRipple(this._hoverRippleRef),this._showFocusRipple(),this._hostElement.classList.add("mdc-slider__thumb--focused")};_onBlur=()=>{this._isActive||this._hideRipple(this._focusRippleRef),this._isHovered&&this._showHoverRipple(),this._hostElement.classList.remove("mdc-slider__thumb--focused")};_onDragStart=A=>{A.button===0&&(this._isActive=!0,this._showActiveRipple())};_onDragEnd=()=>{this._isActive=!1,this._hideRipple(this._activeRippleRef),this._sliderInput._isFocused||this._hideRipple(this._focusRippleRef),this._platform.SAFARI&&this._showHoverRipple()};_showHoverRipple(){this._isShowingRipple(this._hoverRippleRef)||(this._hoverRippleRef=this._showRipple({enterDuration:0,exitDuration:0}),this._hoverRippleRef?.element.classList.add("mat-mdc-slider-hover-ripple"))}_showFocusRipple(){this._isShowingRipple(this._focusRippleRef)||(this._focusRippleRef=this._showRipple({enterDuration:0,exitDuration:0},!0),this._focusRippleRef?.element.classList.add("mat-mdc-slider-focus-ripple"))}_showActiveRipple(){this._isShowingRipple(this._activeRippleRef)||(this._activeRippleRef=this._showRipple({enterDuration:225,exitDuration:400}),this._activeRippleRef?.element.classList.add("mat-mdc-slider-active-ripple"))}_isShowingRipple(A){return A?.state===_s.FADING_IN||A?.state===_s.VISIBLE}_showRipple(A,i){if(!this._slider.disabled&&(this._showValueIndicator(),this._slider._isRange&&this._slider._getThumb(this.thumbPosition===$t.START?$t.END:$t.START)._showValueIndicator(),!(this._slider._globalRippleOptions?.disabled&&!i)))return this._ripple.launch({animation:this._slider._noopAnimations?{enterDuration:0,exitDuration:0}:A,centered:!0,persistent:!0})}_hideRipple(A){if(A?.fadeOut(),this._isShowingAnyRipple())return;this._slider._isRange||this._hideValueIndicator();let i=this._getSibling();i._isShowingAnyRipple()||(this._hideValueIndicator(),i._hideValueIndicator())}_showValueIndicator(){this._hostElement.classList.add("mdc-slider__thumb--with-indicator")}_hideValueIndicator(){this._hostElement.classList.remove("mdc-slider__thumb--with-indicator")}_getSibling(){return this._slider._getThumb(this.thumbPosition===$t.START?$t.END:$t.START)}_getValueIndicatorContainer(){return this._valueIndicatorContainer?.nativeElement}_getKnob(){return this._knob.nativeElement}_isShowingAnyRipple(){return this._isShowingRipple(this._hoverRippleRef)||this._isShowingRipple(this._focusRippleRef)||this._isShowingRipple(this._activeRippleRef)}static \u0275fac=function(i){return new(i||t)};static \u0275cmp=YA({type:t,selectors:[["mat-slider-visual-thumb"]],viewQuery:function(i,n){if(i&1&&(Ge(Gs,5),Ge(dTA,5),Ge(BTA,5)),i&2){let o;$A(o=Ae())&&(n._ripple=o.first),$A(o=Ae())&&(n._knob=o.first),$A(o=Ae())&&(n._valueIndicatorContainer=o.first)}},hostAttrs:[1,"mdc-slider__thumb","mat-mdc-slider-visual-thumb"],inputs:{discrete:"discrete",thumbPosition:"thumbPosition",valueIndicatorText:"valueIndicatorText"},features:[ct([{provide:HaA,useExisting:t}])],decls:4,vars:2,consts:[["knob",""],["valueIndicatorContainer",""],[1,"mdc-slider__value-indicator-container"],[1,"mdc-slider__thumb-knob"],["matRipple","",1,"mat-focus-indicator",3,"matRippleDisabled"],[1,"mdc-slider__value-indicator"],[1,"mdc-slider__value-indicator-text"]],template:function(i,n){i&1&&(NA(0,ETA,5,1,"div",2),UA(1,"div",3,0)(3,"div",4)),i&2&&(FA(n.discrete?0:-1),_(3),vA("matRippleDisabled",!0))},dependencies:[Gs],styles:[".mat-mdc-slider-visual-thumb .mat-ripple{height:100%;width:100%}.mat-mdc-slider .mdc-slider__tick-marks{justify-content:start}.mat-mdc-slider .mdc-slider__tick-marks .mdc-slider__tick-mark--active,.mat-mdc-slider .mdc-slider__tick-marks .mdc-slider__tick-mark--inactive{position:absolute;left:2px}"],encapsulation:2,changeDetection:0})}return t})(),OaA=(()=>{class t{_ngZone=m(de);_cdr=m(lt);_elementRef=m(te);_dir=m(bo,{optional:!0});_globalRippleOptions=m(L2,{optional:!0});_trackActive;_thumbs;_input;_inputs;get disabled(){return this._disabled}set disabled(A){this._disabled=A;let i=this._getInput($t.END),n=this._getInput($t.START);i&&(i.disabled=this._disabled),n&&(n.disabled=this._disabled)}_disabled=!1;get discrete(){return this._discrete}set discrete(A){this._discrete=A,this._updateValueIndicatorUIs()}_discrete=!1;showTickMarks=!1;get min(){return this._min}set min(A){let i=isNaN(A)?this._min:A;this._min!==i&&this._updateMin(i)}_min=0;color;disableRipple=!1;_updateMin(A){let i=this._min;this._min=A,this._isRange?this._updateMinRange({old:i,new:A}):this._updateMinNonRange(A),this._onMinMaxOrStepChange()}_updateMinRange(A){let i=this._getInput($t.END),n=this._getInput($t.START),o=i.value,r=n.value;n.min=A.new,i.min=Math.max(A.new,n.value),n.max=Math.min(i.max,i.value),n._updateWidthInactive(),i._updateWidthInactive(),A.new<A.old?this._onTranslateXChangeBySideEffect(i,n):this._onTranslateXChangeBySideEffect(n,i),o!==i.value&&this._onValueChange(i),r!==n.value&&this._onValueChange(n)}_updateMinNonRange(A){let i=this._getInput($t.END);if(i){let n=i.value;i.min=A,i._updateThumbUIByValue(),this._updateTrackUI(i),n!==i.value&&this._onValueChange(i)}}get max(){return this._max}set max(A){let i=isNaN(A)?this._max:A;this._max!==i&&this._updateMax(i)}_max=100;_updateMax(A){let i=this._max;this._max=A,this._isRange?this._updateMaxRange({old:i,new:A}):this._updateMaxNonRange(A),this._onMinMaxOrStepChange()}_updateMaxRange(A){let i=this._getInput($t.END),n=this._getInput($t.START),o=i.value,r=n.value;i.max=A.new,n.max=Math.min(A.new,i.value),i.min=n.value,i._updateWidthInactive(),n._updateWidthInactive(),A.new>A.old?this._onTranslateXChangeBySideEffect(n,i):this._onTranslateXChangeBySideEffect(i,n),o!==i.value&&this._onValueChange(i),r!==n.value&&this._onValueChange(n)}_updateMaxNonRange(A){let i=this._getInput($t.END);if(i){let n=i.value;i.max=A,i._updateThumbUIByValue(),this._updateTrackUI(i),n!==i.value&&this._onValueChange(i)}}get step(){return this._step}set step(A){let i=isNaN(A)?this._step:A;this._step!==i&&this._updateStep(i)}_step=1;_updateStep(A){this._step=A,this._isRange?this._updateStepRange():this._updateStepNonRange(),this._onMinMaxOrStepChange()}_updateStepRange(){let A=this._getInput($t.END),i=this._getInput($t.START),n=A.value,o=i.value,r=i.value;A.min=this._min,i.max=this._max,A.step=this._step,i.step=this._step,this._platform.SAFARI&&(A.value=A.value,i.value=i.value),A.min=Math.max(this._min,i.value),i.max=Math.min(this._max,A.value),i._updateWidthInactive(),A._updateWidthInactive(),A.value<r?this._onTranslateXChangeBySideEffect(i,A):this._onTranslateXChangeBySideEffect(A,i),n!==A.value&&this._onValueChange(A),o!==i.value&&this._onValueChange(i)}_updateStepNonRange(){let A=this._getInput($t.END);if(A){let i=A.value;A.step=this._step,this._platform.SAFARI&&(A.value=A.value),A._updateThumbUIByValue(),i!==A.value&&this._onValueChange(A)}}displayWith=A=>`${A}`;_tickMarks;_noopAnimations;_dirChangeSubscription;_resizeObserver;_cachedWidth;_cachedLeft;_rippleRadius=24;startValueIndicatorText="";endValueIndicatorText="";_endThumbTransform;_startThumbTransform;_isRange=!1;_isRtl=!1;_hasViewInitialized=!1;_tickMarkTrackWidth=0;_hasAnimation=!1;_resizeTimer=null;_platform=m(Zt);constructor(){m(Ln).load(Qr);let A=m(mi,{optional:!0});this._noopAnimations=A==="NoopAnimations",this._dir&&(this._dirChangeSubscription=this._dir.change.subscribe(()=>this._onDirChange()),this._isRtl=this._dir.value==="rtl")}_knobRadius=8;_inputPadding;ngAfterViewInit(){this._platform.isBrowser&&this._updateDimensions();let A=this._getInput($t.END),i=this._getInput($t.START);this._isRange=!!A&&!!i,this._cdr.detectChanges();let n=this._getThumb($t.END);this._rippleRadius=n._ripple.radius,this._inputPadding=this._rippleRadius-this._knobRadius,this._isRange?this._initUIRange(A,i):this._initUINonRange(A),this._updateTrackUI(A),this._updateTickMarkUI(),this._updateTickMarkTrackUI(),this._observeHostResize(),this._cdr.detectChanges()}_initUINonRange(A){A.initProps(),A.initUI(),this._updateValueIndicatorUI(A),this._hasViewInitialized=!0,A._updateThumbUIByValue()}_initUIRange(A,i){A.initProps(),A.initUI(),i.initProps(),i.initUI(),A._updateMinMax(),i._updateMinMax(),A._updateStaticStyles(),i._updateStaticStyles(),this._updateValueIndicatorUIs(),this._hasViewInitialized=!0,A._updateThumbUIByValue(),i._updateThumbUIByValue()}ngOnDestroy(){this._dirChangeSubscription.unsubscribe(),this._resizeObserver?.disconnect(),this._resizeObserver=null}_onDirChange(){this._isRtl=this._dir?.value==="rtl",this._isRange?this._onDirChangeRange():this._onDirChangeNonRange(),this._updateTickMarkUI()}_onDirChangeRange(){let A=this._getInput($t.END),i=this._getInput($t.START);A._setIsLeftThumb(),i._setIsLeftThumb(),A.translateX=A._calcTranslateXByValue(),i.translateX=i._calcTranslateXByValue(),A._updateStaticStyles(),i._updateStaticStyles(),A._updateWidthInactive(),i._updateWidthInactive(),A._updateThumbUIByValue(),i._updateThumbUIByValue()}_onDirChangeNonRange(){this._getInput($t.END)._updateThumbUIByValue()}_observeHostResize(){typeof ResizeObserver>"u"||!ResizeObserver||this._ngZone.runOutsideAngular(()=>{this._resizeObserver=new ResizeObserver(()=>{this._isActive()||(this._resizeTimer&&clearTimeout(this._resizeTimer),this._onResize())}),this._resizeObserver.observe(this._elementRef.nativeElement)})}_isActive(){return this._getThumb($t.START)._isActive||this._getThumb($t.END)._isActive}_getValue(A=$t.END){let i=this._getInput(A);return i?i.value:this.min}_skipUpdate(){return!!(this._getInput($t.START)?._skipUIUpdate||this._getInput($t.END)?._skipUIUpdate)}_updateDimensions(){this._cachedWidth=this._elementRef.nativeElement.offsetWidth,this._cachedLeft=this._elementRef.nativeElement.getBoundingClientRect().left}_setTrackActiveStyles(A){let i=this._trackActive.nativeElement.style;i.left=A.left,i.right=A.right,i.transformOrigin=A.transformOrigin,i.transform=A.transform}_calcTickMarkTransform(A){let i=A*(this._tickMarkTrackWidth/(this._tickMarks.length-1));return`translateX(${this._isRtl?this._cachedWidth-6-i:i}px`}_onTranslateXChange(A){this._hasViewInitialized&&(this._updateThumbUI(A),this._updateTrackUI(A),this._updateOverlappingThumbUI(A))}_onTranslateXChangeBySideEffect(A,i){this._hasViewInitialized&&(A._updateThumbUIByValue(),i._updateThumbUIByValue())}_onValueChange(A){this._hasViewInitialized&&(this._updateValueIndicatorUI(A),this._updateTickMarkUI(),this._cdr.detectChanges())}_onMinMaxOrStepChange(){this._hasViewInitialized&&(this._updateTickMarkUI(),this._updateTickMarkTrackUI(),this._cdr.markForCheck())}_onResize(){if(this._hasViewInitialized){if(this._updateDimensions(),this._isRange){let A=this._getInput($t.END),i=this._getInput($t.START);A._updateThumbUIByValue(),i._updateThumbUIByValue(),A._updateStaticStyles(),i._updateStaticStyles(),A._updateMinMax(),i._updateMinMax(),A._updateWidthInactive(),i._updateWidthInactive()}else{let A=this._getInput($t.END);A&&A._updateThumbUIByValue()}this._updateTickMarkUI(),this._updateTickMarkTrackUI(),this._cdr.detectChanges()}}_thumbsOverlap=!1;_areThumbsOverlapping(){let A=this._getInput($t.START),i=this._getInput($t.END);return!A||!i?!1:i.translateX-A.translateX<20}_updateOverlappingThumbClassNames(A){let i=A.getSibling(),n=this._getThumb(A.thumbPosition);this._getThumb(i.thumbPosition)._hostElement.classList.remove("mdc-slider__thumb--top"),n._hostElement.classList.toggle("mdc-slider__thumb--top",this._thumbsOverlap)}_updateOverlappingThumbUI(A){!this._isRange||this._skipUpdate()||this._thumbsOverlap!==this._areThumbsOverlapping()&&(this._thumbsOverlap=!this._thumbsOverlap,this._updateOverlappingThumbClassNames(A))}_updateThumbUI(A){if(this._skipUpdate())return;let i=this._getThumb(A.thumbPosition===$t.END?$t.END:$t.START);i._hostElement.style.transform=`translateX(${A.translateX}px)`}_updateValueIndicatorUI(A){if(this._skipUpdate())return;let i=this.displayWith(A.value);if(this._hasViewInitialized?A._valuetext.set(i):A._hostElement.setAttribute("aria-valuetext",i),this.discrete){A.thumbPosition===$t.START?this.startValueIndicatorText=i:this.endValueIndicatorText=i;let n=this._getThumb(A.thumbPosition);i.length<3?n._hostElement.classList.add("mdc-slider__thumb--short-value"):n._hostElement.classList.remove("mdc-slider__thumb--short-value")}}_updateValueIndicatorUIs(){let A=this._getInput($t.END),i=this._getInput($t.START);A&&this._updateValueIndicatorUI(A),i&&this._updateValueIndicatorUI(i)}_updateTickMarkTrackUI(){if(!this.showTickMarks||this._skipUpdate())return;let A=this._step&&this._step>0?this._step:1,n=(Math.floor(this.max/A)*A-this.min)/(this.max-this.min);this._tickMarkTrackWidth=(this._cachedWidth-6)*n}_updateTrackUI(A){this._skipUpdate()||(this._isRange?this._updateTrackUIRange(A):this._updateTrackUINonRange(A))}_updateTrackUIRange(A){let i=A.getSibling();if(!i||!this._cachedWidth)return;let n=Math.abs(i.translateX-A.translateX)/this._cachedWidth;A._isLeftThumb&&this._cachedWidth?this._setTrackActiveStyles({left:"auto",right:`${this._cachedWidth-i.translateX}px`,transformOrigin:"right",transform:`scaleX(${n})`}):this._setTrackActiveStyles({left:`${i.translateX}px`,right:"auto",transformOrigin:"left",transform:`scaleX(${n})`})}_updateTrackUINonRange(A){this._isRtl?this._setTrackActiveStyles({left:"auto",right:"0px",transformOrigin:"right",transform:`scaleX(${1-A.fillPercentage})`}):this._setTrackActiveStyles({left:"0px",right:"auto",transformOrigin:"left",transform:`scaleX(${A.fillPercentage})`})}_updateTickMarkUI(){if(!this.showTickMarks||this.step===void 0||this.min===void 0||this.max===void 0)return;let A=this.step>0?this.step:1;this._isRange?this._updateTickMarkUIRange(A):this._updateTickMarkUINonRange(A)}_updateTickMarkUINonRange(A){let i=this._getValue(),n=Math.max(Math.round((i-this.min)/A),0)+1,o=Math.max(Math.round((this.max-i)/A),0)-1;this._isRtl?n++:o++,this._tickMarks=Array(n).fill(Ch.ACTIVE).concat(Array(o).fill(Ch.INACTIVE))}_updateTickMarkUIRange(A){let i=this._getValue(),n=this._getValue($t.START),o=Math.max(Math.round((n-this.min)/A),0),r=Math.max(Math.round((i-n)/A)+1,0),s=Math.max(Math.round((this.max-i)/A),0);this._tickMarks=Array(o).fill(Ch.INACTIVE).concat(Array(r).fill(Ch.ACTIVE),Array(s).fill(Ch.INACTIVE))}_getInput(A){if(A===$t.END&&this._input)return this._input;if(this._inputs?.length)return A===$t.START?this._inputs.first:this._inputs.last}_getThumb(A){return A===$t.END?this._thumbs?.last:this._thumbs?.first}_setTransition(A){this._hasAnimation=!this._platform.IOS&&A&&!this._noopAnimations,this._elementRef.nativeElement.classList.toggle("mat-mdc-slider-with-animation",this._hasAnimation)}_isCursorOnSliderThumb(A,i){let n=i.width/2,o=i.x+n,r=i.y+n,s=A.clientX-o,a=A.clientY-r;return Math.pow(s,2)+Math.pow(a,2)<Math.pow(n,2)}static \u0275fac=function(i){return new(i||t)};static \u0275cmp=YA({type:t,selectors:[["mat-slider"]],contentQueries:function(i,n,o){if(i&1&&(Ii(o,zaA,5),Ii(o,wTA,4)),i&2){let r;$A(r=Ae())&&(n._input=r.first),$A(r=Ae())&&(n._inputs=r)}},viewQuery:function(i,n){if(i&1&&(Ge(hTA,5),Ge(HaA,5)),i&2){let o;$A(o=Ae())&&(n._trackActive=o.first),$A(o=Ae())&&(n._thumbs=o)}},hostAttrs:[1,"mat-mdc-slider","mdc-slider"],hostVars:12,hostBindings:function(i,n){i&2&&(vo("mat-"+(n.color||"primary")),ue("mdc-slider--range",n._isRange)("mdc-slider--disabled",n.disabled)("mdc-slider--discrete",n.discrete)("mdc-slider--tick-marks",n.showTickMarks)("_mat-animation-noopable",n._noopAnimations))},inputs:{disabled:[2,"disabled","disabled",ae],discrete:[2,"discrete","discrete",ae],showTickMarks:[2,"showTickMarks","showTickMarks",ae],min:[2,"min","min",Mi],color:"color",disableRipple:[2,"disableRipple","disableRipple",ae],max:[2,"max","max",Mi],step:[2,"step","step",Mi],displayWith:"displayWith"},exportAs:["matSlider"],features:[ct([{provide:pG,useExisting:t}])],ngContentSelectors:QTA,decls:9,vars:5,consts:[["trackActive",""],["tickMarkContainer",""],[1,"mdc-slider__track"],[1,"mdc-slider__track--inactive"],[1,"mdc-slider__track--active"],[1,"mdc-slider__track--active_fill"],[1,"mdc-slider__tick-marks"],[3,"discrete","thumbPosition","valueIndicatorText"],[3,"class","transform"]],template:function(i,n){i&1&&(Yt(),xe(0),S(1,"div",2),UA(2,"div",3),S(3,"div",4),UA(4,"div",5,0),R(),NA(6,mTA,3,1,"div",6),R(),NA(7,pTA,1,3,"mat-slider-visual-thumb",7),UA(8,"mat-slider-visual-thumb",7)),i&2&&(_(6),FA(n.showTickMarks?6:-1),_(),FA(n._isRange?7:-1),_(),vA("discrete",n.discrete)("thumbPosition",2)("valueIndicatorText",n.endValueIndicatorText))},dependencies:[DTA],styles:['.mdc-slider__track{position:absolute;top:50%;transform:translateY(-50%);width:100%;pointer-events:none;height:var(--mdc-slider-inactive-track-height, 4px)}.mdc-slider__track--active,.mdc-slider__track--inactive{display:flex;height:100%;position:absolute;width:100%}.mdc-slider__track--active{overflow:hidden;border-radius:var(--mdc-slider-active-track-shape, var(--mat-sys-corner-full));height:var(--mdc-slider-active-track-height, 4px);top:calc((var(--mdc-slider-inactive-track-height, 4px) - var(--mdc-slider-active-track-height, 4px))/2)}.mdc-slider__track--active_fill{border-top-style:solid;box-sizing:border-box;height:100%;width:100%;position:relative;transform-origin:left;transition:transform 80ms ease;border-color:var(--mdc-slider-active-track-color, var(--mat-sys-primary));border-top-width:var(--mdc-slider-active-track-height, 4px)}.mdc-slider--disabled .mdc-slider__track--active_fill{border-color:var(--mdc-slider-disabled-active-track-color, var(--mat-sys-on-surface))}[dir=rtl] .mdc-slider__track--active_fill{-webkit-transform-origin:right;transform-origin:right}.mdc-slider__track--inactive{left:0;top:0;opacity:.24;background-color:var(--mdc-slider-inactive-track-color, var(--mat-sys-surface-variant));height:var(--mdc-slider-inactive-track-height, 4px);border-radius:var(--mdc-slider-inactive-track-shape, var(--mat-sys-corner-full))}.mdc-slider--disabled .mdc-slider__track--inactive{background-color:var(--mdc-slider-disabled-inactive-track-color, var(--mat-sys-on-surface));opacity:.24}.mdc-slider__track--inactive::before{position:absolute;box-sizing:border-box;width:100%;height:100%;top:0;left:0;border:1px solid rgba(0,0,0,0);border-radius:inherit;content:"";pointer-events:none}@media(forced-colors: active){.mdc-slider__track--inactive::before{border-color:CanvasText}}.mdc-slider__value-indicator-container{bottom:44px;left:50%;pointer-events:none;position:absolute;transform:translateX(-50%);transform:var(--mat-slider-value-indicator-container-transform, translateX(-50%) rotate(-45deg))}.mdc-slider__thumb--with-indicator .mdc-slider__value-indicator-container{pointer-events:auto}.mdc-slider__value-indicator{display:flex;align-items:center;border-radius:4px;height:32px;padding:0 12px;transform:scale(0);transform-origin:bottom;opacity:1;transition:transform 100ms cubic-bezier(0.4, 0, 1, 1);word-break:normal;background-color:var(--mdc-slider-label-container-color, var(--mat-sys-primary));color:var(--mdc-slider-label-label-text-color, var(--mat-sys-on-primary));width:var(--mat-slider-value-indicator-width, 28px);height:var(--mat-slider-value-indicator-height, 28px);padding:var(--mat-slider-value-indicator-padding, 0);opacity:var(--mat-slider-value-indicator-opacity, 1);border-radius:var(--mat-slider-value-indicator-border-radius, 50% 50% 50% 0)}.mdc-slider__thumb--with-indicator .mdc-slider__value-indicator{transition:transform 100ms cubic-bezier(0, 0, 0.2, 1);transform:scale(1)}.mdc-slider__value-indicator::before{border-left:6px solid rgba(0,0,0,0);border-right:6px solid rgba(0,0,0,0);border-top:6px solid;bottom:-5px;content:"";height:0;left:50%;position:absolute;transform:translateX(-50%);width:0;display:var(--mat-slider-value-indicator-caret-display, none);border-top-color:var(--mdc-slider-label-container-color, var(--mat-sys-primary))}.mdc-slider__value-indicator::after{position:absolute;box-sizing:border-box;width:100%;height:100%;top:0;left:0;border:1px solid rgba(0,0,0,0);border-radius:inherit;content:"";pointer-events:none}@media(forced-colors: active){.mdc-slider__value-indicator::after{border-color:CanvasText}}.mdc-slider__value-indicator-text{text-align:center;width:var(--mat-slider-value-indicator-width, 28px);transform:var(--mat-slider-value-indicator-text-transform, rotate(45deg));font-family:var(--mdc-slider-label-label-text-font, var(--mat-sys-label-medium-font));font-size:var(--mdc-slider-label-label-text-size, var(--mat-sys-label-medium-size));font-weight:var(--mdc-slider-label-label-text-weight, var(--mat-sys-label-medium-weight));line-height:var(--mdc-slider-label-label-text-line-height, var(--mat-sys-label-medium-line-height));letter-spacing:var(--mdc-slider-label-label-text-tracking, var(--mat-sys-label-medium-tracking))}.mdc-slider__thumb{-webkit-user-select:none;user-select:none;display:flex;left:-24px;outline:none;position:absolute;height:48px;width:48px;pointer-events:none}.mdc-slider--discrete .mdc-slider__thumb{transition:transform 80ms ease}.mdc-slider--disabled .mdc-slider__thumb{pointer-events:none}.mdc-slider__thumb--top{z-index:1}.mdc-slider__thumb-knob{position:absolute;box-sizing:border-box;left:50%;top:50%;transform:translate(-50%, -50%);border-style:solid;width:var(--mdc-slider-handle-width, 20px);height:var(--mdc-slider-handle-height, 20px);border-width:calc(var(--mdc-slider-handle-height, 20px)/2) calc(var(--mdc-slider-handle-width, 20px)/2);box-shadow:var(--mdc-slider-handle-elevation, var(--mat-sys-level1));background-color:var(--mdc-slider-handle-color, var(--mat-sys-primary));border-color:var(--mdc-slider-handle-color, var(--mat-sys-primary));border-radius:var(--mdc-slider-handle-shape, var(--mat-sys-corner-full))}.mdc-slider__thumb:hover .mdc-slider__thumb-knob{background-color:var(--mdc-slider-hover-handle-color, var(--mat-sys-primary));border-color:var(--mdc-slider-hover-handle-color, var(--mat-sys-primary))}.mdc-slider__thumb--focused .mdc-slider__thumb-knob{background-color:var(--mdc-slider-focus-handle-color, var(--mat-sys-primary));border-color:var(--mdc-slider-focus-handle-color, var(--mat-sys-primary))}.mdc-slider--disabled .mdc-slider__thumb-knob{background-color:var(--mdc-slider-disabled-handle-color, var(--mat-sys-on-surface));border-color:var(--mdc-slider-disabled-handle-color, var(--mat-sys-on-surface))}.mdc-slider__thumb--top .mdc-slider__thumb-knob,.mdc-slider__thumb--top.mdc-slider__thumb:hover .mdc-slider__thumb-knob,.mdc-slider__thumb--top.mdc-slider__thumb--focused .mdc-slider__thumb-knob{border:solid 1px #fff;box-sizing:content-box;border-color:var(--mdc-slider-with-overlap-handle-outline-color, var(--mat-sys-on-primary));border-width:var(--mdc-slider-with-overlap-handle-outline-width, 1px)}.mdc-slider__tick-marks{align-items:center;box-sizing:border-box;display:flex;height:100%;justify-content:space-between;padding:0 1px;position:absolute;width:100%}.mdc-slider__tick-mark--active,.mdc-slider__tick-mark--inactive{width:var(--mdc-slider-with-tick-marks-container-size, 2px);height:var(--mdc-slider-with-tick-marks-container-size, 2px);border-radius:var(--mdc-slider-with-tick-marks-container-shape, var(--mat-sys-corner-full))}.mdc-slider__tick-mark--inactive{opacity:var(--mdc-slider-with-tick-marks-inactive-container-opacity, 0.38);background-color:var(--mdc-slider-with-tick-marks-inactive-container-color, var(--mat-sys-on-surface-variant))}.mdc-slider--disabled .mdc-slider__tick-mark--inactive{opacity:var(--mdc-slider-with-tick-marks-inactive-container-opacity, 0.38);background-color:var(--mdc-slider-with-tick-marks-disabled-container-color, var(--mat-sys-on-surface))}.mdc-slider__tick-mark--active{opacity:var(--mdc-slider-with-tick-marks-active-container-opacity, 0.38);background-color:var(--mdc-slider-with-tick-marks-active-container-color, var(--mat-sys-on-primary))}.mdc-slider__input{cursor:pointer;left:2px;margin:0;height:44px;opacity:0;position:absolute;top:2px;width:44px;box-sizing:content-box}.mdc-slider__input.mat-mdc-slider-input-no-pointer-events{pointer-events:none}.mdc-slider__input.mat-slider__right-input{left:auto;right:0}.mat-mdc-slider{display:inline-block;box-sizing:border-box;outline:none;vertical-align:middle;cursor:pointer;height:48px;margin:0 8px;position:relative;touch-action:pan-y;width:auto;min-width:112px;-webkit-tap-highlight-color:rgba(0,0,0,0)}.mat-mdc-slider.mdc-slider--disabled{cursor:auto;opacity:.38}.mat-mdc-slider .mdc-slider__thumb,.mat-mdc-slider .mdc-slider__track--active_fill{transition-duration:0ms}.mat-mdc-slider.mat-mdc-slider-with-animation .mdc-slider__thumb,.mat-mdc-slider.mat-mdc-slider-with-animation .mdc-slider__track--active_fill{transition-duration:80ms}.mat-mdc-slider.mdc-slider--discrete .mdc-slider__thumb,.mat-mdc-slider.mdc-slider--discrete .mdc-slider__track--active_fill{transition-duration:0ms}.mat-mdc-slider.mat-mdc-slider-with-animation .mdc-slider__thumb,.mat-mdc-slider.mat-mdc-slider-with-animation .mdc-slider__track--active_fill{transition-duration:80ms}.mat-mdc-slider .mat-ripple .mat-ripple-element{background-color:var(--mat-slider-ripple-color, var(--mat-sys-primary))}.mat-mdc-slider .mat-ripple .mat-mdc-slider-hover-ripple{background-color:var(--mat-slider-hover-state-layer-color, color-mix(in srgb, var(--mat-sys-primary) 5%, transparent))}.mat-mdc-slider .mat-ripple .mat-mdc-slider-focus-ripple,.mat-mdc-slider .mat-ripple .mat-mdc-slider-active-ripple{background-color:var(--mat-slider-focus-state-layer-color, color-mix(in srgb, var(--mat-sys-primary) 20%, transparent))}.mat-mdc-slider._mat-animation-noopable.mdc-slider--discrete .mdc-slider__thumb,.mat-mdc-slider._mat-animation-noopable.mdc-slider--discrete .mdc-slider__track--active_fill,.mat-mdc-slider._mat-animation-noopable .mdc-slider__value-indicator{transition:none}.mat-mdc-slider .mat-focus-indicator::before{border-radius:50%}.mdc-slider__thumb--focused .mat-focus-indicator::before{content:""}'],encapsulation:2,changeDetection:0})}return t})();var yTA={provide:uc,useExisting:nr(()=>wG),multi:!0};var wG=(()=>{class t{_ngZone=m(de);_elementRef=m(te);_cdr=m(lt);_slider=m(pG);_platform=m(Zt);_listenerCleanups;get value(){return Mi(this._hostElement.value,0)}set value(A){A=isNaN(A)?0:A;let i=A+"";if(!this._hasSetInitialValue){this._initialValue=i;return}this._isActive||this._setValue(i)}_setValue(A){this._hostElement.value=A,this._updateThumbUIByValue(),this._slider._onValueChange(this),this._cdr.detectChanges(),this._slider._cdr.markForCheck()}valueChange=new XA;dragStart=new XA;dragEnd=new XA;get translateX(){return this._slider.min>=this._slider.max?(this._translateX=this._tickMarkOffset,this._translateX):(this._translateX===void 0&&(this._translateX=this._calcTranslateXByValue()),this._translateX)}set translateX(A){this._translateX=A}_translateX;thumbPosition=$t.END;get min(){return Mi(this._hostElement.min,0)}set min(A){this._hostElement.min=A+"",this._cdr.detectChanges()}get max(){return Mi(this._hostElement.max,0)}set max(A){this._hostElement.max=A+"",this._cdr.detectChanges()}get step(){return Mi(this._hostElement.step,0)}set step(A){this._hostElement.step=A+"",this._cdr.detectChanges()}get disabled(){return ae(this._hostElement.disabled)}set disabled(A){this._hostElement.disabled=A,this._cdr.detectChanges(),this._slider.disabled!==this.disabled&&(this._slider.disabled=this.disabled)}get percentage(){return this._slider.min>=this._slider.max?this._slider._isRtl?1:0:(this.value-this._slider.min)/(this._slider.max-this._slider.min)}get fillPercentage(){return this._slider._cachedWidth?this._translateX===0?0:this.translateX/this._slider._cachedWidth:this._slider._isRtl?1:0}_hostElement=this._elementRef.nativeElement;_valuetext=Ko("");_knobRadius=8;_tickMarkOffset=3;_isActive=!1;_isFocused=!1;_setIsFocused(A){this._isFocused=A}_hasSetInitialValue=!1;_initialValue;_formControl;_destroyed=new HA;_skipUIUpdate=!1;_onChangeFn;_onTouchedFn=()=>{};_isControlInitialized=!1;constructor(){let A=m(Gi);this._ngZone.runOutsideAngular(()=>{this._listenerCleanups=[A.listen(this._hostElement,"pointerdown",this._onPointerDown.bind(this)),A.listen(this._hostElement,"pointermove",this._onPointerMove.bind(this)),A.listen(this._hostElement,"pointerup",this._onPointerUp.bind(this))]})}ngOnDestroy(){this._listenerCleanups.forEach(A=>A()),this._destroyed.next(),this._destroyed.complete(),this.dragStart.complete(),this.dragEnd.complete()}initProps(){this._updateWidthInactive(),this.disabled!==this._slider.disabled&&(this._slider.disabled=!0),this.step=this._slider.step,this.min=this._slider.min,this.max=this._slider.max,this._initValue()}initUI(){this._updateThumbUIByValue()}_initValue(){this._hasSetInitialValue=!0,this._initialValue===void 0?this.value=this._getDefaultValue():(this._hostElement.value=this._initialValue,this._updateThumbUIByValue(),this._slider._onValueChange(this),this._cdr.detectChanges())}_getDefaultValue(){return this.min}_onBlur(){this._setIsFocused(!1),this._onTouchedFn()}_onFocus(){this._slider._setTransition(!1),this._slider._updateTrackUI(this),this._setIsFocused(!0)}_onChange(){this.valueChange.emit(this.value),this._isActive&&this._updateThumbUIByValue({withAnimation:!0})}_onInput(){this._onChangeFn?.(this.value),(this._slider.step||!this._isActive)&&this._updateThumbUIByValue({withAnimation:!0}),this._slider._onValueChange(this)}_onNgControlValueChange(){(!this._isActive||!this._isFocused)&&(this._slider._onValueChange(this),this._updateThumbUIByValue()),this._slider.disabled=this._formControl.disabled}_onPointerDown(A){if(!(this.disabled||A.button!==0)){if(this._platform.IOS){let i=this._slider._isCursorOnSliderThumb(A,this._slider._getThumb(this.thumbPosition)._hostElement.getBoundingClientRect());this._isActive=i,this._updateWidthActive(),this._slider._updateDimensions();return}this._isActive=!0,this._setIsFocused(!0),this._updateWidthActive(),this._slider._updateDimensions(),this._slider.step||this._updateThumbUIByPointerEvent(A,{withAnimation:!0}),this.disabled||(this._handleValueCorrection(A),this.dragStart.emit({source:this,parent:this._slider,value:this.value}))}}_handleValueCorrection(A){this._skipUIUpdate=!0,setTimeout(()=>{this._skipUIUpdate=!1,this._fixValue(A)},0)}_fixValue(A){let i=A.clientX-this._slider._cachedLeft,n=this._slider._cachedWidth,o=this._slider.step===0?1:this._slider.step,r=Math.floor((this._slider.max-this._slider.min)/o),s=this._slider._isRtl?1-i/n:i/n,c=Math.round(s*r)/r*(this._slider.max-this._slider.min)+this._slider.min,l=Math.round(c/o)*o,I=this.value;if(l===I){this._slider._onValueChange(this),this._slider.step>0?this._updateThumbUIByValue():this._updateThumbUIByPointerEvent(A,{withAnimation:this._slider._hasAnimation});return}this.value=l,this.valueChange.emit(this.value),this._onChangeFn?.(this.value),this._slider._onValueChange(this),this._slider.step>0?this._updateThumbUIByValue():this._updateThumbUIByPointerEvent(A,{withAnimation:this._slider._hasAnimation})}_onPointerMove(A){!this._slider.step&&this._isActive&&this._updateThumbUIByPointerEvent(A)}_onPointerUp(){this._isActive&&(this._isActive=!1,this._platform.SAFARI&&this._setIsFocused(!1),this.dragEnd.emit({source:this,parent:this._slider,value:this.value}),setTimeout(()=>this._updateWidthInactive(),this._platform.IOS?10:0))}_clamp(A){let i=this._tickMarkOffset,n=this._slider._cachedWidth-this._tickMarkOffset;return Math.max(Math.min(A,n),i)}_calcTranslateXByValue(){return this._slider._isRtl?(1-this.percentage)*(this._slider._cachedWidth-this._tickMarkOffset*2)+this._tickMarkOffset:this.percentage*(this._slider._cachedWidth-this._tickMarkOffset*2)+this._tickMarkOffset}_calcTranslateXByPointerEvent(A){return A.clientX-this._slider._cachedLeft}_updateWidthActive(){}_updateWidthInactive(){this._hostElement.style.padding=`0 ${this._slider._inputPadding}px`,this._hostElement.style.width=`calc(100% + ${this._slider._inputPadding-this._tickMarkOffset*2}px)`,this._hostElement.style.left=`-${this._slider._rippleRadius-this._tickMarkOffset}px`}_updateThumbUIByValue(A){this.translateX=this._clamp(this._calcTranslateXByValue()),this._updateThumbUI(A)}_updateThumbUIByPointerEvent(A,i){this.translateX=this._clamp(this._calcTranslateXByPointerEvent(A)),this._updateThumbUI(i)}_updateThumbUI(A){this._slider._setTransition(!!A?.withAnimation),this._slider._onTranslateXChange(this)}writeValue(A){(this._isControlInitialized||A!==null)&&(this.value=A)}registerOnChange(A){this._onChangeFn=A,this._isControlInitialized=!0}registerOnTouched(A){this._onTouchedFn=A}setDisabledState(A){this.disabled=A}focus(){this._hostElement.focus()}blur(){this._hostElement.blur()}static \u0275fac=function(i){return new(i||t)};static \u0275dir=OA({type:t,selectors:[["input","matSliderThumb",""]],hostAttrs:["type","range",1,"mdc-slider__input"],hostVars:1,hostBindings:function(i,n){i&1&&mA("change",function(){return n._onChange()})("input",function(){return n._onInput()})("blur",function(){return n._onBlur()})("focus",function(){return n._onFocus()}),i&2&&_e("aria-valuetext",n._valuetext())},inputs:{value:[2,"value","value",Mi]},outputs:{valueChange:"valueChange",dragStart:"dragStart",dragEnd:"dragEnd"},exportAs:["matSliderThumb"],features:[ct([yTA,{provide:zaA,useExisting:t}])]})}return t})();var PaA=(()=>{class t{static \u0275fac=function(i){return new(i||t)};static \u0275mod=ge({type:t});static \u0275inj=le({imports:[Ve,Xa]})}return t})();var nf=class t{constructor(e,A,i){this.dialogRef=e;this.fb=A;this.data=i;this.evalMetrics=this.data.evalMetrics,this.evalForm=this.fb.group({tool_trajectory_avg_score_threshold:[this.getEvalMetricThresholdFromData("tool_trajectory_avg_score"),[Oa.required,Oa.min(0),Oa.max(1)]],response_match_score_threshold:[this.getEvalMetricThresholdFromData("response_match_score"),[Oa.required,Oa.min(0),Oa.max(1)]]})}evalForm;evalMetrics=[];getEvalMetricThresholdFromData(e){return this.evalMetrics.find(A=>A.metricName===e)?.threshold??0}onStart(){if(this.evalForm.valid){let{tool_trajectory_avg_score_threshold:e,response_match_score_threshold:A}=this.evalForm.value;for(let i of this.evalMetrics)i.metricName==="tool_trajectory_avg_score"?i.threshold=e:i.metricName==="response_match_score"&&(i.threshold=A);this.dialogRef.close(this.evalMetrics)}}onCancel(){this.dialogRef.close(null)}static \u0275fac=function(A){return new(A||t)(zA(cr),zA(BH),zA($r))};static \u0275cmp=YA({type:t,selectors:[["app-run-eval-config-dialog"]],standalone:!1,decls:26,vars:3,consts:[[1,"dialog-container"],["mat-dialog-title","",1,"dialog-title"],[1,"eval-form",3,"formGroup"],[1,"metric-row"],[1,"metric-name"],[1,"flex-1","pl-4"],["min","0","max","1","step","0.1","thumbLabel","",1,"threshold-slider"],["matSliderThumb","","formControlName","tool_trajectory_avg_score_threshold"],[1,"threshold-value"],["matSliderThumb","","formControlName","response_match_score_threshold"],["align","end",1,"dialog-actions"],["mat-button","",1,"cancel-button",3,"click"],["mat-button","",1,"save-button",3,"click"]],template:function(A,i){A&1&&(S(0,"div",0)(1,"h2",1),tA(2,"EVALUATION METRIC"),R(),S(3,"mat-dialog-content")(4,"form",2)(5,"div",3)(6,"div",4),tA(7,"Tool trajectory avg score: "),R(),S(8,"div",5)(9,"mat-slider",6),UA(10,"input",7),R(),S(11,"span",8),tA(12),R()()(),S(13,"div",3)(14,"div",4),tA(15,"Response match score: "),R(),S(16,"div",5)(17,"mat-slider",6),UA(18,"input",9),R(),S(19,"span",8),tA(20),R()()()()(),S(21,"mat-dialog-actions",10)(22,"button",11),mA("click",function(){return i.onCancel()}),tA(23,"Cancel"),R(),S(24,"button",12),mA("click",function(){return i.onStart()}),tA(25,"Start"),R()()()),A&2&&(_(4),vA("formGroup",i.evalForm),_(8),ot(" ",i.evalForm.controls.tool_trajectory_avg_score_threshold.value," "),_(8),ot(" ",i.evalForm.controls.response_match_score_threshold.value," "))},dependencies:[CH,fc,na,rH,ur,hs,ga,Ia,OaA,wG,bI,lM],styles:[".dialog-container[_ngcontent-%COMP%]{border-radius:12px;padding:18px;width:500px;box-shadow:0 8px 16px #0006}.threshold-slider[_ngcontent-%COMP%]{--mdc-slider-active-track-color: #4285f4;--mdc-slider-inactive-track-color: #616161;--mdc-slider-handle-color: #4285f4;--mdc-slider-ripple-color: #4285f4;width:100px}.metric-row[_ngcontent-%COMP%]{display:flex;flex-direction:row;align-items:center}.metric-name[_ngcontent-%COMP%]{width:250px}.threshold-value[_ngcontent-%COMP%]{margin-left:20px}.mdc-slider__thumb--with-indicator[_ngcontent-%COMP%]{background-color:var(--mdc-slider-handle-color, black);border:none!important;box-shadow:none!important}"]})};var Jg=class t{constructor(e){this.http=e}apiServerDomain=Es.getApiServerBaseUrl();createSession(e,A){if(this.apiServerDomain!=null){let i=this.apiServerDomain+`/apps/${A}/users/${e}/sessions`;return this.http.post(i,null)}return new Ze}listSessions(e,A){if(this.apiServerDomain!=null){let i=this.apiServerDomain+`/apps/${A}/users/${e}/sessions`;return this.http.get(i)}return new Ze}deleteSession(e,A,i){let n=this.apiServerDomain+`/apps/${A}/users/${e}/sessions/${i}`;return this.http.delete(n)}getSession(e,A,i){let n=this.apiServerDomain+`/apps/${A}/users/${e}/sessions/${i}`;return this.http.get(n)}importSession(e,A,i){if(this.apiServerDomain!=null){let n=this.apiServerDomain+`/apps/${A}/users/${e}/sessions`;return this.http.post(n,{appName:A,userId:e,events:i})}return new Ze}static \u0275fac=function(A){return new(A||t)(he(Bs))};static \u0275prov=SA({token:t,factory:t.\u0275fac,providedIn:"root"})};var bTA=["determinateSpinner"];function MTA(t,e){if(t&1&&(hr(),S(0,"svg",11),UA(1,"circle",12),R()),t&2){let A=P();_e("viewBox",A._viewBox()),_(),so("stroke-dasharray",A._strokeCircumference(),"px")("stroke-dashoffset",A._strokeCircumference()/2,"px")("stroke-width",A._circleStrokeWidth(),"%"),_e("r",A._circleRadius())}}var kTA=new BA("mat-progress-spinner-default-options",{providedIn:"root",factory:STA});function STA(){return{diameter:jaA}}var jaA=100,RTA=10,qaA=(()=>{class t{_elementRef=m(te);_noopAnimations;get color(){return this._color||this._defaultColor}set color(A){this._color=A}_color;_defaultColor="primary";_determinateCircle;constructor(){let A=m(mi,{optional:!0}),i=m(kTA);this._noopAnimations=A==="NoopAnimations"&&!!i&&!i._forceAnimations,this.mode=this._elementRef.nativeElement.nodeName.toLowerCase()==="mat-spinner"?"indeterminate":"determinate",i&&(i.color&&(this.color=this._defaultColor=i.color),i.diameter&&(this.diameter=i.diameter),i.strokeWidth&&(this.strokeWidth=i.strokeWidth))}mode;get value(){return this.mode==="determinate"?this._value:0}set value(A){this._value=Math.max(0,Math.min(100,A||0))}_value=0;get diameter(){return this._diameter}set diameter(A){this._diameter=A||0}_diameter=jaA;get strokeWidth(){return this._strokeWidth??this.diameter/10}set strokeWidth(A){this._strokeWidth=A||0}_strokeWidth;_circleRadius(){return(this.diameter-RTA)/2}_viewBox(){let A=this._circleRadius()*2+this.strokeWidth;return`0 0 ${A} ${A}`}_strokeCircumference(){return 2*Math.PI*this._circleRadius()}_strokeDashOffset(){return this.mode==="determinate"?this._strokeCircumference()*(100-this._value)/100:null}_circleStrokeWidth(){return this.strokeWidth/this.diameter*100}static \u0275fac=function(i){return new(i||t)};static \u0275cmp=YA({type:t,selectors:[["mat-progress-spinner"],["mat-spinner"]],viewQuery:function(i,n){if(i&1&&Ge(bTA,5),i&2){let o;$A(o=Ae())&&(n._determinateCircle=o.first)}},hostAttrs:["role","progressbar","tabindex","-1",1,"mat-mdc-progress-spinner","mdc-circular-progress"],hostVars:18,hostBindings:function(i,n){i&2&&(_e("aria-valuemin",0)("aria-valuemax",100)("aria-valuenow",n.mode==="determinate"?n.value:null)("mode",n.mode),vo("mat-"+n.color),so("width",n.diameter,"px")("height",n.diameter,"px")("--mdc-circular-progress-size",n.diameter+"px")("--mdc-circular-progress-active-indicator-width",n.diameter+"px"),ue("_mat-animation-noopable",n._noopAnimations)("mdc-circular-progress--indeterminate",n.mode==="indeterminate"))},inputs:{color:"color",mode:"mode",value:[2,"value","value",Mi],diameter:[2,"diameter","diameter",Mi],strokeWidth:[2,"strokeWidth","strokeWidth",Mi]},exportAs:["matProgressSpinner"],decls:14,vars:11,consts:[["circle",""],["determinateSpinner",""],["aria-hidden","true",1,"mdc-circular-progress__determinate-container"],["xmlns","http://www.w3.org/2000/svg","focusable","false",1,"mdc-circular-progress__determinate-circle-graphic"],["cx","50%","cy","50%",1,"mdc-circular-progress__determinate-circle"],["aria-hidden","true",1,"mdc-circular-progress__indeterminate-container"],[1,"mdc-circular-progress__spinner-layer"],[1,"mdc-circular-progress__circle-clipper","mdc-circular-progress__circle-left"],[3,"ngTemplateOutlet"],[1,"mdc-circular-progress__gap-patch"],[1,"mdc-circular-progress__circle-clipper","mdc-circular-progress__circle-right"],["xmlns","http://www.w3.org/2000/svg","focusable","false",1,"mdc-circular-progress__indeterminate-circle-graphic"],["cx","50%","cy","50%"]],template:function(i,n){if(i&1&&(NA(0,MTA,2,8,"ng-template",null,0,fQ),S(2,"div",2,1),hr(),S(4,"svg",3),UA(5,"circle",4),R()(),uI(),S(6,"div",5)(7,"div",6)(8,"div",7),Mr(9,8),R(),S(10,"div",9),Mr(11,8),R(),S(12,"div",10),Mr(13,8),R()()()),i&2){let o=or(1);_(4),_e("viewBox",n._viewBox()),_(),so("stroke-dasharray",n._strokeCircumference(),"px")("stroke-dashoffset",n._strokeDashOffset(),"px")("stroke-width",n._circleStrokeWidth(),"%"),_e("r",n._circleRadius()),_(4),vA("ngTemplateOutlet",o),_(2),vA("ngTemplateOutlet",o),_(2),vA("ngTemplateOutlet",o)}},dependencies:[vQ],styles:[".mat-mdc-progress-spinner{display:block;overflow:hidden;line-height:0;position:relative;direction:ltr;transition:opacity 250ms cubic-bezier(0.4, 0, 0.6, 1)}.mat-mdc-progress-spinner circle{stroke-width:var(--mdc-circular-progress-active-indicator-width, 4px)}.mat-mdc-progress-spinner._mat-animation-noopable,.mat-mdc-progress-spinner._mat-animation-noopable .mdc-circular-progress__determinate-circle{transition:none !important}.mat-mdc-progress-spinner._mat-animation-noopable .mdc-circular-progress__indeterminate-circle-graphic,.mat-mdc-progress-spinner._mat-animation-noopable .mdc-circular-progress__spinner-layer,.mat-mdc-progress-spinner._mat-animation-noopable .mdc-circular-progress__indeterminate-container{animation:none !important}.mat-mdc-progress-spinner._mat-animation-noopable .mdc-circular-progress__indeterminate-container circle{stroke-dasharray:0 !important}@media(forced-colors: active){.mat-mdc-progress-spinner .mdc-circular-progress__indeterminate-circle-graphic,.mat-mdc-progress-spinner .mdc-circular-progress__determinate-circle{stroke:currentColor;stroke:CanvasText}}.mdc-circular-progress__determinate-container,.mdc-circular-progress__indeterminate-circle-graphic,.mdc-circular-progress__indeterminate-container,.mdc-circular-progress__spinner-layer{position:absolute;width:100%;height:100%}.mdc-circular-progress__determinate-container{transform:rotate(-90deg)}.mdc-circular-progress--indeterminate .mdc-circular-progress__determinate-container{opacity:0}.mdc-circular-progress__indeterminate-container{font-size:0;letter-spacing:0;white-space:nowrap;opacity:0}.mdc-circular-progress--indeterminate .mdc-circular-progress__indeterminate-container{opacity:1;animation:mdc-circular-progress-container-rotate 1568.2352941176ms linear infinite}.mdc-circular-progress__determinate-circle-graphic,.mdc-circular-progress__indeterminate-circle-graphic{fill:rgba(0,0,0,0)}.mat-mdc-progress-spinner .mdc-circular-progress__determinate-circle,.mat-mdc-progress-spinner .mdc-circular-progress__indeterminate-circle-graphic{stroke:var(--mdc-circular-progress-active-indicator-color, var(--mat-sys-primary))}@media(forced-colors: active){.mat-mdc-progress-spinner .mdc-circular-progress__determinate-circle,.mat-mdc-progress-spinner .mdc-circular-progress__indeterminate-circle-graphic{stroke:CanvasText}}.mdc-circular-progress__determinate-circle{transition:stroke-dashoffset 500ms cubic-bezier(0, 0, 0.2, 1)}.mdc-circular-progress__gap-patch{position:absolute;top:0;left:47.5%;box-sizing:border-box;width:5%;height:100%;overflow:hidden}.mdc-circular-progress__gap-patch .mdc-circular-progress__indeterminate-circle-graphic{left:-900%;width:2000%;transform:rotate(180deg)}.mdc-circular-progress__circle-clipper .mdc-circular-progress__indeterminate-circle-graphic{width:200%}.mdc-circular-progress__circle-right .mdc-circular-progress__indeterminate-circle-graphic{left:-100%}.mdc-circular-progress--indeterminate .mdc-circular-progress__circle-left .mdc-circular-progress__indeterminate-circle-graphic{animation:mdc-circular-progress-left-spin 1333ms cubic-bezier(0.4, 0, 0.2, 1) infinite both}.mdc-circular-progress--indeterminate .mdc-circular-progress__circle-right .mdc-circular-progress__indeterminate-circle-graphic{animation:mdc-circular-progress-right-spin 1333ms cubic-bezier(0.4, 0, 0.2, 1) infinite both}.mdc-circular-progress__circle-clipper{display:inline-flex;position:relative;width:50%;height:100%;overflow:hidden}.mdc-circular-progress--indeterminate .mdc-circular-progress__spinner-layer{animation:mdc-circular-progress-spinner-layer-rotate 5332ms cubic-bezier(0.4, 0, 0.2, 1) infinite both}@keyframes mdc-circular-progress-container-rotate{to{transform:rotate(360deg)}}@keyframes mdc-circular-progress-spinner-layer-rotate{12.5%{transform:rotate(135deg)}25%{transform:rotate(270deg)}37.5%{transform:rotate(405deg)}50%{transform:rotate(540deg)}62.5%{transform:rotate(675deg)}75%{transform:rotate(810deg)}87.5%{transform:rotate(945deg)}100%{transform:rotate(1080deg)}}@keyframes mdc-circular-progress-left-spin{from{transform:rotate(265deg)}50%{transform:rotate(130deg)}to{transform:rotate(265deg)}}@keyframes mdc-circular-progress-right-spin{from{transform:rotate(-265deg)}50%{transform:rotate(-130deg)}to{transform:rotate(-265deg)}}"],encapsulation:2,changeDetection:0})}return t})();var VaA=(()=>{class t{static \u0275fac=function(i){return new(i||t)};static \u0275mod=ge({type:t});static \u0275inj=le({imports:[Ve]})}return t})();function xTA(t,e){if(t&1){let A=De();S(0,"div",1)(1,"div"),tA(2,"All eval sets"),R(),S(3,"mat-icon",2),mA("click",function(){LA(A);let n=P();return xA(n.openNewEvalSetDialog())}),tA(4,"add"),R()()}}function FTA(t,e){if(t&1){let A=De();S(0,"div")(1,"div",3)(2,"div",4),tA(3," Create New Evaluation Set "),R(),S(4,"div",5),tA(5," An evaluation set is a curated collection of evaluation cases, where each case includes input-output examples for assessing agent performance. "),R(),S(6,"div",6),mA("click",function(){LA(A);let n=P();return xA(n.openNewEvalSetDialog())}),tA(7," Create Evaluation Set "),R()()()}}function NTA(t,e){if(t&1){let A=De();S(0,"div",8),mA("click",function(){let n=LA(A).$implicit,o=P(2);return xA(o.selectEvalSet(n))}),S(1,"div",9)(2,"span",10),tA(3,"folder"),R(),S(4,"div",11),tA(5),R()(),S(6,"div")(7,"mat-icon",12),tA(8,"chevron_right"),R()()()}if(t&2){let A=e.$implicit;_(5),Mt(A)}}function _TA(t,e){if(t&1&&(S(0,"div"),ln(1,NTA,9,1,"div",7,Kn),R()),t&2){let A=P();_(),gn(A.evalsets)}}function GTA(t,e){if(t&1){let A=De();S(0,"th",29)(1,"mat-checkbox",30),mA("change",function(n){LA(A);let o=P(4);return xA(n?o.toggleAllRows():null)}),R()()}if(t&2){let A=P(4);_(),vA("checked",A.selection.hasValue()&&A.isAllSelected())("indeterminate",A.selection.hasValue()&&!A.isAllSelected())}}function UTA(t,e){if(t&1){let A=De();S(0,"td",31)(1,"mat-checkbox",32),mA("click",function(n){return LA(A),xA(n.stopPropagation())})("change",function(n){let o=LA(A).$implicit,r=P(4);return xA(n?r.selection.toggle(o):null)}),R()()}if(t&2){let A=e.$implicit,i=P(4);_(),vA("checked",i.selection.isSelected(A))}}function KTA(t,e){t&1&&(S(0,"th",29),tA(1," Case ID "),R())}function YTA(t,e){if(t&1){let A=De();S(0,"td",33),mA("click",function(){let n=LA(A).$implicit,o=P(4);return xA(o.getEvalCase(n))}),tA(1),R()}if(t&2){let A,i=e.$implicit,n=P(4);ue("selected-eval-case",i===((A=n.selectedEvalCase())==null?null:A.evalId)),_(),ot(" ",i," ")}}function JTA(t,e){t&1&&(S(0,"th",29),tA(1," Result "),R())}function TTA(t,e){if(t&1){let A=De();S(0,"button",35),mA("click",function(){LA(A);let n=P().$implicit,o=P(4);return xA(o.getSession(n))}),S(1,"span",36),tA(2),R(),S(3,"div",37),tA(4),R()()}if(t&2){let A=P().$implicit,i=P(4);vA("ngClass",i.getEvalResultForCase(A)==1?"result-btn pass":"result-btn fail"),_(2),ot(" ",i.getEvalResultForCase(A)==1?"check":"close"," "),_(2),ot("",i.getEvalResultForCase(A)==1?"Pass":"Fail"," ")}}function zTA(t,e){if(t&1&&(S(0,"td",31),NA(1,TTA,5,3,"button",34),R()),t&2){let A=e.$implicit,i=P(4);_(),FA(i.getEvalResultForCase(A)?1:-1)}}function HTA(t,e){t&1&&UA(0,"tr",38)}function OTA(t,e){t&1&&UA(0,"tr",39)}function PTA(t,e){if(t&1){let A=De();S(0,"div")(1,"div",16)(2,"button",17),mA("click",function(){LA(A);let n=P(3);return xA(n.openEvalConfigDialog())}),tA(3,"Run Evaluation"),R(),S(4,"mat-icon",18),mA("click",function(){LA(A);let n=P(3);return xA(n.toggleEvalHistoryButton())}),tA(5,"history"),R()(),S(6,"div",19)(7,"table",20),f2(8,21),NA(9,GTA,2,2,"th",22)(10,UTA,2,1,"td",23),m2(),f2(11,24),NA(12,KTA,2,0,"th",22)(13,YTA,2,3,"td",25),m2(),f2(14,26),NA(15,JTA,2,0,"th",22)(16,zTA,2,1,"td",23),m2(),NA(17,HTA,1,0,"tr",27)(18,OTA,1,0,"tr",28),R()()()}if(t&2){let A=P(3);_(7),vA("dataSource",A.dataSource),_(10),vA("matHeaderRowDef",A.displayedColumns),_(),vA("matRowDefColumns",A.displayedColumns)}}function jTA(t,e){if(t&1&&(S(0,"div")(1,"span",50),tA(2,"|"),R(),S(3,"span",51),tA(4),R()()),t&2){let A=P().$implicit,i=P(4);_(4),ot("",i.getFailCountForCurrentResult(A.evaluationResults.evaluationResults)," Failed")}}function qTA(t,e){if(t&1&&(S(0,"span",52),tA(1),R()),t&2){let A=e.$implicit;_(),Mb(" ",A.metricName,": ",A.threshold," ")}}function VTA(t,e){if(t&1&&(S(0,"div",46),ln(1,qTA,2,2,"span",52,Kn),R()),t&2){let A=P().$implicit,i=P(4);_(),gn(i.getEvalMetrics(A))}}function ZTA(t,e){if(t&1){let A=De();S(0,"div")(1,"div",53)(2,"span"),tA(3),R(),S(4,"button",54),mA("click",function(){let n=LA(A).$implicit,o=P(6);return xA(o.getHistorySession(n))}),S(5,"span",36),tA(6),R(),S(7,"div",37),tA(8),R()()()()}if(t&2){let A=e.$implicit;_(3),ot(" ",A.evalId," "),_(),vA("ngClass",A.finalEvalStatus==1?"result-btn pass":"result-btn fail"),_(2),ot(" ",A.finalEvalStatus==1?"check":"close"," "),_(2),ot("",A.finalEvalStatus==1?"PASS":"FAIL"," ")}}function WTA(t,e){if(t&1&&(S(0,"div",49),ln(1,ZTA,9,4,"div",null,Kn),R()),t&2){let A=P().$implicit,i=P(4);_(),gn(i.generateHistoryEvaluationDatasource(A.timestamp))}}function XTA(t,e){if(t&1){let A=De();S(0,"div")(1,"div",40)(2,"div",41)(3,"div",42)(4,"div",43),tA(5),R(),S(6,"div",44)(7,"span",45),tA(8),R(),NA(9,jTA,5,1,"div"),R(),NA(10,VTA,3,0,"div",46),R(),S(11,"div",47)(12,"mat-icon",48),mA("click",function(){let n=LA(A).$implicit,o=P(4);return xA(o.toggleHistoryStatusCard(n.timestamp))}),tA(13),R()()(),NA(14,WTA,3,0,"div",49),R()()}if(t&2){let A=e.$implicit,i=P(4);_(5),Mt(i.formatTimestamp(A.timestamp)),_(3),ot("",i.getPassCountForCurrentResult(A.evaluationResults.evaluationResults)," Passed"),_(),FA(i.getFailCountForCurrentResult(A.evaluationResults.evaluationResults)>0?9:-1),_(),FA(i.getEvalMetrics(A)?10:-1),_(3),Mt(i.getEvaluationStatusCardActionButtonIcon(A.timestamp)),_(),FA(i.isEvaluationStatusCardToggled(A.timestamp)?14:-1)}}function $TA(t,e){if(t&1&&(S(0,"div"),ln(1,XTA,15,6,"div",null,Kn),R()),t&2){let A=P(3);_(),gn(A.getEvalHistoryOfCurrentSetSorted())}}function AzA(t,e){if(t&1&&(S(0,"div"),NA(1,PTA,19,3,"div")(2,$TA,3,0,"div"),R()),t&2){let A=P(2);_(),FA(A.showEvalHistory()?-1:1),_(),FA(A.showEvalHistory()?2:-1)}}function ezA(t,e){if(t&1){let A=De();S(0,"button",55),mA("click",function(){LA(A);let n=P(2);return xA(n.openNewEvalCaseDialog())}),S(1,"div",56)(2,"mat-icon"),tA(3,"add"),R(),S(4,"div",57),tA(5),R()()()}if(t&2){let A=P(2);_(5),ot(" Add current session to ",A.selectedEvalSet," ")}}function tzA(t,e){t&1&&(S(0,"div"),UA(1,"mat-spinner",58),R()),t&2&&(_(),vA("diameter",28)("strokeWidth",3))}function izA(t,e){if(t&1){let A=De();S(0,"div")(1,"div",9)(2,"mat-icon",13),mA("click",function(){LA(A);let n=P();return xA(n.clearSelectedEvalSet())}),tA(3,"chevron_left"),R(),S(4,"div",14),mA("click",function(){LA(A);let n=P();return xA(n.clearSelectedEvalSet())}),tA(5),R()(),NA(6,AzA,3,2,"div")(7,ezA,6,1,"button",15)(8,tzA,2,2,"div"),R()}if(t&2){let A=P();_(5),ot(" ",A.selectedEvalSet," "),_(),FA(A.evalCases.length>0&&!A.evalRunning()?6:-1),_(),FA(!A.evalRunning()&&!A.showEvalHistory()?7:-1),_(),FA(A.evalRunning()?8:-1)}}var PC=class t{constructor(e,A){this.evalService=e;this.sessionService=A;this.evalCasesSubject.subscribe(i=>{!this.selectedEvalCase()&&this.deletedEvalCaseIndex>=0&&i.length>0?(this.selectNewEvalCase(i),this.deletedEvalCaseIndex=-1):i.length===0&&this.shouldReturnToSession.emit(!0)})}checkboxes;appName="";userId="";sessionId="";sessionSelected=new XA;shouldShowTab=new XA;evalNotInstalledMsg=new XA;evalCaseSelected=new XA;evalSetIdSelected=new XA;shouldReturnToSession=new XA;evalCasesSubject=new li([]);changeDetectorRef=m(lt);flagService=m(vB);displayedColumns=["select","evalId","finalEvalStatus"];evalsets=[];selectedEvalSet="";evalCases=[];selectedEvalCase=Ko(null);deletedEvalCaseIndex=-1;dataSource=new $3(this.evalCases);selection=new F2(!0,[]);showEvalHistory=Ko(!1);evalRunning=Ko(!1);evalMetrics=_aA;currentEvalResultBySet=new Map;dialog=m(Us);appEvaluationResults={};ngOnChanges(e){e.appName&&(this.selectedEvalSet="",this.evalCases=[],this.getEvalSet(),this.getEvaluationResult())}ngOnInit(){}selectNewEvalCase(e){let A=this.deletedEvalCaseIndex;this.deletedEvalCaseIndex===e.length&&(A=0),this.getEvalCase(e[A])}getEvalSet(){this.appName!=""&&this.evalService.getEvalSets(this.appName).pipe(dr(e=>e.status===404&&e.statusText==="Not Found"?(this.shouldShowTab.emit(!1),ve(null)):ve([]))).subscribe(e=>{e!==null&&(this.shouldShowTab.emit(!0),this.evalsets=e)})}openNewEvalSetDialog(){this.dialog.open(tf,{width:"600px",data:{appName:this.appName}}).afterClosed().subscribe(A=>{A&&this.getEvalSet()})}openNewEvalCaseDialog(){this.dialog.open(ef,{width:"600px",data:{appName:this.appName,userId:this.userId,sessionId:this.sessionId,evalSetId:this.selectedEvalSet}}).afterClosed().subscribe(A=>{A&&this.listEvalCases()})}listEvalCases(){this.evalCases=[],this.evalService.listEvalCases(this.appName,this.selectedEvalSet).subscribe(e=>{this.evalCases=e,this.dataSource=new $3(this.evalCases),this.evalCasesSubject.next(this.evalCases),this.changeDetectorRef.detectChanges()})}runEval(){if(this.evalRunning.set(!0),this.selection.selected.length==0){alert("No case selected!"),this.evalRunning.set(!1);return}this.evalService.runEval(this.appName,this.selectedEvalSet,this.selection.selected,this.evalMetrics).pipe(dr(e=>(e.error?.detail?.includes("not installed")&&this.evalNotInstalledMsg.emit(e.error.detail),ve([])))).subscribe(e=>{this.evalRunning.set(!1),this.currentEvalResultBySet.set(this.selectedEvalSet,e),this.getEvaluationResult()})}selectEvalSet(e){this.selectedEvalSet=e,this.listEvalCases()}clearSelectedEvalSet(){if(this.showEvalHistory()){this.toggleEvalHistoryButton();return}this.selectedEvalSet=""}isAllSelected(){let e=this.selection.selected.length,A=this.dataSource.data.length;return e===A}toggleAllRows(){if(this.isAllSelected()){this.selection.clear();return}this.selection.select(...this.dataSource.data)}getEvalResultForCase(e){let A=this.currentEvalResultBySet.get(this.selectedEvalSet)?.filter(i=>i.evalId==e);if(!(!A||A.length==0))return A[0].finalEvalStatus}formatToolUses(e){let A=[];for(let i of e)A.push({name:i.name,args:i.args});return A}addEvalCaseResultToEvents(e,A){let i=A.evalMetricResultPerInvocation,n=-1;if(i)for(let o=0;o<e.events.length;o++){let r=e.events[o];if(r.author==="user")n++;else{let s=i[n],a=1,c="",l=1,I=1;for(let C of s.evalMetricResults)if(C.evalStatus===2){a=2,c=C.metricName,l=C.score,I=C.threshold;break}r.evalStatus=a,(o===e.events.length-1||e.events[o+1].author==="user")&&this.addEvalFieldsToBotEvent(r,s,c,l,I)}}return e}addEvalFieldsToBotEvent(e,A,i,n,o){e.failedMetric=i,e.evalScore=n,e.evalThreshold=o,e.failedMetric==="tool_trajectory_avg_score"?(e.actualInvocationToolUses=this.formatToolUses(A.actualInvocation.intermediateData.toolUses),e.expectedInvocationToolUses=this.formatToolUses(A.expectedInvocation.intermediateData.toolUses)):e.failedMetric==="response_match_score"&&(e.actualFinalResponse=A.actualInvocation.finalResponse.parts[0].text,e.expectedFinalResponse=A.expectedInvocation.finalResponse.parts[0]?.text)}fromApiResultToSession(e){return{id:e?.id??"",appName:e?.appName??"",userId:e?.userId??"",state:e?.state??[],events:e?.events??[]}}getSession(e){let A=this.currentEvalResultBySet.get(this.selectedEvalSet)?.filter(n=>n.evalId==e)[0],i=A.sessionId;this.sessionService.getSession(this.userId,this.appName,i).subscribe(n=>{this.addEvalCaseResultToEvents(n,A);let o=this.fromApiResultToSession(n);this.sessionSelected.emit(o)})}toggleEvalHistoryButton(){this.showEvalHistory.set(!this.showEvalHistory())}getEvalHistoryOfCurrentSet(){return this.appEvaluationResults[this.appName][this.selectedEvalSet]}getEvalHistoryOfCurrentSetSorted(){let e=this.getEvalHistoryOfCurrentSet();return Object.keys(e).sort((n,o)=>o.localeCompare(n)).map(n=>({timestamp:n,evaluationResults:e[n]}))}getPassCountForCurrentResult(e){return e.filter(A=>A.finalEvalStatus==1).length}getFailCountForCurrentResult(e){return e.filter(A=>A.finalEvalStatus==2).length}formatTimestamp(e){let A=Number(e);if(isNaN(A))return"Invalid timestamp provided";let i=new Date(A*1e3);if(isNaN(i.getTime()))return"Invalid date created from timestamp";let n={month:"short",day:"numeric",year:"numeric",hour:"numeric",minute:"2-digit",hour12:!0};return new Intl.DateTimeFormat("en-US",n).format(i)}getEvaluationStatusCardActionButtonIcon(e){return this.getEvalHistoryOfCurrentSet()[e].isToggled?"keyboard_arrow_up":"keyboard_arrow_down"}toggleHistoryStatusCard(e){this.getEvalHistoryOfCurrentSet()[e].isToggled=!this.getEvalHistoryOfCurrentSet()[e].isToggled}isEvaluationStatusCardToggled(e){return this.getEvalHistoryOfCurrentSet()[e].isToggled}generateHistoryEvaluationDatasource(e){return this.getEvalHistoryOfCurrentSet()[e].evaluationResults}getHistorySession(e){this.addEvalCaseResultToEvents(e.sessionDetails,e);let A=this.fromApiResultToSession(e.sessionDetails);this.sessionSelected.emit(A)}getEvalCase(e){this.evalService.getEvalCase(this.appName,this.selectedEvalSet,e).subscribe(A=>{this.selectedEvalCase.set(A),this.evalCaseSelected.emit(A),this.evalSetIdSelected.emit(this.selectedEvalSet)})}resetEvalCase(){this.selectedEvalCase.set(null)}resetEvalResults(){this.currentEvalResultBySet.clear()}deleteEvalCase(e){this.evalService.deleteEvalCase(this.appName,this.selectedEvalSet,e).subscribe(A=>{this.deletedEvalCaseIndex=this.evalCases.indexOf(e),this.selectedEvalCase.set(null),this.listEvalCases()})}getEvaluationResult(){this.evalService.listEvalResults(this.appName).pipe(dr(e=>e.status===404&&e.statusText==="Not Found"?(this.shouldShowTab.emit(!1),ve(null)):ve([]))).subscribe(e=>{for(let A of e)this.evalService.getEvalResult(this.appName,A).subscribe(i=>{this.appEvaluationResults[this.appName]||(this.appEvaluationResults[this.appName]={}),this.appEvaluationResults[this.appName][i.evalSetId]||(this.appEvaluationResults[this.appName][i.evalSetId]={});let n=i.creationTimestamp;this.appEvaluationResults[this.appName][i.evalSetId][n]||(this.appEvaluationResults[this.appName][i.evalSetId][n]={isToggled:!1,evaluationResults:[]});let o={isToggled:!1,evaluationResults:i.evalCaseResults.map(r=>({setId:r.id,evalId:r.evalId,finalEvalStatus:r.finalEvalStatus,evalMetricResults:r.evalMetricResults,evalMetricResultPerInvocation:r.evalMetricResultPerInvocation,sessionId:r.sessionId,sessionDetails:r.sessionDetails,overallEvalMetricResults:r.overallEvalMetricResults??[]}))};this.appEvaluationResults[this.appName][i.evalSetId][n]=o})})}openEvalConfigDialog(){if(this.selection.selected.length==0){alert("No case selected!");return}this.dialog.open(nf,{maxWidth:"90vw",maxHeight:"90vh",data:{evalMetrics:this.evalMetrics}}).afterClosed().subscribe(A=>{A&&(this.evalMetrics=A,this.runEval())})}getEvalMetrics(e){if(!e||!e.evaluationResults||!e.evaluationResults.evaluationResults)return this.evalMetrics;let A=e.evaluationResults.evaluationResults;return A.length===0?this.evalMetrics:typeof A[0].overallEvalMetricResults>"u"||!A[0].overallEvalMetricResults||A[0].overallEvalMetricResults.length===0?this.evalMetrics:A[0].overallEvalMetricResults.map(n=>({metricName:n.metricName,threshold:n.threshold}))}static \u0275fac=function(A){return new(A||t)(zA(zc),zA(Jg))};static \u0275cmp=YA({type:t,selectors:[["app-eval-tab"]],viewQuery:function(A,i){if(A&1&&Ge(gh,5),A&2){let n;$A(n=Ae())&&(i.checkboxes=n)}},inputs:{appName:"appName",userId:"userId",sessionId:"sessionId"},outputs:{sessionSelected:"sessionSelected",shouldShowTab:"shouldShowTab",evalNotInstalledMsg:"evalNotInstalledMsg",evalCaseSelected:"evalCaseSelected",evalSetIdSelected:"evalSetIdSelected",shouldReturnToSession:"shouldReturnToSession"},standalone:!1,features:[Kt],decls:5,vars:4,consts:[[1,"eval-container"],[1,"eval-set-actions"],["matTooltip","Create new evaluation set",2,"cursor","pointer",3,"click"],[1,"empty-eval-info"],[1,"info-title"],[1,"info-detail"],[1,"info-create",3,"click"],[1,"eval-set-row"],[1,"eval-set-row",3,"click"],[2,"display","flex"],[1,"material-symbols-outlined",2,"margin-right","10px","padding-top","16px"],[2,"font-family","Roboto","font-size","14px","padding","16px","padding-top","20px"],[2,"padding-top","20px","color","#9AA0A6"],[2,"color","white","cursor","pointer",3,"click"],[2,"color","#9AA0A6","padding-top","2px","cursor","pointer",3,"click"],[1,"save-session-btn"],[1,"evaluation-tab-header"],[1,"run-eval-btn",3,"click"],["matTooltip","View eval run history",1,"evaluation-history-icon",3,"click"],[1,"mat-table-container",2,"margin-top","16px"],["mat-table","",3,"dataSource"],["matColumnDef","select"],["mat-header-cell","",4,"matHeaderCellDef"],["mat-cell","",4,"matCellDef"],["matColumnDef","evalId"],["mat-cell","","class","eval-case-id",3,"selected-eval-case","click",4,"matCellDef"],["matColumnDef","finalEvalStatus"],["mat-header-row","",4,"matHeaderRowDef"],["mat-row","",4,"matRowDef","matRowDefColumns"],["mat-header-cell",""],[3,"change","checked","indeterminate"],["mat-cell",""],[3,"click","change","checked"],["mat-cell","",1,"eval-case-id",3,"click"],["matTooltip","View eval run result",3,"ngClass"],["matTooltip","View eval run result",3,"click","ngClass"],[1,"material-symbols-outlined"],[2,"padding-top","4px"],["mat-header-row",""],["mat-row",""],[1,"status-card"],[1,"status-card__overview"],[1,"status-card__info"],[1,"status-card__timestamp"],[1,"status-card__summary"],[1,"status-card__passed"],[1,"status-card__metrics"],[1,"status-card__action"],[3,"click"],[1,"status-card__history-cases"],[1,"status-card__separator"],[1,"status-card__failed"],[1,"status-card__metric"],[1,"status-card__history-case"],[3,"click","ngClass"],[1,"save-session-btn",3,"click"],[1,"save-session-btn-detail"],[1,"save-session-btn-text"],[1,"eval-spinner",3,"diameter","strokeWidth"]],template:function(A,i){A&1&&(S(0,"div",0),NA(1,xTA,5,0,"div",1)(2,FTA,8,0,"div")(3,_TA,3,0,"div")(4,izA,9,4,"div"),R()),A&2&&(_(),FA(i.selectedEvalSet==""?1:-1),_(),FA(i.evalsets.length==0?2:-1),_(),FA(i.evalsets.length>0&&i.selectedEvalSet==""?3:-1),_(),FA(i.selectedEvalSet!=""?4:-1))},dependencies:[Ha,T2,gh,yaA,baA,RaA,MaA,vaA,LaA,kaA,SaA,xaA,FaA,wB,qaA],styles:[".eval-container[_ngcontent-%COMP%]{margin-top:20px;padding-left:25px;padding-right:25px}.eval-case-id[_ngcontent-%COMP%]{cursor:pointer}.eval-set-actions[_ngcontent-%COMP%]{display:flex;justify-content:space-between;color:#9aa0a6;font-style:normal;font-weight:700;font-size:14px}.empty-eval-info[_ngcontent-%COMP%]{margin-top:12px;background-color:#202124;border-radius:8px;box-shadow:0 2px 6px 2px #00000026,0 1px 2px #0000004d}.info-title[_ngcontent-%COMP%]{color:#e8eaed;font-family:Roboto;font-size:14px;font-weight:500;padding-top:13px;padding-right:16px;padding-left:16px}.info-detail[_ngcontent-%COMP%]{color:#e8eaed;font-family:Roboto;font-size:14px;font-weight:400;padding-top:13px;padding-right:16px;padding-left:16px;letter-spacing:.2px}.info-create[_ngcontent-%COMP%]{color:var(--Blue-300, #8ab4f8);font-size:14px;font-style:normal;font-weight:500;padding-right:16px;padding-left:16px;margin-top:19px;padding-bottom:16px;cursor:pointer}.eval-set-row[_ngcontent-%COMP%]{display:flex;justify-content:space-between;cursor:pointer}.selected-eval-case[_ngcontent-%COMP%]{font-weight:900;color:#8ab4f8}.save-session-btn[_ngcontent-%COMP%]{width:100%;background:linear-gradient(0deg,#8ab4f83d 0% 100%),#202124;border:none;border-radius:4px;margin-top:12px;cursor:pointer}.save-session-btn-detail[_ngcontent-%COMP%]{display:flex;padding:8px 16px 8px 12px;justify-content:center}.save-session-btn-text[_ngcontent-%COMP%]{padding-top:2px;color:var(--Blue-100, #d2e3fc);font-family:Google Sans;font-size:14px;font-style:normal;font-weight:500;line-height:20px;letter-spacing:.25px}.run-eval-btn[_ngcontent-%COMP%]{border-radius:4px;border:1px solid var(--Grey-700, #5f6368);background-color:transparent;padding:8px 24px;margin-top:16px;color:#8ab4f8;cursor:pointer}.run-eval-btn[_ngcontent-%COMP%]:hover{background-color:#202124}.result-btn[_ngcontent-%COMP%]{display:flex;background-color:transparent;border-radius:4px;border:1px solid var(--Grey-700, #5f6368);margin-top:4px;cursor:pointer}.result-btn[_ngcontent-%COMP%]:hover{background-color:#202124}.result-btn.pass[_ngcontent-%COMP%]{color:#44c265}.result-btn.fail[_ngcontent-%COMP%]{color:#ff8983}.evaluation-tab-header[_ngcontent-%COMP%]{display:flex;justify-content:space-between;align-items:center;width:100%}.evaluation-history-icon[_ngcontent-%COMP%]{cursor:pointer;margin-top:4px}.status-card[_ngcontent-%COMP%]{display:flex;flex-direction:column;align-items:center;border-radius:8px;background-color:#2d2d2d;padding:12px 16px;margin-top:12px}.status-card__overview[_ngcontent-%COMP%]{display:flex;justify-content:space-between;align-items:center;width:100%}.status-card__info[_ngcontent-%COMP%]{display:flex;flex-direction:column}.status-card__timestamp[_ngcontent-%COMP%]{font-size:.9em;color:#e0e0e0;margin-bottom:5px}.status-card__summary[_ngcontent-%COMP%]{display:flex;align-items:center;font-size:.95em;font-weight:500}.status-card__metrics[_ngcontent-%COMP%]{display:flex;align-items:center;font-size:.75em;font-weight:300;margin-top:3px}.status-card__metric[_ngcontent-%COMP%]{width:180px;color:#bbb}.status-card__failed[_ngcontent-%COMP%]{color:#ff6b6b}.status-card__separator[_ngcontent-%COMP%]{color:#666;margin:0 8px}.status-card__passed[_ngcontent-%COMP%]{color:#63e6be}.status-card__action[_ngcontent-%COMP%]{display:flex;align-items:center}.status-card__action[_ngcontent-%COMP%]   mat-icon[_ngcontent-%COMP%]{color:#bdbdbd;cursor:pointer;transition:transform .2s ease-in-out}.status-card__action[_ngcontent-%COMP%]   mat-icon[_ngcontent-%COMP%]:hover{opacity:.8}.status-card__action[_ngcontent-%COMP%]   .status-card__icon[_ngcontent-%COMP%]{color:#bdbdbd;font-size:1.2em;cursor:pointer}.status-card__action[_ngcontent-%COMP%]   .status-card__icon[_ngcontent-%COMP%]:hover{opacity:.8}.status-card__history-cases[_ngcontent-%COMP%]{display:flex;flex-direction:column;margin-top:3px;justify-content:flex-start;width:100%}.status-card__history-case[_ngcontent-%COMP%]{display:flex;justify-content:space-between;align-items:center;width:100%;margin-top:15px}.eval-spinner[_ngcontent-%COMP%]{margin-top:12px}"],changeDetection:0})};function ozA(t,e){t&1&&UA(0,"div",6)}function rzA(t,e){if(t&1&&(S(0,"div",3)(1,"div",5),ln(2,ozA,1,0,"div",6,Kd),R(),S(4,"span",7),tA(5),R(),S(6,"div",8),tA(7),S(8,"span",9),tA(9),R()(),S(10,"div",10)(11,"div",11),tA(12),R()()()),t&2){let A=e.$implicit,i=P();_(2),gn(i.getArray(A.level)),_(3),ot(" ",i.getSpanIcon(A.span.name)," "),_(),so("width",400-A.level*20,"px"),_(),ot(" ",A.span.name," "),_(2),ot(" (",(i.toMs(A.span.end_time)-i.toMs(A.span.start_time)).toFixed(2),"ms) "),_(2),so("left",i.getRelativeStart(A.span),"%")("width",i.getRelativeWidth(A.span),"%"),_(),ot(" ",(i.toMs(A.span.end_time)-i.toMs(A.span.start_time)).toFixed(2),"ms ")}}var of=class t{constructor(e,A){this.dialogRef=e;this.data=A}tree=[];baseStartTimeMs=0;totalDurationMs=1;flatTree=[];traceLabelIconMap=new Map([["Invocation","start"],["agent_run","directions_run"],["tool","build"],["call_llm","chat"]]);ngOnInit(){this.tree=this.buildSpanTree(this.data.spans),this.flatTree=this.flattenTree(this.tree);let e=this.getGlobalTimes(this.data.spans);this.baseStartTimeMs=e.start,this.totalDurationMs=e.duration}buildSpanTree(e){let A=e.map(o=>nA({},o)),i=new Map,n=[];return A.forEach(o=>i.set(o.span_id,o)),A.forEach(o=>{if(o.parent_span_id&&i.has(o.parent_span_id)){let r=i.get(o.parent_span_id);r.children=r.children||[],r.children.push(o)}else n.push(o)}),n}getGlobalTimes(e){let A=Math.min(...e.map(n=>this.toMs(n.start_time))),i=Math.max(...e.map(n=>this.toMs(n.end_time)));return{start:A,duration:i-A}}toMs(e){return e/1e6}getRelativeStart(e){return(this.toMs(e.start_time)-this.baseStartTimeMs)/this.totalDurationMs*100}getRelativeWidth(e){return(this.toMs(e.end_time)-this.toMs(e.start_time))/this.totalDurationMs*100}flattenTree(e,A=0){return e.flatMap(n=>[{span:n,level:A},...n.children?this.flattenTree(n.children,A+1):[]])}getSpanIcon(e){for(let[A,i]of this.traceLabelIconMap.entries())if(e.startsWith(A))return i;return"start"}getArray(e){return Array.from({length:e})}static \u0275fac=function(A){return new(A||t)(zA(cr),zA($r))};static \u0275cmp=YA({type:t,selectors:[["app-trace-chart"]],standalone:!1,decls:9,vars:1,consts:[["mat-dialog-title",""],[2,"margin-top","8px"],[1,"trace-container"],[1,"trace-row"],["mat-button","","mat-dialog-close",""],[1,"trace-indent"],[1,"indent-connector"],[1,"material-symbols-outlined",2,"margin-right","8px"],[1,"trace-label"],[1,"trace-duration"],[1,"trace-bar-container"],[1,"trace-bar"]],template:function(A,i){A&1&&(S(0,"h2",0),tA(1),R(),S(2,"mat-dialog-content",1)(3,"div",2),ln(4,rzA,13,10,"div",3,Kn),R()(),S(6,"mat-dialog-actions")(7,"button",4),tA(8,"Close"),R()()),A&2&&(_(),ot("Invocation ",i.data.invocId,""),_(3),gn(i.flatTree))},dependencies:[ur,hs,ga,Ia,gg],styles:[".trace-container[_ngcontent-%COMP%]{width:100%;white-space:nowrap;font-size:12px}.trace-label[_ngcontent-%COMP%]{width:400px;color:#e3e3e3;text-overflow:ellipsis;font-family:Google Sans Mono,monospace;font-size:14px;font-style:normal;font-weight:500;line-height:20px;letter-spacing:0px}.trace-bar-container[_ngcontent-%COMP%]{width:50vw;position:relative;height:16px}.trace-bar[_ngcontent-%COMP%]{position:absolute;height:18px;background-color:#2f4d65;border-radius:4px;padding-left:4px;overflow:hidden;font-size:11px;line-height:16px;color:#8dabbf;font-family:Google Sans}.trace-duration[_ngcontent-%COMP%]{color:#888;font-weight:400;margin-left:4px}.trace-row[_ngcontent-%COMP%]{display:flex;align-items:stretch;position:relative;height:32px}.trace-indent[_ngcontent-%COMP%]{display:flex;flex-shrink:0;height:100%}.indent-connector[_ngcontent-%COMP%]{width:20px;position:relative;height:100%}.vertical-line[_ngcontent-%COMP%]{position:absolute;top:0;bottom:0;left:9px;width:1px;background-color:#ccc}.horizontal-line[_ngcontent-%COMP%]{position:absolute;top:50%;left:9px;width:10px;height:1px;background-color:#ccc}"]})};var ZaA=(()=>{class t{get vertical(){return this._vertical}set vertical(A){this._vertical=Yo(A)}_vertical=!1;get inset(){return this._inset}set inset(A){this._inset=Yo(A)}_inset=!1;static \u0275fac=function(i){return new(i||t)};static \u0275cmp=YA({type:t,selectors:[["mat-divider"]],hostAttrs:["role","separator",1,"mat-divider"],hostVars:7,hostBindings:function(i,n){i&2&&(_e("aria-orientation",n.vertical?"vertical":"horizontal"),ue("mat-divider-vertical",n.vertical)("mat-divider-horizontal",!n.vertical)("mat-divider-inset",n.inset))},inputs:{vertical:"vertical",inset:"inset"},decls:0,vars:0,template:function(i,n){},styles:[".mat-divider{display:block;margin:0;border-top-style:solid;border-top-color:var(--mat-divider-color, var(--mat-sys-outline));border-top-width:var(--mat-divider-width, 1px)}.mat-divider.mat-divider-vertical{border-top:0;border-right-style:solid;border-right-color:var(--mat-divider-color, var(--mat-sys-outline));border-right-width:var(--mat-divider-width, 1px)}.mat-divider.mat-divider-inset{margin-left:80px}[dir=rtl] .mat-divider.mat-divider-inset{margin-left:auto;margin-right:80px}"],encapsulation:2,changeDetection:0})}return t})(),WaA=(()=>{class t{static \u0275fac=function(i){return new(i||t)};static \u0275mod=ge({type:t});static \u0275inj=le({imports:[Ve,Ve]})}return t})();var azA=["*"],czA='.mdc-list{margin:0;padding:8px 0;list-style-type:none}.mdc-list:focus{outline:none}.mdc-list-item{display:flex;position:relative;justify-content:flex-start;overflow:hidden;padding:0;align-items:stretch;cursor:pointer;padding-left:16px;padding-right:16px;background-color:var(--mdc-list-list-item-container-color, transparent);border-radius:var(--mdc-list-list-item-container-shape, var(--mat-sys-corner-none))}.mdc-list-item.mdc-list-item--selected{background-color:var(--mdc-list-list-item-selected-container-color)}.mdc-list-item:focus{outline:0}.mdc-list-item.mdc-list-item--disabled{cursor:auto}.mdc-list-item.mdc-list-item--with-one-line{height:var(--mdc-list-list-item-one-line-container-height, 48px)}.mdc-list-item.mdc-list-item--with-one-line .mdc-list-item__start{align-self:center;margin-top:0}.mdc-list-item.mdc-list-item--with-one-line .mdc-list-item__end{align-self:center;margin-top:0}.mdc-list-item.mdc-list-item--with-two-lines{height:var(--mdc-list-list-item-two-line-container-height, 64px)}.mdc-list-item.mdc-list-item--with-two-lines .mdc-list-item__start{align-self:flex-start;margin-top:16px}.mdc-list-item.mdc-list-item--with-two-lines .mdc-list-item__end{align-self:center;margin-top:0}.mdc-list-item.mdc-list-item--with-three-lines{height:var(--mdc-list-list-item-three-line-container-height, 88px)}.mdc-list-item.mdc-list-item--with-three-lines .mdc-list-item__start{align-self:flex-start;margin-top:16px}.mdc-list-item.mdc-list-item--with-three-lines .mdc-list-item__end{align-self:flex-start;margin-top:16px}.mdc-list-item.mdc-list-item--selected::before,.mdc-list-item.mdc-list-item--selected:focus::before,.mdc-list-item:not(.mdc-list-item--selected):focus::before{position:absolute;box-sizing:border-box;width:100%;height:100%;top:0;left:0;content:"";pointer-events:none}a.mdc-list-item{color:inherit;text-decoration:none}.mdc-list-item__start{fill:currentColor;flex-shrink:0;pointer-events:none}.mdc-list-item--with-leading-icon .mdc-list-item__start{color:var(--mdc-list-list-item-leading-icon-color, var(--mat-sys-on-surface-variant));width:var(--mdc-list-list-item-leading-icon-size, 24px);height:var(--mdc-list-list-item-leading-icon-size, 24px);margin-left:16px;margin-right:32px}[dir=rtl] .mdc-list-item--with-leading-icon .mdc-list-item__start{margin-left:32px;margin-right:16px}.mdc-list-item--with-leading-icon:hover .mdc-list-item__start{color:var(--mdc-list-list-item-hover-leading-icon-color)}.mdc-list-item--with-leading-avatar .mdc-list-item__start{width:var(--mdc-list-list-item-leading-avatar-size, 40px);height:var(--mdc-list-list-item-leading-avatar-size, 40px);margin-left:16px;margin-right:16px;border-radius:50%}.mdc-list-item--with-leading-avatar .mdc-list-item__start,[dir=rtl] .mdc-list-item--with-leading-avatar .mdc-list-item__start{margin-left:16px;margin-right:16px;border-radius:50%}.mdc-list-item__end{flex-shrink:0;pointer-events:none}.mdc-list-item--with-trailing-meta .mdc-list-item__end{font-family:var(--mdc-list-list-item-trailing-supporting-text-font, var(--mat-sys-label-small-font));line-height:var(--mdc-list-list-item-trailing-supporting-text-line-height, var(--mat-sys-label-small-line-height));font-size:var(--mdc-list-list-item-trailing-supporting-text-size, var(--mat-sys-label-small-size));font-weight:var(--mdc-list-list-item-trailing-supporting-text-weight, var(--mat-sys-label-small-weight));letter-spacing:var(--mdc-list-list-item-trailing-supporting-text-tracking, var(--mat-sys-label-small-tracking))}.mdc-list-item--with-trailing-icon .mdc-list-item__end{color:var(--mdc-list-list-item-trailing-icon-color, var(--mat-sys-on-surface-variant));width:var(--mdc-list-list-item-trailing-icon-size, 24px);height:var(--mdc-list-list-item-trailing-icon-size, 24px)}.mdc-list-item--with-trailing-icon:hover .mdc-list-item__end{color:var(--mdc-list-list-item-hover-trailing-icon-color)}.mdc-list-item.mdc-list-item--with-trailing-meta .mdc-list-item__end{color:var(--mdc-list-list-item-trailing-supporting-text-color, var(--mat-sys-on-surface-variant))}.mdc-list-item--selected.mdc-list-item--with-trailing-icon .mdc-list-item__end{color:var(--mdc-list-list-item-selected-trailing-icon-color, var(--mat-sys-primary))}.mdc-list-item__content{text-overflow:ellipsis;white-space:nowrap;overflow:hidden;align-self:center;flex:1;pointer-events:none}.mdc-list-item--with-two-lines .mdc-list-item__content,.mdc-list-item--with-three-lines .mdc-list-item__content{align-self:stretch}.mdc-list-item__primary-text{text-overflow:ellipsis;white-space:nowrap;overflow:hidden;color:var(--mdc-list-list-item-label-text-color, var(--mat-sys-on-surface));font-family:var(--mdc-list-list-item-label-text-font, var(--mat-sys-body-large-font));line-height:var(--mdc-list-list-item-label-text-line-height, var(--mat-sys-body-large-line-height));font-size:var(--mdc-list-list-item-label-text-size, var(--mat-sys-body-large-size));font-weight:var(--mdc-list-list-item-label-text-weight, var(--mat-sys-body-large-weight));letter-spacing:var(--mdc-list-list-item-label-text-tracking, var(--mat-sys-body-large-tracking))}.mdc-list-item:hover .mdc-list-item__primary-text{color:var(--mdc-list-list-item-hover-label-text-color, var(--mat-sys-on-surface))}.mdc-list-item:focus .mdc-list-item__primary-text{color:var(--mdc-list-list-item-focus-label-text-color, var(--mat-sys-on-surface))}.mdc-list-item--with-two-lines .mdc-list-item__primary-text,.mdc-list-item--with-three-lines .mdc-list-item__primary-text{display:block;margin-top:0;line-height:normal;margin-bottom:-20px}.mdc-list-item--with-two-lines .mdc-list-item__primary-text::before,.mdc-list-item--with-three-lines .mdc-list-item__primary-text::before{display:inline-block;width:0;height:28px;content:"";vertical-align:0}.mdc-list-item--with-two-lines .mdc-list-item__primary-text::after,.mdc-list-item--with-three-lines .mdc-list-item__primary-text::after{display:inline-block;width:0;height:20px;content:"";vertical-align:-20px}.mdc-list-item__secondary-text{text-overflow:ellipsis;white-space:nowrap;overflow:hidden;display:block;margin-top:0;color:var(--mdc-list-list-item-supporting-text-color, var(--mat-sys-on-surface-variant));font-family:var(--mdc-list-list-item-supporting-text-font, var(--mat-sys-body-medium-font));line-height:var(--mdc-list-list-item-supporting-text-line-height, var(--mat-sys-body-medium-line-height));font-size:var(--mdc-list-list-item-supporting-text-size, var(--mat-sys-body-medium-size));font-weight:var(--mdc-list-list-item-supporting-text-weight, var(--mat-sys-body-medium-weight));letter-spacing:var(--mdc-list-list-item-supporting-text-tracking, var(--mat-sys-body-medium-tracking))}.mdc-list-item__secondary-text::before{display:inline-block;width:0;height:20px;content:"";vertical-align:0}.mdc-list-item--with-three-lines .mdc-list-item__secondary-text{white-space:normal;line-height:20px}.mdc-list-item--with-overline .mdc-list-item__secondary-text{white-space:nowrap;line-height:auto}.mdc-list-item--with-leading-radio.mdc-list-item,.mdc-list-item--with-leading-checkbox.mdc-list-item,.mdc-list-item--with-leading-icon.mdc-list-item,.mdc-list-item--with-leading-avatar.mdc-list-item{padding-left:0;padding-right:16px}[dir=rtl] .mdc-list-item--with-leading-radio.mdc-list-item,[dir=rtl] .mdc-list-item--with-leading-checkbox.mdc-list-item,[dir=rtl] .mdc-list-item--with-leading-icon.mdc-list-item,[dir=rtl] .mdc-list-item--with-leading-avatar.mdc-list-item{padding-left:16px;padding-right:0}.mdc-list-item--with-leading-radio.mdc-list-item--with-two-lines .mdc-list-item__primary-text,.mdc-list-item--with-leading-checkbox.mdc-list-item--with-two-lines .mdc-list-item__primary-text,.mdc-list-item--with-leading-icon.mdc-list-item--with-two-lines .mdc-list-item__primary-text,.mdc-list-item--with-leading-avatar.mdc-list-item--with-two-lines .mdc-list-item__primary-text{display:block;margin-top:0;line-height:normal;margin-bottom:-20px}.mdc-list-item--with-leading-radio.mdc-list-item--with-two-lines .mdc-list-item__primary-text::before,.mdc-list-item--with-leading-checkbox.mdc-list-item--with-two-lines .mdc-list-item__primary-text::before,.mdc-list-item--with-leading-icon.mdc-list-item--with-two-lines .mdc-list-item__primary-text::before,.mdc-list-item--with-leading-avatar.mdc-list-item--with-two-lines .mdc-list-item__primary-text::before{display:inline-block;width:0;height:32px;content:"";vertical-align:0}.mdc-list-item--with-leading-radio.mdc-list-item--with-two-lines .mdc-list-item__primary-text::after,.mdc-list-item--with-leading-checkbox.mdc-list-item--with-two-lines .mdc-list-item__primary-text::after,.mdc-list-item--with-leading-icon.mdc-list-item--with-two-lines .mdc-list-item__primary-text::after,.mdc-list-item--with-leading-avatar.mdc-list-item--with-two-lines .mdc-list-item__primary-text::after{display:inline-block;width:0;height:20px;content:"";vertical-align:-20px}.mdc-list-item--with-leading-radio.mdc-list-item--with-two-lines.mdc-list-item--with-trailing-meta .mdc-list-item__end,.mdc-list-item--with-leading-checkbox.mdc-list-item--with-two-lines.mdc-list-item--with-trailing-meta .mdc-list-item__end,.mdc-list-item--with-leading-icon.mdc-list-item--with-two-lines.mdc-list-item--with-trailing-meta .mdc-list-item__end,.mdc-list-item--with-leading-avatar.mdc-list-item--with-two-lines.mdc-list-item--with-trailing-meta .mdc-list-item__end{display:block;margin-top:0;line-height:normal}.mdc-list-item--with-leading-radio.mdc-list-item--with-two-lines.mdc-list-item--with-trailing-meta .mdc-list-item__end::before,.mdc-list-item--with-leading-checkbox.mdc-list-item--with-two-lines.mdc-list-item--with-trailing-meta .mdc-list-item__end::before,.mdc-list-item--with-leading-icon.mdc-list-item--with-two-lines.mdc-list-item--with-trailing-meta .mdc-list-item__end::before,.mdc-list-item--with-leading-avatar.mdc-list-item--with-two-lines.mdc-list-item--with-trailing-meta .mdc-list-item__end::before{display:inline-block;width:0;height:32px;content:"";vertical-align:0}.mdc-list-item--with-trailing-icon.mdc-list-item,[dir=rtl] .mdc-list-item--with-trailing-icon.mdc-list-item{padding-left:0;padding-right:0}.mdc-list-item--with-trailing-icon .mdc-list-item__end{margin-left:16px;margin-right:16px}.mdc-list-item--with-trailing-meta.mdc-list-item{padding-left:16px;padding-right:0}[dir=rtl] .mdc-list-item--with-trailing-meta.mdc-list-item{padding-left:0;padding-right:16px}.mdc-list-item--with-trailing-meta .mdc-list-item__end{-webkit-user-select:none;user-select:none;margin-left:28px;margin-right:16px}[dir=rtl] .mdc-list-item--with-trailing-meta .mdc-list-item__end{margin-left:16px;margin-right:28px}.mdc-list-item--with-trailing-meta.mdc-list-item--with-three-lines .mdc-list-item__end,.mdc-list-item--with-trailing-meta.mdc-list-item--with-two-lines .mdc-list-item__end{display:block;line-height:normal;align-self:flex-start;margin-top:0}.mdc-list-item--with-trailing-meta.mdc-list-item--with-three-lines .mdc-list-item__end::before,.mdc-list-item--with-trailing-meta.mdc-list-item--with-two-lines .mdc-list-item__end::before{display:inline-block;width:0;height:28px;content:"";vertical-align:0}.mdc-list-item--with-leading-radio .mdc-list-item__start,.mdc-list-item--with-leading-checkbox .mdc-list-item__start{margin-left:8px;margin-right:24px}[dir=rtl] .mdc-list-item--with-leading-radio .mdc-list-item__start,[dir=rtl] .mdc-list-item--with-leading-checkbox .mdc-list-item__start{margin-left:24px;margin-right:8px}.mdc-list-item--with-leading-radio.mdc-list-item--with-two-lines .mdc-list-item__start,.mdc-list-item--with-leading-checkbox.mdc-list-item--with-two-lines .mdc-list-item__start{align-self:flex-start;margin-top:8px}.mdc-list-item--with-trailing-radio.mdc-list-item,.mdc-list-item--with-trailing-checkbox.mdc-list-item{padding-left:16px;padding-right:0}[dir=rtl] .mdc-list-item--with-trailing-radio.mdc-list-item,[dir=rtl] .mdc-list-item--with-trailing-checkbox.mdc-list-item{padding-left:0;padding-right:16px}.mdc-list-item--with-trailing-radio.mdc-list-item--with-leading-icon,.mdc-list-item--with-trailing-radio.mdc-list-item--with-leading-avatar,.mdc-list-item--with-trailing-checkbox.mdc-list-item--with-leading-icon,.mdc-list-item--with-trailing-checkbox.mdc-list-item--with-leading-avatar{padding-left:0}[dir=rtl] .mdc-list-item--with-trailing-radio.mdc-list-item--with-leading-icon,[dir=rtl] .mdc-list-item--with-trailing-radio.mdc-list-item--with-leading-avatar,[dir=rtl] .mdc-list-item--with-trailing-checkbox.mdc-list-item--with-leading-icon,[dir=rtl] .mdc-list-item--with-trailing-checkbox.mdc-list-item--with-leading-avatar{padding-right:0}.mdc-list-item--with-trailing-radio .mdc-list-item__end,.mdc-list-item--with-trailing-checkbox .mdc-list-item__end{margin-left:24px;margin-right:8px}[dir=rtl] .mdc-list-item--with-trailing-radio .mdc-list-item__end,[dir=rtl] .mdc-list-item--with-trailing-checkbox .mdc-list-item__end{margin-left:8px;margin-right:24px}.mdc-list-item--with-trailing-radio.mdc-list-item--with-three-lines .mdc-list-item__end,.mdc-list-item--with-trailing-checkbox.mdc-list-item--with-three-lines .mdc-list-item__end{align-self:flex-start;margin-top:8px}.mdc-list-group__subheader{margin:.75rem 16px}.mdc-list-item--disabled .mdc-list-item__start,.mdc-list-item--disabled .mdc-list-item__content,.mdc-list-item--disabled .mdc-list-item__end{opacity:1}.mdc-list-item--disabled .mdc-list-item__primary-text,.mdc-list-item--disabled .mdc-list-item__secondary-text{opacity:var(--mdc-list-list-item-disabled-label-text-opacity, 0.3)}.mdc-list-item--disabled.mdc-list-item--with-leading-icon .mdc-list-item__start{color:var(--mdc-list-list-item-disabled-leading-icon-color, var(--mat-sys-on-surface));opacity:var(--mdc-list-list-item-disabled-leading-icon-opacity, 0.38)}.mdc-list-item--disabled.mdc-list-item--with-trailing-icon .mdc-list-item__end{color:var(--mdc-list-list-item-disabled-trailing-icon-color, var(--mat-sys-on-surface));opacity:var(--mdc-list-list-item-disabled-trailing-icon-opacity, 0.38)}.mat-mdc-list-item.mat-mdc-list-item-both-leading-and-trailing,[dir=rtl] .mat-mdc-list-item.mat-mdc-list-item-both-leading-and-trailing{padding-left:0;padding-right:0}.mdc-list-item.mdc-list-item--disabled .mdc-list-item__primary-text{color:var(--mdc-list-list-item-disabled-label-text-color, var(--mat-sys-on-surface))}.mdc-list-item:hover::before{background-color:var(--mdc-list-list-item-hover-state-layer-color, var(--mat-sys-on-surface));opacity:var(--mdc-list-list-item-hover-state-layer-opacity, var(--mat-sys-hover-state-layer-opacity))}.mdc-list-item.mdc-list-item--disabled::before{background-color:var(--mdc-list-list-item-disabled-state-layer-color, var(--mat-sys-on-surface));opacity:var(--mdc-list-list-item-disabled-state-layer-opacity, var(--mat-sys-focus-state-layer-opacity))}.mdc-list-item:focus::before{background-color:var(--mdc-list-list-item-focus-state-layer-color, var(--mat-sys-on-surface));opacity:var(--mdc-list-list-item-focus-state-layer-opacity, var(--mat-sys-focus-state-layer-opacity))}.mdc-list-item--disabled .mdc-radio,.mdc-list-item--disabled .mdc-checkbox{opacity:var(--mdc-list-list-item-disabled-label-text-opacity, 0.3)}.mdc-list-item--with-leading-avatar .mat-mdc-list-item-avatar{border-radius:var(--mdc-list-list-item-leading-avatar-shape, var(--mat-sys-corner-full));background-color:var(--mdc-list-list-item-leading-avatar-color, var(--mat-sys-primary-container))}.mat-mdc-list-item-icon{font-size:var(--mdc-list-list-item-leading-icon-size, 24px)}@media(forced-colors: active){a.mdc-list-item--activated::after{content:"";position:absolute;top:50%;right:16px;transform:translateY(-50%);width:10px;height:0;border-bottom:solid 10px;border-radius:10px}a.mdc-list-item--activated [dir=rtl]::after{right:auto;left:16px}}.mat-mdc-list-base{display:block}.mat-mdc-list-base .mdc-list-item__start,.mat-mdc-list-base .mdc-list-item__end,.mat-mdc-list-base .mdc-list-item__content{pointer-events:auto}.mat-mdc-list-item,.mat-mdc-list-option{width:100%;box-sizing:border-box;-webkit-tap-highlight-color:rgba(0,0,0,0)}.mat-mdc-list-item:not(.mat-mdc-list-item-interactive),.mat-mdc-list-option:not(.mat-mdc-list-item-interactive){cursor:default}.mat-mdc-list-item .mat-divider-inset,.mat-mdc-list-option .mat-divider-inset{position:absolute;left:0;right:0;bottom:0}.mat-mdc-list-item .mat-mdc-list-item-avatar~.mat-divider-inset,.mat-mdc-list-option .mat-mdc-list-item-avatar~.mat-divider-inset{margin-left:72px}[dir=rtl] .mat-mdc-list-item .mat-mdc-list-item-avatar~.mat-divider-inset,[dir=rtl] .mat-mdc-list-option .mat-mdc-list-item-avatar~.mat-divider-inset{margin-right:72px}.mat-mdc-list-item-interactive::before{top:0;left:0;right:0;bottom:0;position:absolute;content:"";opacity:0;pointer-events:none;border-radius:inherit}.mat-mdc-list-item>.mat-focus-indicator{top:0;left:0;right:0;bottom:0;position:absolute;pointer-events:none}.mat-mdc-list-item:focus>.mat-focus-indicator::before{content:""}.mat-mdc-list-item.mdc-list-item--with-three-lines .mat-mdc-list-item-line.mdc-list-item__secondary-text{white-space:nowrap;line-height:normal}.mat-mdc-list-item.mdc-list-item--with-three-lines .mat-mdc-list-item-unscoped-content.mdc-list-item__secondary-text{display:-webkit-box;-webkit-box-orient:vertical;-webkit-line-clamp:2}mat-action-list button{background:none;color:inherit;border:none;font:inherit;outline:inherit;-webkit-tap-highlight-color:rgba(0,0,0,0);text-align:start}mat-action-list button::-moz-focus-inner{border:0}.mdc-list-item--with-leading-icon .mdc-list-item__start{margin-inline-start:var(--mat-list-list-item-leading-icon-start-space, 16px);margin-inline-end:var(--mat-list-list-item-leading-icon-end-space, 16px)}.mat-mdc-nav-list .mat-mdc-list-item{border-radius:var(--mat-list-active-indicator-shape, var(--mat-sys-corner-full));--mat-focus-indicator-border-radius:var(--mat-list-active-indicator-shape, var(--mat-sys-corner-full))}.mat-mdc-nav-list .mat-mdc-list-item.mdc-list-item--activated{background-color:var(--mat-list-active-indicator-color, var(--mat-sys-secondary-container))}',lzA=["unscopedContent"],gzA=["text"],IzA=[[["","matListItemAvatar",""],["","matListItemIcon",""]],[["","matListItemTitle",""]],[["","matListItemLine",""]],"*",[["","matListItemMeta",""]],[["mat-divider"]]],CzA=["[matListItemAvatar],[matListItemIcon]","[matListItemTitle]","[matListItemLine]","*","[matListItemMeta]","mat-divider"];var dzA=new BA("ListOption"),BzA=(()=>{class t{_elementRef=m(te);constructor(){}static \u0275fac=function(i){return new(i||t)};static \u0275dir=OA({type:t,selectors:[["","matListItemTitle",""]],hostAttrs:[1,"mat-mdc-list-item-title","mdc-list-item__primary-text"]})}return t})(),EzA=(()=>{class t{_elementRef=m(te);constructor(){}static \u0275fac=function(i){return new(i||t)};static \u0275dir=OA({type:t,selectors:[["","matListItemLine",""]],hostAttrs:[1,"mat-mdc-list-item-line","mdc-list-item__secondary-text"]})}return t})(),hzA=(()=>{class t{static \u0275fac=function(i){return new(i||t)};static \u0275dir=OA({type:t,selectors:[["","matListItemMeta",""]],hostAttrs:[1,"mat-mdc-list-item-meta","mdc-list-item__end"]})}return t})(),XaA=(()=>{class t{_listOption=m(dzA,{optional:!0});constructor(){}_isAlignedAtStart(){return!this._listOption||this._listOption?._getTogglePosition()==="after"}static \u0275fac=function(i){return new(i||t)};static \u0275dir=OA({type:t,hostVars:4,hostBindings:function(i,n){i&2&&ue("mdc-list-item__start",n._isAlignedAtStart())("mdc-list-item__end",!n._isAlignedAtStart())}})}return t})(),QzA=(()=>{class t extends XaA{static \u0275fac=(()=>{let A;return function(n){return(A||(A=bi(t)))(n||t)}})();static \u0275dir=OA({type:t,selectors:[["","matListItemAvatar",""]],hostAttrs:[1,"mat-mdc-list-item-avatar"],features:[et]})}return t})(),uzA=(()=>{class t extends XaA{static \u0275fac=(()=>{let A;return function(n){return(A||(A=bi(t)))(n||t)}})();static \u0275dir=OA({type:t,selectors:[["","matListItemIcon",""]],hostAttrs:[1,"mat-mdc-list-item-icon"],features:[et]})}return t})(),fzA=new BA("MAT_LIST_CONFIG"),yG=(()=>{class t{_isNonInteractive=!0;get disableRipple(){return this._disableRipple}set disableRipple(A){this._disableRipple=Yo(A)}_disableRipple=!1;get disabled(){return this._disabled}set disabled(A){this._disabled=Yo(A)}_disabled=!1;_defaultOptions=m(fzA,{optional:!0});static \u0275fac=function(i){return new(i||t)};static \u0275dir=OA({type:t,hostVars:1,hostBindings:function(i,n){i&2&&_e("aria-disabled",n.disabled)},inputs:{disableRipple:"disableRipple",disabled:"disabled"}})}return t})(),mzA=(()=>{class t{_elementRef=m(te);_ngZone=m(de);_listBase=m(yG,{optional:!0});_platform=m(Zt);_hostElement;_isButtonElement;_noopAnimations;_avatars;_icons;set lines(A){this._explicitLines=Ns(A,null),this._updateItemLines(!1)}_explicitLines=null;get disableRipple(){return this.disabled||this._disableRipple||this._noopAnimations||!!this._listBase?.disableRipple}set disableRipple(A){this._disableRipple=Yo(A)}_disableRipple=!1;get disabled(){return this._disabled||!!this._listBase?.disabled}set disabled(A){this._disabled=Yo(A)}_disabled=!1;_subscriptions=new _t;_rippleRenderer=null;_hasUnscopedTextContent=!1;rippleConfig;get rippleDisabled(){return this.disableRipple||!!this.rippleConfig.disabled}constructor(){m(Ln).load(Qr);let A=m(L2,{optional:!0}),i=m(mi,{optional:!0});this.rippleConfig=A||{},this._hostElement=this._elementRef.nativeElement,this._isButtonElement=this._hostElement.nodeName.toLowerCase()==="button",this._noopAnimations=i==="NoopAnimations",this._listBase&&!this._listBase._isNonInteractive&&this._initInteractiveListItem(),this._isButtonElement&&!this._hostElement.hasAttribute("type")&&this._hostElement.setAttribute("type","button")}ngAfterViewInit(){this._monitorProjectedLinesAndTitle(),this._updateItemLines(!0)}ngOnDestroy(){this._subscriptions.unsubscribe(),this._rippleRenderer!==null&&this._rippleRenderer._removeTriggerEvents()}_hasIconOrAvatar(){return!!(this._avatars.length||this._icons.length)}_initInteractiveListItem(){this._hostElement.classList.add("mat-mdc-list-item-interactive"),this._rippleRenderer=new CB(this,this._ngZone,this._hostElement,this._platform,m(Dt)),this._rippleRenderer.setupTriggerEvents(this._hostElement)}_monitorProjectedLinesAndTitle(){this._ngZone.runOutsideAngular(()=>{this._subscriptions.add(ho(this._lines.changes,this._titles.changes).subscribe(()=>this._updateItemLines(!1)))})}_updateItemLines(A){if(!this._lines||!this._titles||!this._unscopedContent)return;A&&this._checkDomForUnscopedTextContent();let i=this._explicitLines??this._inferLinesFromContent(),n=this._unscopedContent.nativeElement;if(this._hostElement.classList.toggle("mat-mdc-list-item-single-line",i<=1),this._hostElement.classList.toggle("mdc-list-item--with-one-line",i<=1),this._hostElement.classList.toggle("mdc-list-item--with-two-lines",i===2),this._hostElement.classList.toggle("mdc-list-item--with-three-lines",i===3),this._hasUnscopedTextContent){let o=this._titles.length===0&&i===1;n.classList.toggle("mdc-list-item__primary-text",o),n.classList.toggle("mdc-list-item__secondary-text",!o)}else n.classList.remove("mdc-list-item__primary-text"),n.classList.remove("mdc-list-item__secondary-text")}_inferLinesFromContent(){let A=this._titles.length+this._lines.length;return this._hasUnscopedTextContent&&(A+=1),A}_checkDomForUnscopedTextContent(){this._hasUnscopedTextContent=Array.from(this._unscopedContent.nativeElement.childNodes).filter(A=>A.nodeType!==A.COMMENT_NODE).some(A=>!!(A.textContent&&A.textContent.trim()))}static \u0275fac=function(i){return new(i||t)};static \u0275dir=OA({type:t,contentQueries:function(i,n,o){if(i&1&&(Ii(o,QzA,4),Ii(o,uzA,4)),i&2){let r;$A(r=Ae())&&(n._avatars=r),$A(r=Ae())&&(n._icons=r)}},hostVars:4,hostBindings:function(i,n){i&2&&(_e("aria-disabled",n.disabled)("disabled",n._isButtonElement&&n.disabled||null),ue("mdc-list-item--disabled",n.disabled))},inputs:{lines:"lines",disableRipple:"disableRipple",disabled:"disabled"}})}return t})();var $aA=(()=>{class t extends yG{static \u0275fac=(()=>{let A;return function(n){return(A||(A=bi(t)))(n||t)}})();static \u0275cmp=YA({type:t,selectors:[["mat-list"]],hostAttrs:[1,"mat-mdc-list","mat-mdc-list-base","mdc-list"],exportAs:["matList"],features:[ct([{provide:yG,useExisting:t}]),et],ngContentSelectors:azA,decls:1,vars:0,template:function(i,n){i&1&&(Yt(),xe(0))},styles:[czA],encapsulation:2,changeDetection:0})}return t})(),AcA=(()=>{class t extends mzA{_lines;_titles;_meta;_unscopedContent;_itemText;get activated(){return this._activated}set activated(A){this._activated=Yo(A)}_activated=!1;_getAriaCurrent(){return this._hostElement.nodeName==="A"&&this._activated?"page":null}_hasBothLeadingAndTrailing(){return this._meta.length!==0&&(this._avatars.length!==0||this._icons.length!==0)}static \u0275fac=(()=>{let A;return function(n){return(A||(A=bi(t)))(n||t)}})();static \u0275cmp=YA({type:t,selectors:[["mat-list-item"],["a","mat-list-item",""],["button","mat-list-item",""]],contentQueries:function(i,n,o){if(i&1&&(Ii(o,EzA,5),Ii(o,BzA,5),Ii(o,hzA,5)),i&2){let r;$A(r=Ae())&&(n._lines=r),$A(r=Ae())&&(n._titles=r),$A(r=Ae())&&(n._meta=r)}},viewQuery:function(i,n){if(i&1&&(Ge(lzA,5),Ge(gzA,5)),i&2){let o;$A(o=Ae())&&(n._unscopedContent=o.first),$A(o=Ae())&&(n._itemText=o.first)}},hostAttrs:[1,"mat-mdc-list-item","mdc-list-item"],hostVars:13,hostBindings:function(i,n){i&2&&(_e("aria-current",n._getAriaCurrent()),ue("mdc-list-item--activated",n.activated)("mdc-list-item--with-leading-avatar",n._avatars.length!==0)("mdc-list-item--with-leading-icon",n._icons.length!==0)("mdc-list-item--with-trailing-meta",n._meta.length!==0)("mat-mdc-list-item-both-leading-and-trailing",n._hasBothLeadingAndTrailing())("_mat-animation-noopable",n._noopAnimations))},inputs:{activated:"activated"},exportAs:["matListItem"],features:[et],ngContentSelectors:CzA,decls:10,vars:0,consts:[["unscopedContent",""],[1,"mdc-list-item__content"],[1,"mat-mdc-list-item-unscoped-content",3,"cdkObserveContent"],[1,"mat-focus-indicator"]],template:function(i,n){if(i&1){let o=De();Yt(IzA),xe(0),S(1,"span",1),xe(2,1),xe(3,2),S(4,"span",2,0),mA("cdkObserveContent",function(){return LA(o),xA(n._updateItemLines(!0))}),xe(6,3),R()(),xe(7,4),xe(8,5),UA(9,"div",3)}},dependencies:[N6],encapsulation:2,changeDetection:0})}return t})();var ecA=(()=>{class t{static \u0275fac=function(i){return new(i||t)};static \u0275mod=ge({type:t});static \u0275inj=le({imports:[gB,Ve,Xa,ck,WaA]})}return t})();var wzA=["button"],DzA=["*"];function yzA(t,e){if(t&1&&(S(0,"div",2),UA(1,"mat-pseudo-checkbox",6),R()),t&2){let A=P();_(),vA("disabled",A.disabled)}}var tcA=new BA("MAT_BUTTON_TOGGLE_DEFAULT_OPTIONS",{providedIn:"root",factory:vzA});function vzA(){return{hideSingleSelectionIndicator:!1,hideMultipleSelectionIndicator:!1,disabledInteractive:!1}}var icA=new BA("MatButtonToggleGroup"),bzA={provide:uc,useExisting:nr(()=>vG),multi:!0},Hy=class{source;value;constructor(e,A){this.source=e,this.value=A}},vG=(()=>{class t{_changeDetector=m(lt);_dir=m(bo,{optional:!0});_multiple=!1;_disabled=!1;_disabledInteractive=!1;_selectionModel;_rawValue;_controlValueAccessorChangeFn=()=>{};_onTouched=()=>{};_buttonToggles;appearance;get name(){return this._name}set name(A){this._name=A,this._markButtonsForCheck()}_name=m($i).getId("mat-button-toggle-group-");vertical;get value(){let A=this._selectionModel?this._selectionModel.selected:[];return this.multiple?A.map(i=>i.value):A[0]?A[0].value:void 0}set value(A){this._setSelectionByValue(A),this.valueChange.emit(this.value)}valueChange=new XA;get selected(){let A=this._selectionModel?this._selectionModel.selected:[];return this.multiple?A:A[0]||null}get multiple(){return this._multiple}set multiple(A){this._multiple=A,this._markButtonsForCheck()}get disabled(){return this._disabled}set disabled(A){this._disabled=A,this._markButtonsForCheck()}get disabledInteractive(){return this._disabledInteractive}set disabledInteractive(A){this._disabledInteractive=A,this._markButtonsForCheck()}get dir(){return this._dir&&this._dir.value==="rtl"?"rtl":"ltr"}change=new XA;get hideSingleSelectionIndicator(){return this._hideSingleSelectionIndicator}set hideSingleSelectionIndicator(A){this._hideSingleSelectionIndicator=A,this._markButtonsForCheck()}_hideSingleSelectionIndicator;get hideMultipleSelectionIndicator(){return this._hideMultipleSelectionIndicator}set hideMultipleSelectionIndicator(A){this._hideMultipleSelectionIndicator=A,this._markButtonsForCheck()}_hideMultipleSelectionIndicator;constructor(){let A=m(tcA,{optional:!0});this.appearance=A&&A.appearance?A.appearance:"standard",this.hideSingleSelectionIndicator=A?.hideSingleSelectionIndicator??!1,this.hideMultipleSelectionIndicator=A?.hideMultipleSelectionIndicator??!1}ngOnInit(){this._selectionModel=new F2(this.multiple,void 0,!1)}ngAfterContentInit(){this._selectionModel.select(...this._buttonToggles.filter(A=>A.checked)),this.multiple||this._initializeTabIndex()}writeValue(A){this.value=A,this._changeDetector.markForCheck()}registerOnChange(A){this._controlValueAccessorChangeFn=A}registerOnTouched(A){this._onTouched=A}setDisabledState(A){this.disabled=A}_keydown(A){if(this.multiple||this.disabled)return;let n=A.target.id,o=this._buttonToggles.toArray().findIndex(s=>s.buttonId===n),r=null;switch(A.keyCode){case 32:case 13:r=this._buttonToggles.get(o)||null;break;case 38:r=this._getNextButton(o,-1);break;case 37:r=this._getNextButton(o,this.dir==="ltr"?-1:1);break;case 40:r=this._getNextButton(o,1);break;case 39:r=this._getNextButton(o,this.dir==="ltr"?1:-1);break;default:return}r&&(A.preventDefault(),r._onButtonClick(),r.focus())}_emitChangeEvent(A){let i=new Hy(A,this.value);this._rawValue=i.value,this._controlValueAccessorChangeFn(i.value),this.change.emit(i)}_syncButtonToggle(A,i,n=!1,o=!1){!this.multiple&&this.selected&&!A.checked&&(this.selected.checked=!1),this._selectionModel?i?this._selectionModel.select(A):this._selectionModel.deselect(A):o=!0,o?Promise.resolve().then(()=>this._updateModelValue(A,n)):this._updateModelValue(A,n)}_isSelected(A){return this._selectionModel&&this._selectionModel.isSelected(A)}_isPrechecked(A){return typeof this._rawValue>"u"?!1:this.multiple&&Array.isArray(this._rawValue)?this._rawValue.some(i=>A.value!=null&&i===A.value):A.value===this._rawValue}_initializeTabIndex(){if(this._buttonToggles.forEach(A=>{A.tabIndex=-1}),this.selected)this.selected.tabIndex=0;else for(let A=0;A<this._buttonToggles.length;A++){let i=this._buttonToggles.get(A);if(!i.disabled){i.tabIndex=0;break}}this._markButtonsForCheck()}_getNextButton(A,i){let n=this._buttonToggles;for(let o=1;o<=n.length;o++){let r=(A+i*o+n.length)%n.length,s=n.get(r);if(s&&!s.disabled)return s}return null}_setSelectionByValue(A){if(this._rawValue=A,!this._buttonToggles)return;let i=this._buttonToggles.toArray();if(this.multiple&&A?(Array.isArray(A),this._clearSelection(),A.forEach(n=>this._selectValue(n,i))):(this._clearSelection(),this._selectValue(A,i)),!this.multiple&&i.every(n=>n.tabIndex===-1)){for(let n of i)if(!n.disabled){n.tabIndex=0;break}}}_clearSelection(){this._selectionModel.clear(),this._buttonToggles.forEach(A=>{A.checked=!1,this.multiple||(A.tabIndex=-1)})}_selectValue(A,i){for(let n of i)if(n.value===A){n.checked=!0,this._selectionModel.select(n),this.multiple||(n.tabIndex=0);break}}_updateModelValue(A,i){i&&this._emitChangeEvent(A),this.valueChange.emit(this.value)}_markButtonsForCheck(){this._buttonToggles?.forEach(A=>A._markForCheck())}static \u0275fac=function(i){return new(i||t)};static \u0275dir=OA({type:t,selectors:[["mat-button-toggle-group"]],contentQueries:function(i,n,o){if(i&1&&Ii(o,Oy,5),i&2){let r;$A(r=Ae())&&(n._buttonToggles=r)}},hostAttrs:[1,"mat-button-toggle-group"],hostVars:6,hostBindings:function(i,n){i&1&&mA("keydown",function(r){return n._keydown(r)}),i&2&&(_e("role",n.multiple?"group":"radiogroup")("aria-disabled",n.disabled),ue("mat-button-toggle-vertical",n.vertical)("mat-button-toggle-group-appearance-standard",n.appearance==="standard"))},inputs:{appearance:"appearance",name:"name",vertical:[2,"vertical","vertical",ae],value:"value",multiple:[2,"multiple","multiple",ae],disabled:[2,"disabled","disabled",ae],disabledInteractive:[2,"disabledInteractive","disabledInteractive",ae],hideSingleSelectionIndicator:[2,"hideSingleSelectionIndicator","hideSingleSelectionIndicator",ae],hideMultipleSelectionIndicator:[2,"hideMultipleSelectionIndicator","hideMultipleSelectionIndicator",ae]},outputs:{valueChange:"valueChange",change:"change"},exportAs:["matButtonToggleGroup"],features:[ct([bzA,{provide:icA,useExisting:t}])]})}return t})(),Oy=(()=>{class t{_changeDetectorRef=m(lt);_elementRef=m(te);_focusMonitor=m(Jr);_idGenerator=m($i);_animationMode=m(mi,{optional:!0});_checked=!1;ariaLabel;ariaLabelledby=null;_buttonElement;buttonToggleGroup;get buttonId(){return`${this.id}-button`}id;name;value;get tabIndex(){return this._tabIndex}set tabIndex(A){A!==this._tabIndex&&(this._tabIndex=A,this._markForCheck())}_tabIndex;disableRipple;get appearance(){return this.buttonToggleGroup?this.buttonToggleGroup.appearance:this._appearance}set appearance(A){this._appearance=A}_appearance;get checked(){return this.buttonToggleGroup?this.buttonToggleGroup._isSelected(this):this._checked}set checked(A){A!==this._checked&&(this._checked=A,this.buttonToggleGroup&&this.buttonToggleGroup._syncButtonToggle(this,this._checked),this._changeDetectorRef.markForCheck())}get disabled(){return this._disabled||this.buttonToggleGroup&&this.buttonToggleGroup.disabled}set disabled(A){this._disabled=A}_disabled=!1;get disabledInteractive(){return this._disabledInteractive||this.buttonToggleGroup!==null&&this.buttonToggleGroup.disabledInteractive}set disabledInteractive(A){this._disabledInteractive=A}_disabledInteractive;change=new XA;constructor(){m(Ln).load(Qr);let A=m(icA,{optional:!0}),i=m(new Er("tabindex"),{optional:!0})||"",n=m(tcA,{optional:!0});this._tabIndex=parseInt(i)||0,this.buttonToggleGroup=A,this.appearance=n&&n.appearance?n.appearance:"standard",this.disabledInteractive=n?.disabledInteractive??!1}ngOnInit(){let A=this.buttonToggleGroup;this.id=this.id||this._idGenerator.getId("mat-button-toggle-"),A&&(A._isPrechecked(this)?this.checked=!0:A._isSelected(this)!==this._checked&&A._syncButtonToggle(this,this._checked))}ngAfterViewInit(){this._animationMode!=="NoopAnimations"&&this._elementRef.nativeElement.classList.add("mat-button-toggle-animations-enabled"),this._focusMonitor.monitor(this._elementRef,!0)}ngOnDestroy(){let A=this.buttonToggleGroup;this._focusMonitor.stopMonitoring(this._elementRef),A&&A._isSelected(this)&&A._syncButtonToggle(this,!1,!1,!0)}focus(A){this._buttonElement.nativeElement.focus(A)}_onButtonClick(){if(this.disabled)return;let A=this.isSingleSelector()?!0:!this._checked;if(A!==this._checked&&(this._checked=A,this.buttonToggleGroup&&(this.buttonToggleGroup._syncButtonToggle(this,this._checked,!0),this.buttonToggleGroup._onTouched())),this.isSingleSelector()){let i=this.buttonToggleGroup._buttonToggles.find(n=>n.tabIndex===0);i&&(i.tabIndex=-1),this.tabIndex=0}this.change.emit(new Hy(this,this.value))}_markForCheck(){this._changeDetectorRef.markForCheck()}_getButtonName(){return this.isSingleSelector()?this.buttonToggleGroup.name:this.name||null}isSingleSelector(){return this.buttonToggleGroup&&!this.buttonToggleGroup.multiple}static \u0275fac=function(i){return new(i||t)};static \u0275cmp=YA({type:t,selectors:[["mat-button-toggle"]],viewQuery:function(i,n){if(i&1&&Ge(wzA,5),i&2){let o;$A(o=Ae())&&(n._buttonElement=o.first)}},hostAttrs:["role","presentation",1,"mat-button-toggle"],hostVars:14,hostBindings:function(i,n){i&1&&mA("focus",function(){return n.focus()}),i&2&&(_e("aria-label",null)("aria-labelledby",null)("id",n.id)("name",null),ue("mat-button-toggle-standalone",!n.buttonToggleGroup)("mat-button-toggle-checked",n.checked)("mat-button-toggle-disabled",n.disabled)("mat-button-toggle-disabled-interactive",n.disabledInteractive)("mat-button-toggle-appearance-standard",n.appearance==="standard"))},inputs:{ariaLabel:[0,"aria-label","ariaLabel"],ariaLabelledby:[0,"aria-labelledby","ariaLabelledby"],id:"id",name:"name",value:"value",tabIndex:"tabIndex",disableRipple:[2,"disableRipple","disableRipple",ae],appearance:"appearance",checked:[2,"checked","checked",ae],disabled:[2,"disabled","disabled",ae],disabledInteractive:[2,"disabledInteractive","disabledInteractive",ae]},outputs:{change:"change"},exportAs:["matButtonToggle"],ngContentSelectors:DzA,decls:7,vars:13,consts:[["button",""],["type","button",1,"mat-button-toggle-button","mat-focus-indicator",3,"click","id","disabled"],[1,"mat-button-toggle-checkbox-wrapper"],[1,"mat-button-toggle-label-content"],[1,"mat-button-toggle-focus-overlay"],["matRipple","",1,"mat-button-toggle-ripple",3,"matRippleTrigger","matRippleDisabled"],["state","checked","aria-hidden","true","appearance","minimal",3,"disabled"]],template:function(i,n){if(i&1){let o=De();Yt(),S(0,"button",1,0),mA("click",function(){return LA(o),xA(n._onButtonClick())}),NA(2,yzA,2,1,"div",2),S(3,"span",3),xe(4),R()(),UA(5,"span",4)(6,"span",5)}if(i&2){let o=or(1);vA("id",n.buttonId)("disabled",n.disabled&&!n.disabledInteractive||null),_e("role",n.isSingleSelector()?"radio":"button")("tabindex",n.disabled&&!n.disabledInteractive?-1:n.tabIndex)("aria-pressed",n.isSingleSelector()?null:n.checked)("aria-checked",n.isSingleSelector()?n.checked:null)("name",n._getButtonName())("aria-label",n.ariaLabel)("aria-labelledby",n.ariaLabelledby)("aria-disabled",n.disabled&&n.disabledInteractive?"true":null),_(2),FA(n.buttonToggleGroup&&(!n.buttonToggleGroup.multiple&&!n.buttonToggleGroup.hideSingleSelectionIndicator||n.buttonToggleGroup.multiple&&!n.buttonToggleGroup.hideMultipleSelectionIndicator)?2:-1),_(4),vA("matRippleTrigger",o)("matRippleDisabled",n.disableRipple||n.disabled)}},dependencies:[Gs,ak],styles:[".mat-button-toggle-standalone,.mat-button-toggle-group{position:relative;display:inline-flex;flex-direction:row;white-space:nowrap;overflow:hidden;-webkit-tap-highlight-color:rgba(0,0,0,0);transform:translateZ(0);border-radius:var(--mat-legacy-button-toggle-shape)}.mat-button-toggle-standalone:not([class*=mat-elevation-z]),.mat-button-toggle-group:not([class*=mat-elevation-z]){box-shadow:0px 3px 1px -2px rgba(0, 0, 0, 0.2), 0px 2px 2px 0px rgba(0, 0, 0, 0.14), 0px 1px 5px 0px rgba(0, 0, 0, 0.12)}@media(forced-colors: active){.mat-button-toggle-standalone,.mat-button-toggle-group{outline:solid 1px}}.mat-button-toggle-standalone.mat-button-toggle-appearance-standard,.mat-button-toggle-group-appearance-standard{border-radius:var(--mat-standard-button-toggle-shape, var(--mat-sys-corner-full));border:solid 1px var(--mat-standard-button-toggle-divider-color, var(--mat-sys-outline))}.mat-button-toggle-standalone.mat-button-toggle-appearance-standard .mat-pseudo-checkbox,.mat-button-toggle-group-appearance-standard .mat-pseudo-checkbox{--mat-minimal-pseudo-checkbox-selected-checkmark-color: var(--mat-standard-button-toggle-selected-state-text-color, var(--mat-sys-on-secondary-container))}.mat-button-toggle-standalone.mat-button-toggle-appearance-standard:not([class*=mat-elevation-z]),.mat-button-toggle-group-appearance-standard:not([class*=mat-elevation-z]){box-shadow:none}@media(forced-colors: active){.mat-button-toggle-standalone.mat-button-toggle-appearance-standard,.mat-button-toggle-group-appearance-standard{outline:0}}.mat-button-toggle-vertical{flex-direction:column}.mat-button-toggle-vertical .mat-button-toggle-label-content{display:block}.mat-button-toggle{white-space:nowrap;position:relative;color:var(--mat-legacy-button-toggle-text-color);font-family:var(--mat-legacy-button-toggle-label-text-font);font-size:var(--mat-legacy-button-toggle-label-text-size);line-height:var(--mat-legacy-button-toggle-label-text-line-height);font-weight:var(--mat-legacy-button-toggle-label-text-weight);letter-spacing:var(--mat-legacy-button-toggle-label-text-tracking);--mat-minimal-pseudo-checkbox-selected-checkmark-color: var(--mat-legacy-button-toggle-selected-state-text-color)}.mat-button-toggle.cdk-keyboard-focused .mat-button-toggle-focus-overlay{opacity:var(--mat-legacy-button-toggle-focus-state-layer-opacity)}.mat-button-toggle .mat-icon svg{vertical-align:top}.mat-button-toggle-checkbox-wrapper{display:inline-block;justify-content:flex-start;align-items:center;width:0;height:18px;line-height:18px;overflow:hidden;box-sizing:border-box;position:absolute;top:50%;left:16px;transform:translate3d(0, -50%, 0)}[dir=rtl] .mat-button-toggle-checkbox-wrapper{left:auto;right:16px}.mat-button-toggle-appearance-standard .mat-button-toggle-checkbox-wrapper{left:12px}[dir=rtl] .mat-button-toggle-appearance-standard .mat-button-toggle-checkbox-wrapper{left:auto;right:12px}.mat-button-toggle-checked .mat-button-toggle-checkbox-wrapper{width:18px}.mat-button-toggle-animations-enabled .mat-button-toggle-checkbox-wrapper{transition:width 150ms 45ms cubic-bezier(0.4, 0, 0.2, 1)}.mat-button-toggle-vertical .mat-button-toggle-checkbox-wrapper{transition:none}.mat-button-toggle-checked{color:var(--mat-legacy-button-toggle-selected-state-text-color);background-color:var(--mat-legacy-button-toggle-selected-state-background-color)}.mat-button-toggle-disabled{pointer-events:none;color:var(--mat-legacy-button-toggle-disabled-state-text-color);background-color:var(--mat-legacy-button-toggle-disabled-state-background-color);--mat-minimal-pseudo-checkbox-disabled-selected-checkmark-color: var(--mat-legacy-button-toggle-disabled-state-text-color)}.mat-button-toggle-disabled.mat-button-toggle-checked{background-color:var(--mat-legacy-button-toggle-disabled-selected-state-background-color)}.mat-button-toggle-disabled-interactive{pointer-events:auto}.mat-button-toggle-appearance-standard{color:var(--mat-standard-button-toggle-text-color, var(--mat-sys-on-surface));background-color:var(--mat-standard-button-toggle-background-color, transparent);font-family:var(--mat-standard-button-toggle-label-text-font, var(--mat-sys-label-large-font));font-size:var(--mat-standard-button-toggle-label-text-size, var(--mat-sys-label-large-size));line-height:var(--mat-standard-button-toggle-label-text-line-height, var(--mat-sys-label-large-line-height));font-weight:var(--mat-standard-button-toggle-label-text-weight, var(--mat-sys-label-large-weight));letter-spacing:var(--mat-standard-button-toggle-label-text-tracking, var(--mat-sys-label-large-tracking))}.mat-button-toggle-group-appearance-standard .mat-button-toggle-appearance-standard+.mat-button-toggle-appearance-standard{border-left:solid 1px var(--mat-standard-button-toggle-divider-color, var(--mat-sys-outline))}[dir=rtl] .mat-button-toggle-group-appearance-standard .mat-button-toggle-appearance-standard+.mat-button-toggle-appearance-standard{border-left:none;border-right:solid 1px var(--mat-standard-button-toggle-divider-color, var(--mat-sys-outline))}.mat-button-toggle-group-appearance-standard.mat-button-toggle-vertical .mat-button-toggle-appearance-standard+.mat-button-toggle-appearance-standard{border-left:none;border-right:none;border-top:solid 1px var(--mat-standard-button-toggle-divider-color, var(--mat-sys-outline))}.mat-button-toggle-appearance-standard.mat-button-toggle-checked{color:var(--mat-standard-button-toggle-selected-state-text-color, var(--mat-sys-on-secondary-container));background-color:var(--mat-standard-button-toggle-selected-state-background-color, var(--mat-sys-secondary-container))}.mat-button-toggle-appearance-standard.mat-button-toggle-disabled{color:var(--mat-standard-button-toggle-disabled-state-text-color, color-mix(in srgb, var(--mat-sys-on-surface) 38%, transparent));background-color:var(--mat-standard-button-toggle-disabled-state-background-color, transparent)}.mat-button-toggle-appearance-standard.mat-button-toggle-disabled .mat-pseudo-checkbox{--mat-minimal-pseudo-checkbox-disabled-selected-checkmark-color: var(--mat-standard-button-toggle-disabled-selected-state-text-color, color-mix(in srgb, var(--mat-sys-on-surface) 38%, transparent))}.mat-button-toggle-appearance-standard.mat-button-toggle-disabled.mat-button-toggle-checked{color:var(--mat-standard-button-toggle-disabled-selected-state-text-color, color-mix(in srgb, var(--mat-sys-on-surface) 38%, transparent));background-color:var(--mat-standard-button-toggle-disabled-selected-state-background-color, color-mix(in srgb, var(--mat-sys-on-surface) 12%, transparent))}.mat-button-toggle-appearance-standard .mat-button-toggle-focus-overlay{background-color:var(--mat-standard-button-toggle-state-layer-color, var(--mat-sys-on-surface))}.mat-button-toggle-appearance-standard:hover .mat-button-toggle-focus-overlay{opacity:var(--mat-standard-button-toggle-hover-state-layer-opacity, var(--mat-sys-hover-state-layer-opacity))}.mat-button-toggle-appearance-standard.cdk-keyboard-focused .mat-button-toggle-focus-overlay{opacity:var(--mat-standard-button-toggle-focus-state-layer-opacity, var(--mat-sys-focus-state-layer-opacity))}@media(hover: none){.mat-button-toggle-appearance-standard:hover .mat-button-toggle-focus-overlay{display:none}}.mat-button-toggle-label-content{-webkit-user-select:none;user-select:none;display:inline-block;padding:0 16px;line-height:var(--mat-legacy-button-toggle-height);position:relative}.mat-button-toggle-appearance-standard .mat-button-toggle-label-content{padding:0 12px;line-height:var(--mat-standard-button-toggle-height, 40px)}.mat-button-toggle-label-content>*{vertical-align:middle}.mat-button-toggle-focus-overlay{top:0;left:0;right:0;bottom:0;position:absolute;border-radius:inherit;pointer-events:none;opacity:0;background-color:var(--mat-legacy-button-toggle-state-layer-color)}@media(forced-colors: active){.mat-button-toggle-checked .mat-button-toggle-focus-overlay{border-bottom:solid 500px;opacity:.5;height:0}.mat-button-toggle-checked:hover .mat-button-toggle-focus-overlay{opacity:.6}.mat-button-toggle-checked.mat-button-toggle-appearance-standard .mat-button-toggle-focus-overlay{border-bottom:solid 500px}}.mat-button-toggle .mat-button-toggle-ripple{top:0;left:0;right:0;bottom:0;position:absolute;pointer-events:none}.mat-button-toggle-button{border:0;background:none;color:inherit;padding:0;margin:0;font:inherit;outline:none;width:100%;cursor:pointer}.mat-button-toggle-animations-enabled .mat-button-toggle-button{transition:padding 150ms 45ms cubic-bezier(0.4, 0, 0.2, 1)}.mat-button-toggle-vertical .mat-button-toggle-button{transition:none}.mat-button-toggle-disabled .mat-button-toggle-button{cursor:default}.mat-button-toggle-button::-moz-focus-inner{border:0}.mat-button-toggle-checked .mat-button-toggle-button:has(.mat-button-toggle-checkbox-wrapper){padding-left:30px}[dir=rtl] .mat-button-toggle-checked .mat-button-toggle-button:has(.mat-button-toggle-checkbox-wrapper){padding-left:0;padding-right:30px}.mat-button-toggle-standalone.mat-button-toggle-appearance-standard{--mat-focus-indicator-border-radius:var(--mat-standard-button-toggle-shape, var(--mat-sys-corner-full))}.mat-button-toggle-group-appearance-standard:not(.mat-button-toggle-vertical) .mat-button-toggle:last-of-type .mat-button-toggle-button::before{border-top-right-radius:var(--mat-standard-button-toggle-shape, var(--mat-sys-corner-full));border-bottom-right-radius:var(--mat-standard-button-toggle-shape, var(--mat-sys-corner-full))}.mat-button-toggle-group-appearance-standard:not(.mat-button-toggle-vertical) .mat-button-toggle:first-of-type .mat-button-toggle-button::before{border-top-left-radius:var(--mat-standard-button-toggle-shape, var(--mat-sys-corner-full));border-bottom-left-radius:var(--mat-standard-button-toggle-shape, var(--mat-sys-corner-full))}.mat-button-toggle-group-appearance-standard.mat-button-toggle-vertical .mat-button-toggle:last-of-type .mat-button-toggle-button::before{border-bottom-right-radius:var(--mat-standard-button-toggle-shape, var(--mat-sys-corner-full));border-bottom-left-radius:var(--mat-standard-button-toggle-shape, var(--mat-sys-corner-full))}.mat-button-toggle-group-appearance-standard.mat-button-toggle-vertical .mat-button-toggle:first-of-type .mat-button-toggle-button::before{border-top-right-radius:var(--mat-standard-button-toggle-shape, var(--mat-sys-corner-full));border-top-left-radius:var(--mat-standard-button-toggle-shape, var(--mat-sys-corner-full))}"],encapsulation:2,changeDetection:0})}return t})(),ncA=(()=>{class t{static \u0275fac=function(i){return new(i||t)};static \u0275mod=ge({type:t});static \u0275inj=le({imports:[Ve,Xa,Oy,Ve]})}return t})();function kzA(t,e){t&1&&(S(0,"p"),tA(1,"Conversations"),R())}function SzA(t,e){t&1&&(S(0,"p"),tA(1,"Trace"),R())}function RzA(t,e){if(t&1){let A=De();S(0,"mat-button-toggle-group",5),ta("ngModelChange",function(n){LA(A);let o=P(2);return Ja(o.view,n)||(o.view=n),xA(n)}),S(1,"mat-button-toggle",6),tA(2,"Events"),R(),S(3,"mat-button-toggle",7),tA(4,"Trace"),R()()}if(t&2){let A=P(2);ea("ngModel",A.view)}}function LzA(t,e){if(t&1){let A=De();S(0,"mat-list-item",8),mA("click",function(){let n=LA(A).$implicit,o=P(3);return xA(o.selectEvent(n.key))}),S(1,"span",9),tA(2),R(),S(3,"span",10),tA(4),R()()}if(t&2){let A=e.$implicit,i=e.$index;_(2),Mt(i),_(2),Mt(A.value.title)}}function xzA(t,e){if(t&1&&(S(0,"mat-list",4),ln(1,LzA,5,2,"mat-list-item",null,Kn),Ta(3,"keyvalue"),R()),t&2){let A=P(2);_(),gn(uQ(3,0,A.eventsMap,A.mapOrderPreservingSort))}}function FzA(t,e){if(t&1){let A=De();S(0,"mat-list-item",8),mA("click",function(){let n=LA(A).$implicit,o=P(3);return xA(o.openDialog(n.key))}),S(1,"span",9),tA(2),R(),S(3,"span"),tA(4),R()()}if(t&2){let A=e.$implicit,i=e.$index,n=P(3);_(2),Mt(i),_(2),ot("Invocation ",n.findInvocIdFromTraceId(A.key),"")}}function NzA(t,e){if(t&1&&(S(0,"mat-list",4),ln(1,FzA,5,2,"mat-list-item",null,Kn),Ta(3,"keyvalue"),R()),t&2){let A=P(2);_(),gn(uQ(3,0,A.invocTraces,A.mapOrderPreservingSort))}}function _zA(t,e){if(t&1&&(S(0,"div",1)(1,"div",2),NA(2,kzA,2,0,"p")(3,SzA,2,0,"p")(4,RzA,5,1,"mat-button-toggle-group",3),R(),NA(5,xzA,4,3,"mat-list",4)(6,NzA,4,3,"mat-list",4),R()),t&2){let A=P();_(2),FA(A.isTraceView()?-1:2),_(),FA(A.isTraceView()?3:-1),_(),FA(A.traceData?4:-1),_(),FA(A.isTraceView()?-1:5),_(),FA(A.isTraceView()?6:-1)}}function GzA(t,e){t&1&&(S(0,"div")(1,"p"),tA(2,"No conversations"),R()())}var jC=class t{constructor(e){this.dialog=e}eventsMap=new Map;selectedEvent=new XA;traceData=[];llmRequest=void 0;llmResponse=void 0;llmRequestKey="gcp.vertex.agent.llm_request";llmResponseKey="gcp.vertex.agent.llm_response";isDetailsPanelOpen=!1;view="events";invocTraces=new Map;ngOnChanges(e){"traceData"in e&&this.prcessTraceDataToInvocTrace()}showJson=Array(this.eventsMap.size).fill(!1);toggleJson(e){this.showJson[e]=!this.showJson[e]}selectEvent(e){this.selectedEvent.emit(e)}isTraceView(){return this.view=="trace"}mapOrderPreservingSort=(e,A)=>0;prcessTraceDataToInvocTrace(){!this.traceData||this.traceData.length==0||(this.invocTraces=this.traceData.reduce((e,A)=>{let i=A.trace_id,n=e.get(i);return n?(n.push(A),n.sort((o,r)=>o.start_time-r.start_time)):e.set(i,[A]),e},new Map))}findInvocIdFromTraceId(e){return this.invocTraces.get(e)?.find(i=>i.attributes!==void 0&&"gcp.vertex.agent.invocation_id"in i.attributes).attributes["gcp.vertex.agent.invocation_id"]}openDialog(e){let A=this.dialog.open(of,{width:"auto",maxWidth:"90vw",data:{spans:this.invocTraces.get(e),invocId:this.findInvocIdFromTraceId(e)}})}static \u0275fac=function(A){return new(A||t)(zA(Us))};static \u0275cmp=YA({type:t,selectors:[["app-event-tab"]],inputs:{eventsMap:"eventsMap",traceData:"traceData"},outputs:{selectedEvent:"selectedEvent"},standalone:!1,features:[Kt],decls:3,vars:2,consts:[[1,"events-wrapper"],[1,"events-container"],[1,"event-header"],["name","fontStyle","aria-label","Font Style",2,"scale","0.8",3,"ngModel"],[1,"event-list"],["name","fontStyle","aria-label","Font Style",2,"scale","0.8",3,"ngModelChange","ngModel"],["value","events"],["value","trace"],[3,"click"],[1,"event-index"],[1,"event-title"]],template:function(A,i){A&1&&(S(0,"div",0),NA(1,_zA,7,5,"div",1)(2,GzA,3,0,"div"),R()),A&2&&(_(),FA(i.eventsMap.size>0?1:-1),_(),FA(i.eventsMap.size==0?2:-1))},dependencies:[na,ja,$aA,AcA,vG,Oy,MQ],styles:[".events-wrapper[_ngcontent-%COMP%]{padding-left:25px;padding-right:25px;color:#9aa0a6;font-size:14px;font-weight:700}.event-index[_ngcontent-%COMP%]{color:#80868b;font-family:Roboto;font-size:14px;font-style:normal;font-weight:400;margin-right:10px}.event-title[_ngcontent-%COMP%]{font-family:Google Sans Mono,monospace}.spacer[_ngcontent-%COMP%]{flex:1 1 auto}.events-container[_ngcontent-%COMP%]{margin-top:20px}.event-container[_ngcontent-%COMP%]{display:flex;flex-direction:row;margin-top:20px}.function-event-button[_ngcontent-%COMP%]{margin-top:11px}.event-list[_ngcontent-%COMP%]{--mat-list-active-indicator-color: orange}.event-list[_ngcontent-%COMP%]{--mdc-list-list-item-container-color: #2b2b2f}.event-list[_ngcontent-%COMP%]{--mdc-list-list-item-label-text-size: 14px}.event-list[_ngcontent-%COMP%]{--mdc-list-list-item-label-text-weight: 400}.event-list[_ngcontent-%COMP%]{--mdc-list-list-item-one-line-container-height: 52px}[_nghost-%COMP%]     .mdc-list-item{border:1px solid #5f6368;cursor:pointer}[_nghost-%COMP%]     .mdc-list-item:hover{background-color:#1c1b1c}.event-header[_ngcontent-%COMP%]{display:flex;justify-content:space-between}"]})};function KzA(t,e){t&1&&(S(0,"h2",0),tA(1,"Events List"),R())}function YzA(t,e){t&1&&(S(0,"h2",0),tA(1,"Send Response To Pending Event"),R())}function JzA(t,e){t&1&&(S(0,"h2",4),tA(1,"Events List"),R())}function TzA(t,e){t&1&&(S(0,"h2",4),tA(1,"Send Response To Pending Event"),R())}function zzA(t,e){if(t&1){let A=De();S(0,"div")(1,"p"),tA(2,"Name"),R(),S(3,"p"),tA(4),R(),S(5,"p"),tA(6,"Args"),R(),S(7,"p"),tA(8),R(),S(9,"mat-form-field",5)(10,"mat-label"),tA(11,"Response"),R(),S(12,"textarea",6),ta("ngModelChange",function(n){LA(A);let o=P();return Ja(o.selectedEvent.response,n)||(o.selectedEvent.response=n),xA(n)}),R()()()}if(t&2){let A=P();_(4),Mt(A.selectedEvent.name),_(4),Mt(A.argsToJson(A.selectedEvent.args)),_(4),ea("ngModel",A.selectedEvent.response)}}function HzA(t,e){if(t&1){let A=De();S(0,"button",7),mA("click",function(){LA(A);let n=P();return xA(n.sendResponse())}),tA(1),R()}if(t&2){let A=P();vA("disabled",A.sending),_(),ot(" ",A.sending?"Sending...":"Send"," ")}}var rf=class t{constructor(e,A,i){this.dialogRef=e;this.data=A;this.agentService=i;this.selectedEvent=A.event,this.appName=A.appName,this.userId=A.userId,this.sessionId=A.sessionId,this.functionCallEventId=A.functionCallEventId}selectedEvent=null;appName;userId;sessionId;functionCallEventId;sending=!1;response=[];argsToJson(e){return JSON.stringify(e)}sendResponse(){this.sending=!0;let e={appName:this.appName,userId:this.userId,sessionId:this.sessionId,newMessage:{role:"user",parts:[]}};this.selectedEvent.response&&(e.functionCallEventId=this.functionCallEventId,e.newMessage.parts.push({function_response:{id:this.selectedEvent.id,name:this.selectedEvent.name,response:{response:this.selectedEvent.response}}})),this.agentService.runSse(e).subscribe({next:A=>_n(this,null,function*(){let i=JSON.parse(A);this.response.push(i)}),error:A=>console.error("SSE error:",A),complete:()=>{this.sending=!1,this.dialogRef.close({response:this.response,events:[this.selectedEvent]})}})}static \u0275fac=function(A){return new(A||t)(zA(cr),zA($r),zA(K2))};static \u0275cmp=YA({type:t,selectors:[["app-pending-event-dialog"]],standalone:!1,decls:10,vars:6,consts:[["mat-dialog-title",""],["mat-dialog-title","","class","dialog-title",4,"ngIf"],["mat-button","",3,"disabled"],["mat-button","","mat-dialog-close",""],["mat-dialog-title","",1,"dialog-title"],["appearance","outline",1,"response-textarea"],["matInput","",3,"ngModelChange","ngModel"],["mat-button","",3,"click","disabled"]],template:function(A,i){A&1&&(NA(0,KzA,2,0,"h2",0)(1,YzA,2,0,"h2",0)(2,JzA,2,0,"h2",1)(3,TzA,2,0,"h2",1),S(4,"mat-dialog-content"),NA(5,zzA,13,3,"div"),R(),S(6,"mat-dialog-actions"),NA(7,HzA,2,2,"button",2),S(8,"button",3),tA(9,"Close"),R()()),A&2&&(FA(i.selectedEvent?-1:0),_(),FA(i.selectedEvent?1:-1),_(),vA("ngIf",!i.selectedEvent),_(),vA("ngIf",i.selectedEvent),_(2),FA(i.selectedEvent?5:-1),_(2),FA(i.selectedEvent&&i.selectedEvent.response?7:-1))},dependencies:[DQ,fc,na,ja,lg,r8,P1,ur,hs,ga,Ia,gg],styles:[".response-textarea[_ngcontent-%COMP%]{min-width:500px;margin-top:15px}.dialog-title[_ngcontent-%COMP%]{font-weight:700;font-size:large}"]})};var dh=class t{constructor(e,A){this.dialogRef=e;this.data=A}onConfirm(){this.dialogRef.close(!0)}onCancel(){this.dialogRef.close(!1)}static \u0275fac=function(A){return new(A||t)(zA(cr),zA($r))};static \u0275cmp=YA({type:t,selectors:[["app-delete-session-dialog"]],standalone:!1,decls:11,vars:4,consts:[[1,"confirm-delete-wrapper"],["mat-dialog-title",""],["align","end"],["mat-button","",3,"click"],["mat-button","","cdkFocusInitial","",3,"click"]],template:function(A,i){A&1&&(S(0,"div",0)(1,"h2",1),tA(2),R(),S(3,"mat-dialog-content")(4,"p"),tA(5),R()(),S(6,"mat-dialog-actions",2)(7,"button",3),mA("click",function(){return i.onCancel()}),tA(8),R(),S(9,"button",4),mA("click",function(){return i.onConfirm()}),tA(10),R()()()),A&2&&(_(2),Mt(i.data.title),_(3),Mt(i.data.message),_(3),Mt(i.data.cancelButtonText),_(2),Mt(i.data.confirmButtonText))},dependencies:[ur,hs,ga,Ia],encapsulation:2})};function OzA(t,e){if(t&1){let A=De();S(0,"div",3),mA("click",function(){let n=LA(A).$implicit,o=P();return xA(o.getSession(n.id))}),S(1,"div",4)(2,"div",5),tA(3),R(),S(4,"div",6),tA(5),R()()()}if(t&2){let A=e.$implicit,i=P();vA("ngClass",A.id===i.sessionId?"session-item current":"session-item"),_(3),ot(" ",A.id," "),_(2),ot(" ",i.getDate(A)," ")}}var qC=class t{constructor(e,A){this.sessionService=e;this.dialog=A;this.refreshSessionsSubject.pipe(no(()=>this.sessionService.listSessions(this.userId,this.appName))).subscribe(i=>{i=i.sort((n,o)=>Number(o.lastUpdateTime)-Number(n.lastUpdateTime)),this.sessionList=i})}userId="";appName="";sessionId="";sessionSelected=new XA;sessionReloaded=new XA;sessionList=[];refreshSessionsSubject=new HA;ngOnInit(){setTimeout(()=>{this.refreshSessionsSubject.next()},500)}getSession(e){this.sessionService.getSession(this.userId,this.appName,e).subscribe(A=>{let i=this.fromApiResultToSession(A);this.sessionSelected.emit(i)})}getDate(e){let A=e.lastUpdateTime;return new Date(A*1e3).toLocaleString()}fromApiResultToSession(e){return{id:e?.id??"",appName:e?.appName??"",userId:e?.userId??"",state:e?.state??[],events:e?.events??[]}}reloadSession(e){this.sessionService.getSession(this.userId,this.appName,e).subscribe(A=>{let i=this.fromApiResultToSession(A);this.sessionReloaded.emit(i)})}refreshSession(e){if(this.refreshSessionsSubject.next(),!(this.sessionList.length<=1)){let A=this.sessionList.findIndex(i=>i.id==e);return A==this.sessionList.length-1&&(A=-1),this.sessionList[A+1]}}static \u0275fac=function(A){return new(A||t)(zA(Jg),zA(Us))};static \u0275cmp=YA({type:t,selectors:[["app-session-tab"]],inputs:{userId:"userId",appName:"appName",sessionId:"sessionId"},outputs:{sessionSelected:"sessionSelected",sessionReloaded:"sessionReloaded"},standalone:!1,decls:4,vars:0,consts:[[1,"session-wrapper"],[1,"session-tab-container",2,"margin-top","16px"],[3,"ngClass"],[3,"click","ngClass"],[1,"session-info"],[1,"session-id"],[1,"session-date"]],template:function(A,i){A&1&&(S(0,"div",0)(1,"div",1),ln(2,OzA,6,3,"div",2,Kn),R()()),A&2&&(_(2),gn(i.sessionList))},dependencies:[Ha],styles:[".session-wrapper[_ngcontent-%COMP%]{padding-left:25px;padding-right:25px;color:#9aa0a6;font-size:14px;font-weight:700}.session-item[_ngcontent-%COMP%]{display:flex;justify-content:space-between;border:none;background-color:#303030;border-radius:8px;margin-bottom:4px;cursor:pointer}.session-item[_ngcontent-%COMP%]:hover{background-color:#141414}.session-item.current[_ngcontent-%COMP%]{background-color:#004a77}.session-id[_ngcontent-%COMP%]{color:#e8eaed;font-family:Google Sans Mono,monospace;font-size:14px;font-style:normal;font-weight:500;line-height:20px;letter-spacing:.25px}.session-date[_ngcontent-%COMP%]{color:#9aa0a6;font-family:Roboto;font-size:12px;font-style:normal;font-weight:400;line-height:16px;letter-spacing:.3px}.session-info[_ngcontent-%COMP%]{padding:11px}"]})};var Bh=class t{constructor(e){this.http=e}apiServerDomain=Es.getApiServerBaseUrl();getLatestArtifact(e,A,i,n){let o=this.apiServerDomain+`/apps/${A}/users/${e}/sessions/${i}/artifacts/${n}`;return this.http.get(o)}getArtifactVersion(e,A,i,n,o){let r=this.apiServerDomain+`/apps/${A}/users/${e}/sessions/${i}/artifacts/${n}/versions/${o}`;return this.http.get(r)}static \u0275fac=function(A){return new(A||t)(he(Bs))};static \u0275prov=SA({token:t,factory:t.\u0275fac,providedIn:"root"})};var qzA={url:"",deserializer:t=>JSON.parse(t.data),serializer:t=>JSON.stringify(t)},VzA="WebSocketSubject.error must be called with an object with an error code, and an optional reason: { code: number, reason: string }",sf=class t extends cd{constructor(e,A){if(super(),this._socket=null,e instanceof Ze)this.destination=A,this.source=e;else{let i=this._config=Object.assign({},qzA);if(this._output=new HA,typeof e=="string")i.url=e;else for(let n in e)e.hasOwnProperty(n)&&(i[n]=e[n]);if(!i.WebSocketCtor&&WebSocket)i.WebSocketCtor=WebSocket;else if(!i.WebSocketCtor)throw new Error("no WebSocket constructor can be found");this.destination=new qc}}lift(e){let A=new t(this._config,this.destination);return A.operator=e,A.source=this,A}_resetState(){this._socket=null,this.source||(this.destination=new qc),this._output=new HA}multiplex(e,A,i){let n=this;return new Ze(o=>{try{n.next(e())}catch(s){o.error(s)}let r=n.subscribe({next:s=>{try{i(s)&&o.next(s)}catch(a){o.error(a)}},error:s=>o.error(s),complete:()=>o.complete()});return()=>{try{n.next(A())}catch(s){o.error(s)}r.unsubscribe()}})}_connectSocket(){let{WebSocketCtor:e,protocol:A,url:i,binaryType:n}=this._config,o=this._output,r=null;try{r=A?new e(i,A):new e(i),this._socket=r,n&&(this._socket.binaryType=n)}catch(a){o.error(a);return}let s=new _t(()=>{this._socket=null,r&&r.readyState===1&&r.close()});r.onopen=a=>{let{_socket:c}=this;if(!c){r.close(),this._resetState();return}let{openObserver:l}=this._config;l&&l.next(a);let I=this.destination;this.destination=Zg.create(C=>{if(r.readyState===1)try{let{serializer:d}=this._config;r.send(d(C))}catch(d){this.destination.error(d)}},C=>{let{closingObserver:d}=this._config;d&&d.next(void 0),C&&C.code?r.close(C.code,C.reason):o.error(new TypeError(VzA)),this._resetState()},()=>{let{closingObserver:C}=this._config;C&&C.next(void 0),r.close(),this._resetState()}),I&&I instanceof qc&&s.add(I.subscribe(this.destination))},r.onerror=a=>{this._resetState(),o.error(a)},r.onclose=a=>{r===this._socket&&this._resetState();let{closeObserver:c}=this._config;c&&c.next(a),a.wasClean?o.complete():o.error(a)},r.onmessage=a=>{try{let{deserializer:c}=this._config;o.next(c(a))}catch(c){o.error(c)}}}_subscribe(e){let{source:A}=this;return A?A.subscribe(e):(this._socket||this._connectSocket(),this._output.subscribe(e),e.add(()=>{let{_socket:i}=this;this._output.observers.length===0&&(i&&(i.readyState===1||i.readyState===0)&&i.close(),this._resetState())}),e)}unsubscribe(){let{_socket:e}=this;e&&(e.readyState===1||e.readyState===0)&&e.close(),this._resetState(),super.unsubscribe()}};var Tg=class t{socket$;messages$=new li("");audioContext=new AudioContext({sampleRate:22e3});audioBuffer=[];audioIntervalId=null;lastAudioTime=0;closeReasonSubject=new HA;constructor(){}connect(e){this.socket$=new sf({url:e,serializer:A=>JSON.stringify(A),deserializer:A=>A.data,closeObserver:{next:A=>{this.emitWsCloseReason(A.reason)}}}),this.socket$.subscribe(A=>{this.handleIncomingAudio(A),this.messages$.next(A)},A=>{console.error("WebSocket error:",A)}),this.audioIntervalId=setInterval(()=>this.processBufferedAudio(),250)}sendMessage(e){if(e.blob.data=this.arrayBufferToBase64(e.blob.data.buffer),!this.socket$||this.socket$.closed){console.error("WebSocket is not open.");return}this.socket$.next(e)}closeConnection(){clearInterval(this.audioIntervalId),this.audioIntervalId=null,this.socket$&&this.socket$.complete()}getMessages(){return this.messages$.asObservable()}arrayBufferToBase64(e){let A="",i=new Uint8Array(e),n=i.byteLength;for(let o=0;o<n;o++)A+=String.fromCharCode(i[o]);return btoa(A)}handleIncomingAudio(e){let A=JSON.parse(e);if(A.content&&A.content.parts&&A.content.parts[0].inlineData){let i=this.base64ToUint8Array(A.content.parts[0].inlineData.data);this.audioBuffer.push(i)}}processBufferedAudio(){if(this.audioBuffer.length===0)return;let e=this.audioBuffer.reduce((n,o)=>n+o.length,0),A=new Uint8Array(e),i=0;for(let n of this.audioBuffer)A.set(n,i),i+=n.length;this.playPCM(A),this.audioBuffer=[]}base64ToUint8Array(e){let A=atob(this.urlSafeBase64ToBase64(e)),i=A.length,n=new Uint8Array(i);for(let o=0;o<i;o++)n[o]=A.charCodeAt(o);return n}playPCM(e){let A=new Float32Array(e.length/2);for(let s=0;s<A.length;s++){let a=e[s*2]|e[s*2+1]<<8;a>=32768&&(a-=65536),A[s]=a/32768}let i=this.audioContext.createBuffer(1,A.length,22e3);i.copyToChannel(A,0);let n=this.audioContext.createBufferSource();n.buffer=i,n.connect(this.audioContext.destination);let o=this.audioContext.currentTime,r=Math.max(this.lastAudioTime,o);n.start(r),this.lastAudioTime=r+i.duration}urlSafeBase64ToBase64(e){let A=e.replace(/_/g,"/").replace(/-/g,"+");for(;A.length%4!==0;)A+="=";return A}emitWsCloseReason(e){this.closeReasonSubject.next(e)}onCloseReason(){return this.closeReasonSubject.asObservable()}static \u0275fac=function(A){return new(A||t)};static \u0275prov=SA({token:t,factory:t.\u0275fac,providedIn:"root"})};var Eh=class t{constructor(e){this.wsService=e}mediaRecorder;stream;audioContext;source;processor;audioBuffer=[];audioIntervalId=null;startRecording(){return _n(this,null,function*(){try{this.stream=yield navigator.mediaDevices.getUserMedia({audio:!0}),this.audioContext=new AudioContext,yield this.audioContext.audioWorklet.addModule("./assets/audio-processor.js"),this.source=this.audioContext.createMediaStreamSource(this.stream);let e=new AudioWorkletNode(this.audioContext,"audio-processor");e.port.onmessage=A=>{let i=A.data,n=this.float32ToPCM(i);this.audioBuffer.push(n)},this.source.connect(e),e.connect(this.audioContext.destination),this.audioIntervalId=setInterval(()=>this.sendBufferedAudio(),250)}catch(e){console.error("Error accessing microphone:",e)}})}sendBufferedAudio(){if(this.audioBuffer.length===0)return;let e=this.audioBuffer.reduce((o,r)=>o+r.length,0),A=new Uint8Array(e),i=0;for(let o of this.audioBuffer)A.set(o,i),i+=o.length;let n={blob:{mime_type:"audio/pcm",data:A}};this.wsService.sendMessage(n),this.audioBuffer=[]}stopRecording(){this.processor&&this.processor.disconnect(),this.source&&this.source.disconnect(),this.audioContext&&this.audioContext.close(),this.stream&&this.stream.getTracks().forEach(e=>e.stop()),this.audioIntervalId&&(clearInterval(this.audioIntervalId),this.audioIntervalId=null)}float32ToPCM(e){let A=new ArrayBuffer(e.length*2),i=new DataView(A);for(let n=0;n<e.length;n++){let o=Math.max(-1,Math.min(1,e[n]));o=o<0?o*32768:o*32767,i.setInt16(n*2,o,!0)}return new Uint8Array(A)}static \u0275fac=function(A){return new(A||t)(he(Tg))};static \u0275prov=SA({token:t,factory:t.\u0275fac,providedIn:"root"})};var hh=class t{constructor(e,A){this.wsService=e;this.renderer=A.createRenderer(null,null)}mediaRecorder;stream;renderer;videoElement;videoBuffer=[];videoIntervalId=null;createVideoElement(e){this.clearVideoElement(e),this.videoElement=this.renderer.createElement("video"),this.renderer.setAttribute(this.videoElement,"width","400"),this.renderer.setAttribute(this.videoElement,"height","300"),this.renderer.setAttribute(this.videoElement,"autoplay","true"),this.renderer.setAttribute(this.videoElement,"muted","true"),this.renderer.appendChild(e.nativeElement,this.videoElement)}startRecording(e){return _n(this,null,function*(){this.createVideoElement(e);try{this.stream=yield navigator.mediaDevices.getUserMedia({video:!0}),this.videoElement.srcObject=this.stream,this.mediaRecorder=new MediaRecorder(this.stream,{mimeType:"video/webm"}),this.mediaRecorder.start(1e3),this.videoIntervalId=setInterval(()=>this.captureAndSendFrame(),1e3)}catch(A){console.error("Error accessing camera/microphone:",A)}})}captureAndSendFrame(){return _n(this,null,function*(){try{let e=yield this.captureFrame(),i={blob:{mime_type:"image/jpeg",data:yield this.blobToUint8Array(e)}};this.wsService.sendMessage(i)}catch(e){console.error("Error capturing frame:",e)}})}blobToUint8Array(e){return _n(this,null,function*(){let A=yield e.arrayBuffer();return new Uint8Array(A)})}captureFrame(){return _n(this,null,function*(){return new Promise((e,A)=>{try{let i=document.createElement("canvas");i.width=this.videoElement.videoWidth,i.height=this.videoElement.videoHeight;let n=i.getContext("2d");if(!n){A(new Error("Canvas context not supported"));return}n.drawImage(this.videoElement,0,0,i.width,i.height),i.toBlob(o=>{o?e(o):A(new Error("Failed to create image blob"))},"image/png")}catch(i){A(i)}})})}sendBufferedVideo(){if(this.videoBuffer.length===0)return;let e=this.videoBuffer.reduce((o,r)=>o+r.length,0),A=new Uint8Array(e),i=0;for(let o of this.videoBuffer)A.set(o,i),i+=o.length;let n={blob:{mime_type:"image/jpeg",data:A}};this.wsService.sendMessage(n),this.videoBuffer=[]}stopRecording(e){this.mediaRecorder&&this.mediaRecorder.stop(),this.stream&&this.stream.getTracks().forEach(A=>A.stop()),clearInterval(this.videoIntervalId),this.clearVideoElement(e)}clearVideoElement(e){let A=e.nativeElement.querySelector("video");A&&this.renderer.removeChild(e.nativeElement,A)}static \u0275fac=function(A){return new(A||t)(he(Tg),he(ds))};static \u0275prov=SA({token:t,factory:t.\u0275fac,providedIn:"root"})};var j1=class t{constructor(e){this.http=e}apiServerDomain=Es.getApiServerBaseUrl();getEventTrace(e){let A=this.apiServerDomain+`/debug/trace/${e}`;return this.http.get(A)}getTrace(e){let A=this.apiServerDomain+`/debug/trace/session/${e}`;return this.http.get(A)}getEvent(e,A,i,n){let o=this.apiServerDomain+`/apps/${A}/users/${e}/sessions/${i}/events/${n}/graph`;return this.http.get(o)}static \u0275fac=function(A){return new(A||t)(he(Bs))};static \u0275prov=SA({token:t,factory:t.\u0275fac,providedIn:"root"})};var zg=class t{selectedTraceRowSource=new li(void 0);selectedTraceRow$=this.selectedTraceRowSource.asObservable();eventDataSource=new li(void 0);eventData$=this.eventDataSource.asObservable();hoveredMessageIndiciesSource=new li([]);hoveredMessageIndicies$=this.hoveredMessageIndiciesSource.asObservable();messagesSource=new li([]);messages$=this.messagesSource.asObservable();selectedRow(e){this.selectedTraceRowSource.next(e)}setEventData(e){this.eventDataSource.next(e)}setMessages(e){this.messagesSource.next(e)}setHoveredMessages(e,A){if(!e){this.hoveredMessageIndiciesSource.next([]);return}let i=e.attributes,n=i&&i["gcp.vertex.agent.event_id"],o=0,r=[];for(let s of this.messagesSource.value){if(s.role=="user"){o++;continue}if(this.eventDataSource.value?.get(s.eventId).invocationId!=A){o++;continue}if(n)if(i["gcp.vertex.agent.event_id"]==s.eventId){r.push(o),o++;continue}else{o++;continue}else{r.push(o),o++;continue}}this.hoveredMessageIndiciesSource.next(r)}resetTraceService(){this.eventDataSource.next(void 0),this.messagesSource.next([]),this.hoveredMessageIndiciesSource.next([])}static \u0275fac=function(A){return new(A||t)};static \u0275prov=SA({token:t,factory:t.\u0275fac,providedIn:"root"})};var XzA=["*"];var $zA=new BA("MAT_CARD_CONFIG"),rcA=(()=>{class t{appearance;constructor(){let A=m($zA,{optional:!0});this.appearance=A?.appearance||"raised"}static \u0275fac=function(i){return new(i||t)};static \u0275cmp=YA({type:t,selectors:[["mat-card"]],hostAttrs:[1,"mat-mdc-card","mdc-card"],hostVars:4,hostBindings:function(i,n){i&2&&ue("mat-mdc-card-outlined",n.appearance==="outlined")("mdc-card--outlined",n.appearance==="outlined")},inputs:{appearance:"appearance"},exportAs:["matCard"],ngContentSelectors:XzA,decls:1,vars:0,template:function(i,n){i&1&&(Yt(),xe(0))},styles:['.mat-mdc-card{display:flex;flex-direction:column;box-sizing:border-box;position:relative;border-style:solid;border-width:0;background-color:var(--mdc-elevated-card-container-color, var(--mat-sys-surface-container-low));border-color:var(--mdc-elevated-card-container-color, var(--mat-sys-surface-container-low));border-radius:var(--mdc-elevated-card-container-shape, var(--mat-sys-corner-medium));box-shadow:var(--mdc-elevated-card-container-elevation, var(--mat-sys-level1))}.mat-mdc-card::after{position:absolute;top:0;left:0;width:100%;height:100%;border:solid 1px rgba(0,0,0,0);content:"";display:block;pointer-events:none;box-sizing:border-box;border-radius:var(--mdc-elevated-card-container-shape, var(--mat-sys-corner-medium))}.mat-mdc-card-outlined{background-color:var(--mdc-outlined-card-container-color, var(--mat-sys-surface));border-radius:var(--mdc-outlined-card-container-shape, var(--mat-sys-corner-medium));border-width:var(--mdc-outlined-card-outline-width, 1px);border-color:var(--mdc-outlined-card-outline-color, var(--mat-sys-outline-variant));box-shadow:var(--mdc-outlined-card-container-elevation, var(--mat-sys-level0))}.mat-mdc-card-outlined::after{border:none}.mdc-card__media{position:relative;box-sizing:border-box;background-repeat:no-repeat;background-position:center;background-size:cover}.mdc-card__media::before{display:block;content:""}.mdc-card__media:first-child{border-top-left-radius:inherit;border-top-right-radius:inherit}.mdc-card__media:last-child{border-bottom-left-radius:inherit;border-bottom-right-radius:inherit}.mat-mdc-card-actions{display:flex;flex-direction:row;align-items:center;box-sizing:border-box;min-height:52px;padding:8px}.mat-mdc-card-title{font-family:var(--mat-card-title-text-font, var(--mat-sys-title-large-font));line-height:var(--mat-card-title-text-line-height, var(--mat-sys-title-large-line-height));font-size:var(--mat-card-title-text-size, var(--mat-sys-title-large-size));letter-spacing:var(--mat-card-title-text-tracking, var(--mat-sys-title-large-tracking));font-weight:var(--mat-card-title-text-weight, var(--mat-sys-title-large-weight))}.mat-mdc-card-subtitle{color:var(--mat-card-subtitle-text-color, var(--mat-sys-on-surface));font-family:var(--mat-card-subtitle-text-font, var(--mat-sys-title-medium-font));line-height:var(--mat-card-subtitle-text-line-height, var(--mat-sys-title-medium-line-height));font-size:var(--mat-card-subtitle-text-size, var(--mat-sys-title-medium-size));letter-spacing:var(--mat-card-subtitle-text-tracking, var(--mat-sys-title-medium-tracking));font-weight:var(--mat-card-subtitle-text-weight, var(--mat-sys-title-medium-weight))}.mat-mdc-card-title,.mat-mdc-card-subtitle{display:block;margin:0}.mat-mdc-card-avatar~.mat-mdc-card-header-text .mat-mdc-card-title,.mat-mdc-card-avatar~.mat-mdc-card-header-text .mat-mdc-card-subtitle{padding:16px 16px 0}.mat-mdc-card-header{display:flex;padding:16px 16px 0}.mat-mdc-card-content{display:block;padding:0 16px}.mat-mdc-card-content:first-child{padding-top:16px}.mat-mdc-card-content:last-child{padding-bottom:16px}.mat-mdc-card-title-group{display:flex;justify-content:space-between;width:100%}.mat-mdc-card-avatar{height:40px;width:40px;border-radius:50%;flex-shrink:0;margin-bottom:16px;object-fit:cover}.mat-mdc-card-avatar~.mat-mdc-card-header-text .mat-mdc-card-subtitle,.mat-mdc-card-avatar~.mat-mdc-card-header-text .mat-mdc-card-title{line-height:normal}.mat-mdc-card-sm-image{width:80px;height:80px}.mat-mdc-card-md-image{width:112px;height:112px}.mat-mdc-card-lg-image{width:152px;height:152px}.mat-mdc-card-xl-image{width:240px;height:240px}.mat-mdc-card-subtitle~.mat-mdc-card-title,.mat-mdc-card-title~.mat-mdc-card-subtitle,.mat-mdc-card-header .mat-mdc-card-header-text .mat-mdc-card-title,.mat-mdc-card-header .mat-mdc-card-header-text .mat-mdc-card-subtitle,.mat-mdc-card-title-group .mat-mdc-card-title,.mat-mdc-card-title-group .mat-mdc-card-subtitle{padding-top:0}.mat-mdc-card-content>:last-child:not(.mat-mdc-card-footer){margin-bottom:0}.mat-mdc-card-actions-align-end{justify-content:flex-end}'],encapsulation:2,changeDetection:0})}return t})();var scA=(()=>{class t{static \u0275fac=function(i){return new(i||t)};static \u0275mod=ge({type:t});static \u0275inj=le({imports:[Ve,Ve]})}return t})();var eHA=t=>["segment",t],tHA=(t,e)=>({"segment-main":!0,expandable:t,expanded:e});function iHA(t,e){t&1&&UA(0,"div",9)}function nHA(t,e){if(t&1&&(S(0,"span",10),tA(1),R()),t&2){let A=P().$implicit;_(),Mt(A.description)}}function oHA(t,e){if(t&1&&(S(0,"section",11),UA(1,"ngx-json-viewer",12),R()),t&2){let A=P().$implicit,i=P();_(),vA("json",A.value)("expanded",i.expanded)("depth",i.depth)("_currentDepth",i._currentDepth+1)}}function rHA(t,e){if(t&1){let A=De();S(0,"section",2)(1,"section",3),mA("click",function(){let n=LA(A).$implicit,o=P();return xA(o.toggle(n))}),NA(2,iHA,1,0,"div",4),S(3,"span",5),tA(4),R(),S(5,"span",6),tA(6,": "),R(),NA(7,nHA,2,1,"span",7),R(),NA(8,oHA,2,4,"section",8),R()}if(t&2){let A=e.$implicit,i=P();vA("ngClass",Yr(6,eHA,"segment-type-"+A.type)),_(),vA("ngClass",p2(8,tHA,i.isExpandable(A),A.expanded)),_(),vA("ngIf",i.isExpandable(A)),_(2),Mt(A.key),_(3),vA("ngIf",!A.expanded||!i.isExpandable(A)),_(),vA("ngIf",A.expanded&&i.isExpandable(A))}}var Qh=(()=>{class t{constructor(){this.expanded=!0,this.depth=-1,this._currentDepth=0,this.segments=[]}ngOnChanges(){this.segments=[],this.json=this.decycle(this.json),typeof this.json=="object"?Object.keys(this.json).forEach(A=>{this.segments.push(this.parseKeyValue(A,this.json[A]))}):this.segments.push(this.parseKeyValue(`(${typeof this.json})`,this.json))}isExpandable(A){return A.type==="object"||A.type==="array"}toggle(A){this.isExpandable(A)&&(A.expanded=!A.expanded)}parseKeyValue(A,i){let n={key:A,value:i,type:void 0,description:""+i,expanded:this.isExpanded()};switch(typeof n.value){case"number":{n.type="number";break}case"boolean":{n.type="boolean";break}case"function":{n.type="function";break}case"string":{n.type="string",n.description='"'+n.value+'"';break}case"undefined":{n.type="undefined",n.description="undefined";break}case"object":{n.value===null?(n.type="null",n.description="null"):Array.isArray(n.value)?(n.type="array",n.description="Array["+n.value.length+"] "+JSON.stringify(n.value)):n.value instanceof Date?n.type="date":(n.type="object",n.description="Object "+JSON.stringify(n.value));break}}return n}isExpanded(){return this.expanded&&!(this.depth>-1&&this._currentDepth>=this.depth)}decycle(A){let i=new WeakMap;return function n(o,r){let s,a;return typeof o=="object"&&o!==null&&!(o instanceof Boolean)&&!(o instanceof Date)&&!(o instanceof Number)&&!(o instanceof RegExp)&&!(o instanceof String)?(s=i.get(o),s!==void 0?{$ref:s}:(i.set(o,r),Array.isArray(o)?(a=[],o.forEach(function(c,l){a[l]=n(c,r+"["+l+"]")})):(a={},Object.keys(o).forEach(function(c){a[c]=n(o[c],r+"["+JSON.stringify(c)+"]")})),a)):o}(A,"$")}}return t.\u0275fac=function(A){return new(A||t)},t.\u0275cmp=YA({type:t,selectors:[["ngx-json-viewer"]],inputs:{json:"json",expanded:"expanded",depth:"depth",_currentDepth:"_currentDepth"},standalone:!1,features:[Kt],decls:2,vars:1,consts:[[1,"ngx-json-viewer"],[3,"ngClass",4,"ngFor","ngForOf"],[3,"ngClass"],[3,"click","ngClass"],["class","toggler",4,"ngIf"],[1,"segment-key"],[1,"segment-separator"],["class","segment-value",4,"ngIf"],["class","children",4,"ngIf"],[1,"toggler"],[1,"segment-value"],[1,"children"],[3,"json","expanded","depth","_currentDepth"]],template:function(A,i){A&1&&(S(0,"section",0),NA(1,rHA,9,11,"section",1),R()),A&2&&(_(),vA("ngForOf",i.segments))},dependencies:[Ha,kp,DQ,t],styles:['@charset "UTF-8";.ngx-json-viewer[_ngcontent-%COMP%]{font-family:var(--ngx-json-font-family, monospace);font-size:var(--ngx-json-font-size, 1em);width:100%;height:100%;overflow:hidden;position:relative}.ngx-json-viewer[_ngcontent-%COMP%]   .segment[_ngcontent-%COMP%]{padding:2px;margin:1px 1px 1px 12px}.ngx-json-viewer[_ngcontent-%COMP%]   .segment[_ngcontent-%COMP%]   .segment-main[_ngcontent-%COMP%]{word-wrap:break-word}.ngx-json-viewer[_ngcontent-%COMP%]   .segment[_ngcontent-%COMP%]   .segment-main[_ngcontent-%COMP%]   .toggler[_ngcontent-%COMP%]{position:absolute;margin-left:-14px;margin-top:3px;font-size:.8em;line-height:1.2em;vertical-align:middle;color:var(--ngx-json-toggler, #787878)}.ngx-json-viewer[_ngcontent-%COMP%]   .segment[_ngcontent-%COMP%]   .segment-main[_ngcontent-%COMP%]   .toggler[_ngcontent-%COMP%]:after{display:inline-block;content:"\\25ba";transition:transform .1s ease-in}.ngx-json-viewer[_ngcontent-%COMP%]   .segment[_ngcontent-%COMP%]   .segment-main[_ngcontent-%COMP%]   .segment-key[_ngcontent-%COMP%]{color:var(--ngx-json-key, #4E187C)}.ngx-json-viewer[_ngcontent-%COMP%]   .segment[_ngcontent-%COMP%]   .segment-main[_ngcontent-%COMP%]   .segment-separator[_ngcontent-%COMP%]{color:var(--ngx-json-separator, #999)}.ngx-json-viewer[_ngcontent-%COMP%]   .segment[_ngcontent-%COMP%]   .segment-main[_ngcontent-%COMP%]   .segment-value[_ngcontent-%COMP%]{color:var(--ngx-json-value, #000)}.ngx-json-viewer[_ngcontent-%COMP%]   .segment[_ngcontent-%COMP%]   .children[_ngcontent-%COMP%]{margin-left:12px}.ngx-json-viewer[_ngcontent-%COMP%]   .segment-type-string[_ngcontent-%COMP%] > .segment-main[_ngcontent-%COMP%] > .segment-value[_ngcontent-%COMP%]{color:var(--ngx-json-string, #FF6B6B)}.ngx-json-viewer[_ngcontent-%COMP%]   .segment-type-number[_ngcontent-%COMP%] > .segment-main[_ngcontent-%COMP%] > .segment-value[_ngcontent-%COMP%]{color:var(--ngx-json-number, #009688)}.ngx-json-viewer[_ngcontent-%COMP%]   .segment-type-boolean[_ngcontent-%COMP%] > .segment-main[_ngcontent-%COMP%] > .segment-value[_ngcontent-%COMP%]{color:var(--ngx-json-boolean, #B938A4)}.ngx-json-viewer[_ngcontent-%COMP%]   .segment-type-date[_ngcontent-%COMP%] > .segment-main[_ngcontent-%COMP%] > .segment-value[_ngcontent-%COMP%]{color:var(--ngx-json-date, #05668D)}.ngx-json-viewer[_ngcontent-%COMP%]   .segment-type-array[_ngcontent-%COMP%] > .segment-main[_ngcontent-%COMP%] > .segment-value[_ngcontent-%COMP%]{color:var(--ngx-json-array, #999)}.ngx-json-viewer[_ngcontent-%COMP%]   .segment-type-object[_ngcontent-%COMP%] > .segment-main[_ngcontent-%COMP%] > .segment-value[_ngcontent-%COMP%]{color:var(--ngx-json-object, #999)}.ngx-json-viewer[_ngcontent-%COMP%]   .segment-type-function[_ngcontent-%COMP%] > .segment-main[_ngcontent-%COMP%] > .segment-value[_ngcontent-%COMP%]{color:var(--ngx-json-function, #999)}.ngx-json-viewer[_ngcontent-%COMP%]   .segment-type-null[_ngcontent-%COMP%] > .segment-main[_ngcontent-%COMP%] > .segment-value[_ngcontent-%COMP%]{color:var(--ngx-json-null, #fff)}.ngx-json-viewer[_ngcontent-%COMP%]   .segment-type-undefined[_ngcontent-%COMP%] > .segment-main[_ngcontent-%COMP%] > .segment-value[_ngcontent-%COMP%]{color:var(--ngx-json-undefined, #fff)}.ngx-json-viewer[_ngcontent-%COMP%]   .segment-type-null[_ngcontent-%COMP%] > .segment-main[_ngcontent-%COMP%] > .segment-value[_ngcontent-%COMP%]{background-color:var(--ngx-json-null-bg, red)}.ngx-json-viewer[_ngcontent-%COMP%]   .segment-type-undefined[_ngcontent-%COMP%] > .segment-main[_ngcontent-%COMP%] > .segment-key[_ngcontent-%COMP%]{color:var(--ngx-json-undefined-key, #999)}.ngx-json-viewer[_ngcontent-%COMP%]   .segment-type-undefined[_ngcontent-%COMP%] > .segment-main[_ngcontent-%COMP%] > .segment-value[_ngcontent-%COMP%]{background-color:var(--ngx-json-undefined-key, #999)}.ngx-json-viewer[_ngcontent-%COMP%]   .segment-type-object[_ngcontent-%COMP%] > .segment-main[_ngcontent-%COMP%], .ngx-json-viewer[_ngcontent-%COMP%]   .segment-type-array[_ngcontent-%COMP%] > .segment-main[_ngcontent-%COMP%]{white-space:nowrap}.ngx-json-viewer[_ngcontent-%COMP%]   .expanded[_ngcontent-%COMP%] > .toggler[_ngcontent-%COMP%]:after{transform:rotate(90deg)}.ngx-json-viewer[_ngcontent-%COMP%]   .expandable[_ngcontent-%COMP%], .ngx-json-viewer[_ngcontent-%COMP%]   .expandable[_ngcontent-%COMP%] > .toggler[_ngcontent-%COMP%]{cursor:pointer}']}),t})(),acA=(()=>{class t{}return t.\u0275fac=function(A){return new(A||t)},t.\u0275mod=ge({type:t}),t.\u0275inj=le({imports:[g0]}),t})();var ccA=["*"],sHA=["content"],aHA=[[["mat-drawer"]],[["mat-drawer-content"]],"*"],cHA=["mat-drawer","mat-drawer-content","*"];function lHA(t,e){if(t&1){let A=De();S(0,"div",1),mA("click",function(){LA(A);let n=P();return xA(n._onBackdropClicked())}),R()}if(t&2){let A=P();ue("mat-drawer-shown",A._isShowingBackdrop())}}function gHA(t,e){t&1&&(S(0,"mat-drawer-content"),xe(1,2),R())}var IHA=new BA("MAT_DRAWER_DEFAULT_AUTOSIZE",{providedIn:"root",factory:CHA}),lcA=new BA("MAT_DRAWER_CONTAINER");function CHA(){return!1}var SG=(()=>{class t extends h0{_platform=m(Zt);_changeDetectorRef=m(lt);_container=m(LG);constructor(){let A=m(te),i=m(N2),n=m(de);super(A,i,n)}ngAfterContentInit(){this._container._contentMarginChanges.subscribe(()=>{this._changeDetectorRef.markForCheck()})}_shouldBeHidden(){if(this._platform.isBrowser)return!1;let{start:A,end:i}=this._container;return A!=null&&A.mode!=="over"&&A.opened||i!=null&&i.mode!=="over"&&i.opened}static \u0275fac=function(i){return new(i||t)};static \u0275cmp=YA({type:t,selectors:[["mat-drawer-content"]],hostAttrs:[1,"mat-drawer-content"],hostVars:6,hostBindings:function(i,n){i&2&&(so("margin-left",n._container._contentMargins.left,"px")("margin-right",n._container._contentMargins.right,"px"),ue("mat-drawer-content-hidden",n._shouldBeHidden()))},features:[ct([{provide:h0,useExisting:t}]),et],ngContentSelectors:ccA,decls:1,vars:0,template:function(i,n){i&1&&(Yt(),xe(0))},encapsulation:2,changeDetection:0})}return t})(),RG=(()=>{class t{_elementRef=m(te);_focusTrapFactory=m(P6);_focusMonitor=m(Jr);_platform=m(Zt);_ngZone=m(de);_renderer=m(Gi);_interactivityChecker=m(hu);_doc=m(tt,{optional:!0});_container=m(lcA,{optional:!0});_focusTrap=null;_elementFocusedBeforeDrawerWasOpened=null;_eventCleanups;_isAttached;_anchor;get position(){return this._position}set position(A){A=A==="end"?"end":"start",A!==this._position&&(this._isAttached&&this._updatePositionInParent(A),this._position=A,this.onPositionChanged.emit())}_position="start";get mode(){return this._mode}set mode(A){this._mode=A,this._updateFocusTrapState(),this._modeChanged.next()}_mode="over";get disableClose(){return this._disableClose}set disableClose(A){this._disableClose=Yo(A)}_disableClose=!1;get autoFocus(){let A=this._autoFocus;return A??(this.mode==="side"?"dialog":"first-tabbable")}set autoFocus(A){(A==="true"||A==="false"||A==null)&&(A=Yo(A)),this._autoFocus=A}_autoFocus;get opened(){return this._opened}set opened(A){this.toggle(Yo(A))}_opened=!1;_openedVia;_animationStarted=new HA;_animationEnd=new HA;openedChange=new XA(!0);_openedStream=this.openedChange.pipe(pt(A=>A),Je(()=>{}));openedStart=this._animationStarted.pipe(pt(()=>this.opened),dd(void 0));_closedStream=this.openedChange.pipe(pt(A=>!A),Je(()=>{}));closedStart=this._animationStarted.pipe(pt(()=>!this.opened),dd(void 0));_destroyed=new HA;onPositionChanged=new XA;_content;_modeChanged=new HA;_injector=m(Dt);_changeDetectorRef=m(lt);constructor(){this.openedChange.pipe(wt(this._destroyed)).subscribe(A=>{A?(this._doc&&(this._elementFocusedBeforeDrawerWasOpened=this._doc.activeElement),this._takeFocus()):this._isFocusWithinDrawer()&&this._restoreFocus(this._openedVia||"program")}),this._ngZone.runOutsideAngular(()=>{let A=this._elementRef.nativeElement;Oh(A,"keydown").pipe(pt(i=>i.keyCode===27&&!this.disableClose&&!rr(i)),wt(this._destroyed)).subscribe(i=>this._ngZone.run(()=>{this.close(),i.stopPropagation(),i.preventDefault()})),this._eventCleanups=[this._renderer.listen(A,"transitionrun",this._handleTransitionEvent),this._renderer.listen(A,"transitionend",this._handleTransitionEvent),this._renderer.listen(A,"transitioncancel",this._handleTransitionEvent)]}),this._animationEnd.subscribe(()=>{this.openedChange.emit(this._opened)})}_forceFocus(A,i){this._interactivityChecker.isFocusable(A)||(A.tabIndex=-1,this._ngZone.runOutsideAngular(()=>{let n=()=>{o(),r(),A.removeAttribute("tabindex")},o=this._renderer.listen(A,"blur",n),r=this._renderer.listen(A,"mousedown",n)})),A.focus(i)}_focusByCssSelector(A,i){let n=this._elementRef.nativeElement.querySelector(A);n&&this._forceFocus(n,i)}_takeFocus(){if(!this._focusTrap)return;let A=this._elementRef.nativeElement;switch(this.autoFocus){case!1:case"dialog":return;case!0:case"first-tabbable":Vo(()=>{!this._focusTrap.focusInitialElement()&&typeof A.focus=="function"&&A.focus()},{injector:this._injector});break;case"first-heading":this._focusByCssSelector('h1, h2, h3, h4, h5, h6, [role="heading"]');break;default:this._focusByCssSelector(this.autoFocus);break}}_restoreFocus(A){this.autoFocus!=="dialog"&&(this._elementFocusedBeforeDrawerWasOpened?this._focusMonitor.focusVia(this._elementFocusedBeforeDrawerWasOpened,A):this._elementRef.nativeElement.blur(),this._elementFocusedBeforeDrawerWasOpened=null)}_isFocusWithinDrawer(){let A=this._doc.activeElement;return!!A&&this._elementRef.nativeElement.contains(A)}ngAfterViewInit(){this._isAttached=!0,this._position==="end"&&this._updatePositionInParent("end"),this._platform.isBrowser&&(this._focusTrap=this._focusTrapFactory.create(this._elementRef.nativeElement),this._updateFocusTrapState())}ngOnDestroy(){this._eventCleanups.forEach(A=>A()),this._focusTrap?.destroy(),this._anchor?.remove(),this._anchor=null,this._animationStarted.complete(),this._animationEnd.complete(),this._modeChanged.complete(),this._destroyed.next(),this._destroyed.complete()}open(A){return this.toggle(!0,A)}close(){return this.toggle(!1)}_closeViaBackdropClick(){return this._setOpen(!1,!0,"mouse")}toggle(A=!this.opened,i){A&&i&&(this._openedVia=i);let n=this._setOpen(A,!A&&this._isFocusWithinDrawer(),this._openedVia||"program");return A||(this._openedVia=null),n}_setOpen(A,i,n){return A===this._opened?Promise.resolve(A?"open":"close"):(this._opened=A,this._container?._transitionsEnabled?this._setIsAnimating(!0):setTimeout(()=>{this._animationStarted.next(),this._animationEnd.next()}),this._elementRef.nativeElement.classList.toggle("mat-drawer-opened",A),!A&&i&&this._restoreFocus(n),this._changeDetectorRef.markForCheck(),this._updateFocusTrapState(),new Promise(o=>{this.openedChange.pipe(Pn(1)).subscribe(r=>o(r?"open":"close"))}))}_setIsAnimating(A){this._elementRef.nativeElement.classList.toggle("mat-drawer-animating",A)}_getWidth(){return this._elementRef.nativeElement.offsetWidth||0}_updateFocusTrapState(){this._focusTrap&&(this._focusTrap.enabled=!!this._container?.hasBackdrop&&this.opened)}_updatePositionInParent(A){if(!this._platform.isBrowser)return;let i=this._elementRef.nativeElement,n=i.parentNode;A==="end"?(this._anchor||(this._anchor=this._doc.createComment("mat-drawer-anchor"),n.insertBefore(this._anchor,i)),n.appendChild(i)):this._anchor&&this._anchor.parentNode.insertBefore(i,this._anchor)}_handleTransitionEvent=A=>{let i=this._elementRef.nativeElement;A.target===i&&this._ngZone.run(()=>{A.type==="transitionrun"?this._animationStarted.next(A):(A.type==="transitionend"&&this._setIsAnimating(!1),this._animationEnd.next(A))})};static \u0275fac=function(i){return new(i||t)};static \u0275cmp=YA({type:t,selectors:[["mat-drawer"]],viewQuery:function(i,n){if(i&1&&Ge(sHA,5),i&2){let o;$A(o=Ae())&&(n._content=o.first)}},hostAttrs:["tabIndex","-1",1,"mat-drawer"],hostVars:11,hostBindings:function(i,n){i&2&&(_e("align",null),so("visibility",!n._container&&!n.opened?"hidden":null),ue("mat-drawer-end",n.position==="end")("mat-drawer-over",n.mode==="over")("mat-drawer-push",n.mode==="push")("mat-drawer-side",n.mode==="side"))},inputs:{position:"position",mode:"mode",disableClose:"disableClose",autoFocus:"autoFocus",opened:"opened"},outputs:{openedChange:"openedChange",_openedStream:"opened",openedStart:"openedStart",_closedStream:"closed",closedStart:"closedStart",onPositionChanged:"positionChanged"},exportAs:["matDrawer"],ngContentSelectors:ccA,decls:3,vars:0,consts:[["content",""],["cdkScrollable","",1,"mat-drawer-inner-container"]],template:function(i,n){i&1&&(Yt(),S(0,"div",1,0),xe(2),R())},dependencies:[h0],encapsulation:2,changeDetection:0})}return t})(),LG=(()=>{class t{_dir=m(bo,{optional:!0});_element=m(te);_ngZone=m(de);_changeDetectorRef=m(lt);_animationMode=m(mi,{optional:!0});_transitionsEnabled=!1;_allDrawers;_drawers=new Ec;_content;_userContent;get start(){return this._start}get end(){return this._end}get autosize(){return this._autosize}set autosize(A){this._autosize=Yo(A)}_autosize=m(IHA);get hasBackdrop(){return this._drawerHasBackdrop(this._start)||this._drawerHasBackdrop(this._end)}set hasBackdrop(A){this._backdropOverride=A==null?null:Yo(A)}_backdropOverride;backdropClick=new XA;_start;_end;_left;_right;_destroyed=new HA;_doCheckSubject=new HA;_contentMargins={left:null,right:null};_contentMarginChanges=new HA;get scrollable(){return this._userContent||this._content}_injector=m(Dt);constructor(){let A=m(Zt),i=m(mc);this._dir?.change.pipe(wt(this._destroyed)).subscribe(()=>{this._validateDrawers(),this.updateContentMargins()}),i.change().pipe(wt(this._destroyed)).subscribe(()=>this.updateContentMargins()),this._animationMode!=="NoopAnimations"&&A.isBrowser&&this._ngZone.runOutsideAngular(()=>{setTimeout(()=>{this._element.nativeElement.classList.add("mat-drawer-transition"),this._transitionsEnabled=!0},200)})}ngAfterContentInit(){this._allDrawers.changes.pipe(Qo(this._allDrawers),wt(this._destroyed)).subscribe(A=>{this._drawers.reset(A.filter(i=>!i._container||i._container===this)),this._drawers.notifyOnChanges()}),this._drawers.changes.pipe(Qo(null)).subscribe(()=>{this._validateDrawers(),this._drawers.forEach(A=>{this._watchDrawerToggle(A),this._watchDrawerPosition(A),this._watchDrawerMode(A)}),(!this._drawers.length||this._isDrawerOpen(this._start)||this._isDrawerOpen(this._end))&&this.updateContentMargins(),this._changeDetectorRef.markForCheck()}),this._ngZone.runOutsideAngular(()=>{this._doCheckSubject.pipe(Vc(10),wt(this._destroyed)).subscribe(()=>this.updateContentMargins())})}ngOnDestroy(){this._contentMarginChanges.complete(),this._doCheckSubject.complete(),this._drawers.destroy(),this._destroyed.next(),this._destroyed.complete()}open(){this._drawers.forEach(A=>A.open())}close(){this._drawers.forEach(A=>A.close())}updateContentMargins(){let A=0,i=0;if(this._left&&this._left.opened){if(this._left.mode=="side")A+=this._left._getWidth();else if(this._left.mode=="push"){let n=this._left._getWidth();A+=n,i-=n}}if(this._right&&this._right.opened){if(this._right.mode=="side")i+=this._right._getWidth();else if(this._right.mode=="push"){let n=this._right._getWidth();i+=n,A-=n}}A=A||null,i=i||null,(A!==this._contentMargins.left||i!==this._contentMargins.right)&&(this._contentMargins={left:A,right:i},this._ngZone.run(()=>this._contentMarginChanges.next(this._contentMargins)))}ngDoCheck(){this._autosize&&this._isPushed()&&this._ngZone.runOutsideAngular(()=>this._doCheckSubject.next())}_watchDrawerToggle(A){A._animationStarted.pipe(wt(this._drawers.changes)).subscribe(()=>{this.updateContentMargins(),this._changeDetectorRef.markForCheck()}),A.mode!=="side"&&A.openedChange.pipe(wt(this._drawers.changes)).subscribe(()=>this._setContainerClass(A.opened))}_watchDrawerPosition(A){A.onPositionChanged.pipe(wt(this._drawers.changes)).subscribe(()=>{Vo({read:()=>this._validateDrawers()},{injector:this._injector})})}_watchDrawerMode(A){A._modeChanged.pipe(wt(ho(this._drawers.changes,this._destroyed))).subscribe(()=>{this.updateContentMargins(),this._changeDetectorRef.markForCheck()})}_setContainerClass(A){let i=this._element.nativeElement.classList,n="mat-drawer-container-has-open";A?i.add(n):i.remove(n)}_validateDrawers(){this._start=this._end=null,this._drawers.forEach(A=>{A.position=="end"?(this._end!=null,this._end=A):(this._start!=null,this._start=A)}),this._right=this._left=null,this._dir&&this._dir.value==="rtl"?(this._left=this._end,this._right=this._start):(this._left=this._start,this._right=this._end)}_isPushed(){return this._isDrawerOpen(this._start)&&this._start.mode!="over"||this._isDrawerOpen(this._end)&&this._end.mode!="over"}_onBackdropClicked(){this.backdropClick.emit(),this._closeModalDrawersViaBackdrop()}_closeModalDrawersViaBackdrop(){[this._start,this._end].filter(A=>A&&!A.disableClose&&this._drawerHasBackdrop(A)).forEach(A=>A._closeViaBackdropClick())}_isShowingBackdrop(){return this._isDrawerOpen(this._start)&&this._drawerHasBackdrop(this._start)||this._isDrawerOpen(this._end)&&this._drawerHasBackdrop(this._end)}_isDrawerOpen(A){return A!=null&&A.opened}_drawerHasBackdrop(A){return this._backdropOverride==null?!!A&&A.mode!=="side":this._backdropOverride}static \u0275fac=function(i){return new(i||t)};static \u0275cmp=YA({type:t,selectors:[["mat-drawer-container"]],contentQueries:function(i,n,o){if(i&1&&(Ii(o,SG,5),Ii(o,RG,5)),i&2){let r;$A(r=Ae())&&(n._content=r.first),$A(r=Ae())&&(n._allDrawers=r)}},viewQuery:function(i,n){if(i&1&&Ge(SG,5),i&2){let o;$A(o=Ae())&&(n._userContent=o.first)}},hostAttrs:[1,"mat-drawer-container"],hostVars:2,hostBindings:function(i,n){i&2&&ue("mat-drawer-container-explicit-backdrop",n._backdropOverride)},inputs:{autosize:"autosize",hasBackdrop:"hasBackdrop"},outputs:{backdropClick:"backdropClick"},exportAs:["matDrawerContainer"],features:[ct([{provide:lcA,useExisting:t}])],ngContentSelectors:cHA,decls:4,vars:2,consts:[[1,"mat-drawer-backdrop",3,"mat-drawer-shown"],[1,"mat-drawer-backdrop",3,"click"]],template:function(i,n){i&1&&(Yt(aHA),NA(0,lHA,1,2,"div",0),xe(1),xe(2,1),NA(3,gHA,2,0,"mat-drawer-content")),i&2&&(FA(n.hasBackdrop?0:-1),_(3),FA(n._content?-1:3))},dependencies:[SG],styles:[".mat-drawer-container{position:relative;z-index:1;color:var(--mat-sidenav-content-text-color, var(--mat-sys-on-background));background-color:var(--mat-sidenav-content-background-color, var(--mat-sys-background));box-sizing:border-box;display:block;overflow:hidden}.mat-drawer-container[fullscreen]{top:0;left:0;right:0;bottom:0;position:absolute}.mat-drawer-container[fullscreen].mat-drawer-container-has-open{overflow:hidden}.mat-drawer-container.mat-drawer-container-explicit-backdrop .mat-drawer-side{z-index:3}.mat-drawer-container.ng-animate-disabled .mat-drawer-backdrop,.mat-drawer-container.ng-animate-disabled .mat-drawer-content,.ng-animate-disabled .mat-drawer-container .mat-drawer-backdrop,.ng-animate-disabled .mat-drawer-container .mat-drawer-content{transition:none}.mat-drawer-backdrop{top:0;left:0;right:0;bottom:0;position:absolute;display:block;z-index:3;visibility:hidden}.mat-drawer-backdrop.mat-drawer-shown{visibility:visible;background-color:var(--mat-sidenav-scrim-color, color-mix(in srgb, var(--mat-sys-neutral-variant20) 40%, transparent))}.mat-drawer-transition .mat-drawer-backdrop{transition-duration:400ms;transition-timing-function:cubic-bezier(0.25, 0.8, 0.25, 1);transition-property:background-color,visibility}@media(forced-colors: active){.mat-drawer-backdrop{opacity:.5}}.mat-drawer-content{position:relative;z-index:1;display:block;height:100%;overflow:auto}.mat-drawer-content.mat-drawer-content-hidden{opacity:0}.mat-drawer-transition .mat-drawer-content{transition-duration:400ms;transition-timing-function:cubic-bezier(0.25, 0.8, 0.25, 1);transition-property:transform,margin-left,margin-right}.mat-drawer{position:relative;z-index:4;color:var(--mat-sidenav-container-text-color, var(--mat-sys-on-surface-variant));box-shadow:var(--mat-sidenav-container-elevation-shadow, none);background-color:var(--mat-sidenav-container-background-color, var(--mat-sys-surface));border-top-right-radius:var(--mat-sidenav-container-shape, var(--mat-sys-corner-large));border-bottom-right-radius:var(--mat-sidenav-container-shape, var(--mat-sys-corner-large));width:var(--mat-sidenav-container-width, 360px);display:block;position:absolute;top:0;bottom:0;z-index:3;outline:0;box-sizing:border-box;overflow-y:auto;transform:translate3d(-100%, 0, 0)}@media(forced-colors: active){.mat-drawer,[dir=rtl] .mat-drawer.mat-drawer-end{border-right:solid 1px currentColor}}@media(forced-colors: active){[dir=rtl] .mat-drawer,.mat-drawer.mat-drawer-end{border-left:solid 1px currentColor;border-right:none}}.mat-drawer.mat-drawer-side{z-index:2}.mat-drawer.mat-drawer-end{right:0;transform:translate3d(100%, 0, 0);border-top-left-radius:var(--mat-sidenav-container-shape, var(--mat-sys-corner-large));border-bottom-left-radius:var(--mat-sidenav-container-shape, var(--mat-sys-corner-large));border-top-right-radius:0;border-bottom-right-radius:0}[dir=rtl] .mat-drawer{border-top-left-radius:var(--mat-sidenav-container-shape, var(--mat-sys-corner-large));border-bottom-left-radius:var(--mat-sidenav-container-shape, var(--mat-sys-corner-large));border-top-right-radius:0;border-bottom-right-radius:0;transform:translate3d(100%, 0, 0)}[dir=rtl] .mat-drawer.mat-drawer-end{border-top-right-radius:var(--mat-sidenav-container-shape, var(--mat-sys-corner-large));border-bottom-right-radius:var(--mat-sidenav-container-shape, var(--mat-sys-corner-large));border-top-left-radius:0;border-bottom-left-radius:0;left:0;right:auto;transform:translate3d(-100%, 0, 0)}.mat-drawer-transition .mat-drawer{transition:transform 400ms cubic-bezier(0.25, 0.8, 0.25, 1)}.mat-drawer:not(.mat-drawer-opened):not(.mat-drawer-animating){visibility:hidden;box-shadow:none}.mat-drawer:not(.mat-drawer-opened):not(.mat-drawer-animating) .mat-drawer-inner-container{display:none}.mat-drawer.mat-drawer-opened.mat-drawer-opened{transform:none}.mat-drawer-side{box-shadow:none;border-right-color:var(--mat-sidenav-container-divider-color, transparent);border-right-width:1px;border-right-style:solid}.mat-drawer-side.mat-drawer-end{border-left-color:var(--mat-sidenav-container-divider-color, transparent);border-left-width:1px;border-left-style:solid;border-right:none}[dir=rtl] .mat-drawer-side{border-left-color:var(--mat-sidenav-container-divider-color, transparent);border-left-width:1px;border-left-style:solid;border-right:none}[dir=rtl] .mat-drawer-side.mat-drawer-end{border-right-color:var(--mat-sidenav-container-divider-color, transparent);border-right-width:1px;border-right-style:solid;border-left:none}.mat-drawer-inner-container{width:100%;height:100%;overflow:auto}.mat-sidenav-fixed{position:fixed}"],encapsulation:2,changeDetection:0})}return t})();var gcA=(()=>{class t{static \u0275fac=function(i){return new(i||t)};static \u0275mod=ge({type:t});static \u0275inj=le({imports:[Ve,E0,E0,Ve]})}return t})();var _G=["*"];function BHA(t,e){t&1&&xe(0)}var EHA=["tabListContainer"],hHA=["tabList"],QHA=["tabListInner"],uHA=["nextPaginator"],fHA=["previousPaginator"],mHA=t=>({animationDuration:t}),pHA=(t,e)=>({value:t,params:e});function wHA(t,e){}var DHA=["tabBodyWrapper"],yHA=["tabHeader"];function vHA(t,e){}function bHA(t,e){if(t&1&&NA(0,vHA,0,0,"ng-template",12),t&2){let A=P().$implicit;vA("cdkPortalOutlet",A.templateLabel)}}function MHA(t,e){if(t&1&&tA(0),t&2){let A=P().$implicit;Mt(A.textLabel)}}function kHA(t,e){if(t&1){let A=De();S(0,"div",7,2),mA("click",function(){let n=LA(A),o=n.$implicit,r=n.$index,s=P(),a=or(1);return xA(s._handleClick(o,a,r))})("cdkFocusChange",function(n){let o=LA(A).$index,r=P();return xA(r._tabFocusChanged(n,o))}),UA(2,"span",8)(3,"div",9),S(4,"span",10)(5,"span",11),NA(6,bHA,1,1,null,12)(7,MHA,1,1),R()()()}if(t&2){let A=e.$implicit,i=e.$index,n=or(1),o=P();vo(A.labelClass),ue("mdc-tab--active",o.selectedIndex===i),vA("id",o._getTabLabelId(i))("disabled",A.disabled)("fitInkBarToContent",o.fitInkBarToContent),_e("tabIndex",o._getTabIndex(i))("aria-posinset",i+1)("aria-setsize",o._tabs.length)("aria-controls",o._getTabContentId(i))("aria-selected",o.selectedIndex===i)("aria-label",A.ariaLabel||null)("aria-labelledby",!A.ariaLabel&&A.ariaLabelledby?A.ariaLabelledby:null),_(3),vA("matRippleTrigger",n)("matRippleDisabled",A.disabled||o.disableRipple),_(3),FA(A.templateLabel?6:7)}}function SHA(t,e){t&1&&xe(0)}function RHA(t,e){if(t&1){let A=De();S(0,"mat-tab-body",13),mA("_onCentered",function(){LA(A);let n=P();return xA(n._removeTabBodyWrapperHeight())})("_onCentering",function(n){LA(A);let o=P();return xA(o._setTabBodyWrapperHeight(n))}),R()}if(t&2){let A=e.$implicit,i=e.$index,n=P();vo(A.bodyClass),ue("mat-mdc-tab-body-active",n.selectedIndex===i),vA("id",n._getTabContentId(i))("content",A.content)("position",A.position)("origin",A.origin)("animationDuration",n.animationDuration)("preserveContent",n.preserveContent),_e("tabindex",n.contentTabIndex!=null&&n.selectedIndex===i?n.contentTabIndex:null)("aria-labelledby",n._getTabLabelId(i))("aria-hidden",n.selectedIndex!==i)}}var LHA=new BA("MatTabContent"),xHA=(()=>{class t{template=m(vn);constructor(){}static \u0275fac=function(i){return new(i||t)};static \u0275dir=OA({type:t,selectors:[["","matTabContent",""]],features:[ct([{provide:LHA,useExisting:t}])]})}return t})(),FHA=new BA("MatTabLabel"),dcA=new BA("MAT_TAB"),GG=(()=>{class t extends OO{_closestTab=m(dcA,{optional:!0});static \u0275fac=(()=>{let A;return function(n){return(A||(A=bi(t)))(n||t)}})();static \u0275dir=OA({type:t,selectors:[["","mat-tab-label",""],["","matTabLabel",""]],features:[ct([{provide:FHA,useExisting:t}]),et]})}return t})(),BcA=new BA("MAT_TAB_GROUP"),af=(()=>{class t{_viewContainerRef=m(Un);_closestTabGroup=m(BcA,{optional:!0});disabled=!1;get templateLabel(){return this._templateLabel}set templateLabel(A){this._setTemplateLabelInput(A)}_templateLabel;_explicitContent=void 0;_implicitContent;textLabel="";ariaLabel;ariaLabelledby;labelClass;bodyClass;_contentPortal=null;get content(){return this._contentPortal}_stateChanges=new HA;position=null;origin=null;isActive=!1;constructor(){m(Ln).load(Qr)}ngOnChanges(A){(A.hasOwnProperty("textLabel")||A.hasOwnProperty("disabled"))&&this._stateChanges.next()}ngOnDestroy(){this._stateChanges.complete()}ngOnInit(){this._contentPortal=new aa(this._explicitContent||this._implicitContent,this._viewContainerRef)}_setTemplateLabelInput(A){A&&A._closestTab===this&&(this._templateLabel=A)}static \u0275fac=function(i){return new(i||t)};static \u0275cmp=YA({type:t,selectors:[["mat-tab"]],contentQueries:function(i,n,o){if(i&1&&(Ii(o,GG,5),Ii(o,xHA,7,vn)),i&2){let r;$A(r=Ae())&&(n.templateLabel=r.first),$A(r=Ae())&&(n._explicitContent=r.first)}},viewQuery:function(i,n){if(i&1&&Ge(vn,7),i&2){let o;$A(o=Ae())&&(n._implicitContent=o.first)}},hostAttrs:["hidden",""],inputs:{disabled:[2,"disabled","disabled",ae],textLabel:[0,"label","textLabel"],ariaLabel:[0,"aria-label","ariaLabel"],ariaLabelledby:[0,"aria-labelledby","ariaLabelledby"],labelClass:"labelClass",bodyClass:"bodyClass"},exportAs:["matTab"],features:[ct([{provide:dcA,useExisting:t}]),Kt],ngContentSelectors:_G,decls:1,vars:0,template:function(i,n){i&1&&(Yt(),NA(0,BHA,1,0,"ng-template"))},encapsulation:2})}return t})(),xG="mdc-tab-indicator--active",IcA="mdc-tab-indicator--no-transition",FG=class{_items;_currentItem;constructor(e){this._items=e}hide(){this._items.forEach(e=>e.deactivateInkBar()),this._currentItem=void 0}alignToElement(e){let A=this._items.find(n=>n.elementRef.nativeElement===e),i=this._currentItem;if(A!==i&&(i?.deactivateInkBar(),A)){let n=i?.elementRef.nativeElement.getBoundingClientRect?.();A.activateInkBar(n),this._currentItem=A}}},NHA=(()=>{class t{_elementRef=m(te);_inkBarElement;_inkBarContentElement;_fitToContent=!1;get fitInkBarToContent(){return this._fitToContent}set fitInkBarToContent(A){this._fitToContent!==A&&(this._fitToContent=A,this._inkBarElement&&this._appendInkBarElement())}activateInkBar(A){let i=this._elementRef.nativeElement;if(!A||!i.getBoundingClientRect||!this._inkBarContentElement){i.classList.add(xG);return}let n=i.getBoundingClientRect(),o=A.width/n.width,r=A.left-n.left;i.classList.add(IcA),this._inkBarContentElement.style.setProperty("transform",`translateX(${r}px) scaleX(${o})`),i.getBoundingClientRect(),i.classList.remove(IcA),i.classList.add(xG),this._inkBarContentElement.style.setProperty("transform","")}deactivateInkBar(){this._elementRef.nativeElement.classList.remove(xG)}ngOnInit(){this._createInkBarElement()}ngOnDestroy(){this._inkBarElement?.remove(),this._inkBarElement=this._inkBarContentElement=null}_createInkBarElement(){let A=this._elementRef.nativeElement.ownerDocument||document,i=this._inkBarElement=A.createElement("span"),n=this._inkBarContentElement=A.createElement("span");i.className="mdc-tab-indicator",n.className="mdc-tab-indicator__content mdc-tab-indicator__content--underline",i.appendChild(this._inkBarContentElement),this._appendInkBarElement()}_appendInkBarElement(){this._inkBarElement;let A=this._fitToContent?this._elementRef.nativeElement.querySelector(".mdc-tab__content"):this._elementRef.nativeElement;A.appendChild(this._inkBarElement)}static \u0275fac=function(i){return new(i||t)};static \u0275dir=OA({type:t,inputs:{fitInkBarToContent:[2,"fitInkBarToContent","fitInkBarToContent",ae]}})}return t})();var EcA=(()=>{class t extends NHA{elementRef=m(te);disabled=!1;focus(){this.elementRef.nativeElement.focus()}getOffsetLeft(){return this.elementRef.nativeElement.offsetLeft}getOffsetWidth(){return this.elementRef.nativeElement.offsetWidth}static \u0275fac=(()=>{let A;return function(n){return(A||(A=bi(t)))(n||t)}})();static \u0275dir=OA({type:t,selectors:[["","matTabLabelWrapper",""]],hostVars:3,hostBindings:function(i,n){i&2&&(_e("aria-disabled",!!n.disabled),ue("mat-mdc-tab-disabled",n.disabled))},inputs:{disabled:[2,"disabled","disabled",ae]},features:[et]})}return t})(),CcA={passive:!0},_HA=650,GHA=100,UHA=(()=>{class t{_elementRef=m(te);_changeDetectorRef=m(lt);_viewportRuler=m(mc);_dir=m(bo,{optional:!0});_ngZone=m(de);_platform=m(Zt);_sharedResizeObserver=m(n8);_injector=m(Dt);_renderer=m(Gi);_animationMode=m(mi,{optional:!0});_eventCleanups;_scrollDistance=0;_selectedIndexChanged=!1;_destroyed=new HA;_showPaginationControls=!1;_disableScrollAfter=!0;_disableScrollBefore=!0;_tabLabelCount;_scrollDistanceChanged;_keyManager;_currentTextContent;_stopScrolling=new HA;disablePagination=!1;get selectedIndex(){return this._selectedIndex}set selectedIndex(A){let i=isNaN(A)?0:A;this._selectedIndex!=i&&(this._selectedIndexChanged=!0,this._selectedIndex=i,this._keyManager&&this._keyManager.updateActiveItem(i))}_selectedIndex=0;selectFocusedIndex=new XA;indexFocused=new XA;constructor(){this._eventCleanups=this._ngZone.runOutsideAngular(()=>[this._renderer.listen(this._elementRef.nativeElement,"mouseleave",()=>this._stopInterval())])}ngAfterViewInit(){this._eventCleanups.push(HM(this._renderer,this._previousPaginator.nativeElement,"touchstart",()=>this._handlePaginatorPress("before"),CcA),HM(this._renderer,this._nextPaginator.nativeElement,"touchstart",()=>this._handlePaginatorPress("after"),CcA))}ngAfterContentInit(){let A=this._dir?this._dir.change:ve("ltr"),i=this._sharedResizeObserver.observe(this._elementRef.nativeElement).pipe(Vc(32),wt(this._destroyed)),n=this._viewportRuler.change(150).pipe(wt(this._destroyed)),o=()=>{this.updatePagination(),this._alignInkBarToSelectedTab()};this._keyManager=new du(this._items).withHorizontalOrientation(this._getLayoutDirection()).withHomeAndEnd().withWrap().skipPredicate(()=>!1),this._keyManager.updateActiveItem(this._selectedIndex),Vo(o,{injector:this._injector}),ho(A,n,i,this._items.changes,this._itemsResized()).pipe(wt(this._destroyed)).subscribe(()=>{this._ngZone.run(()=>{Promise.resolve().then(()=>{this._scrollDistance=Math.max(0,Math.min(this._getMaxScrollDistance(),this._scrollDistance)),o()})}),this._keyManager.withHorizontalOrientation(this._getLayoutDirection())}),this._keyManager.change.subscribe(r=>{this.indexFocused.emit(r),this._setTabFocus(r)})}_itemsResized(){return typeof ResizeObserver!="function"?Ar:this._items.changes.pipe(Qo(this._items),no(A=>new Ze(i=>this._ngZone.runOutsideAngular(()=>{let n=new ResizeObserver(o=>i.next(o));return A.forEach(o=>n.observe(o.elementRef.nativeElement)),()=>{n.disconnect()}}))),eI(1),pt(A=>A.some(i=>i.contentRect.width>0&&i.contentRect.height>0)))}ngAfterContentChecked(){this._tabLabelCount!=this._items.length&&(this.updatePagination(),this._tabLabelCount=this._items.length,this._changeDetectorRef.markForCheck()),this._selectedIndexChanged&&(this._scrollToLabel(this._selectedIndex),this._checkScrollingControls(),this._alignInkBarToSelectedTab(),this._selectedIndexChanged=!1,this._changeDetectorRef.markForCheck()),this._scrollDistanceChanged&&(this._updateTabScrollPosition(),this._scrollDistanceChanged=!1,this._changeDetectorRef.markForCheck())}ngOnDestroy(){this._eventCleanups.forEach(A=>A()),this._keyManager?.destroy(),this._destroyed.next(),this._destroyed.complete(),this._stopScrolling.complete()}_handleKeydown(A){if(!rr(A))switch(A.keyCode){case 13:case 32:if(this.focusIndex!==this.selectedIndex){let i=this._items.get(this.focusIndex);i&&!i.disabled&&(this.selectFocusedIndex.emit(this.focusIndex),this._itemSelected(A))}break;default:this._keyManager.onKeydown(A)}}_onContentChanges(){let A=this._elementRef.nativeElement.textContent;A!==this._currentTextContent&&(this._currentTextContent=A||"",this._ngZone.run(()=>{this.updatePagination(),this._alignInkBarToSelectedTab(),this._changeDetectorRef.markForCheck()}))}updatePagination(){this._checkPaginationEnabled(),this._checkScrollingControls(),this._updateTabScrollPosition()}get focusIndex(){return this._keyManager?this._keyManager.activeItemIndex:0}set focusIndex(A){!this._isValidIndex(A)||this.focusIndex===A||!this._keyManager||this._keyManager.setActiveItem(A)}_isValidIndex(A){return this._items?!!this._items.toArray()[A]:!0}_setTabFocus(A){if(this._showPaginationControls&&this._scrollToLabel(A),this._items&&this._items.length){this._items.toArray()[A].focus();let i=this._tabListContainer.nativeElement;this._getLayoutDirection()=="ltr"?i.scrollLeft=0:i.scrollLeft=i.scrollWidth-i.offsetWidth}}_getLayoutDirection(){return this._dir&&this._dir.value==="rtl"?"rtl":"ltr"}_updateTabScrollPosition(){if(this.disablePagination)return;let A=this.scrollDistance,i=this._getLayoutDirection()==="ltr"?-A:A;this._tabList.nativeElement.style.transform=`translateX(${Math.round(i)}px)`,(this._platform.TRIDENT||this._platform.EDGE)&&(this._tabListContainer.nativeElement.scrollLeft=0)}get scrollDistance(){return this._scrollDistance}set scrollDistance(A){this._scrollTo(A)}_scrollHeader(A){let i=this._tabListContainer.nativeElement.offsetWidth,n=(A=="before"?-1:1)*i/3;return this._scrollTo(this._scrollDistance+n)}_handlePaginatorClick(A){this._stopInterval(),this._scrollHeader(A)}_scrollToLabel(A){if(this.disablePagination)return;let i=this._items?this._items.toArray()[A]:null;if(!i)return;let n=this._tabListContainer.nativeElement.offsetWidth,{offsetLeft:o,offsetWidth:r}=i.elementRef.nativeElement,s,a;this._getLayoutDirection()=="ltr"?(s=o,a=s+r):(a=this._tabListInner.nativeElement.offsetWidth-o,s=a-r);let c=this.scrollDistance,l=this.scrollDistance+n;s<c?this.scrollDistance-=c-s:a>l&&(this.scrollDistance+=Math.min(a-l,s-c))}_checkPaginationEnabled(){if(this.disablePagination)this._showPaginationControls=!1;else{let A=this._tabListInner.nativeElement.scrollWidth,i=this._elementRef.nativeElement.offsetWidth,n=A-i>=5;n||(this.scrollDistance=0),n!==this._showPaginationControls&&(this._showPaginationControls=n,this._changeDetectorRef.markForCheck())}}_checkScrollingControls(){this.disablePagination?this._disableScrollAfter=this._disableScrollBefore=!0:(this._disableScrollBefore=this.scrollDistance==0,this._disableScrollAfter=this.scrollDistance==this._getMaxScrollDistance(),this._changeDetectorRef.markForCheck())}_getMaxScrollDistance(){let A=this._tabListInner.nativeElement.scrollWidth,i=this._tabListContainer.nativeElement.offsetWidth;return A-i||0}_alignInkBarToSelectedTab(){let A=this._items&&this._items.length?this._items.toArray()[this.selectedIndex]:null,i=A?A.elementRef.nativeElement:null;i?this._inkBar.alignToElement(i):this._inkBar.hide()}_stopInterval(){this._stopScrolling.next()}_handlePaginatorPress(A,i){i&&i.button!=null&&i.button!==0||(this._stopInterval(),AI(_HA,GHA).pipe(wt(ho(this._stopScrolling,this._destroyed))).subscribe(()=>{let{maxScrollDistance:n,distance:o}=this._scrollHeader(A);(o===0||o>=n)&&this._stopInterval()}))}_scrollTo(A){if(this.disablePagination)return{maxScrollDistance:0,distance:0};let i=this._getMaxScrollDistance();return this._scrollDistance=Math.max(0,Math.min(i,A)),this._scrollDistanceChanged=!0,this._checkScrollingControls(),{maxScrollDistance:i,distance:this._scrollDistance}}static \u0275fac=function(i){return new(i||t)};static \u0275dir=OA({type:t,inputs:{disablePagination:[2,"disablePagination","disablePagination",ae],selectedIndex:[2,"selectedIndex","selectedIndex",Mi]},outputs:{selectFocusedIndex:"selectFocusedIndex",indexFocused:"indexFocused"}})}return t})(),KHA=(()=>{class t extends UHA{_items;_tabListContainer;_tabList;_tabListInner;_nextPaginator;_previousPaginator;_inkBar;ariaLabel;ariaLabelledby;disableRipple=!1;ngAfterContentInit(){this._inkBar=new FG(this._items),super.ngAfterContentInit()}_itemSelected(A){A.preventDefault()}static \u0275fac=(()=>{let A;return function(n){return(A||(A=bi(t)))(n||t)}})();static \u0275cmp=YA({type:t,selectors:[["mat-tab-header"]],contentQueries:function(i,n,o){if(i&1&&Ii(o,EcA,4),i&2){let r;$A(r=Ae())&&(n._items=r)}},viewQuery:function(i,n){if(i&1&&(Ge(EHA,7),Ge(hHA,7),Ge(QHA,7),Ge(uHA,5),Ge(fHA,5)),i&2){let o;$A(o=Ae())&&(n._tabListContainer=o.first),$A(o=Ae())&&(n._tabList=o.first),$A(o=Ae())&&(n._tabListInner=o.first),$A(o=Ae())&&(n._nextPaginator=o.first),$A(o=Ae())&&(n._previousPaginator=o.first)}},hostAttrs:[1,"mat-mdc-tab-header"],hostVars:4,hostBindings:function(i,n){i&2&&ue("mat-mdc-tab-header-pagination-controls-enabled",n._showPaginationControls)("mat-mdc-tab-header-rtl",n._getLayoutDirection()=="rtl")},inputs:{ariaLabel:[0,"aria-label","ariaLabel"],ariaLabelledby:[0,"aria-labelledby","ariaLabelledby"],disableRipple:[2,"disableRipple","disableRipple",ae]},features:[et],ngContentSelectors:_G,decls:13,vars:10,consts:[["previousPaginator",""],["tabListContainer",""],["tabList",""],["tabListInner",""],["nextPaginator",""],["mat-ripple","",1,"mat-mdc-tab-header-pagination","mat-mdc-tab-header-pagination-before",3,"click","mousedown","touchend","matRippleDisabled"],[1,"mat-mdc-tab-header-pagination-chevron"],[1,"mat-mdc-tab-label-container",3,"keydown"],["role","tablist",1,"mat-mdc-tab-list",3,"cdkObserveContent"],[1,"mat-mdc-tab-labels"],["mat-ripple","",1,"mat-mdc-tab-header-pagination","mat-mdc-tab-header-pagination-after",3,"mousedown","click","touchend","matRippleDisabled"]],template:function(i,n){if(i&1){let o=De();Yt(),S(0,"div",5,0),mA("click",function(){return LA(o),xA(n._handlePaginatorClick("before"))})("mousedown",function(s){return LA(o),xA(n._handlePaginatorPress("before",s))})("touchend",function(){return LA(o),xA(n._stopInterval())}),UA(2,"div",6),R(),S(3,"div",7,1),mA("keydown",function(s){return LA(o),xA(n._handleKeydown(s))}),S(5,"div",8,2),mA("cdkObserveContent",function(){return LA(o),xA(n._onContentChanges())}),S(7,"div",9,3),xe(9),R()()(),S(10,"div",10,4),mA("mousedown",function(s){return LA(o),xA(n._handlePaginatorPress("after",s))})("click",function(){return LA(o),xA(n._handlePaginatorClick("after"))})("touchend",function(){return LA(o),xA(n._stopInterval())}),UA(12,"div",6),R()}i&2&&(ue("mat-mdc-tab-header-pagination-disabled",n._disableScrollBefore),vA("matRippleDisabled",n._disableScrollBefore||n.disableRipple),_(3),ue("_mat-animation-noopable",n._animationMode==="NoopAnimations"),_(2),_e("aria-label",n.ariaLabel||null)("aria-labelledby",n.ariaLabelledby||null),_(5),ue("mat-mdc-tab-header-pagination-disabled",n._disableScrollAfter),vA("matRippleDisabled",n._disableScrollAfter||n.disableRipple))},dependencies:[Gs,N6],styles:[".mat-mdc-tab-header{display:flex;overflow:hidden;position:relative;flex-shrink:0}.mdc-tab-indicator .mdc-tab-indicator__content{transition-duration:var(--mat-tab-animation-duration, 250ms)}.mat-mdc-tab-header-pagination{-webkit-user-select:none;user-select:none;position:relative;display:none;justify-content:center;align-items:center;min-width:32px;cursor:pointer;z-index:2;-webkit-tap-highlight-color:rgba(0,0,0,0);touch-action:none;box-sizing:content-box;outline:0}.mat-mdc-tab-header-pagination::-moz-focus-inner{border:0}.mat-mdc-tab-header-pagination .mat-ripple-element{opacity:.12;background-color:var(--mat-tab-header-inactive-ripple-color, var(--mat-sys-on-surface))}.mat-mdc-tab-header-pagination-controls-enabled .mat-mdc-tab-header-pagination{display:flex}.mat-mdc-tab-header-pagination-before,.mat-mdc-tab-header-rtl .mat-mdc-tab-header-pagination-after{padding-left:4px}.mat-mdc-tab-header-pagination-before .mat-mdc-tab-header-pagination-chevron,.mat-mdc-tab-header-rtl .mat-mdc-tab-header-pagination-after .mat-mdc-tab-header-pagination-chevron{transform:rotate(-135deg)}.mat-mdc-tab-header-rtl .mat-mdc-tab-header-pagination-before,.mat-mdc-tab-header-pagination-after{padding-right:4px}.mat-mdc-tab-header-rtl .mat-mdc-tab-header-pagination-before .mat-mdc-tab-header-pagination-chevron,.mat-mdc-tab-header-pagination-after .mat-mdc-tab-header-pagination-chevron{transform:rotate(45deg)}.mat-mdc-tab-header-pagination-chevron{border-style:solid;border-width:2px 2px 0 0;height:8px;width:8px;border-color:var(--mat-tab-header-pagination-icon-color, var(--mat-sys-on-surface))}.mat-mdc-tab-header-pagination-disabled{box-shadow:none;cursor:default;pointer-events:none}.mat-mdc-tab-header-pagination-disabled .mat-mdc-tab-header-pagination-chevron{opacity:.4}.mat-mdc-tab-list{flex-grow:1;position:relative;transition:transform 500ms cubic-bezier(0.35, 0, 0.25, 1)}._mat-animation-noopable .mat-mdc-tab-list{transition:none}.mat-mdc-tab-label-container{display:flex;flex-grow:1;overflow:hidden;z-index:1;border-bottom-style:solid;border-bottom-width:var(--mat-tab-header-divider-height, 1px);border-bottom-color:var(--mat-tab-header-divider-color, var(--mat-sys-surface-variant))}.mat-mdc-tab-group-inverted-header .mat-mdc-tab-label-container{border-bottom:none;border-top-style:solid;border-top-width:var(--mat-tab-header-divider-height, 1px);border-top-color:var(--mat-tab-header-divider-color, var(--mat-sys-surface-variant))}.mat-mdc-tab-labels{display:flex;flex:1 0 auto}[mat-align-tabs=center]>.mat-mdc-tab-header .mat-mdc-tab-labels{justify-content:center}[mat-align-tabs=end]>.mat-mdc-tab-header .mat-mdc-tab-labels{justify-content:flex-end}.cdk-drop-list .mat-mdc-tab-labels,.mat-mdc-tab-labels.cdk-drop-list{min-height:var(--mdc-secondary-navigation-tab-container-height, 48px)}.mat-mdc-tab::before{margin:5px}@media(forced-colors: active){.mat-mdc-tab[aria-disabled=true]{color:GrayText}}"],encapsulation:2})}return t})(),YHA=new BA("MAT_TABS_CONFIG"),JHA={translateTab:cg("translateTab",[wc("center, void, left-origin-center, right-origin-center",ar({transform:"none",visibility:"visible"})),wc("left",ar({transform:"translate3d(-100%, 0, 0)",minHeight:"1px",visibility:"hidden"})),wc("right",ar({transform:"translate3d(100%, 0, 0)",minHeight:"1px",visibility:"hidden"})),la("* => left, * => right, left => center, right => center",$a("{{animationDuration}} cubic-bezier(0.35, 0, 0.25, 1)")),la("void => left-origin-center",[ar({transform:"translate3d(-100%, 0, 0)",visibility:"hidden"}),$a("{{animationDuration}} cubic-bezier(0.35, 0, 0.25, 1)")]),la("void => right-origin-center",[ar({transform:"translate3d(100%, 0, 0)",visibility:"hidden"}),$a("{{animationDuration}} cubic-bezier(0.35, 0, 0.25, 1)")])])},THA=(()=>{class t extends ca{_host=m(hcA);_centeringSub=_t.EMPTY;_leavingSub=_t.EMPTY;constructor(){super()}ngOnInit(){super.ngOnInit(),this._centeringSub=this._host._beforeCentering.pipe(Qo(this._host._isCenterPosition(this._host._position))).subscribe(A=>{this._host._content&&A&&!this.hasAttached()&&this.attach(this._host._content)}),this._leavingSub=this._host._afterLeavingCenter.subscribe(()=>{this._host.preserveContent||this.detach()})}ngOnDestroy(){super.ngOnDestroy(),this._centeringSub.unsubscribe(),this._leavingSub.unsubscribe()}static \u0275fac=function(i){return new(i||t)};static \u0275dir=OA({type:t,selectors:[["","matTabBodyHost",""]],features:[et]})}return t})(),hcA=(()=>{class t{_elementRef=m(te);_dir=m(bo,{optional:!0});_positionIndex;_dirChangeSubscription=_t.EMPTY;_position;_translateTabComplete=new HA;_onCentering=new XA;_beforeCentering=new XA;_afterLeavingCenter=new XA;_onCentered=new XA(!0);_portalHost;_content;origin;animationDuration="500ms";preserveContent=!1;set position(A){this._positionIndex=A,this._computePositionAnimationState()}constructor(){if(this._dir){let A=m(lt);this._dirChangeSubscription=this._dir.change.subscribe(i=>{this._computePositionAnimationState(i),A.markForCheck()})}this._translateTabComplete.subscribe(A=>{this._isCenterPosition(A.toState)&&this._isCenterPosition(this._position)&&this._onCentered.emit(),this._isCenterPosition(A.fromState)&&!this._isCenterPosition(this._position)&&this._afterLeavingCenter.emit()})}ngOnInit(){this._position=="center"&&this.origin!=null&&(this._position=this._computePositionFromOrigin(this.origin))}ngOnDestroy(){this._dirChangeSubscription.unsubscribe(),this._translateTabComplete.complete()}_onTranslateTabStarted(A){let i=this._isCenterPosition(A.toState);this._beforeCentering.emit(i),i&&this._onCentering.emit(this._elementRef.nativeElement.clientHeight)}_getLayoutDirection(){return this._dir&&this._dir.value==="rtl"?"rtl":"ltr"}_isCenterPosition(A){return A=="center"||A=="left-origin-center"||A=="right-origin-center"}_computePositionAnimationState(A=this._getLayoutDirection()){this._positionIndex<0?this._position=A=="ltr"?"left":"right":this._positionIndex>0?this._position=A=="ltr"?"right":"left":this._position="center"}_computePositionFromOrigin(A){let i=this._getLayoutDirection();return i=="ltr"&&A<=0||i=="rtl"&&A>0?"left-origin-center":"right-origin-center"}static \u0275fac=function(i){return new(i||t)};static \u0275cmp=YA({type:t,selectors:[["mat-tab-body"]],viewQuery:function(i,n){if(i&1&&Ge(ca,5),i&2){let o;$A(o=Ae())&&(n._portalHost=o.first)}},hostAttrs:[1,"mat-mdc-tab-body"],inputs:{_content:[0,"content","_content"],origin:"origin",animationDuration:"animationDuration",preserveContent:"preserveContent",position:"position"},outputs:{_onCentering:"_onCentering",_beforeCentering:"_beforeCentering",_afterLeavingCenter:"_afterLeavingCenter",_onCentered:"_onCentered"},decls:3,vars:6,consts:[["content",""],["cdkScrollable","",1,"mat-mdc-tab-body-content"],["matTabBodyHost",""]],template:function(i,n){if(i&1){let o=De();S(0,"div",1,0),mA("@translateTab.start",function(s){return LA(o),xA(n._onTranslateTabStarted(s))})("@translateTab.done",function(s){return LA(o),xA(n._translateTabComplete.next(s))}),NA(2,wHA,0,0,"ng-template",2),R()}i&2&&vA("@translateTab",p2(3,pHA,n._position,Yr(1,mHA,n.animationDuration)))},dependencies:[THA,h0],styles:['.mat-mdc-tab-body{top:0;left:0;right:0;bottom:0;position:absolute;display:block;overflow:hidden;outline:0;flex-basis:100%}.mat-mdc-tab-body.mat-mdc-tab-body-active{position:relative;overflow-x:hidden;overflow-y:auto;z-index:1;flex-grow:1}.mat-mdc-tab-group.mat-mdc-tab-group-dynamic-height .mat-mdc-tab-body.mat-mdc-tab-body-active{overflow-y:hidden}.mat-mdc-tab-body-content{height:100%;overflow:auto}.mat-mdc-tab-group-dynamic-height .mat-mdc-tab-body-content{overflow:hidden}.mat-mdc-tab-body-content[style*="visibility: hidden"]{display:none}'],encapsulation:2,data:{animation:[JHA.translateTab]}})}return t})(),zHA=!0,Py=(()=>{class t{_elementRef=m(te);_changeDetectorRef=m(lt);_animationMode=m(mi,{optional:!0});_allTabs;_tabBodyWrapper;_tabHeader;_tabs=new Ec;_indexToSelect=0;_lastFocusedTabIndex=null;_tabBodyWrapperHeight=0;_tabsSubscription=_t.EMPTY;_tabLabelSubscription=_t.EMPTY;color;get fitInkBarToContent(){return this._fitInkBarToContent}set fitInkBarToContent(A){this._fitInkBarToContent=A,this._changeDetectorRef.markForCheck()}_fitInkBarToContent=!1;stretchTabs=!0;alignTabs=null;dynamicHeight=!1;get selectedIndex(){return this._selectedIndex}set selectedIndex(A){this._indexToSelect=isNaN(A)?null:A}_selectedIndex=null;headerPosition="above";get animationDuration(){return this._animationDuration}set animationDuration(A){let i=A+"";this._animationDuration=/^\d+$/.test(i)?A+"ms":i}_animationDuration;get contentTabIndex(){return this._contentTabIndex}set contentTabIndex(A){this._contentTabIndex=isNaN(A)?null:A}_contentTabIndex;disablePagination=!1;disableRipple=!1;preserveContent=!1;get backgroundColor(){return this._backgroundColor}set backgroundColor(A){if(!zHA)throw new Error("mat-tab-group background color must be set through the Sass theming API");let i=this._elementRef.nativeElement.classList;i.remove("mat-tabs-with-background",`mat-background-${this.backgroundColor}`),A&&i.add("mat-tabs-with-background",`mat-background-${A}`),this._backgroundColor=A}_backgroundColor;ariaLabel;ariaLabelledby;selectedIndexChange=new XA;focusChange=new XA;animationDone=new XA;selectedTabChange=new XA(!0);_groupId;_isServer=!m(Zt).isBrowser;constructor(){let A=m(YHA,{optional:!0});this._groupId=m($i).getId("mat-tab-group-"),this.animationDuration=A&&A.animationDuration?A.animationDuration:"500ms",this.disablePagination=A&&A.disablePagination!=null?A.disablePagination:!1,this.dynamicHeight=A&&A.dynamicHeight!=null?A.dynamicHeight:!1,A?.contentTabIndex!=null&&(this.contentTabIndex=A.contentTabIndex),this.preserveContent=!!A?.preserveContent,this.fitInkBarToContent=A&&A.fitInkBarToContent!=null?A.fitInkBarToContent:!1,this.stretchTabs=A&&A.stretchTabs!=null?A.stretchTabs:!0,this.alignTabs=A&&A.alignTabs!=null?A.alignTabs:null}ngAfterContentChecked(){let A=this._indexToSelect=this._clampTabIndex(this._indexToSelect);if(this._selectedIndex!=A){let i=this._selectedIndex==null;if(!i){this.selectedTabChange.emit(this._createChangeEvent(A));let n=this._tabBodyWrapper.nativeElement;n.style.minHeight=n.clientHeight+"px"}Promise.resolve().then(()=>{this._tabs.forEach((n,o)=>n.isActive=o===A),i||(this.selectedIndexChange.emit(A),this._tabBodyWrapper.nativeElement.style.minHeight="")})}this._tabs.forEach((i,n)=>{i.position=n-A,this._selectedIndex!=null&&i.position==0&&!i.origin&&(i.origin=A-this._selectedIndex)}),this._selectedIndex!==A&&(this._selectedIndex=A,this._lastFocusedTabIndex=null,this._changeDetectorRef.markForCheck())}ngAfterContentInit(){this._subscribeToAllTabChanges(),this._subscribeToTabLabels(),this._tabsSubscription=this._tabs.changes.subscribe(()=>{let A=this._clampTabIndex(this._indexToSelect);if(A===this._selectedIndex){let i=this._tabs.toArray(),n;for(let o=0;o<i.length;o++)if(i[o].isActive){this._indexToSelect=this._selectedIndex=o,this._lastFocusedTabIndex=null,n=i[o];break}!n&&i[A]&&Promise.resolve().then(()=>{i[A].isActive=!0,this.selectedTabChange.emit(this._createChangeEvent(A))})}this._changeDetectorRef.markForCheck()})}_subscribeToAllTabChanges(){this._allTabs.changes.pipe(Qo(this._allTabs)).subscribe(A=>{this._tabs.reset(A.filter(i=>i._closestTabGroup===this||!i._closestTabGroup)),this._tabs.notifyOnChanges()})}ngOnDestroy(){this._tabs.destroy(),this._tabsSubscription.unsubscribe(),this._tabLabelSubscription.unsubscribe()}realignInkBar(){this._tabHeader&&this._tabHeader._alignInkBarToSelectedTab()}updatePagination(){this._tabHeader&&this._tabHeader.updatePagination()}focusTab(A){let i=this._tabHeader;i&&(i.focusIndex=A)}_focusChanged(A){this._lastFocusedTabIndex=A,this.focusChange.emit(this._createChangeEvent(A))}_createChangeEvent(A){let i=new NG;return i.index=A,this._tabs&&this._tabs.length&&(i.tab=this._tabs.toArray()[A]),i}_subscribeToTabLabels(){this._tabLabelSubscription&&this._tabLabelSubscription.unsubscribe(),this._tabLabelSubscription=ho(...this._tabs.map(A=>A._stateChanges)).subscribe(()=>this._changeDetectorRef.markForCheck())}_clampTabIndex(A){return Math.min(this._tabs.length-1,Math.max(A||0,0))}_getTabLabelId(A){return`${this._groupId}-label-${A}`}_getTabContentId(A){return`${this._groupId}-content-${A}`}_setTabBodyWrapperHeight(A){if(!this.dynamicHeight||!this._tabBodyWrapperHeight)return;let i=this._tabBodyWrapper.nativeElement;i.style.height=this._tabBodyWrapperHeight+"px",this._tabBodyWrapper.nativeElement.offsetHeight&&(i.style.height=A+"px")}_removeTabBodyWrapperHeight(){let A=this._tabBodyWrapper.nativeElement;this._tabBodyWrapperHeight=A.clientHeight,A.style.height="",this.animationDone.emit()}_handleClick(A,i,n){i.focusIndex=n,A.disabled||(this.selectedIndex=n)}_getTabIndex(A){let i=this._lastFocusedTabIndex??this.selectedIndex;return A===i?0:-1}_tabFocusChanged(A,i){A&&A!=="mouse"&&A!=="touch"&&(this._tabHeader.focusIndex=i)}static \u0275fac=function(i){return new(i||t)};static \u0275cmp=YA({type:t,selectors:[["mat-tab-group"]],contentQueries:function(i,n,o){if(i&1&&Ii(o,af,5),i&2){let r;$A(r=Ae())&&(n._allTabs=r)}},viewQuery:function(i,n){if(i&1&&(Ge(DHA,5),Ge(yHA,5)),i&2){let o;$A(o=Ae())&&(n._tabBodyWrapper=o.first),$A(o=Ae())&&(n._tabHeader=o.first)}},hostAttrs:[1,"mat-mdc-tab-group"],hostVars:11,hostBindings:function(i,n){i&2&&(_e("mat-align-tabs",n.alignTabs),vo("mat-"+(n.color||"primary")),so("--mat-tab-animation-duration",n.animationDuration),ue("mat-mdc-tab-group-dynamic-height",n.dynamicHeight)("mat-mdc-tab-group-inverted-header",n.headerPosition==="below")("mat-mdc-tab-group-stretch-tabs",n.stretchTabs))},inputs:{color:"color",fitInkBarToContent:[2,"fitInkBarToContent","fitInkBarToContent",ae],stretchTabs:[2,"mat-stretch-tabs","stretchTabs",ae],alignTabs:[0,"mat-align-tabs","alignTabs"],dynamicHeight:[2,"dynamicHeight","dynamicHeight",ae],selectedIndex:[2,"selectedIndex","selectedIndex",Mi],headerPosition:"headerPosition",animationDuration:"animationDuration",contentTabIndex:[2,"contentTabIndex","contentTabIndex",Mi],disablePagination:[2,"disablePagination","disablePagination",ae],disableRipple:[2,"disableRipple","disableRipple",ae],preserveContent:[2,"preserveContent","preserveContent",ae],backgroundColor:"backgroundColor",ariaLabel:[0,"aria-label","ariaLabel"],ariaLabelledby:[0,"aria-labelledby","ariaLabelledby"]},outputs:{selectedIndexChange:"selectedIndexChange",focusChange:"focusChange",animationDone:"animationDone",selectedTabChange:"selectedTabChange"},exportAs:["matTabGroup"],features:[ct([{provide:BcA,useExisting:t}])],ngContentSelectors:_G,decls:9,vars:8,consts:[["tabHeader",""],["tabBodyWrapper",""],["tabNode",""],[3,"indexFocused","selectFocusedIndex","selectedIndex","disableRipple","disablePagination","aria-label","aria-labelledby"],["role","tab","matTabLabelWrapper","","cdkMonitorElementFocus","",1,"mdc-tab","mat-mdc-tab","mat-focus-indicator",3,"id","mdc-tab--active","class","disabled","fitInkBarToContent"],[1,"mat-mdc-tab-body-wrapper"],["role","tabpanel",3,"id","mat-mdc-tab-body-active","class","content","position","origin","animationDuration","preserveContent"],["role","tab","matTabLabelWrapper","","cdkMonitorElementFocus","",1,"mdc-tab","mat-mdc-tab","mat-focus-indicator",3,"click","cdkFocusChange","id","disabled","fitInkBarToContent"],[1,"mdc-tab__ripple"],["mat-ripple","",1,"mat-mdc-tab-ripple",3,"matRippleTrigger","matRippleDisabled"],[1,"mdc-tab__content"],[1,"mdc-tab__text-label"],[3,"cdkPortalOutlet"],["role","tabpanel",3,"_onCentered","_onCentering","id","content","position","origin","animationDuration","preserveContent"]],template:function(i,n){if(i&1){let o=De();Yt(),S(0,"mat-tab-header",3,0),mA("indexFocused",function(s){return LA(o),xA(n._focusChanged(s))})("selectFocusedIndex",function(s){return LA(o),xA(n.selectedIndex=s)}),ln(2,kHA,8,17,"div",4,Kn),R(),NA(4,SHA,1,0),S(5,"div",5,1),ln(7,RHA,1,13,"mat-tab-body",6,Kn),R()}i&2&&(vA("selectedIndex",n.selectedIndex||0)("disableRipple",n.disableRipple)("disablePagination",n.disablePagination)("aria-label",n.ariaLabel)("aria-labelledby",n.ariaLabelledby),_(2),gn(n._tabs),_(2),FA(n._isServer?4:-1),_(),ue("_mat-animation-noopable",n._animationMode==="NoopAnimations"),_(2),gn(n._tabs))},dependencies:[KHA,EcA,SO,Gs,ca,hcA],styles:['.mdc-tab{min-width:90px;padding:0 24px;display:flex;flex:1 0 auto;justify-content:center;box-sizing:border-box;border:none;outline:none;text-align:center;white-space:nowrap;cursor:pointer;z-index:1}.mdc-tab__content{display:flex;align-items:center;justify-content:center;height:inherit;pointer-events:none}.mdc-tab__text-label{transition:150ms color linear;display:inline-block;line-height:1;z-index:2}.mdc-tab--active .mdc-tab__text-label{transition-delay:100ms}._mat-animation-noopable .mdc-tab__text-label{transition:none}.mdc-tab-indicator{display:flex;position:absolute;top:0;left:0;justify-content:center;width:100%;height:100%;pointer-events:none;z-index:1}.mdc-tab-indicator__content{transition:var(--mat-tab-animation-duration, 250ms) transform cubic-bezier(0.4, 0, 0.2, 1);transform-origin:left;opacity:0}.mdc-tab-indicator__content--underline{align-self:flex-end;box-sizing:border-box;width:100%;border-top-style:solid}.mdc-tab-indicator--active .mdc-tab-indicator__content{opacity:1}._mat-animation-noopable .mdc-tab-indicator__content,.mdc-tab-indicator--no-transition .mdc-tab-indicator__content{transition:none}.mat-mdc-tab-ripple.mat-mdc-tab-ripple{position:absolute;top:0;left:0;bottom:0;right:0;pointer-events:none}.mat-mdc-tab{-webkit-tap-highlight-color:rgba(0,0,0,0);-webkit-font-smoothing:antialiased;-moz-osx-font-smoothing:grayscale;text-decoration:none;background:none;height:var(--mdc-secondary-navigation-tab-container-height, 48px);font-family:var(--mat-tab-header-label-text-font, var(--mat-sys-title-small-font));font-size:var(--mat-tab-header-label-text-size, var(--mat-sys-title-small-size));letter-spacing:var(--mat-tab-header-label-text-tracking, var(--mat-sys-title-small-tracking));line-height:var(--mat-tab-header-label-text-line-height, var(--mat-sys-title-small-line-height));font-weight:var(--mat-tab-header-label-text-weight, var(--mat-sys-title-small-weight))}.mat-mdc-tab.mdc-tab{flex-grow:0}.mat-mdc-tab .mdc-tab-indicator__content--underline{border-color:var(--mdc-tab-indicator-active-indicator-color, var(--mat-sys-primary));border-top-width:var(--mdc-tab-indicator-active-indicator-height, 2px);border-radius:var(--mdc-tab-indicator-active-indicator-shape, 0)}.mat-mdc-tab:hover .mdc-tab__text-label{color:var(--mat-tab-header-inactive-hover-label-text-color, var(--mat-sys-on-surface))}.mat-mdc-tab:focus .mdc-tab__text-label{color:var(--mat-tab-header-inactive-focus-label-text-color, var(--mat-sys-on-surface))}.mat-mdc-tab.mdc-tab--active .mdc-tab__text-label{color:var(--mat-tab-header-active-label-text-color, var(--mat-sys-on-surface))}.mat-mdc-tab.mdc-tab--active .mdc-tab__ripple::before,.mat-mdc-tab.mdc-tab--active .mat-ripple-element{background-color:var(--mat-tab-header-active-ripple-color, var(--mat-sys-on-surface))}.mat-mdc-tab.mdc-tab--active:hover .mdc-tab__text-label{color:var(--mat-tab-header-active-hover-label-text-color, var(--mat-sys-on-surface))}.mat-mdc-tab.mdc-tab--active:hover .mdc-tab-indicator__content--underline{border-color:var(--mat-tab-header-active-hover-indicator-color, var(--mat-sys-primary))}.mat-mdc-tab.mdc-tab--active:focus .mdc-tab__text-label{color:var(--mat-tab-header-active-focus-label-text-color, var(--mat-sys-on-surface))}.mat-mdc-tab.mdc-tab--active:focus .mdc-tab-indicator__content--underline{border-color:var(--mat-tab-header-active-focus-indicator-color, var(--mat-sys-primary))}.mat-mdc-tab.mat-mdc-tab-disabled{opacity:.4;pointer-events:none}.mat-mdc-tab.mat-mdc-tab-disabled .mdc-tab__content{pointer-events:none}.mat-mdc-tab.mat-mdc-tab-disabled .mdc-tab__ripple::before,.mat-mdc-tab.mat-mdc-tab-disabled .mat-ripple-element{background-color:var(--mat-tab-header-disabled-ripple-color)}.mat-mdc-tab .mdc-tab__ripple::before{content:"";display:block;position:absolute;top:0;left:0;right:0;bottom:0;opacity:0;pointer-events:none;background-color:var(--mat-tab-header-inactive-ripple-color, var(--mat-sys-on-surface))}.mat-mdc-tab .mdc-tab__text-label{color:var(--mat-tab-header-inactive-label-text-color, var(--mat-sys-on-surface));display:inline-flex;align-items:center}.mat-mdc-tab .mdc-tab__content{position:relative;pointer-events:auto}.mat-mdc-tab:hover .mdc-tab__ripple::before{opacity:.04}.mat-mdc-tab.cdk-program-focused .mdc-tab__ripple::before,.mat-mdc-tab.cdk-keyboard-focused .mdc-tab__ripple::before{opacity:.12}.mat-mdc-tab .mat-ripple-element{opacity:.12;background-color:var(--mat-tab-header-inactive-ripple-color, var(--mat-sys-on-surface))}.mat-mdc-tab-group.mat-mdc-tab-group-stretch-tabs>.mat-mdc-tab-header .mat-mdc-tab{flex-grow:1}.mat-mdc-tab-group{display:flex;flex-direction:column;max-width:100%}.mat-mdc-tab-group.mat-tabs-with-background>.mat-mdc-tab-header,.mat-mdc-tab-group.mat-tabs-with-background>.mat-mdc-tab-header-pagination{background-color:var(--mat-tab-header-with-background-background-color)}.mat-mdc-tab-group.mat-tabs-with-background.mat-primary>.mat-mdc-tab-header .mat-mdc-tab .mdc-tab__text-label{color:var(--mat-tab-header-with-background-foreground-color)}.mat-mdc-tab-group.mat-tabs-with-background.mat-primary>.mat-mdc-tab-header .mdc-tab-indicator__content--underline{border-color:var(--mat-tab-header-with-background-foreground-color)}.mat-mdc-tab-group.mat-tabs-with-background:not(.mat-primary)>.mat-mdc-tab-header .mat-mdc-tab:not(.mdc-tab--active) .mdc-tab__text-label{color:var(--mat-tab-header-with-background-foreground-color)}.mat-mdc-tab-group.mat-tabs-with-background:not(.mat-primary)>.mat-mdc-tab-header .mat-mdc-tab:not(.mdc-tab--active) .mdc-tab-indicator__content--underline{border-color:var(--mat-tab-header-with-background-foreground-color)}.mat-mdc-tab-group.mat-tabs-with-background>.mat-mdc-tab-header .mat-mdc-tab-header-pagination-chevron,.mat-mdc-tab-group.mat-tabs-with-background>.mat-mdc-tab-header .mat-focus-indicator::before,.mat-mdc-tab-group.mat-tabs-with-background>.mat-mdc-tab-header-pagination .mat-mdc-tab-header-pagination-chevron,.mat-mdc-tab-group.mat-tabs-with-background>.mat-mdc-tab-header-pagination .mat-focus-indicator::before{border-color:var(--mat-tab-header-with-background-foreground-color)}.mat-mdc-tab-group.mat-tabs-with-background>.mat-mdc-tab-header .mat-ripple-element,.mat-mdc-tab-group.mat-tabs-with-background>.mat-mdc-tab-header .mdc-tab__ripple::before,.mat-mdc-tab-group.mat-tabs-with-background>.mat-mdc-tab-header-pagination .mat-ripple-element,.mat-mdc-tab-group.mat-tabs-with-background>.mat-mdc-tab-header-pagination .mdc-tab__ripple::before{background-color:var(--mat-tab-header-with-background-foreground-color)}.mat-mdc-tab-group.mat-tabs-with-background>.mat-mdc-tab-header .mat-mdc-tab-header-pagination-chevron,.mat-mdc-tab-group.mat-tabs-with-background>.mat-mdc-tab-header-pagination .mat-mdc-tab-header-pagination-chevron{color:var(--mat-tab-header-with-background-foreground-color)}.mat-mdc-tab-group.mat-mdc-tab-group-inverted-header{flex-direction:column-reverse}.mat-mdc-tab-group.mat-mdc-tab-group-inverted-header .mdc-tab-indicator__content--underline{align-self:flex-start}.mat-mdc-tab-body-wrapper{position:relative;overflow:hidden;display:flex;transition:height 500ms cubic-bezier(0.35, 0, 0.25, 1)}.mat-mdc-tab-body-wrapper._mat-animation-noopable{transition:none !important;animation:none !important}'],encapsulation:2})}return t})(),NG=class{index;tab};var QcA=(()=>{class t{static \u0275fac=function(i){return new(i||t)};static \u0275mod=ge({type:t});static \u0275inj=le({imports:[Ve,Ve]})}return t})();function HHA(t,e){t&1&&UA(0,"div",2)}var OHA=new BA("MAT_PROGRESS_BAR_DEFAULT_OPTIONS");var mcA=(()=>{class t{_elementRef=m(te);_ngZone=m(de);_changeDetectorRef=m(lt);_renderer=m(Gi);_cleanupTransitionEnd;_animationMode=m(mi,{optional:!0});constructor(){let A=m(OHA,{optional:!0});this._isNoopAnimation=this._animationMode==="NoopAnimations",A&&(A.color&&(this.color=this._defaultColor=A.color),this.mode=A.mode||this.mode)}_isNoopAnimation=!1;get color(){return this._color||this._defaultColor}set color(A){this._color=A}_color;_defaultColor="primary";get value(){return this._value}set value(A){this._value=fcA(A||0),this._changeDetectorRef.markForCheck()}_value=0;get bufferValue(){return this._bufferValue||0}set bufferValue(A){this._bufferValue=fcA(A||0),this._changeDetectorRef.markForCheck()}_bufferValue=0;animationEnd=new XA;get mode(){return this._mode}set mode(A){this._mode=A,this._changeDetectorRef.markForCheck()}_mode="determinate";ngAfterViewInit(){this._ngZone.runOutsideAngular(()=>{this._cleanupTransitionEnd=this._renderer.listen(this._elementRef.nativeElement,"transitionend",this._transitionendHandler)})}ngOnDestroy(){this._cleanupTransitionEnd?.()}_getPrimaryBarTransform(){return`scaleX(${this._isIndeterminate()?1:this.value/100})`}_getBufferBarFlexBasis(){return`${this.mode==="buffer"?this.bufferValue:100}%`}_isIndeterminate(){return this.mode==="indeterminate"||this.mode==="query"}_transitionendHandler=A=>{this.animationEnd.observers.length===0||!A.target||!A.target.classList.contains("mdc-linear-progress__primary-bar")||(this.mode==="determinate"||this.mode==="buffer")&&this._ngZone.run(()=>this.animationEnd.next({value:this.value}))};static \u0275fac=function(i){return new(i||t)};static \u0275cmp=YA({type:t,selectors:[["mat-progress-bar"]],hostAttrs:["role","progressbar","aria-valuemin","0","aria-valuemax","100","tabindex","-1",1,"mat-mdc-progress-bar","mdc-linear-progress"],hostVars:10,hostBindings:function(i,n){i&2&&(_e("aria-valuenow",n._isIndeterminate()?null:n.value)("mode",n.mode),vo("mat-"+n.color),ue("_mat-animation-noopable",n._isNoopAnimation)("mdc-linear-progress--animation-ready",!n._isNoopAnimation)("mdc-linear-progress--indeterminate",n._isIndeterminate()))},inputs:{color:"color",value:[2,"value","value",Mi],bufferValue:[2,"bufferValue","bufferValue",Mi],mode:"mode"},outputs:{animationEnd:"animationEnd"},exportAs:["matProgressBar"],decls:7,vars:5,consts:[["aria-hidden","true",1,"mdc-linear-progress__buffer"],[1,"mdc-linear-progress__buffer-bar"],[1,"mdc-linear-progress__buffer-dots"],["aria-hidden","true",1,"mdc-linear-progress__bar","mdc-linear-progress__primary-bar"],[1,"mdc-linear-progress__bar-inner"],["aria-hidden","true",1,"mdc-linear-progress__bar","mdc-linear-progress__secondary-bar"]],template:function(i,n){i&1&&(S(0,"div",0),UA(1,"div",1),NA(2,HHA,1,0,"div",2),R(),S(3,"div",3),UA(4,"span",4),R(),S(5,"div",5),UA(6,"span",4),R()),i&2&&(_(),so("flex-basis",n._getBufferBarFlexBasis()),_(),FA(n.mode==="buffer"?2:-1),_(),so("transform",n._getPrimaryBarTransform()))},styles:[`.mat-mdc-progress-bar{display:block;text-align:start}.mat-mdc-progress-bar[mode=query]{transform:scaleX(-1)}.mat-mdc-progress-bar._mat-animation-noopable .mdc-linear-progress__buffer-dots,.mat-mdc-progress-bar._mat-animation-noopable .mdc-linear-progress__primary-bar,.mat-mdc-progress-bar._mat-animation-noopable .mdc-linear-progress__secondary-bar,.mat-mdc-progress-bar._mat-animation-noopable .mdc-linear-progress__bar-inner.mdc-linear-progress__bar-inner{animation:none}.mat-mdc-progress-bar._mat-animation-noopable .mdc-linear-progress__primary-bar,.mat-mdc-progress-bar._mat-animation-noopable .mdc-linear-progress__buffer-bar{transition:transform 1ms}.mdc-linear-progress{position:relative;width:100%;transform:translateZ(0);outline:1px solid rgba(0,0,0,0);overflow-x:hidden;transition:opacity 250ms 0ms cubic-bezier(0.4, 0, 0.6, 1);height:max(var(--mdc-linear-progress-track-height, 4px),var(--mdc-linear-progress-active-indicator-height, 4px))}@media(forced-colors: active){.mdc-linear-progress{outline-color:CanvasText}}.mdc-linear-progress__bar{position:absolute;top:0;bottom:0;margin:auto 0;width:100%;animation:none;transform-origin:top left;transition:transform 250ms 0ms cubic-bezier(0.4, 0, 0.6, 1);height:var(--mdc-linear-progress-active-indicator-height, 4px)}.mdc-linear-progress--indeterminate .mdc-linear-progress__bar{transition:none}[dir=rtl] .mdc-linear-progress__bar{right:0;transform-origin:center right}.mdc-linear-progress__bar-inner{display:inline-block;position:absolute;width:100%;animation:none;border-top-style:solid;border-color:var(--mdc-linear-progress-active-indicator-color, var(--mat-sys-primary));border-top-width:var(--mdc-linear-progress-active-indicator-height, 4px)}.mdc-linear-progress__buffer{display:flex;position:absolute;top:0;bottom:0;margin:auto 0;width:100%;overflow:hidden;height:var(--mdc-linear-progress-track-height, 4px);border-radius:var(--mdc-linear-progress-track-shape, var(--mat-sys-corner-none))}.mdc-linear-progress__buffer-dots{-webkit-mask-image:url("data:image/svg+xml,%3Csvg version='1.1' xmlns='http://www.w3.org/2000/svg' xmlns:xlink='http://www.w3.org/1999/xlink' x='0px' y='0px' enable-background='new 0 0 5 2' xml:space='preserve' viewBox='0 0 5 2' preserveAspectRatio='xMinYMin slice'%3E%3Ccircle cx='1' cy='1' r='1'/%3E%3C/svg%3E");mask-image:url("data:image/svg+xml,%3Csvg version='1.1' xmlns='http://www.w3.org/2000/svg' xmlns:xlink='http://www.w3.org/1999/xlink' x='0px' y='0px' enable-background='new 0 0 5 2' xml:space='preserve' viewBox='0 0 5 2' preserveAspectRatio='xMinYMin slice'%3E%3Ccircle cx='1' cy='1' r='1'/%3E%3C/svg%3E");background-repeat:repeat-x;flex:auto;transform:rotate(180deg);animation:mdc-linear-progress-buffering 250ms infinite linear;background-color:var(--mdc-linear-progress-track-color, var(--mat-sys-surface-variant))}@media(forced-colors: active){.mdc-linear-progress__buffer-dots{background-color:ButtonBorder}}[dir=rtl] .mdc-linear-progress__buffer-dots{animation:mdc-linear-progress-buffering-reverse 250ms infinite linear;transform:rotate(0)}.mdc-linear-progress__buffer-bar{flex:0 1 100%;transition:flex-basis 250ms 0ms cubic-bezier(0.4, 0, 0.6, 1);background-color:var(--mdc-linear-progress-track-color, var(--mat-sys-surface-variant))}.mdc-linear-progress__primary-bar{transform:scaleX(0)}.mdc-linear-progress--indeterminate .mdc-linear-progress__primary-bar{left:-145.166611%}.mdc-linear-progress--indeterminate.mdc-linear-progress--animation-ready .mdc-linear-progress__primary-bar{animation:mdc-linear-progress-primary-indeterminate-translate 2s infinite linear}.mdc-linear-progress--indeterminate.mdc-linear-progress--animation-ready .mdc-linear-progress__primary-bar>.mdc-linear-progress__bar-inner{animation:mdc-linear-progress-primary-indeterminate-scale 2s infinite linear}[dir=rtl] .mdc-linear-progress.mdc-linear-progress--animation-ready .mdc-linear-progress__primary-bar{animation-name:mdc-linear-progress-primary-indeterminate-translate-reverse}[dir=rtl] .mdc-linear-progress.mdc-linear-progress--indeterminate .mdc-linear-progress__primary-bar{right:-145.166611%;left:auto}.mdc-linear-progress__secondary-bar{display:none}.mdc-linear-progress--indeterminate .mdc-linear-progress__secondary-bar{left:-54.888891%;display:block}.mdc-linear-progress--indeterminate.mdc-linear-progress--animation-ready .mdc-linear-progress__secondary-bar{animation:mdc-linear-progress-secondary-indeterminate-translate 2s infinite linear}.mdc-linear-progress--indeterminate.mdc-linear-progress--animation-ready .mdc-linear-progress__secondary-bar>.mdc-linear-progress__bar-inner{animation:mdc-linear-progress-secondary-indeterminate-scale 2s infinite linear}[dir=rtl] .mdc-linear-progress.mdc-linear-progress--animation-ready .mdc-linear-progress__secondary-bar{animation-name:mdc-linear-progress-secondary-indeterminate-translate-reverse}[dir=rtl] .mdc-linear-progress.mdc-linear-progress--indeterminate .mdc-linear-progress__secondary-bar{right:-54.888891%;left:auto}@keyframes mdc-linear-progress-buffering{from{transform:rotate(180deg) translateX(calc(var(--mdc-linear-progress-track-height, 4px) * -2.5))}}@keyframes mdc-linear-progress-primary-indeterminate-translate{0%{transform:translateX(0)}20%{animation-timing-function:cubic-bezier(0.5, 0, 0.701732, 0.495819);transform:translateX(0)}59.15%{animation-timing-function:cubic-bezier(0.302435, 0.381352, 0.55, 0.956352);transform:translateX(83.67142%)}100%{transform:translateX(200.611057%)}}@keyframes mdc-linear-progress-primary-indeterminate-scale{0%{transform:scaleX(0.08)}36.65%{animation-timing-function:cubic-bezier(0.334731, 0.12482, 0.785844, 1);transform:scaleX(0.08)}69.15%{animation-timing-function:cubic-bezier(0.06, 0.11, 0.6, 1);transform:scaleX(0.661479)}100%{transform:scaleX(0.08)}}@keyframes mdc-linear-progress-secondary-indeterminate-translate{0%{animation-timing-function:cubic-bezier(0.15, 0, 0.515058, 0.409685);transform:translateX(0)}25%{animation-timing-function:cubic-bezier(0.31033, 0.284058, 0.8, 0.733712);transform:translateX(37.651913%)}48.35%{animation-timing-function:cubic-bezier(0.4, 0.627035, 0.6, 0.902026);transform:translateX(84.386165%)}100%{transform:translateX(160.277782%)}}@keyframes mdc-linear-progress-secondary-indeterminate-scale{0%{animation-timing-function:cubic-bezier(0.205028, 0.057051, 0.57661, 0.453971);transform:scaleX(0.08)}19.15%{animation-timing-function:cubic-bezier(0.152313, 0.196432, 0.648374, 1.004315);transform:scaleX(0.457104)}44.15%{animation-timing-function:cubic-bezier(0.257759, -0.003163, 0.211762, 1.38179);transform:scaleX(0.72796)}100%{transform:scaleX(0.08)}}@keyframes mdc-linear-progress-primary-indeterminate-translate-reverse{0%{transform:translateX(0)}20%{animation-timing-function:cubic-bezier(0.5, 0, 0.701732, 0.495819);transform:translateX(0)}59.15%{animation-timing-function:cubic-bezier(0.302435, 0.381352, 0.55, 0.956352);transform:translateX(-83.67142%)}100%{transform:translateX(-200.611057%)}}@keyframes mdc-linear-progress-secondary-indeterminate-translate-reverse{0%{animation-timing-function:cubic-bezier(0.15, 0, 0.515058, 0.409685);transform:translateX(0)}25%{animation-timing-function:cubic-bezier(0.31033, 0.284058, 0.8, 0.733712);transform:translateX(-37.651913%)}48.35%{animation-timing-function:cubic-bezier(0.4, 0.627035, 0.6, 0.902026);transform:translateX(-84.386165%)}100%{transform:translateX(-160.277782%)}}@keyframes mdc-linear-progress-buffering-reverse{from{transform:translateX(-10px)}}`],encapsulation:2,changeDetection:0})}return t})();function fcA(t,e=0,A=100){return Math.max(e,Math.min(A,t))}var pcA=(()=>{class t{static \u0275fac=function(i){return new(i||t)};static \u0275mod=ge({type:t});static \u0275inj=le({imports:[Ve]})}return t})();function YG(){return{async:!1,breaks:!1,extensions:null,gfm:!0,hooks:null,pedantic:!1,renderer:null,silent:!1,tokenizer:null,walkTokens:null}}var ZC=YG();function McA(t){ZC=t}var gf={exec:()=>null};function xn(t,e=""){let A=typeof t=="string"?t:t.source,i={replace:(n,o)=>{let r=typeof o=="string"?o:o.source;return r=r.replace(Ps.caret,"$1"),A=A.replace(n,r),i},getRegex:()=>new RegExp(A,e)};return i}var Ps={codeRemoveIndent:/^(?: {1,4}| {0,3}\t)/gm,outputLinkReplace:/\\([\[\]])/g,indentCodeCompensation:/^(\s+)(?:```)/,beginningSpace:/^\s+/,endingHash:/#$/,startingSpaceChar:/^ /,endingSpaceChar:/ $/,nonSpaceChar:/[^ ]/,newLineCharGlobal:/\n/g,tabCharGlobal:/\t/g,multipleSpaceGlobal:/\s+/g,blankLine:/^[ \t]*$/,doubleBlankLine:/\n[ \t]*\n[ \t]*$/,blockquoteStart:/^ {0,3}>/,blockquoteSetextReplace:/\n {0,3}((?:=+|-+) *)(?=\n|$)/g,blockquoteSetextReplace2:/^ {0,3}>[ \t]?/gm,listReplaceTabs:/^\t+/,listReplaceNesting:/^ {1,4}(?=( {4})*[^ ])/g,listIsTask:/^\[[ xX]\] /,listReplaceTask:/^\[[ xX]\] +/,anyLine:/\n.*\n/,hrefBrackets:/^<(.*)>$/,tableDelimiter:/[:|]/,tableAlignChars:/^\||\| *$/g,tableRowBlankLine:/\n[ \t]*$/,tableAlignRight:/^ *-+: *$/,tableAlignCenter:/^ *:-+: *$/,tableAlignLeft:/^ *:-+ *$/,startATag:/^<a /i,endATag:/^<\/a>/i,startPreScriptTag:/^<(pre|code|kbd|script)(\s|>)/i,endPreScriptTag:/^<\/(pre|code|kbd|script)(\s|>)/i,startAngleBracket:/^</,endAngleBracket:/>$/,pedanticHrefTitle:/^([^'"]*[^\s])\s+(['"])(.*)\2/,unicodeAlphaNumeric:/[\p{L}\p{N}]/u,escapeTest:/[&<>"']/,escapeReplace:/[&<>"']/g,escapeTestNoEncode:/[<>"']|&(?!(#\d{1,7}|#[Xx][a-fA-F0-9]{1,6}|\w+);)/,escapeReplaceNoEncode:/[<>"']|&(?!(#\d{1,7}|#[Xx][a-fA-F0-9]{1,6}|\w+);)/g,unescapeTest:/&(#(?:\d+)|(?:#x[0-9A-Fa-f]+)|(?:\w+));?/ig,caret:/(^|[^\[])\^/g,percentDecode:/%25/g,findPipe:/\|/g,splitPipe:/ \|/,slashPipe:/\\\|/g,carriageReturn:/\r\n|\r/g,spaceLine:/^ +$/gm,notSpaceStart:/^\S*/,endingNewline:/\n$/,listItemRegex:t=>new RegExp(`^( {0,3}${t})((?:[	 ][^\\n]*)?(?:\\n|$))`),nextBulletRegex:t=>new RegExp(`^ {0,${Math.min(3,t-1)}}(?:[*+-]|\\d{1,9}[.)])((?:[ 	][^\\n]*)?(?:\\n|$))`),hrRegex:t=>new RegExp(`^ {0,${Math.min(3,t-1)}}((?:- *){3,}|(?:_ *){3,}|(?:\\* *){3,})(?:\\n+|$)`),fencesBeginRegex:t=>new RegExp(`^ {0,${Math.min(3,t-1)}}(?:\`\`\`|~~~)`),headingBeginRegex:t=>new RegExp(`^ {0,${Math.min(3,t-1)}}#`),htmlBeginRegex:t=>new RegExp(`^ {0,${Math.min(3,t-1)}}<(?:[a-z].*>|!--)`,"i")},jHA=/^(?:[ \t]*(?:\n|$))+/,qHA=/^((?: {4}| {0,3}\t)[^\n]+(?:\n(?:[ \t]*(?:\n|$))*)?)+/,VHA=/^ {0,3}(`{3,}(?=[^`\n]*(?:\n|$))|~{3,})([^\n]*)(?:\n|$)(?:|([\s\S]*?)(?:\n|$))(?: {0,3}\1[~`]* *(?=\n|$)|$)/,Cf=/^ {0,3}((?:-[\t ]*){3,}|(?:_[ \t]*){3,}|(?:\*[ \t]*){3,})(?:\n+|$)/,ZHA=/^ {0,3}(#{1,6})(?=\s|$)(.*)(?:\n+|$)/,JG=/(?:[*+-]|\d{1,9}[.)])/,kcA=/^(?!bull |blockCode|fences|blockquote|heading|html|table)((?:.|\n(?!\s*?\n|bull |blockCode|fences|blockquote|heading|html|table))+?)\n {0,3}(=+|-+) *(?:\n+|$)/,ScA=xn(kcA).replace(/bull/g,JG).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(),WHA=xn(kcA).replace(/bull/g,JG).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(),TG=/^([^\n]+(?:\n(?!hr|heading|lheading|blockquote|fences|list|html|table| +\n)[^\n]+)*)/,XHA=/^[^\n]+/,zG=/(?!\s*\])(?:\\.|[^\[\]\\])+/,$HA=xn(/^ {0,3}\[(label)\]: *(?:\n[ \t]*)?([^<\s][^\s]*|<.*?>)(?:(?: +(?:\n[ \t]*)?| *\n[ \t]*)(title))? *(?:\n+|$)/).replace("label",zG).replace("title",/(?:"(?:\\"?|[^"\\])*"|'[^'\n]*(?:\n[^'\n]+)*\n?'|\([^()]*\))/).getRegex(),AOA=xn(/^( {0,3}bull)([ \t][^\n]+?)?(?:\n|$)/).replace(/bull/g,JG).getRegex(),Vy="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",HG=/<!--(?:-?>|[\s\S]*?(?:-->|$))/,eOA=xn("^ {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",HG).replace("tag",Vy).replace("attribute",/ +[a-zA-Z:_][\w.:-]*(?: *= *"[^"\n]*"| *= *'[^'\n]*'| *= *[^\s"'=<>`]+)?/).getRegex(),RcA=xn(TG).replace("hr",Cf).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",Vy).getRegex(),tOA=xn(/^( {0,3}> ?(paragraph|[^\n]*)(?:\n|$))+/).replace("paragraph",RcA).getRegex(),OG={blockquote:tOA,code:qHA,def:$HA,fences:VHA,heading:ZHA,hr:Cf,html:eOA,lheading:ScA,list:AOA,newline:jHA,paragraph:RcA,table:gf,text:XHA},wcA=xn("^ *([^\\n ].*)\\n {0,3}((?:\\| *)?:?-+:? *(?:\\| *:?-+:? *)*(?:\\| *)?)(?:\\n((?:(?! *\\n|hr|heading|blockquote|code|fences|list|html).*(?:\\n|$))*)\\n*|$)").replace("hr",Cf).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",Vy).getRegex(),iOA=Ne(nA({},OG),{lheading:WHA,table:wcA,paragraph:xn(TG).replace("hr",Cf).replace("heading"," {0,3}#{1,6}(?:\\s|$)").replace("|lheading","").replace("table",wcA).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",Vy).getRegex()}),nOA=Ne(nA({},OG),{html:xn(`^ *(?:comment *(?:\\n|\\s*$)|<(tag)[\\s\\S]+?</\\1> *(?:\\n{2,}|\\s*$)|<tag(?:"[^"]*"|'[^']*'|\\s[^'"/>\\s]*)*?/?> *(?:\\n{2,}|\\s*$))`).replace("comment",HG).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(),def:/^ *\[([^\]]+)\]: *<?([^\s>]+)>?(?: +(["(][^\n]+[")]))? *(?:\n+|$)/,heading:/^(#{1,6})(.*)(?:\n+|$)/,fences:gf,lheading:/^(.+?)\n {0,3}(=+|-+) *(?:\n+|$)/,paragraph:xn(TG).replace("hr",Cf).replace("heading",` *#{1,6} *[^
]`).replace("lheading",ScA).replace("|table","").replace("blockquote"," {0,3}>").replace("|fences","").replace("|list","").replace("|html","").replace("|tag","").getRegex()}),oOA=/^\\([!"#$%&'()*+,\-./:;<=>?@\[\]\\^_`{|}~])/,rOA=/^(`+)([^`]|[^`][\s\S]*?[^`])\1(?!`)/,LcA=/^( {2,}|\\)\n(?!\s*$)/,sOA=/^(`+|[^`])(?:(?= {2,}\n)|[\s\S]*?(?:(?=[\\<!\[`*_]|\b_|$)|[^ ](?= {2,}\n)))/,Zy=/[\p{P}\p{S}]/u,PG=/[\s\p{P}\p{S}]/u,xcA=/[^\s\p{P}\p{S}]/u,aOA=xn(/^((?![*_])punctSpace)/,"u").replace(/punctSpace/g,PG).getRegex(),FcA=/(?!~)[\p{P}\p{S}]/u,cOA=/(?!~)[\s\p{P}\p{S}]/u,lOA=/(?:[^\s\p{P}\p{S}]|~)/u,gOA=/\[[^[\]]*?\]\((?:\\.|[^\\\(\)]|\((?:\\.|[^\\\(\)])*\))*\)|`[^`]*?`|<[^<>]*?>/g,NcA=/^(?:\*+(?:((?!\*)punct)|[^\s*]))|^_+(?:((?!_)punct)|([^\s_]))/,IOA=xn(NcA,"u").replace(/punct/g,Zy).getRegex(),COA=xn(NcA,"u").replace(/punct/g,FcA).getRegex(),_cA="^[^_*]*?__[^_*]*?\\*[^_*]*?(?=__)|[^*]+(?=[^*])|(?!\\*)punct(\\*+)(?=[\\s]|$)|notPunctSpace(\\*+)(?!\\*)(?=punctSpace|$)|(?!\\*)punctSpace(\\*+)(?=notPunctSpace)|[\\s](\\*+)(?!\\*)(?=punct)|(?!\\*)punct(\\*+)(?!\\*)(?=punct)|notPunctSpace(\\*+)(?=notPunctSpace)",dOA=xn(_cA,"gu").replace(/notPunctSpace/g,xcA).replace(/punctSpace/g,PG).replace(/punct/g,Zy).getRegex(),BOA=xn(_cA,"gu").replace(/notPunctSpace/g,lOA).replace(/punctSpace/g,cOA).replace(/punct/g,FcA).getRegex(),EOA=xn("^[^_*]*?\\*\\*[^_*]*?_[^_*]*?(?=\\*\\*)|[^_]+(?=[^_])|(?!_)punct(_+)(?=[\\s]|$)|notPunctSpace(_+)(?!_)(?=punctSpace|$)|(?!_)punctSpace(_+)(?=notPunctSpace)|[\\s](_+)(?!_)(?=punct)|(?!_)punct(_+)(?!_)(?=punct)","gu").replace(/notPunctSpace/g,xcA).replace(/punctSpace/g,PG).replace(/punct/g,Zy).getRegex(),hOA=xn(/\\(punct)/,"gu").replace(/punct/g,Zy).getRegex(),QOA=xn(/^<(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(),uOA=xn(HG).replace("(?:-->|$)","-->").getRegex(),fOA=xn("^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",uOA).replace("attribute",/\s+[a-zA-Z:_][\w.:-]*(?:\s*=\s*"[^"]*"|\s*=\s*'[^']*'|\s*=\s*[^\s"'=<>`]+)?/).getRegex(),qy=/(?:\[(?:\\.|[^\[\]\\])*\]|\\.|`[^`]*`|[^\[\]\\`])*?/,mOA=xn(/^!?\[(label)\]\(\s*(href)(?:(?:[ \t]*(?:\n[ \t]*)?)(title))?\s*\)/).replace("label",qy).replace("href",/<(?:\\.|[^\n<>\\])+>|[^ \t\n\x00-\x1f]*/).replace("title",/"(?:\\"?|[^"\\])*"|'(?:\\'?|[^'\\])*'|\((?:\\\)?|[^)\\])*\)/).getRegex(),GcA=xn(/^!?\[(label)\]\[(ref)\]/).replace("label",qy).replace("ref",zG).getRegex(),UcA=xn(/^!?\[(ref)\](?:\[\])?/).replace("ref",zG).getRegex(),pOA=xn("reflink|nolink(?!\\()","g").replace("reflink",GcA).replace("nolink",UcA).getRegex(),jG={_backpedal:gf,anyPunctuation:hOA,autolink:QOA,blockSkip:gOA,br:LcA,code:rOA,del:gf,emStrongLDelim:IOA,emStrongRDelimAst:dOA,emStrongRDelimUnd:EOA,escape:oOA,link:mOA,nolink:UcA,punctuation:aOA,reflink:GcA,reflinkSearch:pOA,tag:fOA,text:sOA,url:gf},wOA=Ne(nA({},jG),{link:xn(/^!?\[(label)\]\((.*?)\)/).replace("label",qy).getRegex(),reflink:xn(/^!?\[(label)\]\s*\[([^\]]*)\]/).replace("label",qy).getRegex()}),UG=Ne(nA({},jG),{emStrongRDelimAst:BOA,emStrongLDelim:COA,url:xn(/^((?: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(),_backpedal:/(?:[^?!.,:;*_'"~()&]+|\([^)]*\)|&(?![a-zA-Z0-9]+;$)|[?!.,:;*_'"~)]+(?!$))+/,del:/^(~~?)(?=[^\s~])((?:\\.|[^\\])*?(?:\\.|[^\s~\\]))\1(?=[^~]|$)/,text:/^([`~]+|[^`~])(?:(?= {2,}\n)|(?=[a-zA-Z0-9.!#$%&'*+\/=?_`{\|}~-]+@)|[\s\S]*?(?:(?=[\\<!\[`*~_]|\b_|https?:\/\/|ftp:\/\/|www\.|$)|[^ ](?= {2,}\n)|[^a-zA-Z0-9.!#$%&'*+\/=?_`{\|}~-](?=[a-zA-Z0-9.!#$%&'*+\/=?_`{\|}~-]+@)))/}),DOA=Ne(nA({},UG),{br:xn(LcA).replace("{2,}","*").getRegex(),text:xn(UG.text).replace("\\b_","\\b_| {2,}\\n").replace(/\{2,\}/g,"*").getRegex()}),jy={normal:OG,gfm:iOA,pedantic:nOA},cf={normal:jG,gfm:UG,breaks:DOA,pedantic:wOA},yOA={"&":"&amp;","<":"&lt;",">":"&gt;",'"':"&quot;","'":"&#39;"},DcA=t=>yOA[t];function Hg(t,e){if(e){if(Ps.escapeTest.test(t))return t.replace(Ps.escapeReplace,DcA)}else if(Ps.escapeTestNoEncode.test(t))return t.replace(Ps.escapeReplaceNoEncode,DcA);return t}function ycA(t){try{t=encodeURI(t).replace(Ps.percentDecode,"%")}catch{return null}return t}function vcA(t,e){let A=t.replace(Ps.findPipe,(o,r,s)=>{let a=!1,c=r;for(;--c>=0&&s[c]==="\\";)a=!a;return a?"|":" |"}),i=A.split(Ps.splitPipe),n=0;if(i[0].trim()||i.shift(),i.length>0&&!i.at(-1)?.trim()&&i.pop(),e)if(i.length>e)i.splice(e);else for(;i.length<e;)i.push("");for(;n<i.length;n++)i[n]=i[n].trim().replace(Ps.slashPipe,"|");return i}function lf(t,e,A){let i=t.length;if(i===0)return"";let n=0;for(;n<i&&t.charAt(i-n-1)===e;)n++;return t.slice(0,i-n)}function vOA(t,e){if(t.indexOf(e[1])===-1)return-1;let A=0;for(let i=0;i<t.length;i++)if(t[i]==="\\")i++;else if(t[i]===e[0])A++;else if(t[i]===e[1]&&(A--,A<0))return i;return A>0?-2:-1}function bcA(t,e,A,i,n){let o=e.href,r=e.title||null,s=t[1].replace(n.other.outputLinkReplace,"$1");i.state.inLink=!0;let a={type:t[0].charAt(0)==="!"?"image":"link",raw:A,href:o,title:r,text:s,tokens:i.inlineTokens(s)};return i.state.inLink=!1,a}function bOA(t,e,A){let i=t.match(A.other.indentCodeCompensation);if(i===null)return e;let n=i[1];return e.split(`
`).map(o=>{let r=o.match(A.other.beginningSpace);if(r===null)return o;let[s]=r;return s.length>=n.length?o.slice(n.length):o}).join(`
`)}var fh=class{options;rules;lexer;constructor(e){this.options=e||ZC}space(e){let A=this.rules.block.newline.exec(e);if(A&&A[0].length>0)return{type:"space",raw:A[0]}}code(e){let A=this.rules.block.code.exec(e);if(A){let i=A[0].replace(this.rules.other.codeRemoveIndent,"");return{type:"code",raw:A[0],codeBlockStyle:"indented",text:this.options.pedantic?i:lf(i,`
`)}}}fences(e){let A=this.rules.block.fences.exec(e);if(A){let i=A[0],n=bOA(i,A[3]||"",this.rules);return{type:"code",raw:i,lang:A[2]?A[2].trim().replace(this.rules.inline.anyPunctuation,"$1"):A[2],text:n}}}heading(e){let A=this.rules.block.heading.exec(e);if(A){let i=A[2].trim();if(this.rules.other.endingHash.test(i)){let n=lf(i,"#");(this.options.pedantic||!n||this.rules.other.endingSpaceChar.test(n))&&(i=n.trim())}return{type:"heading",raw:A[0],depth:A[1].length,text:i,tokens:this.lexer.inline(i)}}}hr(e){let A=this.rules.block.hr.exec(e);if(A)return{type:"hr",raw:lf(A[0],`
`)}}blockquote(e){let A=this.rules.block.blockquote.exec(e);if(A){let i=lf(A[0],`
`).split(`
`),n="",o="",r=[];for(;i.length>0;){let s=!1,a=[],c;for(c=0;c<i.length;c++)if(this.rules.other.blockquoteStart.test(i[c]))a.push(i[c]),s=!0;else if(!s)a.push(i[c]);else break;i=i.slice(c);let l=a.join(`
`),I=l.replace(this.rules.other.blockquoteSetextReplace,`
    $1`).replace(this.rules.other.blockquoteSetextReplace2,"");n=n?`${n}
${l}`:l,o=o?`${o}
${I}`:I;let C=this.lexer.state.top;if(this.lexer.state.top=!0,this.lexer.blockTokens(I,r,!0),this.lexer.state.top=C,i.length===0)break;let d=r.at(-1);if(d?.type==="code")break;if(d?.type==="blockquote"){let B=d,E=B.raw+`
`+i.join(`
`),Q=this.blockquote(E);r[r.length-1]=Q,n=n.substring(0,n.length-B.raw.length)+Q.raw,o=o.substring(0,o.length-B.text.length)+Q.text;break}else if(d?.type==="list"){let B=d,E=B.raw+`
`+i.join(`
`),Q=this.list(E);r[r.length-1]=Q,n=n.substring(0,n.length-d.raw.length)+Q.raw,o=o.substring(0,o.length-B.raw.length)+Q.raw,i=E.substring(r.at(-1).raw.length).split(`
`);continue}}return{type:"blockquote",raw:n,tokens:r,text:o}}}list(e){let A=this.rules.block.list.exec(e);if(A){let i=A[1].trim(),n=i.length>1,o={type:"list",raw:"",ordered:n,start:n?+i.slice(0,-1):"",loose:!1,items:[]};i=n?`\\d{1,9}\\${i.slice(-1)}`:`\\${i}`,this.options.pedantic&&(i=n?i:"[*+-]");let r=this.rules.other.listItemRegex(i),s=!1;for(;e;){let c=!1,l="",I="";if(!(A=r.exec(e))||this.rules.block.hr.test(e))break;l=A[0],e=e.substring(l.length);let C=A[2].split(`
`,1)[0].replace(this.rules.other.listReplaceTabs,v=>" ".repeat(3*v.length)),d=e.split(`
`,1)[0],B=!C.trim(),E=0;if(this.options.pedantic?(E=2,I=C.trimStart()):B?E=A[1].length+1:(E=A[2].search(this.rules.other.nonSpaceChar),E=E>4?1:E,I=C.slice(E),E+=A[1].length),B&&this.rules.other.blankLine.test(d)&&(l+=d+`
`,e=e.substring(d.length+1),c=!0),!c){let v=this.rules.other.nextBulletRegex(E),L=this.rules.other.hrRegex(E),x=this.rules.other.fencesBeginRegex(E),y=this.rules.other.headingBeginRegex(E),F=this.rules.other.htmlBeginRegex(E);for(;e;){let U=e.split(`
`,1)[0],T;if(d=U,this.options.pedantic?(d=d.replace(this.rules.other.listReplaceNesting,"  "),T=d):T=d.replace(this.rules.other.tabCharGlobal,"    "),x.test(d)||y.test(d)||F.test(d)||v.test(d)||L.test(d))break;if(T.search(this.rules.other.nonSpaceChar)>=E||!d.trim())I+=`
`+T.slice(E);else{if(B||C.replace(this.rules.other.tabCharGlobal,"    ").search(this.rules.other.nonSpaceChar)>=4||x.test(C)||y.test(C)||L.test(C))break;I+=`
`+d}!B&&!d.trim()&&(B=!0),l+=U+`
`,e=e.substring(U.length+1),C=T.slice(E)}}o.loose||(s?o.loose=!0:this.rules.other.doubleBlankLine.test(l)&&(s=!0));let Q=null,u;this.options.gfm&&(Q=this.rules.other.listIsTask.exec(I),Q&&(u=Q[0]!=="[ ] ",I=I.replace(this.rules.other.listReplaceTask,""))),o.items.push({type:"list_item",raw:l,task:!!Q,checked:u,loose:!1,text:I,tokens:[]}),o.raw+=l}let a=o.items.at(-1);if(a)a.raw=a.raw.trimEnd(),a.text=a.text.trimEnd();else return;o.raw=o.raw.trimEnd();for(let c=0;c<o.items.length;c++)if(this.lexer.state.top=!1,o.items[c].tokens=this.lexer.blockTokens(o.items[c].text,[]),!o.loose){let l=o.items[c].tokens.filter(C=>C.type==="space"),I=l.length>0&&l.some(C=>this.rules.other.anyLine.test(C.raw));o.loose=I}if(o.loose)for(let c=0;c<o.items.length;c++)o.items[c].loose=!0;return o}}html(e){let A=this.rules.block.html.exec(e);if(A)return{type:"html",block:!0,raw:A[0],pre:A[1]==="pre"||A[1]==="script"||A[1]==="style",text:A[0]}}def(e){let A=this.rules.block.def.exec(e);if(A){let i=A[1].toLowerCase().replace(this.rules.other.multipleSpaceGlobal," "),n=A[2]?A[2].replace(this.rules.other.hrefBrackets,"$1").replace(this.rules.inline.anyPunctuation,"$1"):"",o=A[3]?A[3].substring(1,A[3].length-1).replace(this.rules.inline.anyPunctuation,"$1"):A[3];return{type:"def",tag:i,raw:A[0],href:n,title:o}}}table(e){let A=this.rules.block.table.exec(e);if(!A||!this.rules.other.tableDelimiter.test(A[2]))return;let i=vcA(A[1]),n=A[2].replace(this.rules.other.tableAlignChars,"").split("|"),o=A[3]?.trim()?A[3].replace(this.rules.other.tableRowBlankLine,"").split(`
`):[],r={type:"table",raw:A[0],header:[],align:[],rows:[]};if(i.length===n.length){for(let s of n)this.rules.other.tableAlignRight.test(s)?r.align.push("right"):this.rules.other.tableAlignCenter.test(s)?r.align.push("center"):this.rules.other.tableAlignLeft.test(s)?r.align.push("left"):r.align.push(null);for(let s=0;s<i.length;s++)r.header.push({text:i[s],tokens:this.lexer.inline(i[s]),header:!0,align:r.align[s]});for(let s of o)r.rows.push(vcA(s,r.header.length).map((a,c)=>({text:a,tokens:this.lexer.inline(a),header:!1,align:r.align[c]})));return r}}lheading(e){let A=this.rules.block.lheading.exec(e);if(A)return{type:"heading",raw:A[0],depth:A[2].charAt(0)==="="?1:2,text:A[1],tokens:this.lexer.inline(A[1])}}paragraph(e){let A=this.rules.block.paragraph.exec(e);if(A){let i=A[1].charAt(A[1].length-1)===`
`?A[1].slice(0,-1):A[1];return{type:"paragraph",raw:A[0],text:i,tokens:this.lexer.inline(i)}}}text(e){let A=this.rules.block.text.exec(e);if(A)return{type:"text",raw:A[0],text:A[0],tokens:this.lexer.inline(A[0])}}escape(e){let A=this.rules.inline.escape.exec(e);if(A)return{type:"escape",raw:A[0],text:A[1]}}tag(e){let A=this.rules.inline.tag.exec(e);if(A)return!this.lexer.state.inLink&&this.rules.other.startATag.test(A[0])?this.lexer.state.inLink=!0:this.lexer.state.inLink&&this.rules.other.endATag.test(A[0])&&(this.lexer.state.inLink=!1),!this.lexer.state.inRawBlock&&this.rules.other.startPreScriptTag.test(A[0])?this.lexer.state.inRawBlock=!0:this.lexer.state.inRawBlock&&this.rules.other.endPreScriptTag.test(A[0])&&(this.lexer.state.inRawBlock=!1),{type:"html",raw:A[0],inLink:this.lexer.state.inLink,inRawBlock:this.lexer.state.inRawBlock,block:!1,text:A[0]}}link(e){let A=this.rules.inline.link.exec(e);if(A){let i=A[2].trim();if(!this.options.pedantic&&this.rules.other.startAngleBracket.test(i)){if(!this.rules.other.endAngleBracket.test(i))return;let r=lf(i.slice(0,-1),"\\");if((i.length-r.length)%2===0)return}else{let r=vOA(A[2],"()");if(r===-2)return;if(r>-1){let a=(A[0].indexOf("!")===0?5:4)+A[1].length+r;A[2]=A[2].substring(0,r),A[0]=A[0].substring(0,a).trim(),A[3]=""}}let n=A[2],o="";if(this.options.pedantic){let r=this.rules.other.pedanticHrefTitle.exec(n);r&&(n=r[1],o=r[3])}else o=A[3]?A[3].slice(1,-1):"";return n=n.trim(),this.rules.other.startAngleBracket.test(n)&&(this.options.pedantic&&!this.rules.other.endAngleBracket.test(i)?n=n.slice(1):n=n.slice(1,-1)),bcA(A,{href:n&&n.replace(this.rules.inline.anyPunctuation,"$1"),title:o&&o.replace(this.rules.inline.anyPunctuation,"$1")},A[0],this.lexer,this.rules)}}reflink(e,A){let i;if((i=this.rules.inline.reflink.exec(e))||(i=this.rules.inline.nolink.exec(e))){let n=(i[2]||i[1]).replace(this.rules.other.multipleSpaceGlobal," "),o=A[n.toLowerCase()];if(!o){let r=i[0].charAt(0);return{type:"text",raw:r,text:r}}return bcA(i,o,i[0],this.lexer,this.rules)}}emStrong(e,A,i=""){let n=this.rules.inline.emStrongLDelim.exec(e);if(!n||n[3]&&i.match(this.rules.other.unicodeAlphaNumeric))return;if(!(n[1]||n[2]||"")||!i||this.rules.inline.punctuation.exec(i)){let r=[...n[0]].length-1,s,a,c=r,l=0,I=n[0][0]==="*"?this.rules.inline.emStrongRDelimAst:this.rules.inline.emStrongRDelimUnd;for(I.lastIndex=0,A=A.slice(-1*e.length+r);(n=I.exec(A))!=null;){if(s=n[1]||n[2]||n[3]||n[4]||n[5]||n[6],!s)continue;if(a=[...s].length,n[3]||n[4]){c+=a;continue}else if((n[5]||n[6])&&r%3&&!((r+a)%3)){l+=a;continue}if(c-=a,c>0)continue;a=Math.min(a,a+c+l);let C=[...n[0]][0].length,d=e.slice(0,r+n.index+C+a);if(Math.min(r,a)%2){let E=d.slice(1,-1);return{type:"em",raw:d,text:E,tokens:this.lexer.inlineTokens(E)}}let B=d.slice(2,-2);return{type:"strong",raw:d,text:B,tokens:this.lexer.inlineTokens(B)}}}}codespan(e){let A=this.rules.inline.code.exec(e);if(A){let i=A[2].replace(this.rules.other.newLineCharGlobal," "),n=this.rules.other.nonSpaceChar.test(i),o=this.rules.other.startingSpaceChar.test(i)&&this.rules.other.endingSpaceChar.test(i);return n&&o&&(i=i.substring(1,i.length-1)),{type:"codespan",raw:A[0],text:i}}}br(e){let A=this.rules.inline.br.exec(e);if(A)return{type:"br",raw:A[0]}}del(e){let A=this.rules.inline.del.exec(e);if(A)return{type:"del",raw:A[0],text:A[2],tokens:this.lexer.inlineTokens(A[2])}}autolink(e){let A=this.rules.inline.autolink.exec(e);if(A){let i,n;return A[2]==="@"?(i=A[1],n="mailto:"+i):(i=A[1],n=i),{type:"link",raw:A[0],text:i,href:n,tokens:[{type:"text",raw:i,text:i}]}}}url(e){let A;if(A=this.rules.inline.url.exec(e)){let i,n;if(A[2]==="@")i=A[0],n="mailto:"+i;else{let o;do o=A[0],A[0]=this.rules.inline._backpedal.exec(A[0])?.[0]??"";while(o!==A[0]);i=A[0],A[1]==="www."?n="http://"+A[0]:n=A[0]}return{type:"link",raw:A[0],text:i,href:n,tokens:[{type:"text",raw:i,text:i}]}}}inlineText(e){let A=this.rules.inline.text.exec(e);if(A){let i=this.lexer.state.inRawBlock;return{type:"text",raw:A[0],text:A[0],escaped:i}}}},xl=class t{tokens;options;state;tokenizer;inlineQueue;constructor(e){this.tokens=[],this.tokens.links=Object.create(null),this.options=e||ZC,this.options.tokenizer=this.options.tokenizer||new fh,this.tokenizer=this.options.tokenizer,this.tokenizer.options=this.options,this.tokenizer.lexer=this,this.inlineQueue=[],this.state={inLink:!1,inRawBlock:!1,top:!0};let A={other:Ps,block:jy.normal,inline:cf.normal};this.options.pedantic?(A.block=jy.pedantic,A.inline=cf.pedantic):this.options.gfm&&(A.block=jy.gfm,this.options.breaks?A.inline=cf.breaks:A.inline=cf.gfm),this.tokenizer.rules=A}static get rules(){return{block:jy,inline:cf}}static lex(e,A){return new t(A).lex(e)}static lexInline(e,A){return new t(A).inlineTokens(e)}lex(e){e=e.replace(Ps.carriageReturn,`
`),this.blockTokens(e,this.tokens);for(let A=0;A<this.inlineQueue.length;A++){let i=this.inlineQueue[A];this.inlineTokens(i.src,i.tokens)}return this.inlineQueue=[],this.tokens}blockTokens(e,A=[],i=!1){for(this.options.pedantic&&(e=e.replace(Ps.tabCharGlobal,"    ").replace(Ps.spaceLine,""));e;){let n;if(this.options.extensions?.block?.some(r=>(n=r.call({lexer:this},e,A))?(e=e.substring(n.raw.length),A.push(n),!0):!1))continue;if(n=this.tokenizer.space(e)){e=e.substring(n.raw.length);let r=A.at(-1);n.raw.length===1&&r!==void 0?r.raw+=`
`:A.push(n);continue}if(n=this.tokenizer.code(e)){e=e.substring(n.raw.length);let r=A.at(-1);r?.type==="paragraph"||r?.type==="text"?(r.raw+=`
`+n.raw,r.text+=`
`+n.text,this.inlineQueue.at(-1).src=r.text):A.push(n);continue}if(n=this.tokenizer.fences(e)){e=e.substring(n.raw.length),A.push(n);continue}if(n=this.tokenizer.heading(e)){e=e.substring(n.raw.length),A.push(n);continue}if(n=this.tokenizer.hr(e)){e=e.substring(n.raw.length),A.push(n);continue}if(n=this.tokenizer.blockquote(e)){e=e.substring(n.raw.length),A.push(n);continue}if(n=this.tokenizer.list(e)){e=e.substring(n.raw.length),A.push(n);continue}if(n=this.tokenizer.html(e)){e=e.substring(n.raw.length),A.push(n);continue}if(n=this.tokenizer.def(e)){e=e.substring(n.raw.length);let r=A.at(-1);r?.type==="paragraph"||r?.type==="text"?(r.raw+=`
`+n.raw,r.text+=`
`+n.raw,this.inlineQueue.at(-1).src=r.text):this.tokens.links[n.tag]||(this.tokens.links[n.tag]={href:n.href,title:n.title});continue}if(n=this.tokenizer.table(e)){e=e.substring(n.raw.length),A.push(n);continue}if(n=this.tokenizer.lheading(e)){e=e.substring(n.raw.length),A.push(n);continue}let o=e;if(this.options.extensions?.startBlock){let r=1/0,s=e.slice(1),a;this.options.extensions.startBlock.forEach(c=>{a=c.call({lexer:this},s),typeof a=="number"&&a>=0&&(r=Math.min(r,a))}),r<1/0&&r>=0&&(o=e.substring(0,r+1))}if(this.state.top&&(n=this.tokenizer.paragraph(o))){let r=A.at(-1);i&&r?.type==="paragraph"?(r.raw+=`
`+n.raw,r.text+=`
`+n.text,this.inlineQueue.pop(),this.inlineQueue.at(-1).src=r.text):A.push(n),i=o.length!==e.length,e=e.substring(n.raw.length);continue}if(n=this.tokenizer.text(e)){e=e.substring(n.raw.length);let r=A.at(-1);r?.type==="text"?(r.raw+=`
`+n.raw,r.text+=`
`+n.text,this.inlineQueue.pop(),this.inlineQueue.at(-1).src=r.text):A.push(n);continue}if(e){let r="Infinite loop on byte: "+e.charCodeAt(0);if(this.options.silent){console.error(r);break}else throw new Error(r)}}return this.state.top=!0,A}inline(e,A=[]){return this.inlineQueue.push({src:e,tokens:A}),A}inlineTokens(e,A=[]){let i=e,n=null;if(this.tokens.links){let s=Object.keys(this.tokens.links);if(s.length>0)for(;(n=this.tokenizer.rules.inline.reflinkSearch.exec(i))!=null;)s.includes(n[0].slice(n[0].lastIndexOf("[")+1,-1))&&(i=i.slice(0,n.index)+"["+"a".repeat(n[0].length-2)+"]"+i.slice(this.tokenizer.rules.inline.reflinkSearch.lastIndex))}for(;(n=this.tokenizer.rules.inline.anyPunctuation.exec(i))!=null;)i=i.slice(0,n.index)+"++"+i.slice(this.tokenizer.rules.inline.anyPunctuation.lastIndex);for(;(n=this.tokenizer.rules.inline.blockSkip.exec(i))!=null;)i=i.slice(0,n.index)+"["+"a".repeat(n[0].length-2)+"]"+i.slice(this.tokenizer.rules.inline.blockSkip.lastIndex);let o=!1,r="";for(;e;){o||(r=""),o=!1;let s;if(this.options.extensions?.inline?.some(c=>(s=c.call({lexer:this},e,A))?(e=e.substring(s.raw.length),A.push(s),!0):!1))continue;if(s=this.tokenizer.escape(e)){e=e.substring(s.raw.length),A.push(s);continue}if(s=this.tokenizer.tag(e)){e=e.substring(s.raw.length),A.push(s);continue}if(s=this.tokenizer.link(e)){e=e.substring(s.raw.length),A.push(s);continue}if(s=this.tokenizer.reflink(e,this.tokens.links)){e=e.substring(s.raw.length);let c=A.at(-1);s.type==="text"&&c?.type==="text"?(c.raw+=s.raw,c.text+=s.text):A.push(s);continue}if(s=this.tokenizer.emStrong(e,i,r)){e=e.substring(s.raw.length),A.push(s);continue}if(s=this.tokenizer.codespan(e)){e=e.substring(s.raw.length),A.push(s);continue}if(s=this.tokenizer.br(e)){e=e.substring(s.raw.length),A.push(s);continue}if(s=this.tokenizer.del(e)){e=e.substring(s.raw.length),A.push(s);continue}if(s=this.tokenizer.autolink(e)){e=e.substring(s.raw.length),A.push(s);continue}if(!this.state.inLink&&(s=this.tokenizer.url(e))){e=e.substring(s.raw.length),A.push(s);continue}let a=e;if(this.options.extensions?.startInline){let c=1/0,l=e.slice(1),I;this.options.extensions.startInline.forEach(C=>{I=C.call({lexer:this},l),typeof I=="number"&&I>=0&&(c=Math.min(c,I))}),c<1/0&&c>=0&&(a=e.substring(0,c+1))}if(s=this.tokenizer.inlineText(a)){e=e.substring(s.raw.length),s.raw.slice(-1)!=="_"&&(r=s.raw.slice(-1)),o=!0;let c=A.at(-1);c?.type==="text"?(c.raw+=s.raw,c.text+=s.text):A.push(s);continue}if(e){let c="Infinite loop on byte: "+e.charCodeAt(0);if(this.options.silent){console.error(c);break}else throw new Error(c)}}return A}},Og=class{options;parser;constructor(e){this.options=e||ZC}space(e){return""}code({text:e,lang:A,escaped:i}){let n=(A||"").match(Ps.notSpaceStart)?.[0],o=e.replace(Ps.endingNewline,"")+`
`;return n?'<pre><code class="language-'+Hg(n)+'">'+(i?o:Hg(o,!0))+`</code></pre>
`:"<pre><code>"+(i?o:Hg(o,!0))+`</code></pre>
`}blockquote({tokens:e}){return`<blockquote>
${this.parser.parse(e)}</blockquote>
`}html({text:e}){return e}heading({tokens:e,depth:A}){return`<h${A}>${this.parser.parseInline(e)}</h${A}>
`}hr(e){return`<hr>
`}list(e){let A=e.ordered,i=e.start,n="";for(let s=0;s<e.items.length;s++){let a=e.items[s];n+=this.listitem(a)}let o=A?"ol":"ul",r=A&&i!==1?' start="'+i+'"':"";return"<"+o+r+`>
`+n+"</"+o+`>
`}listitem(e){let A="";if(e.task){let i=this.checkbox({checked:!!e.checked});e.loose?e.tokens[0]?.type==="paragraph"?(e.tokens[0].text=i+" "+e.tokens[0].text,e.tokens[0].tokens&&e.tokens[0].tokens.length>0&&e.tokens[0].tokens[0].type==="text"&&(e.tokens[0].tokens[0].text=i+" "+Hg(e.tokens[0].tokens[0].text),e.tokens[0].tokens[0].escaped=!0)):e.tokens.unshift({type:"text",raw:i+" ",text:i+" ",escaped:!0}):A+=i+" "}return A+=this.parser.parse(e.tokens,!!e.loose),`<li>${A}</li>
`}checkbox({checked:e}){return"<input "+(e?'checked="" ':"")+'disabled="" type="checkbox">'}paragraph({tokens:e}){return`<p>${this.parser.parseInline(e)}</p>
`}table(e){let A="",i="";for(let o=0;o<e.header.length;o++)i+=this.tablecell(e.header[o]);A+=this.tablerow({text:i});let n="";for(let o=0;o<e.rows.length;o++){let r=e.rows[o];i="";for(let s=0;s<r.length;s++)i+=this.tablecell(r[s]);n+=this.tablerow({text:i})}return n&&(n=`<tbody>${n}</tbody>`),`<table>
<thead>
`+A+`</thead>
`+n+`</table>
`}tablerow({text:e}){return`<tr>
${e}</tr>
`}tablecell(e){let A=this.parser.parseInline(e.tokens),i=e.header?"th":"td";return(e.align?`<${i} align="${e.align}">`:`<${i}>`)+A+`</${i}>
`}strong({tokens:e}){return`<strong>${this.parser.parseInline(e)}</strong>`}em({tokens:e}){return`<em>${this.parser.parseInline(e)}</em>`}codespan({text:e}){return`<code>${Hg(e,!0)}</code>`}br(e){return"<br>"}del({tokens:e}){return`<del>${this.parser.parseInline(e)}</del>`}link({href:e,title:A,tokens:i}){let n=this.parser.parseInline(i),o=ycA(e);if(o===null)return n;e=o;let r='<a href="'+e+'"';return A&&(r+=' title="'+Hg(A)+'"'),r+=">"+n+"</a>",r}image({href:e,title:A,text:i,tokens:n}){n&&(i=this.parser.parseInline(n,this.parser.textRenderer));let o=ycA(e);if(o===null)return Hg(i);e=o;let r=`<img src="${e}" alt="${i}"`;return A&&(r+=` title="${Hg(A)}"`),r+=">",r}text(e){return"tokens"in e&&e.tokens?this.parser.parseInline(e.tokens):"escaped"in e&&e.escaped?e.text:Hg(e.text)}},If=class{strong({text:e}){return e}em({text:e}){return e}codespan({text:e}){return e}del({text:e}){return e}html({text:e}){return e}text({text:e}){return e}link({text:e}){return""+e}image({text:e}){return""+e}br(){return""}},Fl=class t{options;renderer;textRenderer;constructor(e){this.options=e||ZC,this.options.renderer=this.options.renderer||new Og,this.renderer=this.options.renderer,this.renderer.options=this.options,this.renderer.parser=this,this.textRenderer=new If}static parse(e,A){return new t(A).parse(e)}static parseInline(e,A){return new t(A).parseInline(e)}parse(e,A=!0){let i="";for(let n=0;n<e.length;n++){let o=e[n];if(this.options.extensions?.renderers?.[o.type]){let s=o,a=this.options.extensions.renderers[s.type].call({parser:this},s);if(a!==!1||!["space","hr","heading","code","table","blockquote","list","html","paragraph","text"].includes(s.type)){i+=a||"";continue}}let r=o;switch(r.type){case"space":{i+=this.renderer.space(r);continue}case"hr":{i+=this.renderer.hr(r);continue}case"heading":{i+=this.renderer.heading(r);continue}case"code":{i+=this.renderer.code(r);continue}case"table":{i+=this.renderer.table(r);continue}case"blockquote":{i+=this.renderer.blockquote(r);continue}case"list":{i+=this.renderer.list(r);continue}case"html":{i+=this.renderer.html(r);continue}case"paragraph":{i+=this.renderer.paragraph(r);continue}case"text":{let s=r,a=this.renderer.text(s);for(;n+1<e.length&&e[n+1].type==="text";)s=e[++n],a+=`
`+this.renderer.text(s);A?i+=this.renderer.paragraph({type:"paragraph",raw:a,text:a,tokens:[{type:"text",raw:a,text:a,escaped:!0}]}):i+=a;continue}default:{let s='Token with "'+r.type+'" type was not found.';if(this.options.silent)return console.error(s),"";throw new Error(s)}}}return i}parseInline(e,A=this.renderer){let i="";for(let n=0;n<e.length;n++){let o=e[n];if(this.options.extensions?.renderers?.[o.type]){let s=this.options.extensions.renderers[o.type].call({parser:this},o);if(s!==!1||!["escape","html","link","image","strong","em","codespan","br","del","text"].includes(o.type)){i+=s||"";continue}}let r=o;switch(r.type){case"escape":{i+=A.text(r);break}case"html":{i+=A.html(r);break}case"link":{i+=A.link(r);break}case"image":{i+=A.image(r);break}case"strong":{i+=A.strong(r);break}case"em":{i+=A.em(r);break}case"codespan":{i+=A.codespan(r);break}case"br":{i+=A.br(r);break}case"del":{i+=A.del(r);break}case"text":{i+=A.text(r);break}default:{let s='Token with "'+r.type+'" type was not found.';if(this.options.silent)return console.error(s),"";throw new Error(s)}}}return i}},uh=class{options;block;constructor(e){this.options=e||ZC}static passThroughHooks=new Set(["preprocess","postprocess","processAllTokens"]);preprocess(e){return e}postprocess(e){return e}processAllTokens(e){return e}provideLexer(){return this.block?xl.lex:xl.lexInline}provideParser(){return this.block?Fl.parse:Fl.parseInline}},KG=class{defaults=YG();options=this.setOptions;parse=this.parseMarkdown(!0);parseInline=this.parseMarkdown(!1);Parser=Fl;Renderer=Og;TextRenderer=If;Lexer=xl;Tokenizer=fh;Hooks=uh;constructor(...e){this.use(...e)}walkTokens(e,A){let i=[];for(let n of e)switch(i=i.concat(A.call(this,n)),n.type){case"table":{let o=n;for(let r of o.header)i=i.concat(this.walkTokens(r.tokens,A));for(let r of o.rows)for(let s of r)i=i.concat(this.walkTokens(s.tokens,A));break}case"list":{let o=n;i=i.concat(this.walkTokens(o.items,A));break}default:{let o=n;this.defaults.extensions?.childTokens?.[o.type]?this.defaults.extensions.childTokens[o.type].forEach(r=>{let s=o[r].flat(1/0);i=i.concat(this.walkTokens(s,A))}):o.tokens&&(i=i.concat(this.walkTokens(o.tokens,A)))}}return i}use(...e){let A=this.defaults.extensions||{renderers:{},childTokens:{}};return e.forEach(i=>{let n=nA({},i);if(n.async=this.defaults.async||n.async||!1,i.extensions&&(i.extensions.forEach(o=>{if(!o.name)throw new Error("extension name required");if("renderer"in o){let r=A.renderers[o.name];r?A.renderers[o.name]=function(...s){let a=o.renderer.apply(this,s);return a===!1&&(a=r.apply(this,s)),a}:A.renderers[o.name]=o.renderer}if("tokenizer"in o){if(!o.level||o.level!=="block"&&o.level!=="inline")throw new Error("extension level must be 'block' or 'inline'");let r=A[o.level];r?r.unshift(o.tokenizer):A[o.level]=[o.tokenizer],o.start&&(o.level==="block"?A.startBlock?A.startBlock.push(o.start):A.startBlock=[o.start]:o.level==="inline"&&(A.startInline?A.startInline.push(o.start):A.startInline=[o.start]))}"childTokens"in o&&o.childTokens&&(A.childTokens[o.name]=o.childTokens)}),n.extensions=A),i.renderer){let o=this.defaults.renderer||new Og(this.defaults);for(let r in i.renderer){if(!(r in o))throw new Error(`renderer '${r}' does not exist`);if(["options","parser"].includes(r))continue;let s=r,a=i.renderer[s],c=o[s];o[s]=(...l)=>{let I=a.apply(o,l);return I===!1&&(I=c.apply(o,l)),I||""}}n.renderer=o}if(i.tokenizer){let o=this.defaults.tokenizer||new fh(this.defaults);for(let r in i.tokenizer){if(!(r in o))throw new Error(`tokenizer '${r}' does not exist`);if(["options","rules","lexer"].includes(r))continue;let s=r,a=i.tokenizer[s],c=o[s];o[s]=(...l)=>{let I=a.apply(o,l);return I===!1&&(I=c.apply(o,l)),I}}n.tokenizer=o}if(i.hooks){let o=this.defaults.hooks||new uh;for(let r in i.hooks){if(!(r in o))throw new Error(`hook '${r}' does not exist`);if(["options","block"].includes(r))continue;let s=r,a=i.hooks[s],c=o[s];uh.passThroughHooks.has(r)?o[s]=l=>{if(this.defaults.async)return Promise.resolve(a.call(o,l)).then(C=>c.call(o,C));let I=a.call(o,l);return c.call(o,I)}:o[s]=(...l)=>{let I=a.apply(o,l);return I===!1&&(I=c.apply(o,l)),I}}n.hooks=o}if(i.walkTokens){let o=this.defaults.walkTokens,r=i.walkTokens;n.walkTokens=function(s){let a=[];return a.push(r.call(this,s)),o&&(a=a.concat(o.call(this,s))),a}}this.defaults=nA(nA({},this.defaults),n)}),this}setOptions(e){return this.defaults=nA(nA({},this.defaults),e),this}lexer(e,A){return xl.lex(e,A??this.defaults)}parser(e,A){return Fl.parse(e,A??this.defaults)}parseMarkdown(e){return(i,n)=>{let o=nA({},n),r=nA(nA({},this.defaults),o),s=this.onError(!!r.silent,!!r.async);if(this.defaults.async===!0&&o.async===!1)return s(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."));if(typeof i>"u"||i===null)return s(new Error("marked(): input parameter is undefined or null"));if(typeof i!="string")return s(new Error("marked(): input parameter is of type "+Object.prototype.toString.call(i)+", string expected"));r.hooks&&(r.hooks.options=r,r.hooks.block=e);let a=r.hooks?r.hooks.provideLexer():e?xl.lex:xl.lexInline,c=r.hooks?r.hooks.provideParser():e?Fl.parse:Fl.parseInline;if(r.async)return Promise.resolve(r.hooks?r.hooks.preprocess(i):i).then(l=>a(l,r)).then(l=>r.hooks?r.hooks.processAllTokens(l):l).then(l=>r.walkTokens?Promise.all(this.walkTokens(l,r.walkTokens)).then(()=>l):l).then(l=>c(l,r)).then(l=>r.hooks?r.hooks.postprocess(l):l).catch(s);try{r.hooks&&(i=r.hooks.preprocess(i));let l=a(i,r);r.hooks&&(l=r.hooks.processAllTokens(l)),r.walkTokens&&this.walkTokens(l,r.walkTokens);let I=c(l,r);return r.hooks&&(I=r.hooks.postprocess(I)),I}catch(l){return s(l)}}}onError(e,A){return i=>{if(i.message+=`
Please report this to https://github.com/markedjs/marked.`,e){let n="<p>An error occurred:</p><pre>"+Hg(i.message+"",!0)+"</pre>";return A?Promise.resolve(n):n}if(A)return Promise.reject(i);throw i}}},VC=new KG;function En(t,e){return VC.parse(t,e)}En.options=En.setOptions=function(t){return VC.setOptions(t),En.defaults=VC.defaults,McA(En.defaults),En};En.getDefaults=YG;En.defaults=ZC;En.use=function(...t){return VC.use(...t),En.defaults=VC.defaults,McA(En.defaults),En};En.walkTokens=function(t,e){return VC.walkTokens(t,e)};En.parseInline=VC.parseInline;En.Parser=Fl;En.parser=Fl.parse;En.Renderer=Og;En.TextRenderer=If;En.Lexer=xl;En.lexer=xl.lex;En.Tokenizer=fh;En.Hooks=uh;En.parse=En;var fye=En.options,mye=En.setOptions,pye=En.use,wye=En.walkTokens,Dye=En.parseInline;var yye=Fl.parse,vye=xl.lex;var MOA=["*"],kOA="Copy",SOA="Copied",ROA=(()=>{class t{constructor(){this._buttonClick$=new HA,this.copied$=this._buttonClick$.pipe(no(()=>ho(ve(!0),AI(3e3).pipe(dd(!1)))),Zc(),$g(1)),this.copiedText$=this.copied$.pipe(Qo(!1),Je(A=>A?SOA:kOA))}onCopyToClipboardClick(){this._buttonClick$.next()}static{this.\u0275fac=function(i){return new(i||t)}}static{this.\u0275cmp=YA({type:t,selectors:[["markdown-clipboard"]],decls:4,vars:7,consts:[[1,"markdown-clipboard-button",3,"click"]],template:function(i,n){i&1&&(S(0,"button",0),Ta(1,"async"),mA("click",function(){return n.onCopyToClipboardClick()}),tA(2),Ta(3,"async"),R()),i&2&&(ue("copied",w2(1,3,n.copied$)),_(2),Mt(w2(3,5,n.copiedText$)))},dependencies:[bQ],encapsulation:2,changeDetection:0})}}return t})(),LOA=new BA("CLIPBOARD_OPTIONS");var qG=function(t){return t.CommandLine="command-line",t.LineHighlight="line-highlight",t.LineNumbers="line-numbers",t}(qG||{}),KcA=new BA("MARKED_EXTENSIONS"),xOA=new BA("MARKED_OPTIONS"),FOA=new BA("MERMAID_OPTIONS"),NOA="[ngx-markdown] When using the `emoji` attribute you *have to* include Emoji-Toolkit files to `angular.json` or use imports. See README for more information",_OA="[ngx-markdown] When using the `katex` attribute you *have to* include KaTeX files to `angular.json` or use imports. See README for more information",GOA="[ngx-markdown] When using the `mermaid` attribute you *have to* include Mermaid files to `angular.json` or use imports. See README for more information",UOA="[ngx-markdown] When using the `clipboard` attribute you *have to* include Clipboard files to `angular.json` or use imports. See README for more information",KOA="[ngx-markdown] When using the `clipboard` attribute you *have to* provide the `viewContainerRef` parameter to `MarkdownService.render()` function",YOA="[ngx-markdown] When using the `src` attribute you *have to* pass the `HttpClient` as a parameter of the `forRoot` method. See README for more information",YcA=new BA("SECURITY_CONTEXT");var JcA=(()=>{class t{get options(){return this._options}set options(A){this._options=nA(nA({},this.DEFAULT_MARKED_OPTIONS),A)}get renderer(){return this.options.renderer}set renderer(A){this.options.renderer=A}constructor(A,i,n,o,r,s,a,c){this.clipboardOptions=A,this.extensions=i,this.mermaidOptions=o,this.platform=r,this.securityContext=s,this.http=a,this.sanitizer=c,this.DEFAULT_MARKED_OPTIONS={renderer:new Og},this.DEFAULT_KATEX_OPTIONS={delimiters:[{left:"$$",right:"$$",display:!0},{left:"$",right:"$",display:!1},{left:"\\(",right:"\\)",display:!1},{left:"\\begin{equation}",right:"\\end{equation}",display:!0},{left:"\\begin{align}",right:"\\end{align}",display:!0},{left:"\\begin{alignat}",right:"\\end{alignat}",display:!0},{left:"\\begin{gather}",right:"\\end{gather}",display:!0},{left:"\\begin{CD}",right:"\\end{CD}",display:!0},{left:"\\[",right:"\\]",display:!0}]},this.DEFAULT_MERMAID_OPTIONS={startOnLoad:!1},this.DEFAULT_CLIPBOARD_OPTIONS={buttonComponent:void 0},this.DEFAULT_PARSE_OPTIONS={decodeHtml:!1,inline:!1,emoji:!1,mermaid:!1,markedOptions:void 0,disableSanitizer:!1},this.DEFAULT_RENDER_OPTIONS={clipboard:!1,clipboardOptions:void 0,katex:!1,katexOptions:void 0,mermaid:!1,mermaidOptions:void 0},this._reload$=new HA,this.reload$=this._reload$.asObservable(),this.options=n}parse(A,i=this.DEFAULT_PARSE_OPTIONS){let{decodeHtml:n,inline:o,emoji:r,mermaid:s,disableSanitizer:a}=i,c=nA(nA({},this.options),i.markedOptions),l=c.renderer||this.renderer||new Og;this.extensions&&(this.renderer=this.extendsRendererForExtensions(l)),s&&(this.renderer=this.extendsRendererForMermaid(l));let I=this.trimIndentation(A),C=n?this.decodeHtml(I):I,d=r?this.parseEmoji(C):C,B=this.parseMarked(d,c,o);return(a?B:this.sanitizer.sanitize(this.securityContext,B))||""}render(A,i=this.DEFAULT_RENDER_OPTIONS,n){let{clipboard:o,clipboardOptions:r,katex:s,katexOptions:a,mermaid:c,mermaidOptions:l}=i;s&&this.renderKatex(A,nA(nA({},this.DEFAULT_KATEX_OPTIONS),a)),c&&this.renderMermaid(A,nA(nA(nA({},this.DEFAULT_MERMAID_OPTIONS),this.mermaidOptions),l)),o&&this.renderClipboard(A,n,nA(nA(nA({},this.DEFAULT_CLIPBOARD_OPTIONS),this.clipboardOptions),r)),this.highlight(A)}reload(){this._reload$.next()}getSource(A){if(!this.http)throw new Error(YOA);return this.http.get(A,{responseType:"text"}).pipe(Je(i=>this.handleExtension(A,i)))}highlight(A){if(!$l(this.platform)||typeof Prism>"u"||typeof Prism.highlightAllUnder>"u")return;A||(A=document);let i=A.querySelectorAll('pre code:not([class*="language-"])');Array.prototype.forEach.call(i,n=>n.classList.add("language-none")),Prism.highlightAllUnder(A)}decodeHtml(A){if(!$l(this.platform))return A;let i=document.createElement("textarea");return i.innerHTML=A,i.value}extendsRendererForExtensions(A){let i=A;return i.\u0275NgxMarkdownRendererExtendedForExtensions===!0||(this.extensions?.length>0&&En.use(...this.extensions),i.\u0275NgxMarkdownRendererExtendedForExtensions=!0),A}extendsRendererForMermaid(A){let i=A;if(i.\u0275NgxMarkdownRendererExtendedForMermaid===!0)return A;let n=A.code;return A.code=o=>o.lang==="mermaid"?`<div class="mermaid">${o.text}</div>`:n(o),i.\u0275NgxMarkdownRendererExtendedForMermaid=!0,A}handleExtension(A,i){let n=A.lastIndexOf("://"),o=n>-1?A.substring(n+4):A,r=o.lastIndexOf("/"),s=r>-1?o.substring(r+1).split("?")[0]:"",a=s.lastIndexOf("."),c=a>-1?s.substring(a+1):"";return c&&c!=="md"?"```"+c+`
`+i+"\n```":i}parseMarked(A,i,n=!1){if(i.renderer){let o=nA({},i.renderer);delete o.\u0275NgxMarkdownRendererExtendedForExtensions,delete o.\u0275NgxMarkdownRendererExtendedForMermaid,delete i.renderer,En.use({renderer:o})}return n?En.parseInline(A,i):En.parse(A,i)}parseEmoji(A){if(!$l(this.platform))return A;if(typeof joypixels>"u"||typeof joypixels.shortnameToUnicode>"u")throw new Error(NOA);return joypixels.shortnameToUnicode(A)}renderKatex(A,i){if($l(this.platform)){if(typeof katex>"u"||typeof renderMathInElement>"u")throw new Error(_OA);renderMathInElement(A,i)}}renderClipboard(A,i,n){if(!$l(this.platform))return;if(typeof ClipboardJS>"u")throw new Error(UOA);if(!i)throw new Error(KOA);let{buttonComponent:o,buttonTemplate:r}=n,s=A.querySelectorAll("pre");for(let a=0;a<s.length;a++){let c=s.item(a),l=document.createElement("div");l.style.position="relative",c.parentNode.insertBefore(l,c),l.appendChild(c);let I=document.createElement("div");I.classList.add("markdown-clipboard-toolbar"),I.style.position="absolute",I.style.top=".5em",I.style.right=".5em",I.style.zIndex="1",l.insertAdjacentElement("beforeend",I),l.onmouseenter=()=>I.classList.add("hover"),l.onmouseleave=()=>I.classList.remove("hover");let C;if(o){let B=i.createComponent(o);C=B.hostView,B.changeDetectorRef.markForCheck()}else if(r)C=i.createEmbeddedView(r);else{let B=i.createComponent(ROA);C=B.hostView,B.changeDetectorRef.markForCheck()}let d;C.rootNodes.forEach(B=>{I.appendChild(B),d=new ClipboardJS(B,{text:()=>c.innerText})}),C.onDestroy(()=>d.destroy())}}renderMermaid(A,i=this.DEFAULT_MERMAID_OPTIONS){if(!$l(this.platform))return;if(typeof mermaid>"u"||typeof mermaid.initialize>"u")throw new Error(GOA);let n=A.querySelectorAll(".mermaid");n.length!==0&&(mermaid.initialize(i),mermaid.run({nodes:n}))}trimIndentation(A){if(!A)return"";let i;return A.split(`
`).map(n=>{let o=i;return n.length>0&&(o=isNaN(o)?n.search(/\S|$/):Math.min(n.search(/\S|$/),o)),isNaN(i)&&(i=o),o?n.substring(o):n}).join(`
`)}static{this.\u0275fac=function(i){return new(i||t)(he(LOA,8),he(KcA,8),he(xOA,8),he(FOA,8),he(hc),he(YcA),he(Bs,8),he(il))}}static{this.\u0275prov=SA({token:t,factory:t.\u0275fac})}}return t})(),TcA=(()=>{class t{get disableSanitizer(){return this._disableSanitizer}set disableSanitizer(A){this._disableSanitizer=this.coerceBooleanProperty(A)}get inline(){return this._inline}set inline(A){this._inline=this.coerceBooleanProperty(A)}get clipboard(){return this._clipboard}set clipboard(A){this._clipboard=this.coerceBooleanProperty(A)}get emoji(){return this._emoji}set emoji(A){this._emoji=this.coerceBooleanProperty(A)}get katex(){return this._katex}set katex(A){this._katex=this.coerceBooleanProperty(A)}get mermaid(){return this._mermaid}set mermaid(A){this._mermaid=this.coerceBooleanProperty(A)}get lineHighlight(){return this._lineHighlight}set lineHighlight(A){this._lineHighlight=this.coerceBooleanProperty(A)}get lineNumbers(){return this._lineNumbers}set lineNumbers(A){this._lineNumbers=this.coerceBooleanProperty(A)}get commandLine(){return this._commandLine}set commandLine(A){this._commandLine=this.coerceBooleanProperty(A)}constructor(A,i,n){this.element=A,this.markdownService=i,this.viewContainerRef=n,this.error=new XA,this.load=new XA,this.ready=new XA,this._clipboard=!1,this._commandLine=!1,this._disableSanitizer=!1,this._emoji=!1,this._inline=!1,this._katex=!1,this._lineHighlight=!1,this._lineNumbers=!1,this._mermaid=!1,this.destroyed$=new HA}ngOnChanges(){this.loadContent()}loadContent(){if(this.data!=null){this.handleData();return}if(this.src!=null){this.handleSrc();return}}ngAfterViewInit(){!this.data&&!this.src&&this.handleTransclusion(),this.markdownService.reload$.pipe(wt(this.destroyed$)).subscribe(()=>this.loadContent())}ngOnDestroy(){this.destroyed$.next(),this.destroyed$.complete()}render(A,i=!1){return _n(this,null,function*(){let n={decodeHtml:i,inline:this.inline,emoji:this.emoji,mermaid:this.mermaid,disableSanitizer:this.disableSanitizer},o={clipboard:this.clipboard,clipboardOptions:this.getClipboardOptions(),katex:this.katex,katexOptions:this.katexOptions,mermaid:this.mermaid,mermaidOptions:this.mermaidOptions},r=yield this.markdownService.parse(A,n);this.element.nativeElement.innerHTML=r,this.handlePlugins(),this.markdownService.render(this.element.nativeElement,o,this.viewContainerRef),this.ready.emit()})}coerceBooleanProperty(A){return A!=null&&`${String(A)}`!="false"}getClipboardOptions(){if(this.clipboardButtonComponent||this.clipboardButtonTemplate)return{buttonComponent:this.clipboardButtonComponent,buttonTemplate:this.clipboardButtonTemplate}}handleData(){this.render(this.data)}handleSrc(){this.markdownService.getSource(this.src).subscribe({next:A=>{this.render(A).then(()=>{this.load.emit(A)})},error:A=>this.error.emit(A)})}handleTransclusion(){this.render(this.element.nativeElement.innerHTML,!0)}handlePlugins(){this.commandLine&&(this.setPluginClass(this.element.nativeElement,qG.CommandLine),this.setPluginOptions(this.element.nativeElement,{dataFilterOutput:this.filterOutput,dataHost:this.host,dataPrompt:this.prompt,dataOutput:this.output,dataUser:this.user})),this.lineHighlight&&this.setPluginOptions(this.element.nativeElement,{dataLine:this.line,dataLineOffset:this.lineOffset}),this.lineNumbers&&(this.setPluginClass(this.element.nativeElement,qG.LineNumbers),this.setPluginOptions(this.element.nativeElement,{dataStart:this.start}))}setPluginClass(A,i){let n=A.querySelectorAll("pre");for(let o=0;o<n.length;o++){let r=i instanceof Array?i:[i];n.item(o).classList.add(...r)}}setPluginOptions(A,i){let n=A.querySelectorAll("pre");for(let o=0;o<n.length;o++)Object.keys(i).forEach(r=>{let s=i[r];if(s){let a=this.toLispCase(r);n.item(o).setAttribute(a,s.toString())}})}toLispCase(A){let i=A.match(/([A-Z])/g);if(!i)return A;let n=A.toString();for(let o=0,r=i.length;o<r;o++)n=n.replace(new RegExp(i[o]),"-"+i[o].toLowerCase());return n.slice(0,1)==="-"&&(n=n.slice(1)),n}static{this.\u0275fac=function(i){return new(i||t)(zA(te),zA(JcA),zA(Un))}}static{this.\u0275cmp=YA({type:t,selectors:[["markdown"],["","markdown",""]],inputs:{data:"data",src:"src",disableSanitizer:"disableSanitizer",inline:"inline",clipboard:"clipboard",clipboardButtonComponent:"clipboardButtonComponent",clipboardButtonTemplate:"clipboardButtonTemplate",emoji:"emoji",katex:"katex",katexOptions:"katexOptions",mermaid:"mermaid",mermaidOptions:"mermaidOptions",lineHighlight:"lineHighlight",line:"line",lineOffset:"lineOffset",lineNumbers:"lineNumbers",start:"start",commandLine:"commandLine",filterOutput:"filterOutput",host:"host",prompt:"prompt",output:"output",user:"user"},outputs:{error:"error",load:"load",ready:"ready"},features:[Kt],ngContentSelectors:MOA,decls:1,vars:0,template:function(i,n){i&1&&(Yt(),xe(0))},encapsulation:2})}}return t})();function JOA(t){return[JcA,t?.loader??[],t?.clipboardOptions??[],t?.markedOptions??[],t?.mermaidOptions??[],zOA(t?.markedExtensions)??[],{provide:YcA,useValue:t?.sanitize??Kr.HTML}]}function TOA(t){return t!=null&&t.provide!=null}function zOA(t){if(t)return t.reduce((e,A)=>{let i=TOA(A)?Ne(nA({},A),{multi:!0}):{provide:KcA,useValue:A,multi:!0};return[...e,i]},[])}var zcA=(()=>{class t{static forRoot(A){return{ngModule:t,providers:[JOA(A)]}}static forChild(){return{ngModule:t}}static{this.\u0275fac=function(i){return new(i||t)}}static{this.\u0275mod=ge({type:t})}static{this.\u0275inj=le({imports:[g0]})}}return t})();var OOA=["switch"],POA=["*"];function jOA(t,e){t&1&&(S(0,"span",10),hr(),S(1,"svg",12),UA(2,"path",13),R(),S(3,"svg",14),UA(4,"path",15),R()())}var qOA=new BA("mat-slide-toggle-default-options",{providedIn:"root",factory:()=>({disableToggleValue:!1,hideIcon:!1,disabledInteractive:!1})}),VOA={provide:uc,useExisting:nr(()=>Xy),multi:!0},Wy=class{source;checked;constructor(e,A){this.source=e,this.checked=A}},Xy=(()=>{class t{_elementRef=m(te);_focusMonitor=m(Jr);_changeDetectorRef=m(lt);defaults=m(qOA);_onChange=A=>{};_onTouched=()=>{};_validatorOnChange=()=>{};_uniqueId;_checked=!1;_createChangeEvent(A){return new Wy(this,A)}_labelId;get buttonId(){return`${this.id||this._uniqueId}-button`}_switchElement;focus(){this._switchElement.nativeElement.focus()}_noopAnimations;_focused;name=null;id;labelPosition="after";ariaLabel=null;ariaLabelledby=null;ariaDescribedby;required;color;disabled=!1;disableRipple=!1;tabIndex=0;get checked(){return this._checked}set checked(A){this._checked=A,this._changeDetectorRef.markForCheck()}hideIcon;disabledInteractive;change=new XA;toggleChange=new XA;get inputId(){return`${this.id||this._uniqueId}-input`}constructor(){m(Ln).load(Qr);let A=m(new Er("tabindex"),{optional:!0}),i=this.defaults,n=m(mi,{optional:!0});this.tabIndex=A==null?0:parseInt(A)||0,this.color=i.color||"accent",this._noopAnimations=n==="NoopAnimations",this.id=this._uniqueId=m($i).getId("mat-mdc-slide-toggle-"),this.hideIcon=i.hideIcon??!1,this.disabledInteractive=i.disabledInteractive??!1,this._labelId=this._uniqueId+"-label"}ngAfterContentInit(){this._focusMonitor.monitor(this._elementRef,!0).subscribe(A=>{A==="keyboard"||A==="program"?(this._focused=!0,this._changeDetectorRef.markForCheck()):A||Promise.resolve().then(()=>{this._focused=!1,this._onTouched(),this._changeDetectorRef.markForCheck()})})}ngOnChanges(A){A.required&&this._validatorOnChange()}ngOnDestroy(){this._focusMonitor.stopMonitoring(this._elementRef)}writeValue(A){this.checked=!!A}registerOnChange(A){this._onChange=A}registerOnTouched(A){this._onTouched=A}validate(A){return this.required&&A.value!==!0?{required:!0}:null}registerOnValidatorChange(A){this._validatorOnChange=A}setDisabledState(A){this.disabled=A,this._changeDetectorRef.markForCheck()}toggle(){this.checked=!this.checked,this._onChange(this.checked)}_emitChangeEvent(){this._onChange(this.checked),this.change.emit(this._createChangeEvent(this.checked))}_handleClick(){this.disabled||(this.toggleChange.emit(),this.defaults.disableToggleValue||(this.checked=!this.checked,this._onChange(this.checked),this.change.emit(new Wy(this,this.checked))))}_getAriaLabelledBy(){return this.ariaLabelledby?this.ariaLabelledby:this.ariaLabel?null:this._labelId}static \u0275fac=function(i){return new(i||t)};static \u0275cmp=YA({type:t,selectors:[["mat-slide-toggle"]],viewQuery:function(i,n){if(i&1&&Ge(OOA,5),i&2){let o;$A(o=Ae())&&(n._switchElement=o.first)}},hostAttrs:[1,"mat-mdc-slide-toggle"],hostVars:13,hostBindings:function(i,n){i&2&&(Fs("id",n.id),_e("tabindex",null)("aria-label",null)("name",null)("aria-labelledby",null),vo(n.color?"mat-"+n.color:""),ue("mat-mdc-slide-toggle-focused",n._focused)("mat-mdc-slide-toggle-checked",n.checked)("_mat-animation-noopable",n._noopAnimations))},inputs:{name:"name",id:"id",labelPosition:"labelPosition",ariaLabel:[0,"aria-label","ariaLabel"],ariaLabelledby:[0,"aria-labelledby","ariaLabelledby"],ariaDescribedby:[0,"aria-describedby","ariaDescribedby"],required:[2,"required","required",ae],color:"color",disabled:[2,"disabled","disabled",ae],disableRipple:[2,"disableRipple","disableRipple",ae],tabIndex:[2,"tabIndex","tabIndex",A=>A==null?0:Mi(A)],checked:[2,"checked","checked",ae],hideIcon:[2,"hideIcon","hideIcon",ae],disabledInteractive:[2,"disabledInteractive","disabledInteractive",ae]},outputs:{change:"change",toggleChange:"toggleChange"},exportAs:["matSlideToggle"],features:[ct([VOA,{provide:d0,useExisting:t,multi:!0}]),Kt],ngContentSelectors:POA,decls:13,vars:27,consts:[["switch",""],["mat-internal-form-field","",3,"labelPosition"],["role","switch","type","button",1,"mdc-switch",3,"click","tabIndex","disabled"],[1,"mdc-switch__track"],[1,"mdc-switch__handle-track"],[1,"mdc-switch__handle"],[1,"mdc-switch__shadow"],[1,"mdc-elevation-overlay"],[1,"mdc-switch__ripple"],["mat-ripple","",1,"mat-mdc-slide-toggle-ripple","mat-focus-indicator",3,"matRippleTrigger","matRippleDisabled","matRippleCentered"],[1,"mdc-switch__icons"],[1,"mdc-label",3,"click","for"],["viewBox","0 0 24 24","aria-hidden","true",1,"mdc-switch__icon","mdc-switch__icon--on"],["d","M19.69,5.23L8.96,15.96l-4.23-4.23L2.96,13.5l6,6L21.46,7L19.69,5.23z"],["viewBox","0 0 24 24","aria-hidden","true",1,"mdc-switch__icon","mdc-switch__icon--off"],["d","M20 13H4v-2h16v2z"]],template:function(i,n){if(i&1){let o=De();Yt(),S(0,"div",1)(1,"button",2,0),mA("click",function(){return LA(o),xA(n._handleClick())}),UA(3,"span",3),S(4,"span",4)(5,"span",5)(6,"span",6),UA(7,"span",7),R(),S(8,"span",8),UA(9,"span",9),R(),NA(10,jOA,5,0,"span",10),R()()(),S(11,"label",11),mA("click",function(s){return LA(o),xA(s.stopPropagation())}),xe(12),R()()}if(i&2){let o=or(2);vA("labelPosition",n.labelPosition),_(),ue("mdc-switch--selected",n.checked)("mdc-switch--unselected",!n.checked)("mdc-switch--checked",n.checked)("mdc-switch--disabled",n.disabled)("mat-mdc-slide-toggle-disabled-interactive",n.disabledInteractive),vA("tabIndex",n.disabled&&!n.disabledInteractive?-1:n.tabIndex)("disabled",n.disabled&&!n.disabledInteractive),_e("id",n.buttonId)("name",n.name)("aria-label",n.ariaLabel)("aria-labelledby",n._getAriaLabelledBy())("aria-describedby",n.ariaDescribedby)("aria-required",n.required||null)("aria-checked",n.checked)("aria-disabled",n.disabled&&n.disabledInteractive?"true":null),_(8),vA("matRippleTrigger",o)("matRippleDisabled",n.disableRipple||n.disabled)("matRippleCentered",!0),_(),FA(n.hideIcon?-1:10),_(),vA("for",n.buttonId),_e("id",n._labelId)}},dependencies:[Gs,BB],styles:['.mdc-switch{align-items:center;background:none;border:none;cursor:pointer;display:inline-flex;flex-shrink:0;margin:0;outline:none;overflow:visible;padding:0;position:relative;width:var(--mdc-switch-track-width, 52px)}.mdc-switch.mdc-switch--disabled{cursor:default;pointer-events:none}.mdc-switch.mat-mdc-slide-toggle-disabled-interactive{pointer-events:auto}.mdc-switch__track{overflow:hidden;position:relative;width:100%;height:var(--mdc-switch-track-height, 32px);border-radius:var(--mdc-switch-track-shape, var(--mat-sys-corner-full))}.mdc-switch--disabled.mdc-switch .mdc-switch__track{opacity:var(--mdc-switch-disabled-track-opacity, 0.12)}.mdc-switch__track::before,.mdc-switch__track::after{border:1px solid rgba(0,0,0,0);border-radius:inherit;box-sizing:border-box;content:"";height:100%;left:0;position:absolute;width:100%;border-width:var(--mat-switch-track-outline-width, 2px);border-color:var(--mat-switch-track-outline-color, var(--mat-sys-outline))}.mdc-switch--selected .mdc-switch__track::before,.mdc-switch--selected .mdc-switch__track::after{border-width:var(--mat-switch-selected-track-outline-width, 2px);border-color:var(--mat-switch-selected-track-outline-color, transparent)}.mdc-switch--disabled .mdc-switch__track::before,.mdc-switch--disabled .mdc-switch__track::after{border-width:var(--mat-switch-disabled-unselected-track-outline-width, 2px);border-color:var(--mat-switch-disabled-unselected-track-outline-color, var(--mat-sys-on-surface))}@media(forced-colors: active){.mdc-switch__track{border-color:currentColor}}.mdc-switch__track::before{transition:transform 75ms 0ms cubic-bezier(0, 0, 0.2, 1);transform:translateX(0);background:var(--mdc-switch-unselected-track-color, var(--mat-sys-surface-variant))}.mdc-switch--selected .mdc-switch__track::before{transition:transform 75ms 0ms cubic-bezier(0.4, 0, 0.6, 1);transform:translateX(100%)}[dir=rtl] .mdc-switch--selected .mdc-switch--selected .mdc-switch__track::before{transform:translateX(-100%)}.mdc-switch--selected .mdc-switch__track::before{opacity:var(--mat-switch-hidden-track-opacity, 0);transition:var(--mat-switch-hidden-track-transition, opacity 75ms)}.mdc-switch--unselected .mdc-switch__track::before{opacity:var(--mat-switch-visible-track-opacity, 1);transition:var(--mat-switch-visible-track-transition, opacity 75ms)}.mdc-switch:enabled:hover:not(:focus):not(:active) .mdc-switch__track::before{background:var(--mdc-switch-unselected-hover-track-color, var(--mat-sys-surface-variant))}.mdc-switch:enabled:focus:not(:active) .mdc-switch__track::before{background:var(--mdc-switch-unselected-focus-track-color, var(--mat-sys-surface-variant))}.mdc-switch:enabled:active .mdc-switch__track::before{background:var(--mdc-switch-unselected-pressed-track-color, var(--mat-sys-surface-variant))}.mat-mdc-slide-toggle-disabled-interactive.mdc-switch--disabled:hover:not(:focus):not(:active) .mdc-switch__track::before,.mat-mdc-slide-toggle-disabled-interactive.mdc-switch--disabled:focus:not(:active) .mdc-switch__track::before,.mat-mdc-slide-toggle-disabled-interactive.mdc-switch--disabled:active .mdc-switch__track::before,.mdc-switch.mdc-switch--disabled .mdc-switch__track::before{background:var(--mdc-switch-disabled-unselected-track-color, var(--mat-sys-surface-variant))}.mdc-switch__track::after{transform:translateX(-100%);background:var(--mdc-switch-selected-track-color, var(--mat-sys-primary))}[dir=rtl] .mdc-switch__track::after{transform:translateX(100%)}.mdc-switch--selected .mdc-switch__track::after{transform:translateX(0)}.mdc-switch--selected .mdc-switch__track::after{opacity:var(--mat-switch-visible-track-opacity, 1);transition:var(--mat-switch-visible-track-transition, opacity 75ms)}.mdc-switch--unselected .mdc-switch__track::after{opacity:var(--mat-switch-hidden-track-opacity, 0);transition:var(--mat-switch-hidden-track-transition, opacity 75ms)}.mdc-switch:enabled:hover:not(:focus):not(:active) .mdc-switch__track::after{background:var(--mdc-switch-selected-hover-track-color, var(--mat-sys-primary))}.mdc-switch:enabled:focus:not(:active) .mdc-switch__track::after{background:var(--mdc-switch-selected-focus-track-color, var(--mat-sys-primary))}.mdc-switch:enabled:active .mdc-switch__track::after{background:var(--mdc-switch-selected-pressed-track-color, var(--mat-sys-primary))}.mat-mdc-slide-toggle-disabled-interactive.mdc-switch--disabled:hover:not(:focus):not(:active) .mdc-switch__track::after,.mat-mdc-slide-toggle-disabled-interactive.mdc-switch--disabled:focus:not(:active) .mdc-switch__track::after,.mat-mdc-slide-toggle-disabled-interactive.mdc-switch--disabled:active .mdc-switch__track::after,.mdc-switch.mdc-switch--disabled .mdc-switch__track::after{background:var(--mdc-switch-disabled-selected-track-color, var(--mat-sys-on-surface))}.mdc-switch__handle-track{height:100%;pointer-events:none;position:absolute;top:0;transition:transform 75ms 0ms cubic-bezier(0.4, 0, 0.2, 1);left:0;right:auto;transform:translateX(0);width:calc(100% - var(--mdc-switch-handle-width))}[dir=rtl] .mdc-switch__handle-track{left:auto;right:0}.mdc-switch--selected .mdc-switch__handle-track{transform:translateX(100%)}[dir=rtl] .mdc-switch--selected .mdc-switch__handle-track{transform:translateX(-100%)}.mdc-switch__handle{display:flex;pointer-events:auto;position:absolute;top:50%;transform:translateY(-50%);left:0;right:auto;transition:width 75ms cubic-bezier(0.4, 0, 0.2, 1),height 75ms cubic-bezier(0.4, 0, 0.2, 1),margin 75ms cubic-bezier(0.4, 0, 0.2, 1);width:var(--mdc-switch-handle-width);height:var(--mdc-switch-handle-height);border-radius:var(--mdc-switch-handle-shape, var(--mat-sys-corner-full))}[dir=rtl] .mdc-switch__handle{left:auto;right:0}.mat-mdc-slide-toggle .mdc-switch--unselected .mdc-switch__handle{width:var(--mat-switch-unselected-handle-size, 16px);height:var(--mat-switch-unselected-handle-size, 16px);margin:var(--mat-switch-unselected-handle-horizontal-margin, 0 8px)}.mat-mdc-slide-toggle .mdc-switch--unselected .mdc-switch__handle:has(.mdc-switch__icons){margin:var(--mat-switch-unselected-with-icon-handle-horizontal-margin, 0 4px)}.mat-mdc-slide-toggle .mdc-switch--selected .mdc-switch__handle{width:var(--mat-switch-selected-handle-size, 24px);height:var(--mat-switch-selected-handle-size, 24px);margin:var(--mat-switch-selected-handle-horizontal-margin, 0 24px)}.mat-mdc-slide-toggle .mdc-switch--selected .mdc-switch__handle:has(.mdc-switch__icons){margin:var(--mat-switch-selected-with-icon-handle-horizontal-margin, 0 24px)}.mat-mdc-slide-toggle .mdc-switch__handle:has(.mdc-switch__icons){width:var(--mat-switch-with-icon-handle-size, 24px);height:var(--mat-switch-with-icon-handle-size, 24px)}.mat-mdc-slide-toggle .mdc-switch:active:not(.mdc-switch--disabled) .mdc-switch__handle{width:var(--mat-switch-pressed-handle-size, 28px);height:var(--mat-switch-pressed-handle-size, 28px)}.mat-mdc-slide-toggle .mdc-switch--selected:active:not(.mdc-switch--disabled) .mdc-switch__handle{margin:var(--mat-switch-selected-pressed-handle-horizontal-margin, 0 22px)}.mat-mdc-slide-toggle .mdc-switch--unselected:active:not(.mdc-switch--disabled) .mdc-switch__handle{margin:var(--mat-switch-unselected-pressed-handle-horizontal-margin, 0 2px)}.mdc-switch--disabled.mdc-switch--selected .mdc-switch__handle::after{opacity:var(--mat-switch-disabled-selected-handle-opacity, 1)}.mdc-switch--disabled.mdc-switch--unselected .mdc-switch__handle::after{opacity:var(--mat-switch-disabled-unselected-handle-opacity, 0.38)}.mdc-switch__handle::before,.mdc-switch__handle::after{border:1px solid rgba(0,0,0,0);border-radius:inherit;box-sizing:border-box;content:"";width:100%;height:100%;left:0;position:absolute;top:0;transition:background-color 75ms 0ms cubic-bezier(0.4, 0, 0.2, 1),border-color 75ms 0ms cubic-bezier(0.4, 0, 0.2, 1);z-index:-1}@media(forced-colors: active){.mdc-switch__handle::before,.mdc-switch__handle::after{border-color:currentColor}}.mdc-switch--selected:enabled .mdc-switch__handle::after{background:var(--mdc-switch-selected-handle-color, var(--mat-sys-on-primary))}.mdc-switch--selected:enabled:hover:not(:focus):not(:active) .mdc-switch__handle::after{background:var(--mdc-switch-selected-hover-handle-color, var(--mat-sys-primary-container))}.mdc-switch--selected:enabled:focus:not(:active) .mdc-switch__handle::after{background:var(--mdc-switch-selected-focus-handle-color, var(--mat-sys-primary-container))}.mdc-switch--selected:enabled:active .mdc-switch__handle::after{background:var(--mdc-switch-selected-pressed-handle-color, var(--mat-sys-primary-container))}.mat-mdc-slide-toggle-disabled-interactive.mdc-switch--disabled.mdc-switch--selected:hover:not(:focus):not(:active) .mdc-switch__handle::after,.mat-mdc-slide-toggle-disabled-interactive.mdc-switch--disabled.mdc-switch--selected:focus:not(:active) .mdc-switch__handle::after,.mat-mdc-slide-toggle-disabled-interactive.mdc-switch--disabled.mdc-switch--selected:active .mdc-switch__handle::after,.mdc-switch--selected.mdc-switch--disabled .mdc-switch__handle::after{background:var(--mdc-switch-disabled-selected-handle-color, var(--mat-sys-surface))}.mdc-switch--unselected:enabled .mdc-switch__handle::after{background:var(--mdc-switch-unselected-handle-color, var(--mat-sys-outline))}.mdc-switch--unselected:enabled:hover:not(:focus):not(:active) .mdc-switch__handle::after{background:var(--mdc-switch-unselected-hover-handle-color, var(--mat-sys-on-surface-variant))}.mdc-switch--unselected:enabled:focus:not(:active) .mdc-switch__handle::after{background:var(--mdc-switch-unselected-focus-handle-color, var(--mat-sys-on-surface-variant))}.mdc-switch--unselected:enabled:active .mdc-switch__handle::after{background:var(--mdc-switch-unselected-pressed-handle-color, var(--mat-sys-on-surface-variant))}.mdc-switch--unselected.mdc-switch--disabled .mdc-switch__handle::after{background:var(--mdc-switch-disabled-unselected-handle-color, var(--mat-sys-on-surface))}.mdc-switch__handle::before{background:var(--mdc-switch-handle-surface-color)}.mdc-switch__shadow{border-radius:inherit;bottom:0;left:0;position:absolute;right:0;top:0}.mdc-switch:enabled .mdc-switch__shadow{box-shadow:var(--mdc-switch-handle-elevation-shadow)}.mat-mdc-slide-toggle-disabled-interactive.mdc-switch--disabled:hover:not(:focus):not(:active) .mdc-switch__shadow,.mat-mdc-slide-toggle-disabled-interactive.mdc-switch--disabled:focus:not(:active) .mdc-switch__shadow,.mat-mdc-slide-toggle-disabled-interactive.mdc-switch--disabled:active .mdc-switch__shadow,.mdc-switch.mdc-switch--disabled .mdc-switch__shadow{box-shadow:var(--mdc-switch-disabled-handle-elevation-shadow)}.mdc-switch__ripple{left:50%;position:absolute;top:50%;transform:translate(-50%, -50%);z-index:-1;width:var(--mdc-switch-state-layer-size, 40px);height:var(--mdc-switch-state-layer-size, 40px)}.mdc-switch__ripple::after{content:"";opacity:0}.mdc-switch--disabled .mdc-switch__ripple::after{display:none}.mat-mdc-slide-toggle-disabled-interactive .mdc-switch__ripple::after{display:block}.mdc-switch:hover .mdc-switch__ripple::after{opacity:.04;transition:75ms opacity cubic-bezier(0, 0, 0.2, 1)}.mat-mdc-slide-toggle.mat-mdc-slide-toggle-focused .mdc-switch .mdc-switch__ripple::after{opacity:.12}.mat-mdc-slide-toggle-disabled-interactive.mdc-switch--disabled:enabled:focus .mdc-switch__ripple::after,.mat-mdc-slide-toggle-disabled-interactive.mdc-switch--disabled:enabled:active .mdc-switch__ripple::after,.mat-mdc-slide-toggle-disabled-interactive.mdc-switch--disabled:enabled:hover:not(:focus) .mdc-switch__ripple::after,.mdc-switch--unselected:enabled:hover:not(:focus) .mdc-switch__ripple::after{background:var(--mdc-switch-unselected-hover-state-layer-color, var(--mat-sys-on-surface))}.mdc-switch--unselected:enabled:focus .mdc-switch__ripple::after{background:var(--mdc-switch-unselected-focus-state-layer-color, var(--mat-sys-on-surface))}.mdc-switch--unselected:enabled:active .mdc-switch__ripple::after{background:var(--mdc-switch-unselected-pressed-state-layer-color, var(--mat-sys-on-surface));opacity:var(--mdc-switch-unselected-pressed-state-layer-opacity, var(--mat-sys-pressed-state-layer-opacity));transition:opacity 75ms linear}.mdc-switch--selected:enabled:hover:not(:focus) .mdc-switch__ripple::after{background:var(--mdc-switch-selected-hover-state-layer-color, var(--mat-sys-primary))}.mdc-switch--selected:enabled:focus .mdc-switch__ripple::after{background:var(--mdc-switch-selected-focus-state-layer-color, var(--mat-sys-primary))}.mdc-switch--selected:enabled:active .mdc-switch__ripple::after{background:var(--mdc-switch-selected-pressed-state-layer-color, var(--mat-sys-primary));opacity:var(--mdc-switch-selected-pressed-state-layer-opacity, var(--mat-sys-pressed-state-layer-opacity));transition:opacity 75ms linear}.mdc-switch__icons{position:relative;height:100%;width:100%;z-index:1}.mdc-switch--disabled.mdc-switch--unselected .mdc-switch__icons{opacity:var(--mdc-switch-disabled-unselected-icon-opacity, 0.38)}.mdc-switch--disabled.mdc-switch--selected .mdc-switch__icons{opacity:var(--mdc-switch-disabled-selected-icon-opacity, 0.38)}.mdc-switch__icon{bottom:0;left:0;margin:auto;position:absolute;right:0;top:0;opacity:0;transition:opacity 30ms 0ms cubic-bezier(0.4, 0, 1, 1)}.mdc-switch--unselected .mdc-switch__icon{width:var(--mdc-switch-unselected-icon-size, 16px);height:var(--mdc-switch-unselected-icon-size, 16px);fill:var(--mdc-switch-unselected-icon-color, var(--mat-sys-surface-variant))}.mdc-switch--unselected.mdc-switch--disabled .mdc-switch__icon{fill:var(--mdc-switch-disabled-unselected-icon-color, var(--mat-sys-surface-variant))}.mdc-switch--selected .mdc-switch__icon{width:var(--mdc-switch-selected-icon-size, 16px);height:var(--mdc-switch-selected-icon-size, 16px);fill:var(--mdc-switch-selected-icon-color, var(--mat-sys-on-primary-container))}.mdc-switch--selected.mdc-switch--disabled .mdc-switch__icon{fill:var(--mdc-switch-disabled-selected-icon-color, var(--mat-sys-on-surface))}.mdc-switch--selected .mdc-switch__icon--on,.mdc-switch--unselected .mdc-switch__icon--off{opacity:1;transition:opacity 45ms 30ms cubic-bezier(0, 0, 0.2, 1)}.mat-mdc-slide-toggle{-webkit-user-select:none;user-select:none;display:inline-block;-webkit-tap-highlight-color:rgba(0,0,0,0);outline:0}.mat-mdc-slide-toggle .mat-mdc-slide-toggle-ripple,.mat-mdc-slide-toggle .mdc-switch__ripple::after{top:0;left:0;right:0;bottom:0;position:absolute;border-radius:50%;pointer-events:none}.mat-mdc-slide-toggle .mat-mdc-slide-toggle-ripple:not(:empty),.mat-mdc-slide-toggle .mdc-switch__ripple::after:not(:empty){transform:translateZ(0)}.mat-mdc-slide-toggle.mat-mdc-slide-toggle-focused .mat-focus-indicator::before{content:""}.mat-mdc-slide-toggle .mat-internal-form-field{color:var(--mat-switch-label-text-color, var(--mat-sys-on-surface));font-family:var(--mat-switch-label-text-font, var(--mat-sys-body-medium-font));line-height:var(--mat-switch-label-text-line-height, var(--mat-sys-body-medium-line-height));font-size:var(--mat-switch-label-text-size, var(--mat-sys-body-medium-size));letter-spacing:var(--mat-switch-label-text-tracking, var(--mat-sys-body-medium-tracking));font-weight:var(--mat-switch-label-text-weight, var(--mat-sys-body-medium-weight))}.mat-mdc-slide-toggle .mat-ripple-element{opacity:.12}.mat-mdc-slide-toggle .mat-focus-indicator::before{border-radius:50%}.mat-mdc-slide-toggle._mat-animation-noopable .mdc-switch__handle-track,.mat-mdc-slide-toggle._mat-animation-noopable .mdc-switch__icon,.mat-mdc-slide-toggle._mat-animation-noopable .mdc-switch__handle::before,.mat-mdc-slide-toggle._mat-animation-noopable .mdc-switch__handle::after,.mat-mdc-slide-toggle._mat-animation-noopable .mdc-switch__track::before,.mat-mdc-slide-toggle._mat-animation-noopable .mdc-switch__track::after{transition:none}.mat-mdc-slide-toggle .mdc-switch:enabled+.mdc-label{cursor:pointer}.mat-mdc-slide-toggle .mdc-switch--disabled+label{color:var(--mdc-switch-disabled-label-text-color)}'],encapsulation:2,changeDetection:0})}return t})();var HcA=(()=>{class t{static \u0275fac=function(i){return new(i||t)};static \u0275mod=ge({type:t});static \u0275inj=le({imports:[Xy,Ve,Ve]})}return t})();var df=class t{sessionState={};constructor(){}static \u0275fac=function(A){return new(A||t)};static \u0275cmp=YA({type:t,selectors:[["app-state-tab"]],inputs:{sessionState:"sessionState"},standalone:!1,decls:3,vars:1,consts:[[1,"state-wrapper"],[3,"json"]],template:function(A,i){A&1&&(S(0,"div",0)(1,"div"),UA(2,"ngx-json-viewer",1),R()()),A&2&&(_(2),vA("json",i.sessionState))},dependencies:[Qh],styles:[".state-wrapper[_ngcontent-%COMP%]{padding-left:25px;padding-right:25px;margin-top:16px}"]})};var Bf=class t{constructor(e,A){this.el=e;this.renderer=A;this.sideDrawerMaxWidth=window.innerWidth/2}sideDrawerMinWidth=310;sideDrawerMaxWidth;resizeHandle=null;resizingEvent={isResizing:!1,startingCursorX:0,startingWidth:0};ngAfterViewInit(){this.resizeHandle=document.getElementsByClassName("resize-handler")[0],this.renderer.listen(this.resizeHandle,"mousedown",e=>this.onResizeHandleMouseDown(e)),document.documentElement.style.setProperty("--side-drawer-width","570px"),this.renderer.setStyle(this.el.nativeElement,"width","var(--side-drawer-width)")}onResizeHandleMouseDown(e){this.resizingEvent={isResizing:!0,startingCursorX:e.clientX,startingWidth:this.sideDrawerWidth},e.preventDefault()}onMouseMove(e){if(!this.resizingEvent.isResizing)return;let A=e.clientX-this.resizingEvent.startingCursorX,i=this.resizingEvent.startingWidth+A;this.sideDrawerWidth=i,this.renderer.addClass(document.body,"resizing")}onMouseUp(){this.resizingEvent.isResizing=!1,this.renderer.removeClass(document.body,"resizing")}onResize(){this.sideDrawerMaxWidth=window.innerWidth/2,this.sideDrawerWidth=this.sideDrawerWidth}set sideDrawerWidth(e){let A=Math.min(Math.max(e,this.sideDrawerMinWidth),this.sideDrawerMaxWidth);document.body.style.setProperty("--side-drawer-width",`${A}px`)}get sideDrawerWidth(){let e=getComputedStyle(document.body).getPropertyValue("--side-drawer-width"),A=parseInt(e,10);return isNaN(A)?500:A}static \u0275fac=function(A){return new(A||t)(zA(te),zA(Gi))};static \u0275dir=OA({type:t,selectors:[["","appResizableDrawer",""]],hostBindings:function(A,i){A&1&&mA("mousemove",function(o){return i.onMouseMove(o)},!1,Ud)("mouseup",function(){return i.onMouseUp()},!1,Ud)("resize",function(){return i.onResize()},!1,cp)},standalone:!1})};var Ef=class t{constructor(e,A){this.el=e;this.renderer=A;this.bottomMaxHeight=window.innerHeight}bottomMinHeight=310;bottomMaxHeight;resizeHandle=null;resizingEvent={isResizing:!1,startingCursorY:0,startingHeight:0};ngAfterViewInit(){this.resizeHandle=document.getElementsByClassName("bottom-resize-handler")[0],this.renderer.listen(this.resizeHandle,"mousedown",e=>this.onResizeHandleMouseDown(e)),document.documentElement.style.setProperty("--bottom-panel-height","310px"),this.renderer.setStyle(this.el.nativeElement,"height","var(--bottom-panel-height)")}onResizeHandleMouseDown(e){this.resizingEvent={isResizing:!0,startingCursorY:e.clientY,startingHeight:this.bottomPanelHeight},e.preventDefault()}onMouseMove(e){if(!this.resizingEvent.isResizing)return;let A=this.resizingEvent.startingCursorY-e.clientY,i=this.resizingEvent.startingHeight+A;this.bottomPanelHeight=i,this.renderer.addClass(document.body,"resizing")}onMouseUp(){this.resizingEvent.isResizing=!1,this.renderer.removeClass(document.body,"resizing")}onResize(){this.bottomMaxHeight=window.innerHeight/2,this.bottomPanelHeight=this.bottomPanelHeight}set bottomPanelHeight(e){let A=Math.min(Math.max(e,this.bottomMinHeight),this.bottomMaxHeight);document.body.style.setProperty("--bottom-panel-height",`${A}px`)}get bottomPanelHeight(){let e=getComputedStyle(document.body).getPropertyValue("--bottom-panel-height"),A=parseInt(e,10);return isNaN(A)?500:A}static \u0275fac=function(A){return new(A||t)(zA(te),zA(Gi))};static \u0275dir=OA({type:t,selectors:[["","appResizableBottomPanel",""]],hostBindings:function(A,i){A&1&&mA("mousemove",function(o){return i.onMouseMove(o)},!1,Ud)("mouseup",function(){return i.onMouseUp()},!1,Ud)("resize",function(){return i.onResize()},!1,cp)},standalone:!1})};var OcA=new BA("CdkAccordion");var PcA=(()=>{class t{accordion=m(OcA,{optional:!0,skipSelf:!0});_changeDetectorRef=m(lt);_expansionDispatcher=m(uB);_openCloseAllSubscription=_t.EMPTY;closed=new XA;opened=new XA;destroyed=new XA;expandedChange=new XA;id=m($i).getId("cdk-accordion-child-");get expanded(){return this._expanded}set expanded(A){if(this._expanded!==A){if(this._expanded=A,this.expandedChange.emit(A),A){this.opened.emit();let i=this.accordion?this.accordion.id:this.id;this._expansionDispatcher.notify(this.id,i)}else this.closed.emit();this._changeDetectorRef.markForCheck()}}_expanded=!1;disabled=!1;_removeUniqueSelectionListener=()=>{};constructor(){}ngOnInit(){this._removeUniqueSelectionListener=this._expansionDispatcher.listen((A,i)=>{this.accordion&&!this.accordion.multi&&this.accordion.id===i&&this.id!==A&&(this.expanded=!1)}),this.accordion&&(this._openCloseAllSubscription=this._subscribeToOpenCloseAllActions())}ngOnDestroy(){this.opened.complete(),this.closed.complete(),this.destroyed.emit(),this.destroyed.complete(),this._removeUniqueSelectionListener(),this._openCloseAllSubscription.unsubscribe()}toggle(){this.disabled||(this.expanded=!this.expanded)}close(){this.disabled||(this.expanded=!1)}open(){this.disabled||(this.expanded=!0)}_subscribeToOpenCloseAllActions(){return this.accordion._openCloseAllActions.subscribe(A=>{this.disabled||(this.expanded=A)})}static \u0275fac=function(i){return new(i||t)};static \u0275dir=OA({type:t,selectors:[["cdk-accordion-item"],["","cdkAccordionItem",""]],inputs:{expanded:[2,"expanded","expanded",ae],disabled:[2,"disabled","disabled",ae]},outputs:{closed:"closed",opened:"opened",destroyed:"destroyed",expandedChange:"expandedChange"},exportAs:["cdkAccordionItem"],features:[ct([{provide:OcA,useValue:void 0}])]})}return t})(),jcA=(()=>{class t{static \u0275fac=function(i){return new(i||t)};static \u0275mod=ge({type:t});static \u0275inj=le({})}return t})();var APA=["body"],ePA=["bodyWrapper"],tPA=[[["mat-expansion-panel-header"]],"*",[["mat-action-row"]]],iPA=["mat-expansion-panel-header","*","mat-action-row"];function nPA(t,e){}var oPA=[[["mat-panel-title"]],[["mat-panel-description"]],"*"],rPA=["mat-panel-title","mat-panel-description","*"];function sPA(t,e){t&1&&(S(0,"span",1),hr(),S(1,"svg",2),UA(2,"path",3),R()())}var qcA=new BA("MAT_ACCORDION"),VcA=new BA("MAT_EXPANSION_PANEL"),aPA=(()=>{class t{_template=m(vn);_expansionPanel=m(VcA,{optional:!0});constructor(){}static \u0275fac=function(i){return new(i||t)};static \u0275dir=OA({type:t,selectors:[["ng-template","matExpansionPanelContent",""]]})}return t})(),ZcA=new BA("MAT_EXPANSION_PANEL_DEFAULT_OPTIONS"),VG=(()=>{class t extends PcA{_viewContainerRef=m(Un);_animationsDisabled=m(mi,{optional:!0})==="NoopAnimations";_document=m(tt);_ngZone=m(de);_elementRef=m(te);_renderer=m(Gi);_cleanupTransitionEnd;get hideToggle(){return this._hideToggle||this.accordion&&this.accordion.hideToggle}set hideToggle(A){this._hideToggle=A}_hideToggle=!1;get togglePosition(){return this._togglePosition||this.accordion&&this.accordion.togglePosition}set togglePosition(A){this._togglePosition=A}_togglePosition;afterExpand=new XA;afterCollapse=new XA;_inputChanges=new HA;accordion=m(qcA,{optional:!0,skipSelf:!0});_lazyContent;_body;_bodyWrapper;_portal;_headerId=m($i).getId("mat-expansion-panel-header-");constructor(){super();let A=m(ZcA,{optional:!0});this._expansionDispatcher=m(uB),A&&(this.hideToggle=A.hideToggle)}_hasSpacing(){return this.accordion?this.expanded&&this.accordion.displayMode==="default":!1}_getExpandedState(){return this.expanded?"expanded":"collapsed"}toggle(){this.expanded=!this.expanded}close(){this.expanded=!1}open(){this.expanded=!0}ngAfterContentInit(){this._lazyContent&&this._lazyContent._expansionPanel===this&&this.opened.pipe(Qo(null),pt(()=>this.expanded&&!this._portal),Pn(1)).subscribe(()=>{this._portal=new aa(this._lazyContent._template,this._viewContainerRef)}),this._setupAnimationEvents()}ngOnChanges(A){this._inputChanges.next(A)}ngOnDestroy(){super.ngOnDestroy(),this._cleanupTransitionEnd?.(),this._inputChanges.complete()}_containsFocus(){if(this._body){let A=this._document.activeElement,i=this._body.nativeElement;return A===i||i.contains(A)}return!1}_transitionEndListener=({target:A,propertyName:i})=>{A===this._bodyWrapper?.nativeElement&&i==="grid-template-rows"&&this._ngZone.run(()=>{this.expanded?this.afterExpand.emit():this.afterCollapse.emit()})};_setupAnimationEvents(){this._ngZone.runOutsideAngular(()=>{this._animationsDisabled?(this.opened.subscribe(()=>this._ngZone.run(()=>this.afterExpand.emit())),this.closed.subscribe(()=>this._ngZone.run(()=>this.afterCollapse.emit()))):setTimeout(()=>{let A=this._elementRef.nativeElement;this._cleanupTransitionEnd=this._renderer.listen(A,"transitionend",this._transitionEndListener),A.classList.add("mat-expansion-panel-animations-enabled")},200)})}static \u0275fac=function(i){return new(i||t)};static \u0275cmp=YA({type:t,selectors:[["mat-expansion-panel"]],contentQueries:function(i,n,o){if(i&1&&Ii(o,aPA,5),i&2){let r;$A(r=Ae())&&(n._lazyContent=r.first)}},viewQuery:function(i,n){if(i&1&&(Ge(APA,5),Ge(ePA,5)),i&2){let o;$A(o=Ae())&&(n._body=o.first),$A(o=Ae())&&(n._bodyWrapper=o.first)}},hostAttrs:[1,"mat-expansion-panel"],hostVars:4,hostBindings:function(i,n){i&2&&ue("mat-expanded",n.expanded)("mat-expansion-panel-spacing",n._hasSpacing())},inputs:{hideToggle:[2,"hideToggle","hideToggle",ae],togglePosition:"togglePosition"},outputs:{afterExpand:"afterExpand",afterCollapse:"afterCollapse"},exportAs:["matExpansionPanel"],features:[ct([{provide:qcA,useValue:void 0},{provide:VcA,useExisting:t}]),et,Kt],ngContentSelectors:iPA,decls:9,vars:4,consts:[["bodyWrapper",""],["body",""],[1,"mat-expansion-panel-content-wrapper"],["role","region",1,"mat-expansion-panel-content",3,"id"],[1,"mat-expansion-panel-body"],[3,"cdkPortalOutlet"]],template:function(i,n){i&1&&(Yt(tPA),xe(0),S(1,"div",2,0)(3,"div",3,1)(5,"div",4),xe(6,1),NA(7,nPA,0,0,"ng-template",5),R(),xe(8,2),R()()),i&2&&(_(),_e("inert",n.expanded?null:""),_(2),vA("id",n.id),_e("aria-labelledby",n._headerId),_(4),vA("cdkPortalOutlet",n._portal))},dependencies:[ca],styles:[".mat-expansion-panel{box-sizing:content-box;display:block;margin:0;overflow:hidden;position:relative;background:var(--mat-expansion-container-background-color, var(--mat-sys-surface));color:var(--mat-expansion-container-text-color, var(--mat-sys-on-surface));border-radius:var(--mat-expansion-container-shape, 12px)}.mat-expansion-panel.mat-expansion-panel-animations-enabled{transition:margin 225ms cubic-bezier(0.4, 0, 0.2, 1),box-shadow 280ms cubic-bezier(0.4, 0, 0.2, 1)}.mat-expansion-panel:not([class*=mat-elevation-z]){box-shadow:0px 3px 1px -2px rgba(0, 0, 0, 0.2), 0px 2px 2px 0px rgba(0, 0, 0, 0.14), 0px 1px 5px 0px rgba(0, 0, 0, 0.12)}.mat-accordion .mat-expansion-panel:not(.mat-expanded),.mat-accordion .mat-expansion-panel:not(.mat-expansion-panel-spacing){border-radius:0}.mat-accordion .mat-expansion-panel:first-of-type{border-top-right-radius:var(--mat-expansion-container-shape, 12px);border-top-left-radius:var(--mat-expansion-container-shape, 12px)}.mat-accordion .mat-expansion-panel:last-of-type{border-bottom-right-radius:var(--mat-expansion-container-shape, 12px);border-bottom-left-radius:var(--mat-expansion-container-shape, 12px)}@media(forced-colors: active){.mat-expansion-panel{outline:solid 1px}}.mat-expansion-panel-content-wrapper{display:grid;grid-template-rows:0fr;grid-template-columns:100%}.mat-expansion-panel-animations-enabled .mat-expansion-panel-content-wrapper{transition:grid-template-rows 225ms cubic-bezier(0.4, 0, 0.2, 1)}.mat-expansion-panel.mat-expanded>.mat-expansion-panel-content-wrapper{grid-template-rows:1fr}@supports not (grid-template-rows: 0fr){.mat-expansion-panel-content-wrapper{height:0}.mat-expansion-panel.mat-expanded>.mat-expansion-panel-content-wrapper{height:auto}}.mat-expansion-panel-content{display:flex;flex-direction:column;overflow:visible;min-height:0;visibility:hidden;font-family:var(--mat-expansion-container-text-font, var(--mat-sys-body-large-font));font-size:var(--mat-expansion-container-text-size, var(--mat-sys-body-large-size));font-weight:var(--mat-expansion-container-text-weight, var(--mat-sys-body-large-weight));line-height:var(--mat-expansion-container-text-line-height, var(--mat-sys-body-large-line-height));letter-spacing:var(--mat-expansion-container-text-tracking, var(--mat-sys-body-large-tracking))}.mat-expansion-panel-animations-enabled .mat-expansion-panel-content{transition:visibility 190ms linear}.mat-expansion-panel.mat-expanded>.mat-expansion-panel-content-wrapper>.mat-expansion-panel-content{visibility:visible}.mat-expansion-panel-body{padding:0 24px 16px}.mat-expansion-panel-spacing{margin:16px 0}.mat-accordion>.mat-expansion-panel-spacing:first-child,.mat-accordion>*:first-child:not(.mat-expansion-panel) .mat-expansion-panel-spacing{margin-top:0}.mat-accordion>.mat-expansion-panel-spacing:last-child,.mat-accordion>*:last-child:not(.mat-expansion-panel) .mat-expansion-panel-spacing{margin-bottom:0}.mat-action-row{border-top-style:solid;border-top-width:1px;display:flex;flex-direction:row;justify-content:flex-end;padding:16px 8px 16px 24px;border-top-color:var(--mat-expansion-actions-divider-color, var(--mat-sys-outline))}.mat-action-row .mat-button-base,.mat-action-row .mat-mdc-button-base{margin-left:8px}[dir=rtl] .mat-action-row .mat-button-base,[dir=rtl] .mat-action-row .mat-mdc-button-base{margin-left:0;margin-right:8px}"],encapsulation:2,changeDetection:0})}return t})();var WcA=(()=>{class t{panel=m(VG,{host:!0});_element=m(te);_focusMonitor=m(Jr);_changeDetectorRef=m(lt);_parentChangeSubscription=_t.EMPTY;constructor(){m(Ln).load(Qr);let A=this.panel,i=m(ZcA,{optional:!0}),n=m(new Er("tabindex"),{optional:!0}),o=A.accordion?A.accordion._stateChanges.pipe(pt(r=>!!(r.hideToggle||r.togglePosition))):Ar;this.tabIndex=parseInt(n||"")||0,this._parentChangeSubscription=ho(A.opened,A.closed,o,A._inputChanges.pipe(pt(r=>!!(r.hideToggle||r.disabled||r.togglePosition)))).subscribe(()=>this._changeDetectorRef.markForCheck()),A.closed.pipe(pt(()=>A._containsFocus())).subscribe(()=>this._focusMonitor.focusVia(this._element,"program")),i&&(this.expandedHeight=i.expandedHeight,this.collapsedHeight=i.collapsedHeight)}expandedHeight;collapsedHeight;tabIndex=0;get disabled(){return this.panel.disabled}_toggle(){this.disabled||this.panel.toggle()}_isExpanded(){return this.panel.expanded}_getExpandedState(){return this.panel._getExpandedState()}_getPanelId(){return this.panel.id}_getTogglePosition(){return this.panel.togglePosition}_showToggle(){return!this.panel.hideToggle&&!this.panel.disabled}_getHeaderHeight(){let A=this._isExpanded();return A&&this.expandedHeight?this.expandedHeight:!A&&this.collapsedHeight?this.collapsedHeight:null}_keydown(A){switch(A.keyCode){case 32:case 13:rr(A)||(A.preventDefault(),this._toggle());break;default:this.panel.accordion&&this.panel.accordion._handleHeaderKeydown(A);return}}focus(A,i){A?this._focusMonitor.focusVia(this._element,A,i):this._element.nativeElement.focus(i)}ngAfterViewInit(){this._focusMonitor.monitor(this._element).subscribe(A=>{A&&this.panel.accordion&&this.panel.accordion._handleHeaderFocus(this)})}ngOnDestroy(){this._parentChangeSubscription.unsubscribe(),this._focusMonitor.stopMonitoring(this._element)}static \u0275fac=function(i){return new(i||t)};static \u0275cmp=YA({type:t,selectors:[["mat-expansion-panel-header"]],hostAttrs:["role","button",1,"mat-expansion-panel-header","mat-focus-indicator"],hostVars:13,hostBindings:function(i,n){i&1&&mA("click",function(){return n._toggle()})("keydown",function(r){return n._keydown(r)}),i&2&&(_e("id",n.panel._headerId)("tabindex",n.disabled?-1:n.tabIndex)("aria-controls",n._getPanelId())("aria-expanded",n._isExpanded())("aria-disabled",n.panel.disabled),so("height",n._getHeaderHeight()),ue("mat-expanded",n._isExpanded())("mat-expansion-toggle-indicator-after",n._getTogglePosition()==="after")("mat-expansion-toggle-indicator-before",n._getTogglePosition()==="before"))},inputs:{expandedHeight:"expandedHeight",collapsedHeight:"collapsedHeight",tabIndex:[2,"tabIndex","tabIndex",A=>A==null?0:Mi(A)]},ngContentSelectors:rPA,decls:5,vars:3,consts:[[1,"mat-content"],[1,"mat-expansion-indicator"],["xmlns","http://www.w3.org/2000/svg","viewBox","0 -960 960 960","aria-hidden","true","focusable","false"],["d","M480-345 240-585l56-56 184 184 184-184 56 56-240 240Z"]],template:function(i,n){i&1&&(Yt(oPA),S(0,"span",0),xe(1),xe(2,1),xe(3,2),R(),NA(4,sPA,3,0,"span",1)),i&2&&(ue("mat-content-hide-toggle",!n._showToggle()),_(4),FA(n._showToggle()?4:-1))},styles:['.mat-expansion-panel-header{display:flex;flex-direction:row;align-items:center;padding:0 24px;border-radius:inherit;height:var(--mat-expansion-header-collapsed-state-height, 48px);font-family:var(--mat-expansion-header-text-font, var(--mat-sys-title-medium-font));font-size:var(--mat-expansion-header-text-size, var(--mat-sys-title-medium-size));font-weight:var(--mat-expansion-header-text-weight, var(--mat-sys-title-medium-weight));line-height:var(--mat-expansion-header-text-line-height, var(--mat-sys-title-medium-line-height));letter-spacing:var(--mat-expansion-header-text-tracking, var(--mat-sys-title-medium-tracking))}.mat-expansion-panel-animations-enabled .mat-expansion-panel-header{transition:height 225ms cubic-bezier(0.4, 0, 0.2, 1)}.mat-expansion-panel-header::before{border-radius:inherit}.mat-expansion-panel-header.mat-expanded{height:var(--mat-expansion-header-expanded-state-height, 64px)}.mat-expansion-panel-header[aria-disabled=true]{color:var(--mat-expansion-header-disabled-state-text-color, color-mix(in srgb, var(--mat-sys-on-surface) 38%, transparent))}.mat-expansion-panel-header:not([aria-disabled=true]){cursor:pointer}.mat-expansion-panel:not(.mat-expanded) .mat-expansion-panel-header:not([aria-disabled=true]):hover{background:var(--mat-expansion-header-hover-state-layer-color, color-mix(in srgb, var(--mat-sys-on-surface) calc(var(--mat-sys-hover-state-layer-opacity) * 100%), transparent))}@media(hover: none){.mat-expansion-panel:not(.mat-expanded) .mat-expansion-panel-header:not([aria-disabled=true]):hover{background:var(--mat-expansion-container-background-color, var(--mat-sys-surface))}}.mat-expansion-panel .mat-expansion-panel-header:not([aria-disabled=true]).cdk-keyboard-focused,.mat-expansion-panel .mat-expansion-panel-header:not([aria-disabled=true]).cdk-program-focused{background:var(--mat-expansion-header-focus-state-layer-color, color-mix(in srgb, var(--mat-sys-on-surface) calc(var(--mat-sys-focus-state-layer-opacity) * 100%), transparent))}.mat-expansion-panel-header._mat-animation-noopable{transition:none}.mat-expansion-panel-header:focus,.mat-expansion-panel-header:hover{outline:none}.mat-expansion-panel-header.mat-expanded:focus,.mat-expansion-panel-header.mat-expanded:hover{background:inherit}.mat-expansion-panel-header.mat-expansion-toggle-indicator-before{flex-direction:row-reverse}.mat-expansion-panel-header.mat-expansion-toggle-indicator-before .mat-expansion-indicator{margin:0 16px 0 0}[dir=rtl] .mat-expansion-panel-header.mat-expansion-toggle-indicator-before .mat-expansion-indicator{margin:0 0 0 16px}.mat-content{display:flex;flex:1;flex-direction:row;overflow:hidden}.mat-content.mat-content-hide-toggle{margin-right:8px}[dir=rtl] .mat-content.mat-content-hide-toggle{margin-right:0;margin-left:8px}.mat-expansion-toggle-indicator-before .mat-content.mat-content-hide-toggle{margin-left:24px;margin-right:0}[dir=rtl] .mat-expansion-toggle-indicator-before .mat-content.mat-content-hide-toggle{margin-right:24px;margin-left:0}.mat-expansion-panel-header-title{color:var(--mat-expansion-header-text-color, var(--mat-sys-on-surface))}.mat-expansion-panel-header-title,.mat-expansion-panel-header-description{display:flex;flex-grow:1;flex-basis:0;margin-right:16px;align-items:center}[dir=rtl] .mat-expansion-panel-header-title,[dir=rtl] .mat-expansion-panel-header-description{margin-right:0;margin-left:16px}.mat-expansion-panel-header[aria-disabled=true] .mat-expansion-panel-header-title,.mat-expansion-panel-header[aria-disabled=true] .mat-expansion-panel-header-description{color:inherit}.mat-expansion-panel-header-description{flex-grow:2;color:var(--mat-expansion-header-description-color, var(--mat-sys-on-surface-variant))}.mat-expansion-panel-animations-enabled .mat-expansion-indicator{transition:transform 225ms cubic-bezier(0.4, 0, 0.2, 1)}.mat-expansion-panel-header.mat-expanded .mat-expansion-indicator{transform:rotate(180deg)}.mat-expansion-indicator::after{border-style:solid;border-width:0 2px 2px 0;content:"";display:inline-block;padding:3px;transform:rotate(45deg);vertical-align:middle;color:var(--mat-expansion-header-indicator-color, var(--mat-sys-on-surface-variant));display:var(--mat-expansion-legacy-header-indicator-display, none)}.mat-expansion-indicator svg{width:24px;height:24px;margin:0 -8px;vertical-align:middle;fill:var(--mat-expansion-header-indicator-color, var(--mat-sys-on-surface-variant));display:var(--mat-expansion-header-indicator-display, inline-block)}@media(forced-colors: active){.mat-expansion-panel-content{border-top:1px solid;border-top-left-radius:0;border-top-right-radius:0}}'],encapsulation:2,changeDetection:0})}return t})();var XcA=(()=>{class t{static \u0275fac=function(i){return new(i||t)};static \u0275dir=OA({type:t,selectors:[["mat-panel-title"]],hostAttrs:[1,"mat-expansion-panel-header-title"]})}return t})();var $cA=(()=>{class t{static \u0275fac=function(i){return new(i||t)};static \u0275mod=ge({type:t});static \u0275inj=le({imports:[Ve,jcA,sg]})}return t})();var AlA=t=>({color:t});function lPA(t,e){t&1&&UA(0,"div",8)}function gPA(t,e){if(t&1&&(S(0,"span",14),tA(1),R()),t&2){let A=P().$implicit,i=P();so("left",i.getRelativeStart(A.span)+5,"%"),_(),ot("",(i.toMs(A.span.end_time)-i.toMs(A.span.start_time)).toFixed(2),"ms")}}function IPA(t,e){if(t&1){let A=De();S(0,"div",5),mA("click",function(){let n=LA(A).$implicit,o=P();return xA(o.selectRow(n))})("mouseenter",function(){let n=LA(A).$implicit,o=P();return xA(o.onHover(n))})("mouseleave",function(){LA(A);let n=P();return xA(n.onHoverOut())}),S(1,"div",6)(2,"div",7),ln(3,lPA,1,0,"div",8,Kd),R(),S(5,"span",9),tA(6),R(),S(7,"div",10),tA(8),R()(),S(9,"div",11)(10,"div",12),tA(11),R(),NA(12,gPA,2,3,"span",13),R()()}if(t&2){let A=e.$implicit,i=P();ue("selected",i.rowSelected(A)),_(3),gn(i.getArray(A.level)),_(2),vA("ngStyle",Yr(14,AlA,i.isEventRow(A)?"#8AB4F8":"white")),_(),ot(" ",i.getSpanIcon(A.span.name)," "),_(),so("width",400-A.level*20,"px"),vA("ngStyle",Yr(16,AlA,i.isEventRow(A)?"#8AB4F8":"white")),_(),ot(" ",A.span.name," "),_(2),so("left",i.getRelativeStart(A.span),"%")("width",i.getRelativeWidth(A.span),"%"),_(),ot(" ",(i.toMs(A.span.end_time)-i.toMs(A.span.start_time)).toFixed(2),"ms "),_(),FA(i.getRelativeWidth(A.span)<10?12:-1)}}var hf=class t{constructor(e){this.traceService=e}spans=[];invocationId="";tree=[];eventData;baseStartTimeMs=0;totalDurationMs=1;flatTree=[];traceLabelIconMap=new Map([["Invocation","start"],["agent_run","directions_run"],["tool","build"],["call_llm","chat"]]);selectedRow=void 0;ngOnInit(){this.tree=this.buildSpanTree(this.spans),this.flatTree=this.flattenTree(this.tree);let e=this.getGlobalTimes(this.spans);this.baseStartTimeMs=e.start,this.totalDurationMs=e.duration,this.traceService.selectedTraceRow$.subscribe(A=>this.selectedRow=A),this.traceService.eventData$.subscribe(A=>this.eventData=A)}buildSpanTree(e){let A=e.map(o=>nA({},o)),i=new Map,n=[];return A.forEach(o=>i.set(o.span_id,o)),A.forEach(o=>{if(o.parent_span_id&&i.has(o.parent_span_id)){let r=i.get(o.parent_span_id);r.children=r.children||[],r.children.push(o)}else n.push(o)}),n}getGlobalTimes(e){let A=Math.min(...e.map(n=>this.toMs(n.start_time))),i=Math.max(...e.map(n=>this.toMs(n.end_time)));return{start:A,duration:i-A}}toMs(e){return e/1e6}getRelativeStart(e){return(this.toMs(e.start_time)-this.baseStartTimeMs)/this.totalDurationMs*100}getRelativeWidth(e){return(this.toMs(e.end_time)-this.toMs(e.start_time))/this.totalDurationMs*100}flattenTree(e,A=0){return e.flatMap(n=>[{span:n,level:A},...n.children?this.flattenTree(n.children,A+1):[]])}getSpanIcon(e){for(let[A,i]of this.traceLabelIconMap.entries())if(e.startsWith(A))return i;return"start"}getArray(e){return Array.from({length:e})}selectRow(e){if(this.selectedRow&&this.selectedRow.span_id==e.span.span_id){this.traceService.selectedRow(void 0),this.traceService.setHoveredMessages(void 0,this.invocationId);return}this.traceService.selectedRow(e.span),this.traceService.setHoveredMessages(e.span,this.invocationId)}rowSelected(e){return this.selectedRow==e.span}isEventRow(e){if(!e.span.attributes)return!1;let A=e?.span.attributes["gcp.vertex.agent.event_id"];return!!(A&&this.eventData&&this.eventData.has(A))}onHover(e){this.traceService.setHoveredMessages(e.span,this.invocationId)}onHoverOut(){this.traceService.setHoveredMessages(void 0,this.invocationId),this.selectedRow&&this.traceService.setHoveredMessages(this.selectedRow,this.invocationId)}static \u0275fac=function(A){return new(A||t)(zA(zg))};static \u0275cmp=YA({type:t,selectors:[["app-trace-tree"]],inputs:{spans:"spans",invocationId:"invocationId"},standalone:!1,decls:8,vars:1,consts:[[2,"margin-top","15px"],[1,"invocation-id-container"],[1,"invocation-id"],[1,"trace-container"],[1,"trace-row",3,"selected"],[1,"trace-row",3,"click","mouseenter","mouseleave"],[1,"trace-row-left"],[1,"trace-indent"],[1,"indent-connector"],[1,"material-symbols-outlined",2,"margin-right","8px",3,"ngStyle"],[1,"trace-label",3,"ngStyle"],[1,"trace-bar-container"],[1,"trace-bar"],[2,"position","absolute","color","#8dabbf",3,"left"],[2,"position","absolute","color","#8dabbf"]],template:function(A,i){A&1&&(S(0,"div",0)(1,"div",1),tA(2,"Invocation ID: "),S(3,"div",2),tA(4),R()(),S(5,"div",3),ln(6,IPA,13,18,"div",4,Kn),R()()),A&2&&(_(4),Mt(i.invocationId),_(2),gn(i.flatTree))},dependencies:[yQ],styles:[".trace-container[_ngcontent-%COMP%]{width:100%;white-space:nowrap;font-size:12px}.trace-label[_ngcontent-%COMP%]{width:400px;color:#e3e3e3;font-family:Google Sans Mono,monospace;font-size:13px;font-style:normal;font-weight:500;line-height:20px;letter-spacing:0px;text-overflow:ellipsis;white-space:nowrap;overflow:hidden}.trace-bar-container[_ngcontent-%COMP%]{width:100%;position:relative;height:16px}.trace-bar[_ngcontent-%COMP%]{position:absolute;height:18px;background-color:#2f4d65;border-radius:4px;padding-left:4px;overflow:hidden;font-size:11px;line-height:16px;color:#8dabbf;font-family:Google Sans}.trace-duration[_ngcontent-%COMP%]{color:#888;font-weight:400;margin-left:4px}.trace-row[_ngcontent-%COMP%]{display:flex;align-items:stretch;position:relative;height:32px;align-items:center;cursor:pointer}.trace-row[_ngcontent-%COMP%]:hover, .trace-row.selected[_ngcontent-%COMP%]{background-color:#3b3d3c}.trace-indent[_ngcontent-%COMP%]{display:flex;flex-shrink:0;height:100%}.indent-connector[_ngcontent-%COMP%]{width:20px;position:relative;height:100%}.vertical-line[_ngcontent-%COMP%]{position:absolute;top:0;bottom:0;left:9px;width:1px;background-color:#ccc}.horizontal-line[_ngcontent-%COMP%]{position:absolute;top:50%;left:9px;width:10px;height:1px;background-color:#ccc}.trace-row-left[_ngcontent-%COMP%]{display:flex;width:50%}.invocation-id-container[_ngcontent-%COMP%]{color:#9aa0a6;font-size:14px;font-style:normal;font-weight:700;line-height:20px;letter-spacing:0px;margin-bottom:5px}.invocation-id[_ngcontent-%COMP%]{font-family:Google Sans Mono,monospace}"]})};function dPA(t,e){if(t&1&&(S(0,"div",3)(1,"mat-expansion-panel")(2,"mat-expansion-panel-header")(3,"mat-panel-title"),tA(4),R()(),UA(5,"app-trace-tree",4),R()()),t&2){let A=e.$implicit,i=P();_(4),ot(" ",i.invocToUserMsg.get(A.key)," "),_(),vA("spans",A.value)("invocationId",i.findInvocIdFromTraceId(A.key))}}var Qf=class t{traceData=[];invocTraces=new Map;invocToUserMsg=new Map;constructor(){}ngOnInit(){}ngOnChanges(e){"traceData"in e&&this.rebuildTrace()}rebuildTrace(){this.invocTraces=this.traceData.reduce((e,A)=>{let i=A.trace_id,n=e.get(i);return n?(n.push(A),n.sort((o,r)=>o.start_time-r.start_time)):e.set(i,[A]),e},new Map);for(let[e,A]of this.invocTraces)this.invocToUserMsg.set(e,this.findUserMsgFromInvocGroup(A))}getArray(e){return Array.from({length:e})}findUserMsgFromInvocGroup(e){let A=e?.find(o=>o.attributes!==void 0&&"gcp.vertex.agent.invocation_id"in o.attributes);return JSON.parse(A.attributes["gcp.vertex.agent.llm_request"]).contents.filter(o=>o.role=="user").at(-1).parts[0]?.text??"[attachment]"}findInvocIdFromTraceId(e){return this.invocTraces.get(e)?.find(i=>i.attributes!==void 0&&"gcp.vertex.agent.invocation_id"in i.attributes).attributes["gcp.vertex.agent.invocation_id"]}mapOrderPreservingSort=(e,A)=>0;static \u0275fac=function(A){return new(A||t)};static \u0275cmp=YA({type:t,selectors:[["app-trace-tab"]],inputs:{traceData:"traceData"},standalone:!1,features:[Kt],decls:7,vars:3,consts:[[2,"padding-left","25px","padding-right","25px"],["mat-dialog-title","",1,"trace-title"],[1,"trace-list-wrapper"],[1,"trace-item"],[3,"spans","invocationId"]],template:function(A,i){A&1&&(S(0,"div",0)(1,"h2",1),tA(2,"Invocations"),R(),S(3,"div",2),ln(4,dPA,6,3,"div",3,Kn),Ta(6,"keyvalue"),R()()),A&2&&(_(4),gn(uQ(6,0,i.invocTraces,i.mapOrderPreservingSort)))},dependencies:[hs,VG,WcA,XcA,hf,MQ],styles:[".trace-container[_ngcontent-%COMP%]{width:100%;white-space:nowrap;font-size:12px}.trace-title[_ngcontent-%COMP%]{color:#9aa0a6;font-size:14px;font-style:normal;font-weight:700;line-height:20px;letter-spacing:0px}.trace-label[_ngcontent-%COMP%]{width:400px;color:#e3e3e3;text-overflow:ellipsis;font-family:Google Sans Mono,monospace;font-size:14px;font-style:normal;font-weight:500;line-height:20px;letter-spacing:0px}.trace-bar-container[_ngcontent-%COMP%]{width:50vw;position:relative;height:16px}.trace-bar[_ngcontent-%COMP%]{position:absolute;height:18px;background-color:#2f4d65;border-radius:4px;padding-left:4px;overflow:hidden;font-size:11px;line-height:16px;color:#8dabbf;font-family:Google Sans}.trace-duration[_ngcontent-%COMP%]{color:#888;font-weight:400;margin-left:4px}.trace-row[_ngcontent-%COMP%]{display:flex;align-items:stretch;position:relative;height:32px}.trace-indent[_ngcontent-%COMP%]{display:flex;flex-shrink:0;height:100%}.indent-connector[_ngcontent-%COMP%]{width:20px;position:relative;height:100%}.vertical-line[_ngcontent-%COMP%]{position:absolute;top:0;bottom:0;left:9px;width:1px;background-color:#ccc}.horizontal-line[_ngcontent-%COMP%]{position:absolute;top:50%;left:9px;width:10px;height:1px;background-color:#ccc}.trace-item[_ngcontent-%COMP%]{margin-top:5px}.trace-item[_ngcontent-%COMP%]{--mat-expansion-container-background-color: #333537}.trace-item[_ngcontent-%COMP%]{--mat-expansion-header-focus-state-layer-color: red}.trace-item[_ngcontent-%COMP%]{--mat-expansion-header-description-color: #8e918f}.trace-item[_ngcontent-%COMP%]{--mat-expansion-header-text-size: 15}  .mat-expansion-panel-header.mat-expanded:focus{background-color:#444746!important}  .mat-expansion-panel-header.mat-expanded{background-color:#444746!important}  .mat-expansion-panel-header.mat-expanded:hover{background-color:#444746!important}  .mat-expansion-panel-header-title{text-overflow:ellipsis;white-space:nowrap;overflow:hidden}  .mat-expansion-panel-header-description{text-overflow:ellipsis;white-space:nowrap;overflow:hidden}"]})};function EPA(t,e){if(t&1){let A=De();S(0,"div",11),mA("click",function(){LA(A);let n=P();return xA(n.openViewImageDialog(n.rawSvgString))}),R()}if(t&2){let A=P();vA("innerHtml",A.renderedEventGraph,mI)}}var uf=class t{constructor(e,A,i,n){this.dialog=e;this.traceService=A;this.eventService=i;this.sanitizer=n}userId="";sessionId="";appName="";panelClosed=new XA;renderedEventGraph;eventData;selectedRow=void 0;rawSvgString=null;llmRequest=void 0;llmResponse=void 0;llmRequestKey="gcp.vertex.agent.llm_request";llmResponseKey="gcp.vertex.agent.llm_response";ngOnInit(){this.traceService.selectedTraceRow$.subscribe(e=>{this.selectedRow=e;let A=this.getEventIdFromSpan();A&&(this.eventService.getEventTrace(A).subscribe(i=>{this.llmRequest=JSON.parse(i[this.llmRequestKey]),this.llmResponse=JSON.parse(i[this.llmResponseKey])}),this.getEventGraph(A))}),this.traceService.eventData$.subscribe(e=>this.eventData=e)}openViewImageDialog(e){let A=this.dialog.open(m0,{maxWidth:"90vw",maxHeight:"90vh",data:{imageData:e}})}getEventDetails(){if(this.eventData&&this.selectedRow)return this.eventData.get(this.getEventIdFromSpan())}getEventIdFromSpan(){if(this.selectedRow)return this.selectedRow.attributes["gcp.vertex.agent.event_id"]}getEventGraph(e){this.eventService.getEvent(this.userId,this.appName,this.sessionId,e).subscribe(A=>_n(this,null,function*(){if(!A.dotSrc){this.renderedEventGraph=void 0;return}let i=A.dotSrc,o=(yield vu()).renderString(i,{format:"svg",engine:"dot"});this.rawSvgString=o,this.renderedEventGraph=this.sanitizer.bypassSecurityTrustHtml(o)}))}closePanel(){this.panelClosed.emit(!0)}static \u0275fac=function(A){return new(A||t)(zA(Us),zA(zg),zA(j1),zA(il))};static \u0275cmp=YA({type:t,selectors:[["app-trace-event"]],inputs:{userId:"userId",sessionId:"sessionId",appName:"appName"},outputs:{panelClosed:"panelClosed"},standalone:!1,decls:17,vars:4,consts:[[1,"wrapper"],["mat-stretch-tabs","false","mat-align-tabs","start"],["label","Event"],[1,"json-viewer-container"],[3,"json"],["label","Request"],["label","Response"],["label","Graph"],[1,"event-graph-container"],[3,"innerHtml"],["mat-icon-button","",1,"tab-header-action",3,"click"],[3,"click","innerHtml"]],template:function(A,i){A&1&&(S(0,"div",0)(1,"mat-tab-group",1)(2,"mat-tab",2)(3,"div",3),UA(4,"ngx-json-viewer",4),R()(),S(5,"mat-tab",5)(6,"div",3),UA(7,"ngx-json-viewer",4),R()(),S(8,"mat-tab",6)(9,"div",3),UA(10,"ngx-json-viewer",4),R()(),S(11,"mat-tab",7)(12,"div",8),NA(13,EPA,1,1,"div",9),R()()(),S(14,"button",10),mA("click",function(){return i.closePanel()}),S(15,"mat-icon"),tA(16,"close"),R()()()),A&2&&(_(4),vA("json",i.getEventDetails()),_(3),vA("json",i.llmRequest),_(3),vA("json",i.llmResponse),_(3),FA(i.renderedEventGraph?13:-1))},dependencies:[T2,EB,Qh,af,Py],styles:[".json-viewer-container[_ngcontent-%COMP%]{padding-top:8px;padding-left:12px;padding-right:12px;background-color:#1b1b1b}.event-graph-container[_ngcontent-%COMP%]{text-align:center;padding-top:20px}.event-graph-container[_ngcontent-%COMP%]     svg text{font-family:Google Sans Mono,monospace;font-size:11px}.wrapper[_ngcontent-%COMP%]{position:relative}.tab-header-action[_ngcontent-%COMP%]{position:absolute;top:0;right:0;height:48px;z-index:2;margin-right:10px}"]})};var QPA=["videoContainer"],uPA=["sideDrawer"],fPA=["autoScroll"],mPA=["messageTextarea"],pPA=["bottomPanel"],wPA=t=>({"edit-mode":t}),DPA=()=>[],yPA=(t,e)=>({"user-message":t,"bot-message":e}),vPA=(t,e)=>({"eval-pass":t,"eval-fail":e}),bPA=t=>({"eval-fail":t}),WG=t=>({"background-color":t}),MPA=(t,e)=>({"font-style":t,color:e}),tlA=t=>({"function-event-button-highlight":t}),XG=t=>({hidden:t});function kPA(t,e){if(t&1){let A=De();S(0,"span",28),mA("click",function(){LA(A);let n=P();return xA(n.toggleSidePanel())}),tA(1,"left_panel_open"),R()}}function SPA(t,e){if(t&1&&(S(0,"mat-option",17),tA(1),R()),t&2){let A=e.$implicit;vA("value",A),_(),Mt(A)}}function RPA(t,e){t&1&&ln(0,SPA,2,2,"mat-option",17,Kn),t&2&&gn(e)}function LPA(t,e){if(t&1&&(S(0,"mat-option",17),tA(1),R()),t&2){let A=P();vA("value",A.selectedAppControl.value),_(),Mt(A.selectedAppControl.value)}}function xPA(t,e){t&1&&(S(0,"span",37),tA(1,"Trace"),R())}function FPA(t,e){t&1&&(S(0,"span",37),tA(1,"Events"),R())}function NPA(t,e){t&1&&(S(0,"span",37),tA(1,"State"),R())}function _PA(t,e){t&1&&(S(0,"span",37),tA(1,"Artifacts"),R())}function GPA(t,e){t&1&&(S(0,"span",37),tA(1,"Sessions"),R())}function UPA(t,e){t&1&&(S(0,"span",37),tA(1,"Eval"),R())}function KPA(t,e){if(t&1){let A=De();S(0,"mat-tab"),NA(1,UPA,2,0,"ng-template",31),S(2,"app-eval-tab",38),mA("shouldShowTab",function(n){LA(A);let o=P(2);return xA(o.handleShouldShowEvalTab(n))})("sessionSelected",function(n){LA(A);let o=P(2);return xA(o.updateWithSelectedSession(n))})("evalCaseSelected",function(n){LA(A);let o=P(2);return xA(o.updateWithSelectedEvalCase(n))})("evalSetIdSelected",function(n){LA(A);let o=P(2);return xA(o.updateSelectedEvalSetId(n))})("shouldReturnToSession",function(n){LA(A);let o=P(2);return xA(o.handleReturnToSession(n))})("evalNotInstalledMsg",function(n){LA(A);let o=P(2);return xA(o.handleEvalNotInstalled(n))}),R()()}if(t&2){let A=P(2);_(2),vA("appName",A.appName)("userId",A.userId)("sessionId",A.sessionId)}}function YPA(t,e){if(t&1){let A=De();S(0,"div",18)(1,"mat-tab-group",29),mA("selectedTabChange",function(n){LA(A);let o=P();return xA(o.handleTabChange(n))}),S(2,"mat-tab",30),NA(3,xPA,2,0,"ng-template",31),UA(4,"app-trace-tab",32),R(),S(5,"mat-tab",30),NA(6,FPA,2,0,"ng-template",31),S(7,"app-event-tab",33),mA("selectedEvent",function(n){LA(A);let o=P();return xA(o.selectEvent(n))}),R()(),S(8,"mat-tab"),NA(9,NPA,2,0,"ng-template",31),UA(10,"app-state-tab",34),R(),S(11,"mat-tab"),NA(12,_PA,2,0,"ng-template",31),UA(13,"app-artifact-tab",35),R(),S(14,"mat-tab"),NA(15,GPA,2,0,"ng-template",31),S(16,"app-session-tab",36),mA("sessionSelected",function(n){LA(A);let o=P();return xA(o.updateWithSelectedSession(n))})("sessionReloaded",function(n){LA(A);let o=P();return xA(o.updateSessionState(n))}),R()(),NA(17,KPA,3,3,"mat-tab"),R()()}if(t&2){let A=P();_(4),vA("traceData",A.traceData),_(3),vA("eventsMap",A.eventData)("traceData",A.traceData),_(3),vA("sessionState",A.currentSessionState),_(3),vA("artifacts",A.artifacts),_(3),vA("userId",A.userId)("appName",A.appName)("sessionId",A.sessionId),_(),FA(A.shouldShowEvalTab()?17:-1)}}function JPA(t,e){if(t&1){let A=De();S(0,"div",51),mA("click",function(){LA(A);let n=P(2);return xA(n.openViewImageDialog(n.rawSvgString))}),R()}if(t&2){let A=P(2);vA("innerHtml",A.renderedEventGraph,mI)}}function TPA(t,e){if(t&1){let A=De();S(0,"div",19)(1,"div",39)(2,"div",40)(3,"mat-paginator",41),mA("page",function(n){LA(A);let o=P();return xA(o.handlePageEvent(n))}),R(),S(4,"button",42)(5,"mat-icon",43),mA("click",function(){LA(A);let n=P();return xA(n.closeSelectedEvent())}),tA(6,"close"),R()()()(),S(7,"div")(8,"mat-tab-group")(9,"mat-tab",44)(10,"div",45),NA(11,JPA,1,1,"div",46),R(),S(12,"div",47),UA(13,"ngx-json-viewer",48),R()(),S(14,"mat-tab",49)(15,"div",47),UA(16,"ngx-json-viewer",48),R()(),S(17,"mat-tab",50)(18,"div",47),UA(19,"ngx-json-viewer",48),R()()()()()}if(t&2){let A=P();_(3),vA("length",A.eventData.size)("pageSize",1)("pageIndex",A.selectedEventIndex),_(8),FA(A.renderedEventGraph?11:-1),_(2),vA("json",A.selectedEvent),_(3),vA("json",A.llmRequest),_(3),vA("json",A.llmResponse)}}function zPA(t,e){if(t&1){let A=De();S(0,"span",53),mA("click",function(){LA(A);let n=P(2);return xA(n.toggleSidePanel())}),tA(1,"left_panel_open"),R()}}function HPA(t,e){if(t&1){let A=De();S(0,"button",58),mA("click",function(){LA(A);let n=P(3);return xA(n.cancelEditEvalCase())}),tA(1,"Cancel"),R(),S(2,"button",59),mA("click",function(){LA(A);let n=P(3);return xA(n.saveEvalCase())}),tA(3," Save "),R()}if(t&2){let A=P(3);_(2),vA("disabled",!A.hasEvalCaseChanged()||A.isEvalCaseEditing())}}function OPA(t,e){if(t&1){let A=De();S(0,"span",60),mA("click",function(){LA(A);let n=P(3);return xA(n.editEvalCase())}),tA(1," edit "),R(),S(2,"span",61),mA("click",function(){LA(A);let n=P(3);return xA(n.deleteEvalCase())}),tA(3," delete "),R()}}function PPA(t,e){if(t&1&&(S(0,"div",54)(1,"div",55),tA(2,"Eval Case ID"),R(),S(3,"div",56),tA(4),R()(),S(5,"div",57),NA(6,HPA,4,1)(7,OPA,4,0),R()),t&2){let A=P(2);_(4),Mt(A.evalCase.evalId),_(2),FA(A.isEvalEditMode()?6:7)}}function jPA(t,e){if(t&1){let A=De();S(0,"span",70),mA("click",function(){LA(A);let n=P(3);return xA(n.importSession())}),tA(1," upload "),R()}}function qPA(t,e){if(t&1){let A=De();S(0,"div",54)(1,"div",55),tA(2,"Session ID"),R(),S(3,"div",56),tA(4),R()(),S(5,"div",57)(6,"div",62)(7,"mat-slide-toggle",63),mA("change",function(){LA(A);let n=P(2);return xA(n.toggleSse())}),tA(8," Token Streaming "),R()(),UA(9,"mat-divider",64),S(10,"div",65)(11,"div",66),mA("click",function(){LA(A);let n=P(2);return xA(n.onNewSessionClick())}),S(12,"mat-icon"),tA(13,"add"),R(),tA(14," New Session "),R(),S(15,"span",67),mA("click",function(){LA(A);let n=P(2);return xA(n.deleteSession(n.sessionId))}),tA(16," delete "),R(),S(17,"span",68),mA("click",function(){LA(A);let n=P(2);return xA(n.exportSession())}),tA(18," download "),R(),NA(19,jPA,2,0,"span",69),Ta(20,"async"),R()()}if(t&2){let A=P(2);_(4),Mt(A.sessionId),_(3),vA("checked",A.enableSseIndicator()),_(2),vA("vertical",!0),_(10),FA(w2(20,4,A.importSessionEnabledObs)?19:-1)}}function VPA(t,e){if(t&1&&(S(0,"div",22),NA(1,zPA,2,0,"span",52)(2,PPA,8,2)(3,qPA,21,6),R()),t&2){let A=P();vA("ngClass",Yr(3,wPA,A.isEvalEditMode())),_(),FA(A.showSidePanel?-1:1),_(),FA(A.evalCase?2:3)}}function ZPA(t,e){t&1&&(S(0,"div",71)(1,"span"),tA(2,"Loading agents, please wait..."),R()())}function WPA(t,e){t&1&&(S(0,"span"),tA(1,"Welcome to ADK!"),UA(2,"br"),tA(3," Select an agent on the left to begin with."),R())}function XPA(t,e){if(t&1&&(tA(0," Error message: "),UA(1,"br"),S(2,"pre",73),tA(3),R()),t&2){let A=P(4);_(3),Mt(A.loadingError())}}function $PA(t,e){t&1&&(S(0,"pre",72),tA(1,"Warning: No agents found in current folder."),R())}function AjA(t,e){if(t&1&&(S(0,"div"),tA(1," Failed to load agents. To get started, run "),S(2,"pre"),tA(3,"adk web"),R(),tA(4," in the folder that contains the agents."),UA(5,"br"),NA(6,XPA,4,1)(7,$PA,2,0,"pre",72),R()),t&2){let A=P(3);_(6),FA(A.loadingError()?6:7)}}function ejA(t,e){if(t&1&&(S(0,"div",71),NA(1,WPA,4,0,"span"),Ta(2,"async"),NA(3,AjA,8,1,"div"),R()),t&2){let A=P(2);_(),FA((w2(2,1,A.apps$)||jT(3,DPA)).length>0?1:3)}}function tjA(t,e){if(t&1&&NA(0,ZPA,3,0,"div",71)(1,ejA,4,4,"div",71),t&2){let A=P();FA(A.isLoadingApps()?0:1)}}function ijA(t,e){if(t&1){let A=De();S(0,"button",74),mA("click",function(){LA(A);let n=P();return xA(n.openDialog())}),S(1,"mat-icon"),tA(2,"priority_high"),R()()}}function njA(t,e){if(t&1){let A=De();S(0,"button",80),mA("click",function(){LA(A);let n=P().$index,o=P(2);return xA(o.clickEvent(n))}),S(1,"mat-icon",81),tA(2,"robot_2"),R()()}if(t&2){let A=P().$index,i=P(2);vo(i.customIconColorClass(A)),vA("matTooltip",i.getAgentNameFromEvent(A))}}function ojA(t,e){t&1&&UA(0,"mat-progress-bar",82)}function rjA(t,e){if(t&1&&UA(0,"img",87),t&2){let A=P().$implicit;vA("src",A.url,Ka)}}function sjA(t,e){if(t&1&&(S(0,"mat-icon"),tA(1,"insert_drive_file"),R(),S(2,"a",88),tA(3),R()),t&2){let A=P().$implicit;_(2),vA("href",A.url,Ka),_(),Mt(A.file.name)}}function ajA(t,e){if(t&1&&(S(0,"div",86),NA(1,rjA,1,1,"img",87)(2,sjA,4,2),R()),t&2){let A=e.$implicit;_(),FA(A.file.type.startsWith("image/")?1:-1),_(),FA(A.file.type.startsWith("image/")?-1:2)}}function cjA(t,e){if(t&1&&(S(0,"div",83),ln(1,ajA,3,2,"div",86,Kn),R()),t&2){let A=P(2).$implicit;_(),gn(A.attachments)}}function ljA(t,e){t&1&&(S(0,"div",84),tA(1,"Thought"),R())}function gjA(t,e){if(t&1){let A=De();S(0,"div",89)(1,"textarea",91,3),ta("ngModelChange",function(n){LA(A);let o=P(5);return Ja(o.userEditEvalCaseMessage,n)||(o.userEditEvalCaseMessage=n),xA(n)}),mA("keydown",function(n){LA(A);let o=P(3).$implicit,r=P(2);return xA(r.handleKeydown(n,o))}),R(),S(3,"div",92)(4,"span",93),mA("click",function(){LA(A);let n=P(3).$implicit,o=P(2);return xA(o.cancelEditMessage(n))}),tA(5," close "),R(),S(6,"span",94),mA("click",function(){LA(A);let n=P(3).$implicit,o=P(2);return xA(o.saveEditMessage(n))}),tA(7," check "),R()()()}if(t&2){let A=P(5);_(),ea("ngModel",A.userEditEvalCaseMessage)}}function IjA(t,e){if(t&1&&UA(0,"markdown",90),t&2){let A=P(3).$implicit;vA("data",A.text)("ngStyle",p2(2,MPA,A.thought?"italic":"normal",A.thought?"#9aa0a6":"white"))}}function CjA(t,e){if(t&1&&NA(0,gjA,8,1,"div",89)(1,IjA,1,5,"markdown",90),t&2){let A=P(2).$implicit;FA(A.isEditing?0:1)}}function djA(t,e){if(t&1&&(S(0,"div"),UA(1,"div",95),R()),t&2){let A=P(2).$implicit,i=P(2);_(),vA("innerHTML",i.renderGooglerSearch(A.renderedContent),mI)}}function BjA(t,e){if(t&1&&(S(0,"code"),tA(1),R()),t&2){let A=P(2).$implicit;_(),ot(" ",A.executableCode.code," ")}}function EjA(t,e){if(t&1&&(S(0,"div")(1,"div"),tA(2),R(),S(3,"div"),tA(4),R()()),t&2){let A=P(2).$implicit;_(2),ot("Outcome: ",A.codeExecutionResult.outcome,""),_(2),ot("Output: ",A.codeExecutionResult.output,"")}}function hjA(t,e){if(t&1){let A=De();S(0,"div",96)(1,"img",97),mA("click",function(){LA(A);let n=P(4).$implicit,o=P(2);return xA(o.openViewImageDialog(n.inlineData.data))}),R()()}if(t&2){let A=P(4).$implicit;_(),vA("src",A.inlineData.data,Ka)}}function QjA(t,e){if(t&1&&(S(0,"div"),UA(1,"app-audio-player",98),R()),t&2){let A=P(4).$implicit;_(),vA("base64data",A.inlineData.data)}}function ujA(t,e){if(t&1){let A=De();S(0,"div")(1,"div",99)(2,"mat-icon"),tA(3,"description"),R(),S(4,"button",100),mA("click",function(){LA(A);let n=P(4).$implicit,o=P(2);return xA(o.openBase64InNewTab(n.inlineData.data,n.inlineData.mimeType))}),tA(5),R()()()}if(t&2){let A=P(4).$implicit;_(5),ot(" ",A.inlineData.name," ")}}function fjA(t,e){if(t&1){let A=De();S(0,"div")(1,"button",100),mA("click",function(){LA(A);let n=P(4).$implicit,o=P(2);return xA(o.openBase64InNewTab(n.inlineData.data,n.inlineData.mimeType))}),tA(2),R()()}if(t&2){let A=P(4).$implicit;_(2),ot(" ",A.inlineData.name," ")}}function mjA(t,e){if(t&1&&(S(0,"div")(1,"div"),NA(2,hjA,2,1,"div",96)(3,QjA,2,1,"div")(4,ujA,6,1,"div")(5,fjA,3,1,"div"),R()()),t&2){let A,i=P(3).$implicit,n=P(2);_(2),FA((A=i.inlineData.mediaType)===n.MediaType.IMAGE?2:A===n.MediaType.AUDIO?3:A===n.MediaType.TEXT?4:5)}}function pjA(t,e){if(t&1){let A=De();S(0,"div")(1,"img",101),mA("click",function(){LA(A);let n=P(4).$implicit,o=P(2);return xA(o.openViewImageDialog(n.inlineData.data))}),R()()}if(t&2){let A=P(4).$implicit;_(),vA("src",A.inlineData.data,Ka)}}function wjA(t,e){if(t&1&&(S(0,"div",86)(1,"mat-icon"),tA(2,"insert_drive_file"),R(),S(3,"a",88),tA(4),R()()),t&2){let A=P(4).$implicit;_(3),vA("href",A.inlineData.data,Ka),_(),Mt(A.inlineData.displayName)}}function DjA(t,e){if(t&1&&(S(0,"div"),NA(1,pjA,2,1,"div")(2,wjA,5,2,"div",86),R()),t&2){let A=P(3).$implicit;_(),FA(A.inlineData.mimeType.startsWith("image/")?1:2)}}function yjA(t,e){if(t&1&&NA(0,mjA,6,1,"div")(1,DjA,3,1,"div"),t&2){let A=P(2).$implicit;FA(A.role==="bot"?0:1)}}function vjA(t,e){if(t&1&&(S(0,"div",104)(1,"div",105),tA(2,"Actual tool uses:"),R(),UA(3,"ngx-json-viewer",48),R(),S(4,"div",106)(5,"div",107),tA(6," Expected tool uses: "),R(),UA(7,"ngx-json-viewer",48),R()),t&2){let A=P(3).$implicit;_(3),vA("json",A.actualInvocationToolUses),_(4),vA("json",A.expectedInvocationToolUses)}}function bjA(t,e){if(t&1&&(S(0,"div",104)(1,"div",105),tA(2,"Actual response:"),R(),S(3,"div"),tA(4),R()(),S(5,"div",106)(6,"div",107),tA(7,"Expected response:"),R(),S(8,"div"),tA(9),R()()),t&2){let A=P(3).$implicit;_(4),Mt(A.actualFinalResponse),_(5),Mt(A.expectedFinalResponse)}}function MjA(t,e){if(t&1&&(S(0,"div",103)(1,"span",108),tA(2),R(),S(3,"span",109),tA(4),R()()),t&2){let A=P(3).$implicit;_(2),ot("Match score: ",A.evalScore,""),_(2),ot("Threshold: ",A.evalThreshold,"")}}function kjA(t,e){if(t&1&&(S(0,"div",85)(1,"div",102),NA(2,vjA,8,2)(3,bjA,10,2),R(),NA(4,MjA,5,2,"div",103),R()),t&2){let A=P(2).$implicit;_(2),FA(A.actualInvocationToolUses?2:A.actualFinalResponse?3:-1),_(2),FA(A.evalScore!==void 0&&A.evalThreshold!==void 0?4:-1)}}function SjA(t,e){if(t&1&&(S(0,"mat-card",77),NA(1,ojA,1,0,"mat-progress-bar",82)(2,cjA,3,0,"div",83),S(3,"div"),NA(4,ljA,2,0,"div",84),S(5,"div"),NA(6,CjA,2,1),R(),NA(7,djA,2,1,"div"),R(),NA(8,BjA,2,1,"code")(9,EjA,5,2,"div")(10,yjA,2,1)(11,kjA,5,2,"div",85),R()),t&2){let A=P(),i=A.$implicit,n=A.$index,o=P(2);vA("ngClass",Yr(11,bPA,i.evalStatus===2))("ngStyle",Yr(13,WG,o.shouldMessageHighlighted(n)?"rgb(15, 82, 35)":"")),_(),FA(i.isLoading?1:-1),_(),FA(i.attachments?2:-1),_(2),FA(i.thought?4:-1),_(2),FA(i.text?6:-1),_(),FA(i.renderedContent?7:-1),_(),FA(i.executableCode?8:-1),_(),FA(i.codeExecutionResult?9:-1),_(),FA(i.inlineData?10:-1),_(),FA(i.failedMetric&&i.evalStatus===2?11:-1)}}function RjA(t,e){if(t&1){let A=De();S(0,"button",110),mA("click",function(){LA(A);let n=P().$index,o=P(2);return xA(o.clickEvent(n))}),S(1,"mat-icon"),tA(2,"bolt"),R(),tA(3),R()}if(t&2){let A=P(),i=A.$implicit,n=A.$index,o=P(2);vA("ngClass",Yr(2,tlA,o.shouldMessageHighlighted(n))),_(3),ot(" ",i.functionCall.name," ")}}function LjA(t,e){if(t&1){let A=De();S(0,"button",110),mA("click",function(){LA(A);let n=P().$index,o=P(2);return xA(o.clickEvent(n))}),S(1,"mat-icon"),tA(2,"check"),R(),tA(3),R()}if(t&2){let A=P(),i=A.$implicit,n=A.$index,o=P(2);vA("ngClass",Yr(2,tlA,o.shouldMessageHighlighted(n))),_(3),ot(" ",i.functionResponse.name," ")}}function xjA(t,e){if(t&1){let A=De();S(0,"div")(1,"span",111),mA("click",function(){LA(A);let n=P(2).$implicit,o=P(2);return xA(o.editEvalCaseMessage(n))}),tA(2," edit "),R(),S(3,"span",112),mA("click",function(){LA(A);let n=P(2),o=n.$implicit,r=n.$index,s=P(2);return xA(s.deleteEvalCaseMessage(o,r))}),tA(4," delete "),R()()}if(t&2){let A=P(4);_(),vA("ngClass",Yr(2,XG,A.isEvalCaseEditing())),_(2),vA("ngClass",Yr(4,XG,A.isEvalCaseEditing()))}}function FjA(t,e){if(t&1){let A=De();S(0,"div")(1,"span",113),mA("click",function(){LA(A);let n=P(2).$implicit,o=P(2);return xA(o.editFunctionArgs(n))}),tA(2," edit "),R()()}if(t&2){let A=P(4);_(),vA("ngClass",Yr(1,XG,A.isEvalCaseEditing()))}}function NjA(t,e){if(t&1&&(NA(0,xjA,5,6,"div"),Ta(1,"async"),NA(2,FjA,3,3,"div")),t&2){let A=P().$implicit,i=P(2);FA(A.text?0:w2(1,1,i.isEditFunctionArgsEnabledObs)&&A.functionCall?2:-1)}}function _jA(t,e){t&1&&(S(0,"button",42)(1,"mat-icon"),tA(2,"person"),R()())}function GjA(t,e){if(t&1&&(S(0,"div",75),NA(1,njA,3,3,"button",76)(2,SjA,12,15,"mat-card",77)(3,RjA,4,4,"button",78)(4,LjA,4,4,"button",78),S(5,"div",75)(6,"span",79),tA(7),R(),S(8,"span"),tA(9),R()(),NA(10,NjA,3,3)(11,_jA,3,0,"button",42),R()),t&2){let A=e.$implicit,i=P(2);vA("ngClass",p2(10,yPA,A.role==="user",A.role==="bot")),_(),FA(A.role==="bot"?1:-1),_(),FA(!A.functionCall&&!A.functionResponse?2:-1),_(),FA(A.functionCall?3:-1),_(),FA(A.functionResponse?4:-1),_(),vA("ngClass",p2(13,vPA,A.evalStatus===1,A.evalStatus===2)),_(2),Mt(A.evalStatus===1?"check":A.evalStatus===2?"close":""),_(2),Mt(A.evalStatus===1?"Pass":A.evalStatus===2?"Fail":""),_(),FA(i.evalCase&&A.role==="bot"&&i.isEvalEditMode()?10:-1),_(),FA(A.role==="user"?11:-1)}}function UjA(t,e){if(t&1&&(S(0,"div",25,1),UA(2,"div",null,2),ln(4,GjA,12,16,"div",75,Kn),R()),t&2){let A=P();_(4),gn(A.messages)}}function KjA(t,e){if(t&1){let A=De();S(0,"div",121),UA(1,"img",123),S(2,"button",124),mA("click",function(){LA(A);let n=P().$index,o=P(3);return xA(o.removeFile(n))}),S(3,"mat-icon",125),tA(4,"close"),R()()()}if(t&2){let A=P().$implicit;_(),vA("src",A.url,Ka)}}function YjA(t,e){if(t&1){let A=De();S(0,"div",122)(1,"button",124),mA("click",function(){LA(A);let n=P().$index,o=P(3);return xA(o.removeFile(n))}),S(2,"mat-icon",125),tA(3,"close"),R()(),S(4,"div",126)(5,"mat-icon"),tA(6,"insert_drive_file"),R(),S(7,"span"),tA(8),R()()()}if(t&2){let A=P().$implicit;_(8),Mt(A.file.name)}}function JjA(t,e){if(t&1&&(S(0,"div"),NA(1,KjA,5,1,"div",121)(2,YjA,9,1,"div",122),R()),t&2){let A=e.$implicit;_(),FA(A.file.type.startsWith("image/")?1:-1),_(),FA(A.file.type.startsWith("image/")?-1:2)}}function TjA(t,e){if(t&1&&(S(0,"div",116),ln(1,JjA,3,2,"div",null,Kn),R()),t&2){let A=P(2);_(),gn(A.selectedFiles)}}function zjA(t,e){if(t&1){let A=De();S(0,"div",26)(1,"input",114,4),mA("change",function(n){LA(A);let o=P();return xA(o.onFileSelect(n))}),R(),S(3,"mat-form-field",115),NA(4,TjA,3,0,"div",116),S(5,"textarea",117),ta("ngModelChange",function(n){LA(A);let o=P();return Ja(o.userInput,n)||(o.userInput=n),xA(n)}),mA("keydown.enter",function(n){LA(A);let o=P();return xA(o.sendMessage(n))}),R(),S(6,"div",118)(7,"button",119),mA("click",function(){LA(A);let n=or(2);return xA(n.click())}),S(8,"mat-icon"),tA(9,"attach_file"),R()(),S(10,"div")(11,"button",120),mA("click",function(){LA(A);let n=P();return xA(n.toggleAudioRecording())}),S(12,"mat-icon"),tA(13,"mic"),R()(),S(14,"button",120),mA("click",function(){LA(A);let n=P();return xA(n.toggleVideoRecording())}),S(15,"mat-icon"),tA(16,"videocam"),R()()()()()()}if(t&2){let A=P();_(4),FA(A.selectedFiles.length&&A.appName!=""?4:-1),_(),ea("ngModel",A.userInput),_(6),vA("ngStyle",Yr(6,WG,A.isAudioRecording?"rgb(234, 67, 53)":"rgb(51, 53, 55)"))("matTooltip",A.isAudioRecording?"Turn off microphone":"Use microphone"),_(3),vA("ngStyle",Yr(8,WG,A.isVideoRecording?"rgb(234, 67, 53)":"rgb(51, 53, 55)"))("matTooltip",A.isVideoRecording?"Turn off camera":"Use camera")}}function HjA(t,e){if(t&1){let A=De();S(0,"div",27,5),UA(2,"div",127),S(3,"app-trace-event",128),mA("panelClosed",function(){LA(A);let n=P();return xA(n.closeTraceEventDetailPanel())}),R()()}if(t&2){let A=P();_(3),vA("userId",A.userId)("appName",A.appName)("sessionId",A.sessionId)}}function OjA(t){for(t=t.replace(/-/g,"+").replace(/_/g,"/");t.length%4!==0;)t+="=";return t}var $G=class extends TI{nextPageLabel="Next Event";previousPageLabel="Previous Event";firstPageLabel="First Event";lastPageLabel="Last Event";getRangeLabel=(e,A,i)=>i===0?`Event 0 of ${i}`:(i=Math.max(i,0),`Event ${e*A+1} of ${i}`)},elA="Restarting bidirectional streaming is not currently supported. Please refresh the page or start a new session.",ff=class t{constructor(e,A,i,n,o,r,s,a,c,l,I,C,d,B,E){this.sanitizer=e;this.sessionService=A;this.artifactService=i;this.audioService=n;this.webSocketService=o;this.videoService=r;this.dialog=s;this.eventService=a;this.route=c;this.downloadService=l;this.evalService=I;this.traceService=C;this.location=d;this.renderer=B;this.document=E}videoContainer;sideDrawer;eventTabComponent;sessionTab;evalTab;scrollContainer;textarea;bottomPanelRef;_snackBar=m(pP);shouldShowEvalTab=Ko(!0);enableSseIndicator=Ko(!1);isChatMode=Ko(!0);isEvalCaseEditing=Ko(!1);hasEvalCaseChanged=Ko(!1);isEvalEditMode=Ko(!1);videoElement;currentMessage="";messages=[];lastTextChunk="";streamingTextMessage=null;latestThought="";artifacts=[];userInput="";userEditEvalCaseMessage="";userId="user";appName="";sessionId="";evalCase=null;updatedEvalCase=null;evalSetId="";isAudioRecording=!1;isVideoRecording=!1;longRunningEvents=[];functionCallEventId="";redirectUri=Es.getBaseUrlWithoutPath();showSidePanel=!0;useSse=!1;currentSessionState={};messagesSubject=new li([]);streamingTextMessageSubject=new li(null);scrollInterruptedSubject=new li(!0);isModelThinkingSubject=new li(!1);sessionHasUsedBidi=new Set;eventData=new Map;traceData=[];eventMessageIndexArray=[];renderedEventGraph;rawSvgString=null;selectedEvent=void 0;selectedEventIndex=void 0;llmRequest=void 0;llmResponse=void 0;llmRequestKey="gcp.vertex.agent.llm_request";llmResponseKey="gcp.vertex.agent.llm_response";getMediaTypeFromMimetype=h8;selectedFiles=[];previousMessageCount=0;openBase64InNewTab=qk;MediaType=Ru;router=m(ng);activatedRoute=m(ra);selectedAppControl=new vI("",{nonNullable:!0});changeDetectorRef=m(lt);agentService=m(K2);isLoadingApps=Ko(!1);loadingError=Ko("");apps$=ve([]).pipe(oo(()=>{this.isLoadingApps.set(!0),this.selectedAppControl.disable()}),no(()=>this.agentService.listApps().pipe(dr(e=>(this.loadingError.set(e.message),ve(void 0))))),Pn(1),oo(e=>{this.isLoadingApps.set(!1),this.selectedAppControl.enable(),e?.length==1&&this.router.navigate([],{relativeTo:this.route,queryParams:{app:e[0]}})}),$g());featureFlagService=m(vB);importSessionEnabledObs=this.featureFlagService.isImportSessionEnabled();isEditFunctionArgsEnabledObs=this.featureFlagService.isEditFunctionArgsEnabled();isSessionUrlEnabledObs=this.featureFlagService.isSessionUrlEnabled();bottomPanelVisible=!1;hoveredEventMessageIndices=[];ngOnInit(){if(this.syncSelectedAppFromUrl(),this.updateSelectedAppUrl(),this.webSocketService.onCloseReason().subscribe(i=>{let n=`Please check server log for full details: 
`+i;this.openSnackBar(n,"OK")}),new URL(window.location.href).searchParams.has("code")){let i=window.location.href;window.opener?.postMessage({authResponseUrl:i},window.origin),window.close()}this.agentService.getApp().subscribe(i=>{this.appName=i}),Ls([this.agentService.getLoadingState(),this.isModelThinkingSubject]).subscribe(([i,n])=>{let o=this.messages[this.messages.length-1];i?!o?.isLoading&&!this.streamingTextMessage&&(this.messages.push({role:"bot",isLoading:!0}),this.messagesSubject.next(this.messages)):o?.isLoading&&!n&&(this.messages.pop(),this.messagesSubject.next(this.messages),this.changeDetectorRef.detectChanges())}),Ls([this.messagesSubject,this.scrollInterruptedSubject,this.streamingTextMessageSubject]).subscribe(([i,n,o])=>{n||setTimeout(()=>{this.scrollToBottom()},100)}),this.traceService.selectedTraceRow$.subscribe(i=>{let n=i?.attributes["gcp.vertex.agent.event_id"];n&&this.eventData.has(n)?this.bottomPanelVisible=!0:this.bottomPanelVisible=!1}),this.traceService.hoveredMessageIndicies$.subscribe(i=>this.hoveredEventMessageIndices=i)}ngAfterViewInit(){this.showSidePanel=!0,this.sideDrawer.open()}scrollToBottom(){setTimeout(()=>{this.scrollContainer.nativeElement.scrollTo({top:this.scrollContainer.nativeElement.scrollHeight,behavior:"smooth"})})}selectApp(e){e!=this.appName&&(this.agentService.setApp(e),this.isSessionUrlEnabledObs.subscribe(A=>{let i=this.activatedRoute.snapshot.queryParams.session;if(!A||!i){this.createSessionAndReset();return}i&&this.sessionService.getSession(this.userId,this.appName,i).pipe(Pn(1),dr(n=>(this.openSnackBar("Cannot find specified session. Creating a new one.","OK"),this.createSessionAndReset(),ve(null)))).subscribe(n=>{n&&this.updateWithSelectedSession(n)})}))}createSessionAndReset(){this.createSession(),this.eventData=new Map,this.eventMessageIndexArray=[],this.messages=[],this.artifacts=[],this.userInput="",this.longRunningEvents=[]}createSession(){this.sessionService.createSession(this.userId,this.appName).subscribe(e=>{this.currentSessionState=e.state,this.sessionId=e.id,this.sessionTab.refreshSession(),this.isSessionUrlEnabledObs.subscribe(A=>{A&&this.updateSelectedSessionUrl()})})}sendMessage(e){return _n(this,null,function*(){if(this.messages.length===0&&(this.scrollContainer.nativeElement.addEventListener("wheel",()=>{this.scrollInterruptedSubject.next(!0)}),this.scrollContainer.nativeElement.addEventListener("touchmove",()=>{this.scrollInterruptedSubject.next(!0)})),this.scrollInterruptedSubject.next(!1),e.preventDefault(),!this.userInput.trim()&&this.selectedFiles.length<=0||e instanceof KeyboardEvent&&e.isComposing)return;if(this.userInput.trim()&&(this.messages.push({role:"user",text:this.userInput}),this.messagesSubject.next(this.messages)),this.selectedFiles.length>0){let n=this.selectedFiles.map(o=>({file:o.file,url:o.url}));this.messages.push({role:"user",attachments:n}),this.messagesSubject.next(this.messages)}let A={appName:this.appName,userId:this.userId,sessionId:this.sessionId,newMessage:{role:"user",parts:yield this.getUserMessageParts()},streaming:this.useSse};this.selectedFiles=[];let i=this.eventMessageIndexArray.length-1;this.streamingTextMessage=null,this.agentService.runSse(A).subscribe({next:n=>_n(this,null,function*(){if(n.startsWith('{"error"')){this.openSnackBar(n,"OK");return}let o=JSON.parse(n);if(o.error){this.openSnackBar(o.error,"OK");return}if(o.content)for(let r of o.content.parts)i+=1,this.processPart(o,r,i),this.traceService.setEventData(this.eventData);this.changeDetectorRef.detectChanges()}),error:n=>console.error("SSE error:",n),complete:()=>{this.streamingTextMessage=null,this.sessionTab.reloadSession(this.sessionId),this.eventService.getTrace(this.sessionId).pipe(dr(n=>n.status===404?ve(null):ve([]))).subscribe(n=>{this.traceData=n,this.changeDetectorRef.detectChanges()}),this.traceService.setMessages(this.messages)}}),this.userInput="",this.changeDetectorRef.detectChanges()})}processPart(e,A,i){let n=e.groundingMetadata?.searchEntryPoint?.renderedContent;if(A.text){this.isModelThinkingSubject.next(!1);let o=A.text;if(A.thought){if(o!==this.latestThought){this.storeEvents(A,e,i);let r={role:"bot",text:this.processThoughtText(o),thought:!0,eventId:e.id};this.insertMessageBeforeLoadingMessage(r)}this.latestThought=o}else if(this.streamingTextMessage){if(n&&(this.streamingTextMessage.renderedContent=e.groundingMetadata.searchEntryPoint.renderedContent),o==this.streamingTextMessage.text){this.storeEvents(A,e,i),this.eventMessageIndexArray[i]=o,this.streamingTextMessage=null;return}this.streamingTextMessage.text+=o,this.streamingTextMessageSubject.next(this.streamingTextMessage)}else if(this.streamingTextMessage={role:"bot",text:this.processThoughtText(o),thought:!!A.thought,eventId:e.id},n&&(this.streamingTextMessage.renderedContent=e.groundingMetadata.searchEntryPoint.renderedContent),this.insertMessageBeforeLoadingMessage(this.streamingTextMessage),!this.useSse){this.storeEvents(A,e,i),this.eventMessageIndexArray[i]=o,this.streamingTextMessage=null;return}}else A.thought?this.isModelThinkingSubject.next(!0):(this.isModelThinkingSubject.next(!1),this.storeEvents(A,e,i),this.storeMessage(A,e,i,e.author==="user"?"user":"bot"))}getUserMessageParts(){return _n(this,null,function*(){let e=[];if(this.userInput.trim()&&e.push({text:`${this.userInput}`}),this.selectedFiles.length>0)for(let A of this.selectedFiles)e.push({inlineData:{displayName:A.file.name,data:yield this.readFileAsBytes(A.file),mimeType:A.file.type}});return e})}readFileAsBytes(e){return new Promise((A,i)=>{let n=new FileReader;n.onload=o=>{let r=o.target.result.split(",")[1];A(r)},n.onerror=i,n.readAsDataURL(e)})}updateRedirectUri(e,A){try{let i=new URL(e);return i.searchParams.set("redirect_uri",A),i.toString()}catch(i){return console.warn("Failed to update redirect URI: ",i),e}}storeMessage(e,A,i,n,o,r){if(A?.author&&this.createAgentIconColorClass(A.author),A?.longRunningToolIds&&A.longRunningToolIds.length>0){this.getAsyncFunctionsFromParts(A.longRunningToolIds,A.content.parts);let a=this.longRunningEvents[0];if(a.args.authConfig&&a.args.authConfig.exchangedAuthCredential&&a.args.authConfig.exchangedAuthCredential.oauth2){let c=a.args.authConfig.exchangedAuthCredential.oauth2.authUri,l=this.updateRedirectUri(c,this.redirectUri);this.openOAuthPopup(l).then(I=>{this.functionCallEventId=A.id,this.sendOAuthResponse(a,I,this.redirectUri)}).catch(I=>{console.error("OAuth Error:",I)})}else this.functionCallEventId=A.id}if(A?.actions&&A.actions.artifactDelta)for(let a in A.actions.artifactDelta)A.actions.artifactDelta.hasOwnProperty(a)&&this.renderArtifact(a,A.actions.artifactDelta[a]);A?.evalStatus&&this.isChatMode.set(!1);let s={role:n,evalStatus:A?.evalStatus,failedMetric:A?.failedMetric,evalScore:A?.evalScore,evalThreshold:A?.evalThreshold,actualInvocationToolUses:A?.actualInvocationToolUses,expectedInvocationToolUses:A?.expectedInvocationToolUses,actualFinalResponse:A?.actualFinalResponse,expectedFinalResponse:A?.expectedFinalResponse,invocationIndex:o!==void 0?o:void 0,finalResponsePartIndex:r?.finalResponsePartIndex!==void 0?r.finalResponsePartIndex:void 0,toolUseIndex:r?.toolUseIndex!==void 0?r.toolUseIndex:void 0};if(e.inlineData){let a=this.formatBase64Data(e.inlineData.data,e.inlineData.mimeType);s.inlineData={displayName:e.inlineData.displayName,data:a,mimeType:e.inlineData.mimeType},this.eventMessageIndexArray[i]=e.inlineData}else if(e.text)s.text=e.text,s.thought=!!e.thought,A?.groundingMetadata&&A.groundingMetadata.searchEntryPoint&&A.groundingMetadata.searchEntryPoint.renderedContent&&(s.renderedContent=A.groundingMetadata.searchEntryPoint.renderedContent),s.eventId=A?.id,this.eventMessageIndexArray[i]=e.text;else if(e.functionCall)s.functionCall=e.functionCall,s.eventId=A?.id,this.eventMessageIndexArray[i]=e.functionCall;else if(e.functionResponse)s.functionResponse=e.functionResponse,s.eventId=A?.id,this.eventMessageIndexArray[i]=e.functionResponse;else if(e.executableCode)s.executableCode=e.executableCode,this.eventMessageIndexArray[i]=e.executableCode;else if(e.codeExecutionResult&&(s.codeExecutionResult=e.codeExecutionResult,this.eventMessageIndexArray[i]=e.codeExecutionResult,A.actions&&A.actions.artifact_delta))for(let a in A.actions.artifact_delta)A.actions.artifact_delta.hasOwnProperty(a)&&this.renderArtifact(a,A.actions.artifact_delta[a]);Object.keys(e).length>0&&this.insertMessageBeforeLoadingMessage(s)}insertMessageBeforeLoadingMessage(e){this.messages[this.messages.length-1]?.isLoading?this.messages.splice(this.messages.length-1,0,e):this.messages.push(e),this.messagesSubject.next(this.messages)}formatBase64Data(e,A){let i=OjA(e);return`data:${A};base64,${i}`}renderArtifact(e,A){let i={role:"bot",inlineData:{data:"",mimeType:"image/png"}};this.insertMessageBeforeLoadingMessage(i);let n=this.messages.length-2;this.artifactService.getArtifactVersion(this.userId,this.appName,this.sessionId,e,A).subscribe(o=>{let r=o.inlineData.mimeType,s=this.formatBase64Data(o.inlineData.data,r),a=h8(r),c={name:this.createDefaultArtifactName(r),data:s,mimeType:r,mediaType:a};this.messages[n]={role:"bot",inlineData:c},this.artifacts=[...this.artifacts,{id:e,data:s,mimeType:r,versionId:A,mediaType:h8(r)}]})}storeEvents(e,A,i){let n="";e.text?n+="text:"+e.text:e.functionCall?n+="functionCall:"+e.functionCall.name:e.functionResponse?n+="functionResponse:"+e.functionResponse.name:e.executableCode?n+="executableCode:"+e.executableCode.code.slice(0,10):e.codeExecutionResult&&(n+="codeExecutionResult:"+e.codeExecutionResult.outcome),A.title=n,this.eventData.set(A.id,A),this.eventData=new Map(this.eventData)}sendOAuthResponse(e,A,i){this.longRunningEvents.pop();let n={appName:this.appName,userId:this.userId,sessionId:this.sessionId,newMessage:{role:"user",parts:[]}};var o=structuredClone(e.args.authConfig);o.exchangedAuthCredential.oauth2.authResponseUri=A,o.exchangedAuthCredential.oauth2.redirectUri=i,n.functionCallEventId=this.functionCallEventId,n.newMessage.parts.push({function_response:{id:e.id,name:e.name,response:o}});let r=[];this.agentService.runSse(n).subscribe({next:s=>_n(this,null,function*(){let a=JSON.parse(s);r.push(a)}),error:s=>console.error("SSE error:",s),complete:()=>{this.processRunSseResponse(r)}})}processRunSseResponse(e){let A=this.eventMessageIndexArray.length-1;for(let i of e)if(i.content)for(let n of i.content.parts)A+=1,this.processPart(i,n,A)}openDialog(){this.dialog.open(rf,{width:"600px",data:{event:this.longRunningEvents[0],appName:this.appName,userId:this.userId,sessionId:this.sessionId,functionCallEventId:this.functionCallEventId}}).afterClosed().subscribe(A=>{A&&(this.removeFinishedLongRunningEvents(A.events),this.processRunSseResponse(A.response))})}removeFinishedLongRunningEvents(e){let A=new Set(e.map(i=>i.id));this.longRunningEvents=this.longRunningEvents.filter(i=>!A.has(i.id))}getAgentNameFromEvent(e){let A=this.messages[e].eventId;return this.eventData.get(A)?.author??this.selectedAppControl.value}customIconColorClass(e){let A=this.getAgentNameFromEvent(e);return`custom-icon-color-${(0,ZG.default)(A).replace("#","")}`}createAgentIconColorClass(e){let A=(0,ZG.default)(e),i=`custom-icon-color-${A.replace("#","")}`;this.injectCustomIconColorStyle(i,A)}clickEvent(e){let A=this.messages[e].eventId;this.sideDrawer.open(),this.showSidePanel=!0,this.selectedEvent=this.eventData.get(A),this.selectedEventIndex=this.getIndexOfKeyInMap(A),this.eventService.getEventTrace(this.selectedEvent.id).subscribe(i=>{this.llmRequest=JSON.parse(i[this.llmRequestKey]),this.llmResponse=JSON.parse(i[this.llmResponseKey])}),this.eventService.getEvent(this.userId,this.appName,this.sessionId,this.selectedEvent.id).subscribe(i=>_n(this,null,function*(){if(!i.dotSrc){this.renderedEventGraph=void 0;return}let n=i.dotSrc,r=(yield vu()).renderString(n,{format:"svg",engine:"dot"});this.rawSvgString=r,this.renderedEventGraph=this.sanitizer.bypassSecurityTrustHtml(r)}))}userMessagesLength(e){return this.messages.slice(0,e).filter(A=>A.role=="user").length}ngOnDestroy(){this.webSocketService.closeConnection()}onAppSelection(e){this.isAudioRecording&&(this.stopAudioRecording(),this.isAudioRecording=!1),this.isVideoRecording&&(this.stopVideoRecording(),this.isVideoRecording=!1),this.evalTab?.resetEvalResults(),this.traceData=[],this.bottomPanelVisible=!1}toggleAudioRecording(){this.isAudioRecording?this.stopAudioRecording():this.startAudioRecording()}startAudioRecording(){if(this.sessionHasUsedBidi.has(this.sessionId)){this.openSnackBar(elA,"OK");return}this.isAudioRecording=!0;let e=window.location.protocol==="https:"?"wss":"ws";this.webSocketService.connect(`${e}://${Es.getWSServerUrl()}/run_live?app_name=${this.appName}&user_id=${this.userId}&session_id=${this.sessionId}`),this.audioService.startRecording(),this.messages.push({role:"user",text:"Speaking..."}),this.messages.push({role:"bot",text:"Speaking..."}),this.messagesSubject.next(this.messages),this.sessionHasUsedBidi.add(this.sessionId)}stopAudioRecording(){this.audioService.stopRecording(),this.webSocketService.closeConnection(),this.isAudioRecording=!1}toggleVideoRecording(){this.isVideoRecording?this.stopVideoRecording():this.startVideoRecording()}startVideoRecording(){if(this.sessionHasUsedBidi.has(this.sessionId)){this.openSnackBar(elA,"OK");return}this.isVideoRecording=!0;let e=window.location.protocol==="https:"?"wss":"ws";this.webSocketService.connect(`${e}://${Es.getWSServerUrl()}/run_live?app_name=${this.appName}&user_id=${this.userId}&session_id=${this.sessionId}`),this.videoService.startRecording(this.videoContainer),this.audioService.startRecording(),this.messages.push({role:"user",text:"Speaking..."}),this.messagesSubject.next(this.messages),this.sessionHasUsedBidi.add(this.sessionId)}stopVideoRecording(){this.audioService.stopRecording(),this.videoService.stopRecording(this.videoContainer),this.webSocketService.closeConnection(),this.isVideoRecording=!1}getAsyncFunctionsFromParts(e,A){for(let i of A)i.functionCall&&e.includes(i.functionCall.id)&&this.longRunningEvents.push(i.functionCall)}openOAuthPopup(e){return new Promise((A,i)=>{if(!window.open(e,"oauthPopup","width=600,height=700")){i("Popup blocked!");return}let o=r=>{if(r.origin!==window.location.origin)return;let{authResponseUrl:s}=r.data;s?(A(s),window.removeEventListener("message",o)):console.log("OAuth failed",r)};window.addEventListener("message",o)})}toggleSidePanel(){this.showSidePanel?this.sideDrawer.close():this.sideDrawer.open(),this.showSidePanel=!this.showSidePanel}handleTabChange(e){this.isChatMode()||(this.resetEditEvalCaseVars(),this.handleReturnToSession(!0))}handleShouldShowEvalTab(e){this.shouldShowEvalTab.set(e)}handleReturnToSession(e){this.sessionTab.getSession(this.sessionId),this.evalTab.resetEvalCase(),this.isChatMode.set(!0)}handleEvalNotInstalled(e){e&&this.openSnackBar(e,"OK")}resetEventsAndMessages(){this.eventData.clear(),this.eventMessageIndexArray=[],this.messages=[],this.messagesSubject.next(this.messages),this.artifacts=[]}updateWithSelectedSession(e){if(!e||!e.id||!e.events||!e.state)return;this.traceService.resetTraceService(),this.sessionId=e.id,this.currentSessionState=e.state,this.evalCase=null,this.isChatMode.set(!0),this.isSessionUrlEnabledObs.subscribe(i=>{i&&this.updateSelectedSessionUrl()}),this.resetEventsAndMessages();let A=0;e.events.forEach(i=>{i.content?.parts?.forEach(n=>{this.storeMessage(n,i,A,i.author==="user"?"user":"bot"),A+=1,i.author&&i.author!=="user"&&this.storeEvents(n,i,A)})}),this.eventService.getTrace(this.sessionId).subscribe(i=>{this.traceData=i,this.traceService.setEventData(this.eventData),this.traceService.setMessages(this.messages)}),this.bottomPanelVisible=!1}updateWithSelectedEvalCase(e){this.evalCase=e,this.isChatMode.set(!1),this.resetEventsAndMessages();let A=0,i=0;for(let n of e.conversation){if(n.userContent?.parts)for(let o of n.userContent.parts)this.storeMessage(o,null,A,"user"),A++;if(n.intermediateData?.toolUses){let o=0;for(let r of n.intermediateData.toolUses){let s={functionCall:{name:r.name,args:r.args}};this.storeMessage(s,null,A,"bot",i,{toolUseIndex:o}),A++,o++;let a={functionResponse:{name:r.name}};this.storeMessage(a,null,A,"bot"),A++}}if(n.finalResponse?.parts){let o=0;for(let r of n.finalResponse.parts)this.storeMessage(r,null,A,"bot",i,{finalResponsePartIndex:o}),A++,o++}i++}}updateSelectedEvalSetId(e){this.evalSetId=e}editEvalCaseMessage(e){this.isEvalCaseEditing.set(!0),this.userEditEvalCaseMessage=e.text,e.isEditing=!0,setTimeout(()=>{this.textarea?.nativeElement.focus();let A=this.textarea?.nativeElement.value.length;e.text.charAt(A-1)===`
`&&A--,this.textarea?.nativeElement.setSelectionRange(A,A)},0)}editFunctionArgs(e){this.isEvalCaseEditing.set(!0),this.dialog.open(W3,{maxWidth:"90vw",maxHeight:"90vh",data:{functionName:e.functionCall.name,args:e.functionCall.args}}).afterClosed().subscribe(i=>{this.isEvalCaseEditing.set(!1),i&&(this.hasEvalCaseChanged.set(!0),e.functionCall.args=i,this.updatedEvalCase=structuredClone(this.evalCase),this.updatedEvalCase.conversation[e.invocationIndex].intermediateData.toolUses[e.toolUseIndex].args=i)})}saveEvalCase(){this.evalService.updateEvalCase(this.appName,this.evalSetId,this.updatedEvalCase.evalId,this.updatedEvalCase).subscribe(e=>{this.openSnackBar("Eval case updated","OK"),this.resetEditEvalCaseVars()})}cancelEditEvalCase(){this.resetEditEvalCaseVars(),this.updateWithSelectedEvalCase(this.evalCase)}resetEditEvalCaseVars(){this.hasEvalCaseChanged.set(!1),this.isEvalCaseEditing.set(!1),this.isEvalEditMode.set(!1),this.updatedEvalCase=null}cancelEditMessage(e){e.isEditing=!1,this.isEvalCaseEditing.set(!1)}saveEditMessage(e){this.hasEvalCaseChanged.set(!0),this.isEvalCaseEditing.set(!1),e.isEditing=!1,e.text=this.userEditEvalCaseMessage?this.userEditEvalCaseMessage:" ",this.updatedEvalCase=structuredClone(this.evalCase),this.updatedEvalCase.conversation[e.invocationIndex].finalResponse.parts[e.finalResponsePartIndex]={text:this.userEditEvalCaseMessage},this.userEditEvalCaseMessage=""}handleKeydown(e,A){e.key==="Enter"&&!e.shiftKey?(e.preventDefault(),this.saveEditMessage(A)):e.key==="Escape"&&this.cancelEditMessage(A)}deleteEvalCaseMessage(e,A){this.hasEvalCaseChanged.set(!0),this.messages.splice(A,1),this.messagesSubject.next(this.messages),this.updatedEvalCase=structuredClone(this.evalCase),this.updatedEvalCase.conversation[e.invocationIndex].finalResponse.parts.splice(e.finalResponsePartIndex,1)}editEvalCase(){this.isEvalEditMode.set(!0)}deleteEvalCase(){let e={title:"Confirm delete",message:`Are you sure you want to delete ${this.evalCase.evalId}?`,confirmButtonText:"Delete",cancelButtonText:"Cancel"};this.dialog.open(dh,{width:"600px",data:e}).afterClosed().subscribe(i=>{i&&(this.evalTab.deleteEvalCase(this.evalCase.evalId),this.openSnackBar("Eval case deleted","OK"))})}updateSessionState(e){this.currentSessionState=e.state}onNewSessionClick(){this.createSession(),this.eventData.clear(),this.eventMessageIndexArray=[],this.messages=[],this.artifacts=[],this.traceData=[],this.bottomPanelVisible=!1,this.evalTab.showEvalHistory&&this.evalTab.toggleEvalHistoryButton()}onFileSelect(e){let A=e.target;if(A.files)for(let i=0;i<A.files.length;i++){let n=A.files[i],o=URL.createObjectURL(n);this.selectedFiles.push({file:n,url:o})}A.value=""}removeFile(e){URL.revokeObjectURL(this.selectedFiles[e].url),this.selectedFiles.splice(e,1)}toggleSse(){this.useSse=!this.useSse}selectEvent(e){this.selectedEvent=this.eventData.get(e),this.selectedEventIndex=this.getIndexOfKeyInMap(e),this.eventService.getEventTrace(this.selectedEvent.id).subscribe(A=>{this.llmRequest=JSON.parse(A[this.llmRequestKey]),this.llmResponse=JSON.parse(A[this.llmResponseKey])}),this.eventService.getEvent(this.userId,this.appName,this.sessionId,this.selectedEvent.id).subscribe(A=>_n(this,null,function*(){if(!A.dotSrc){this.renderedEventGraph=void 0;return}let i=A.dotSrc,o=(yield vu()).renderString(i,{format:"svg",engine:"dot"});this.rawSvgString=o,this.renderedEventGraph=this.sanitizer.bypassSecurityTrustHtml(o)}))}deleteSession(e){let A={title:"Confirm delete",message:`Are you sure you want to delete this session ${this.sessionId}?`,confirmButtonText:"Delete",cancelButtonText:"Cancel"};this.dialog.open(dh,{width:"600px",data:A}).afterClosed().subscribe(n=>{n&&this.sessionService.deleteSession(this.userId,this.appName,e).subscribe(o=>{let r=this.sessionTab.refreshSession(e);r?this.sessionTab.getSession(r.id):window.location.reload()})})}syncSelectedAppFromUrl(){Ls([this.router.events.pipe(pt(e=>e instanceof Za),Je(()=>this.activatedRoute.snapshot.queryParams)),this.apps$]).subscribe(([e,A])=>{if(A&&A.length){let i=e.app;i&&A.includes(i)?this.selectedAppControl.setValue(i):i&&this.openSnackBar(`Agent '${i}' not found`,"OK")}})}updateSelectedAppUrl(){this.selectedAppControl.valueChanges.pipe(Zc(),pt(Boolean)).subscribe(e=>{this.selectApp(e);let A=this.activatedRoute.snapshot.queryParams.app;e!==A&&this.router.navigate([],{queryParams:{app:e},queryParamsHandling:"merge"})})}updateSelectedSessionUrl(){let e=this.router.createUrlTree([],{queryParams:{session:this.sessionId},queryParamsHandling:"merge"}).toString();this.location.replaceState(e)}handlePageEvent(e){if(e.pageIndex>=0){let A=this.getKeyAtIndexInMap(e.pageIndex);A&&this.selectEvent(A)}}closeSelectedEvent(){this.selectedEvent=void 0,this.selectedEventIndex=void 0}getIndexOfKeyInMap(e){let A=0,i=(o,r)=>0,n=Array.from(this.eventData.keys()).sort(i);for(let o of n){if(o===e)return A;A++}}getKeyAtIndexInMap(e){let A=(n,o)=>0,i=Array.from(this.eventData.keys()).sort(A);if(e>=0&&e<i.length)return i[e]}openSnackBar(e,A){this._snackBar.open(e,A)}processThoughtText(e){return e.replace("/*PLANNING*/","").replace("/*ACTION*/","")}openLink(e){window.open(e,"_blank")}renderGooglerSearch(e){return this.sanitizer.bypassSecurityTrustHtml(e)}openViewImageDialog(e){let A=this.dialog.open(m0,{maxWidth:"90vw",maxHeight:"90vh",data:{imageData:e}})}createDefaultArtifactName(e){return!e||!e.includes("/")?"":e.replace("/",".")}exportSession(){this.sessionService.getSession(this.userId,this.appName,this.sessionId).subscribe(e=>{console.log(e),this.downloadService.downloadObjectAsJson(e,`session-${this.sessionId}.json`)})}closeTraceEventDetailPanel(){this.bottomPanelVisible=!1,this.traceService.selectedRow(void 0),this.traceService.setHoveredMessages(void 0,"")}shouldMessageHighlighted(e){return this.hoveredEventMessageIndices.includes(e)}importSession(){let e=document.createElement("input");e.type="file",e.accept="application/json",e.onchange=()=>{if(!e.files||e.files.length===0)return;let A=e.files[0],i=new FileReader;i.onload=n=>{if(n.target?.result)try{let o=JSON.parse(n.target.result);if(!o.userId||!o.appName||!o.events){this.openSnackBar("Invalid session file format","OK");return}this.sessionService.importSession(o.userId,o.appName,o.events).subscribe(r=>{this.openSnackBar("Session imported","OK"),this.sessionTab.refreshSession()})}catch{this.openSnackBar("Error parsing session file","OK")}},i.readAsText(A)},e.click()}injectCustomIconColorStyle(e,A){if(this.document.getElementById(e))return;let i=this.renderer.createElement("style");this.renderer.setAttribute(i,"id",e),this.renderer.setAttribute(i,"type","text/css");let n=`
      .${e} {
        background-color: ${A} !important;
      }
    `;this.renderer.appendChild(i,this.renderer.createText(n)),this.renderer.appendChild(this.document.head,i)}static \u0275fac=function(A){return new(A||t)(zA(il),zA(Jg),zA(Bh),zA(Eh),zA(Tg),zA(hh),zA(Us),zA(j1),zA(ra),zA(J2),zA(zc),zA(zg),zA(Qc),zA(Gi),zA(tt))};static \u0275cmp=YA({type:t,selectors:[["app-chat"]],viewQuery:function(A,i){if(A&1&&(Ge(QPA,5,te),Ge(uPA,5),Ge(jC,5),Ge(qC,5),Ge(PC,5),Ge(fPA,5),Ge(mPA,5),Ge(pPA,5)),A&2){let n;$A(n=Ae())&&(i.videoContainer=n.first),$A(n=Ae())&&(i.sideDrawer=n.first),$A(n=Ae())&&(i.eventTabComponent=n.first),$A(n=Ae())&&(i.sessionTab=n.first),$A(n=Ae())&&(i.evalTab=n.first),$A(n=Ae())&&(i.scrollContainer=n.first),$A(n=Ae())&&(i.textarea=n.first),$A(n=Ae())&&(i.bottomPanelRef=n.first)}},standalone:!1,features:[ct([{provide:TI,useClass:$G}])],decls:28,vars:15,consts:[["sideDrawer",""],["autoScroll",""],["videoContainer",""],["messageTextarea",""],["fileInput",""],["bottomPanel",""],["autosize","",1,"drawer-container"],["matTooltip","Open panel",1,"material-symbols-outlined",2,"position","absolute","width","24px","height","24px","color","#c4c7c5","cursor","pointer","margin-left","20px","margin-top","20px","z-index","9999"],["mode","side","appResizableDrawer","",1,"side-drawer"],[2,"margin-top","20px","margin-left","20px","display","flex"],[2,"width","100%"],[1,"drawer-header"],[1,"drawer-logo"],["src","assets/ADK-512-color.svg","width","32px","height","32px"],["matTooltip","Collapse panel",1,"material-symbols-outlined",2,"color","#c4c7c5","cursor","pointer","margin-right","15px",3,"click"],[1,"app-select-container"],[1,"app-select",3,"selectionChange","placeholder","formControl"],[1,"app-name-option",3,"value"],[1,"tabs-container"],[1,"details-panel-container"],[1,"resize-handler"],[1,"chat-container"],[1,"chat-toolbar",3,"ngClass"],[1,"chat-card"],["mat-fab","","color","primary",1,"fab-button"],[1,"chat-messages"],[1,"chat-input"],["appResizableBottomPanel","",1,"trace-detail-container"],["matTooltip","Open panel",1,"material-symbols-outlined",2,"position","absolute","width","24px","height","24px","color","#c4c7c5","cursor","pointer","margin-left","20px","margin-top","20px","z-index","9999",3,"click"],[3,"selectedTabChange"],[1,"tabs-header"],["mat-tab-label",""],[3,"traceData"],[3,"selectedEvent","eventsMap","traceData"],[3,"sessionState"],[3,"artifacts"],[3,"sessionSelected","sessionReloaded","userId","appName","sessionId"],[1,"tab-label"],[3,"shouldShowTab","sessionSelected","evalCaseSelected","evalSetIdSelected","shouldReturnToSession","evalNotInstalledMsg","appName","userId","sessionId"],[1,"details-content"],[2,"display","flex","justify-content","flex-end","margin-top","10px"],["aria-label","Select event",1,"event-paginator",3,"page","length","pageSize","pageIndex"],["mat-mini-fab",""],[3,"click"],["label","Event"],[1,"event-graph-container"],[3,"innerHtml"],[1,"json-viewer-container"],[3,"json"],["label","Request"],["label","Response"],[3,"click","innerHtml"],["matTooltip","Open panel",1,"material-symbols-outlined",2,"width","24px","height","24px","color","#c4c7c5","cursor","pointer","margin-left","20px","margin-top","-2px","z-index","9999"],["matTooltip","Open panel",1,"material-symbols-outlined",2,"width","24px","height","24px","color","#c4c7c5","cursor","pointer","margin-left","20px","margin-top","-2px","z-index","9999",3,"click"],[2,"display","flex"],[1,"toolbar-session-text"],[1,"toolbar-session-id"],[1,"toolbar-actions"],["mat-button","",2,"height","30px",3,"click"],["mat-flat-button","",2,"height","30px",3,"click","disabled"],["matTooltip","Edit current eval case",1,"material-symbols-outlined","toolbar-icon",3,"click"],["matTooltip","Delete current eval case",1,"material-symbols-outlined","toolbar-icon",3,"click"],[1,"toolbar-sse-toggle"],[1,"example-margin",3,"change","checked"],[2,"margin-left","8px","margin-right","8px","height","22px",3,"vertical"],[2,"display","flex","align-items","center"],[1,"toolbar-new-sesison",3,"click"],["matTooltip","Delete current session",1,"material-symbols-outlined","toolbar-icon",3,"click"],["matTooltip","Export current session",1,"material-symbols-outlined","toolbar-icon",3,"click"],["matTooltip","Import session",1,"material-symbols-outlined","toolbar-icon"],["matTooltip","Import session",1,"material-symbols-outlined","toolbar-icon",3,"click"],[1,"empty-state-container"],[1,"warning"],[1,"error"],["mat-fab","","color","primary",1,"fab-button",3,"click"],[3,"ngClass"],["mat-mini-fab","",3,"matTooltip","class"],[1,"message-card",3,"ngClass","ngStyle"],["mat-stroked-button","",1,"function-event-button",3,"ngClass"],[1,"material-symbols-outlined"],["mat-mini-fab","",3,"click","matTooltip"],["fontSet","material-symbols-outlined"],["mode","buffer",1,"loading-bar"],[1,"attachments"],[1,"thought-chip"],[1,"eval-compare-container"],[1,"attachment"],["alt","attachment",1,"image-preview-chat",3,"src"],["download","",3,"href"],[1,"edit-message-container"],[1,"message-text",3,"data","ngStyle"],["rows","4","cols","80",1,"message-textarea",3,"ngModelChange","keydown","ngModel"],[1,"edit-message-buttons-container"],["matTooltip","Cancel editing",1,"material-symbols-outlined",2,"width","24px","height","24px","color","#c4c7c5","cursor","pointer","margin-right","16px",3,"click"],["matTooltip","Save eval case message",1,"material-symbols-outlined",2,"width","24px","height","24px","color","rgb(97, 151, 202)","cursor","pointer","margin-right","16px",3,"click"],[3,"innerHTML"],[1,"generated-image-container"],["alt","image",1,"generated-image",3,"click","src"],[3,"base64data"],[1,"html-artifact-container"],[1,"link-style-button",3,"click"],["alt","image",1,"image-preview-chat",3,"click","src"],[1,"actual-expected-compare-container"],[1,"score-threshold-container"],[1,"actual-result"],[1,"eval-response-header","header-actual"],[1,"expected-result"],[1,"eval-response-header","header-expected"],[1,"header-actual"],[1,"header-expected"],["mat-stroked-button","",1,"function-event-button",3,"click","ngClass"],["matTooltip","Edit eval case message",1,"material-symbols-outlined","eval-case-edit-button",3,"click","ngClass"],["matTooltip","Delete eval case message",1,"material-symbols-outlined","eval-case-edit-button",3,"click","ngClass"],["matTooltip","Edit function arguments",1,"material-symbols-outlined","eval-case-edit-button",3,"click","ngClass"],["type","file","multiple","","hidden","",3,"change"],["appearance","outline",1,"input-field"],[1,"file-preview"],["matInput","","cdkTextareaAutosize","","cdkAutosizeMinRows","1","cdkAutosizeMaxRows","10","placeholder","Type a Message...",1,"chat-input-box",2,"caret-color","white",3,"ngModelChange","keydown.enter","ngModel"],[1,"chat-input-actions"],["mat-icon-button","","matTooltip","Upload local file",1,"function-event-button",3,"click"],["mat-icon-button","","matSuffix","",3,"click","ngStyle","matTooltip"],[1,"image-container"],[1,"file-container"],["alt","preview",1,"image-preview",3,"src"],["mat-icon-button","",1,"delete-button",3,"click"],["color","warn"],[1,"file-info"],[1,"bottom-resize-handler"],[3,"panelClosed","userId","appName","sessionId"]],template:function(A,i){if(A&1){let n=De();S(0,"mat-drawer-container",6),NA(1,kPA,2,0,"span",7),S(2,"mat-drawer",8,0)(4,"div",9)(5,"div",10)(6,"div",11)(7,"div",12),UA(8,"img",13),tA(9," Agent Development Kit "),R(),S(10,"span",14),mA("click",function(){return LA(n),xA(i.toggleSidePanel())}),tA(11,"left_panel_close"),R()()()(),S(12,"div",15)(13,"mat-select",16),mA("selectionChange",function(r){return LA(n),xA(i.onAppSelection(r))}),NA(14,RPA,2,0),Ta(15,"async"),NA(16,LPA,2,2,"mat-option",17),R()(),NA(17,YPA,18,9,"div",18)(18,TPA,20,7,"div",19),UA(19,"div",20),R(),S(20,"div",21),NA(21,VPA,4,5,"div",22),S(22,"mat-card",23),NA(23,tjA,2,1)(24,ijA,3,0,"button",24)(25,UjA,6,0,"div",25)(26,zjA,17,10,"div",26),R(),NA(27,HjA,4,3,"div",27),R()()}if(A&2){let n;_(),FA(!i.showSidePanel&&i.appName===""?1:-1),_(12),vA("placeholder",i.isLoadingApps()?"Loading...":"Select an agent")("formControl",i.selectedAppControl),_(),FA((n=w2(15,13,i.apps$))?14:-1,n),_(2),FA(i.selectedAppControl.value&&i.isLoadingApps()?16:-1),_(),FA(i.appName!=""&&i.showSidePanel?17:-1),_(),FA(i.selectedEvent&&i.showSidePanel?18:-1),_(3),FA(i.appName!=""?21:-1),_(2),FA(i.selectedAppControl.value?-1:23),_(),FA(i.longRunningEvents.length>0?24:-1),_(),FA(i.appName!=""?25:-1),_(),FA(i.appName!=""&&i.isChatMode()?26:-1),_(),FA(i.bottomPanelVisible?27:-1)}},dependencies:[Ha,yQ,fc,na,ja,rcA,T2,lg,gP,P1,JaA,ur,EB,HO,zO,Sk,ZaA,Qh,RG,LG,GG,af,Py,pB,x2,wB,mcA,TcA,Xy,cM,jC,qC,PC,Su,df,zI,Bf,Ef,Qf,uf,bQ],styles:[".expand-side-drawer[_ngcontent-%COMP%]{position:relative;top:4%;left:1%}.drawer-container[_ngcontent-%COMP%]{height:100%;background-color:#131314}.generated-image-container[_ngcontent-%COMP%]{max-width:400px}.generated-image[_ngcontent-%COMP%]{max-width:100%;min-width:40px;border-radius:8px}.chat-container[_ngcontent-%COMP%]{width:100%;height:100%;max-width:100%;margin:auto;display:flex;flex-direction:column;flex:1}.event-container[_ngcontent-%COMP%]{color:#fff}.html-artifact-container[_ngcontent-%COMP%], .drawer-header[_ngcontent-%COMP%]{width:100%;display:flex;justify-content:flex-start;align-items:center}.drawer-header[_ngcontent-%COMP%]   .mat-icon[_ngcontent-%COMP%]{width:36px;height:36px;color:#bdc1c6;cursor:pointer;display:flex;align-items:center;justify-content:center}.chat-card[_ngcontent-%COMP%]{display:flex;flex-direction:column;overflow:hidden;flex:1;min-height:12%;box-shadow:none;background-color:#131314}.loading-bar[_ngcontent-%COMP%]{width:100px;margin:15px}.chat-messages[_ngcontent-%COMP%]{flex-grow:1;overflow-y:auto;padding:20px;margin-top:16px}.message-card[_ngcontent-%COMP%]{padding:5px 20px;margin:5px;border-radius:20px;max-width:80%;font-size:14px;font-weight:400;position:relative;display:inline-block}.function-event-button[_ngcontent-%COMP%]{background-color:#fff;margin:5px 5px 10px}.function-event-button-highlight[_ngcontent-%COMP%]{background-color:#0f5223;border-color:#0f5223!important;color:#fff!important}.user-message[_ngcontent-%COMP%]{display:flex;justify-content:flex-end;align-items:center}.user-message[_ngcontent-%COMP%]   .message-card[_ngcontent-%COMP%]{background-color:#004a77;align-self:flex-end;color:#fff;box-shadow:none}.bot-message[_ngcontent-%COMP%]{display:flex;align-items:center}.bot-message[_ngcontent-%COMP%]   .message-card[_ngcontent-%COMP%]{background-color:#303030;align-self:flex-start;color:#fff;box-shadow:none}.bot-message[_ngcontent-%COMP%]:focus-within   .message-card[_ngcontent-%COMP%]{background-color:#131314;border:1px solid #8ab4f8}.message-textarea[_ngcontent-%COMP%]{background-color:#303030;max-width:100%;border:none;font-family:Google Sans,Helvetica Neue,sans-serif}.message-textarea[_ngcontent-%COMP%]:focus{background-color:#131314;outline:none}.edit-message-buttons-container[_ngcontent-%COMP%]{display:flex;justify-content:flex-end}.message-card[_ngcontent-%COMP%]   .eval-compare-container[_ngcontent-%COMP%]{visibility:hidden;position:absolute;left:10px;z-index:10;background-color:#484848;overflow:hidden;border-radius:20px;padding:5px 20px;margin-bottom:10px;font-size:16px}.message-card[_ngcontent-%COMP%]   .eval-compare-container[_ngcontent-%COMP%]   .actual-result[_ngcontent-%COMP%]{border-right:2px solid #8a8686;padding-right:8px;min-width:350px;max-width:350px}.message-card[_ngcontent-%COMP%]   .eval-compare-container[_ngcontent-%COMP%]   .expected-result[_ngcontent-%COMP%]{padding-left:12px;min-width:350px;max-width:350px}.message-card[_ngcontent-%COMP%]:hover   .eval-compare-container[_ngcontent-%COMP%]{visibility:visible}.actual-expected-compare-container[_ngcontent-%COMP%]{display:flex}.score-threshold-container[_ngcontent-%COMP%]{display:flex;justify-content:center;gap:10px;align-items:center;margin-top:15px;font-size:14px;font-weight:600}.eval-response-header[_ngcontent-%COMP%]{padding-bottom:5px;border-bottom:2px solid #8a8686;font-style:italic;font-weight:700}.header-expected[_ngcontent-%COMP%]{color:#44c265}.header-actual[_ngcontent-%COMP%]{color:#ff8983}.eval-case-edit-button[_ngcontent-%COMP%]{cursor:pointer;margin-left:4px;margin-right:4px}.eval-pass[_ngcontent-%COMP%]{display:flex;color:#44c265}.eval-fail[_ngcontent-%COMP%]{display:flex;color:#ff8983}.navigation-button-sidepanel[_ngcontent-%COMP%]{margin-left:auto;margin-right:20px}.chat-input[_ngcontent-%COMP%]{display:flex;padding:10px;width:60%;margin:0 auto}.hidden[_ngcontent-%COMP%]{visibility:hidden}.input-field[_ngcontent-%COMP%]{flex-grow:1}.input-field[_ngcontent-%COMP%]   textarea[_ngcontent-%COMP%]{color:#fff;border:none;padding:10px;box-sizing:content-box}.input-field[_ngcontent-%COMP%]   textarea[_ngcontent-%COMP%]::placeholder{color:#8e918f}.input-field[_ngcontent-%COMP%]   button[_ngcontent-%COMP%]{color:#fff;background-color:#333537}.chat-input-actions[_ngcontent-%COMP%]{width:106%;margin-top:10px;display:flex;justify-content:space-between}.chat-input-actions[_ngcontent-%COMP%]   button[_ngcontent-%COMP%]{margin-left:10px;margin-right:10px}.fab-button[_ngcontent-%COMP%]{position:fixed;bottom:200px;right:100px;z-index:1000}.sidepanel-toggle[_ngcontent-%COMP%]{position:relative;top:100px;z-index:1000}.side-drawer[_ngcontent-%COMP%]{background-color:#1b1b1b;color:#fff;border-radius:0}.tabs-container[_ngcontent-%COMP%]{width:100%;margin-top:20px}.tab-label[_ngcontent-%COMP%]{font-size:14px}.file-preview[_ngcontent-%COMP%]{display:flex;flex-wrap:wrap;gap:5px;margin-top:2px;margin-bottom:8px}.file-item[_ngcontent-%COMP%]{display:flex;align-items:center;gap:5px;background:#eee;padding:5px;border-radius:4px}.image-preview[_ngcontent-%COMP%]{width:40px;height:40px;object-fit:cover;border-radius:4px}.image-preview-chat[_ngcontent-%COMP%]{max-width:90%;max-height:70vh;width:auto;height:auto;border-radius:8px;cursor:pointer;transition:transform .2s ease-in-out}button[_ngcontent-%COMP%]{margin-left:20px;margin-right:20px}.app-select[_ngcontent-%COMP%]{width:100%}.empty-state-container[_ngcontent-%COMP%]{color:#eee;height:100%;display:flex;flex-direction:column;justify-content:center;align-items:center;font-family:Google Sans,sans-serif;font-weight:400;letter-spacing:normal;line-height:24px;font-size:18px}.empty-state-container[_ngcontent-%COMP%]   pre.warning[_ngcontent-%COMP%]{color:#ffc185}.empty-state-container[_ngcontent-%COMP%]   pre.error[_ngcontent-%COMP%]{color:#ff4545}[_nghost-%COMP%]     .mat-mdc-unelevated-button:not(:disabled){color:#202124;background-color:#8ab4f8}[_nghost-%COMP%]     .message-text p{white-space:pre-line;word-break:break-word;overflow-wrap:break-word}[_nghost-%COMP%]     .mdc-linear-progress__buffer-dots{background:#fff}[_nghost-%COMP%]     .mat-mdc-select-arrow-wrapper{margin-left:4px}[_nghost-%COMP%]     .mat-mdc-text-field-wrapper{border:1px solid #8e918f}[_nghost-%COMP%]     .input-field .mat-mdc-text-field-wrapper{border:1px solid #8e918f;border-radius:16px}[_nghost-%COMP%]     .mdc-notched-outline__leading, [_nghost-%COMP%]     .mdc-notched-outline__notch, [_nghost-%COMP%]     .mdc-notched-outline__trailing{border:none}[_nghost-%COMP%]     .mat-mdc-form-field-icon-suffix{padding:0 10px 0 40px}[_nghost-%COMP%]     .segment-key{color:#d3d3d3!important}[_nghost-%COMP%]     .mat-mdc-mini-fab{background-color:#fff}[_nghost-%COMP%]     .mat-mdc-mini-fab mat-icon{color:#000}.mat-mdc-select-placeholder[_ngcontent-%COMP%]{margin-left:20px}.resize-handler[_ngcontent-%COMP%]{background:#5f6368;width:4px;border-radius:4px;position:absolute;display:block;height:20%;top:40%;right:0;z-index:9999;cursor:ew-resize}.bottom-resize-handler[_ngcontent-%COMP%]{background:#5f6368;height:5px;border-radius:4px;position:absolute;display:block;width:20%;left:40%;top:0;right:0;z-index:9999;cursor:ns-resize}.trace-detail-container[_ngcontent-%COMP%]{position:relative;background-color:#1b1b1b}.trace-detail-container[_ngcontent-%COMP%]   app-trace-event[_ngcontent-%COMP%]{padding-top:8px}.new-session-button[_ngcontent-%COMP%]{margin-top:0;margin-left:50px;width:130px;height:28px;font-size:14px}.app-select-container[_ngcontent-%COMP%]{width:35%;margin-top:12px;background-color:#212123;margin-left:10px;height:30px;display:flex;justify-content:space-between;padding-left:20px;padding-right:20px;border-radius:10px;padding-top:5px}.app-select-container[_ngcontent-%COMP%]{--mat-select-placeholder-text-color: #8ab4f8}.app-select-container[_ngcontent-%COMP%]{--mat-select-enabled-trigger-text-color: #8ab4f8}.app-select-container[_ngcontent-%COMP%]{--mat-select-enabled-arrow-color: #8ab4f8}.json-viewer-container[_ngcontent-%COMP%]{margin:10px}.event-paginator[_ngcontent-%COMP%]{margin-top:-8px;margin-right:auto;background-color:inherit;display:flex;justify-content:center}[_nghost-%COMP%]     .mat-mdc-paginator-page-size{display:none!important}.details-panel-container[_ngcontent-%COMP%]{position:absolute;width:100%;height:98%;left:0;right:0;bottom:0;background:#242424;display:inline-block;justify-content:center;align-items:center;z-index:10}.details-content[_ngcontent-%COMP%]{color:#fff;font-size:14px}.adk-checkbox[_ngcontent-%COMP%]{position:fixed;bottom:0;left:0;right:0;margin-bottom:20px;margin-left:20px}.drawer-header[_ngcontent-%COMP%]{display:flex;justify-content:space-between}.drawer-header[_ngcontent-%COMP%]{--mdc-filled-button-container-color: #89b4f8}.drawer-header[_ngcontent-%COMP%]{--mdc-filled-button-label-text-color: black}.chat-toolbar[_ngcontent-%COMP%]{position:sticky;top:0;height:48px;background:#1b1b1b;display:flex;align-items:center;z-index:10}.chat-toolbar.edit-mode[_ngcontent-%COMP%]{background:#44c2651a}.attachment[_ngcontent-%COMP%]{display:flex;align-items:center}.toolbar-actions[_ngcontent-%COMP%]{margin-left:auto;display:flex;align-items:center}.toolbar-session-text[_ngcontent-%COMP%]{color:#fdfdfd;font-family:Roboto;font-size:12px;font-style:normal;font-weight:500;line-height:12px;letter-spacing:.8px;text-transform:uppercase;margin-left:20px;padding-top:4px}.toolbar-session-id[_ngcontent-%COMP%]{color:#9aa0a6;font-family:Google Sans Mono,monospace;font-size:14px;font-style:normal;font-weight:400;line-height:20px;letter-spacing:.25px;margin-left:5px}.toolbar-icon[_ngcontent-%COMP%]{width:24px;height:24px;color:#c4c7c5;cursor:pointer;margin-right:16px}.toolbar-new-sesison[_ngcontent-%COMP%]{font-size:14px;margin-right:16px;color:#9aa0a6;cursor:pointer;display:flex;align-items:center}.toolbar-sse-toggle[_ngcontent-%COMP%]{--mat-switch-label-text-size: 14px}.toolbar-sse-toggle[_ngcontent-%COMP%]{--mat-switch-label-text-color: #9aa0a6}.toolbar-sse-toggle[_ngcontent-%COMP%]{--mdc-switch-selected-track-color: #8ab4f9}.toolbar-sse-toggle[_ngcontent-%COMP%]{--mdc-switch-selected-focus-track-color: #8ab4f9}.toolbar-sse-toggle[_ngcontent-%COMP%]{--mdc-switch-selected-hover-track-color: #8ab4f9}.toolbar-sse-toggle[_ngcontent-%COMP%]{--mdc-switch-selected-handle-color: #1b73e8}.toolbar-sse-toggle[_ngcontent-%COMP%]{--mdc-switch-selected-focus-handle-color: #1b73e8}.toolbar-sse-toggle[_ngcontent-%COMP%]{--mdc-switch-selected-hover-handle-color: #1b73e8}.toolbar-sse-toggle[_ngcontent-%COMP%]{--mdc-switch-track-height: 24px}.toolbar-sse-toggle[_ngcontent-%COMP%]{--mdc-switch-track-width: 46px}.toolbar-sse-toggle[_ngcontent-%COMP%]{--mat-switch-track-outline-color: #1b73e8}.toolbar-sse-toggle[_ngcontent-%COMP%]{--mat-switch-with-icon-handle-size: 20px}.image-container[_ngcontent-%COMP%]{position:relative;display:inline-block;border-radius:12px;overflow:hidden}.image-preview[_ngcontent-%COMP%]{display:block;width:100%;height:auto;border-radius:12px;width:80px;height:80px}.delete-button[_ngcontent-%COMP%]{position:absolute;top:1px;right:1px;background-color:#000000b3;border:none;border-radius:50%;padding:8px;cursor:pointer;color:#fff;display:flex;align-items:center;justify-content:center;margin-right:0;scale:.7}.delete-button[_ngcontent-%COMP%]   mat-icon[_ngcontent-%COMP%]{font-size:20px}.file-container[_ngcontent-%COMP%]{position:relative;display:flex;flex-direction:column;gap:8px;height:80px;background-color:#1e1e1e;border-radius:12px}.file-info[_ngcontent-%COMP%]{margin-right:60px;padding-top:20px;padding-left:16px}.thought-chip[_ngcontent-%COMP%]{border-radius:5px;background-color:#8ab4f8;width:80px;text-align:center;margin-top:5px}.event-graph-container[_ngcontent-%COMP%]{margin-top:16px;margin-bottom:16px;display:flex;justify-content:center;max-height:33%;cursor:pointer}.event-graph-container[_ngcontent-%COMP%]     svg{width:100%;height:100%;display:block;object-fit:contain}.event-graph-container[_ngcontent-%COMP%]     svg text{font-family:Google Sans Mono,monospace;font-size:11px}[_nghost-%COMP%]     pre{white-space:pre-wrap;word-break:break-word;overflow-x:auto;max-width:100%}.link-style-button[_ngcontent-%COMP%]{background:none;border:none;padding:0;font:inherit;color:#007bff!important;text-decoration:underline;cursor:pointer;outline:none;font-size:14px}.drawer-logo[_ngcontent-%COMP%]{margin-left:9px;display:flex;align-items:center;font-size:16px;font-style:normal;font-weight:500;line-height:24px;letter-spacing:.1px}.drawer-logo[_ngcontent-%COMP%]   img[_ngcontent-%COMP%]{margin-right:9px}  .mat-drawer-content{display:flex!important}  .mat-drawer{border-right:1px solid #444746!important}.app-name-option[_ngcontent-%COMP%], .app-select[_ngcontent-%COMP%]{color:#9aa0a6;font-family:Google Sans Mono,monospace;font-style:normal;font-weight:400;padding-left:unset}"],changeDetection:0})};var mh=class t{title="agent_framework_web";userId="";appName="";sessionId="";constructor(){}static \u0275fac=function(A){return new(A||t)};static \u0275cmp=YA({type:t,selectors:[["app-root"]],standalone:!1,decls:1,vars:0,template:function(A,i){A&1&&UA(0,"app-chat")},dependencies:[ff],encapsulation:2})};var jjA=[{path:"",component:mh}],$y=class t{static \u0275fac=function(A){return new(A||t)};static \u0275mod=ge({type:t});static \u0275inj=le({imports:[R6.forRoot(jjA),R6]})};function ilA(t){return new ZA(3e3,!1)}function qjA(){return new ZA(3100,!1)}function VjA(){return new ZA(3101,!1)}function ZjA(t){return new ZA(3001,!1)}function WjA(t){return new ZA(3003,!1)}function XjA(t){return new ZA(3004,!1)}function olA(t,e){return new ZA(3005,!1)}function rlA(){return new ZA(3006,!1)}function slA(){return new ZA(3007,!1)}function alA(t,e){return new ZA(3008,!1)}function clA(t){return new ZA(3002,!1)}function llA(t,e,A,i,n){return new ZA(3010,!1)}function glA(){return new ZA(3011,!1)}function IlA(){return new ZA(3012,!1)}function ClA(){return new ZA(3200,!1)}function dlA(){return new ZA(3202,!1)}function BlA(){return new ZA(3013,!1)}function ElA(t){return new ZA(3014,!1)}function hlA(t){return new ZA(3015,!1)}function QlA(t){return new ZA(3016,!1)}function ulA(t,e){return new ZA(3404,!1)}function $jA(t){return new ZA(3502,!1)}function flA(t){return new ZA(3503,!1)}function mlA(){return new ZA(3300,!1)}function plA(t){return new ZA(3504,!1)}function wlA(t){return new ZA(3301,!1)}function DlA(t,e){return new ZA(3302,!1)}function ylA(t){return new ZA(3303,!1)}function vlA(t,e){return new ZA(3400,!1)}function blA(t){return new ZA(3401,!1)}function MlA(t){return new ZA(3402,!1)}function klA(t,e){return new ZA(3505,!1)}function n2(t){switch(t.length){case 0:return new ag;case 1:return t[0];default:return new JI(t)}}function iU(t,e,A=new Map,i=new Map){let n=[],o=[],r=-1,s=null;if(e.forEach(a=>{let c=a.get("offset"),l=c==r,I=l&&s||new Map;a.forEach((C,d)=>{let B=d,E=C;if(d!=="offset")switch(B=t.normalizePropertyName(B,n),E){case mB:E=A.get(d);break;case pc:E=i.get(d);break;default:E=t.normalizeStyleValue(d,B,E,n);break}I.set(B,E)}),l||o.push(I),s=I,r=c}),n.length)throw $jA(n);return o}function A7(t,e,A,i){switch(e){case"start":t.onStart(()=>i(A&&AU(A,"start",t)));break;case"done":t.onDone(()=>i(A&&AU(A,"done",t)));break;case"destroy":t.onDestroy(()=>i(A&&AU(A,"destroy",t)));break}}function AU(t,e,A){let i=A.totalTime,n=!!A.disabled,o=e7(t.element,t.triggerName,t.fromState,t.toState,e||t.phaseName,i??t.totalTime,n),r=t._data;return r!=null&&(o._data=r),o}function e7(t,e,A,i,n="",o=0,r){return{element:t,triggerName:e,fromState:A,toState:i,phaseName:n,totalTime:o,disabled:!!r}}function Sa(t,e,A){let i=t.get(e);return i||t.set(e,i=A),i}function nU(t){let e=t.indexOf(":"),A=t.substring(1,e),i=t.slice(e+1);return[A,i]}var AqA=typeof document>"u"?null:document.documentElement;function t7(t){let e=t.parentNode||t.host||null;return e===AqA?null:e}function eqA(t){return t.substring(1,6)=="ebkit"}var WC=null,nlA=!1;function SlA(t){WC||(WC=tqA()||{},nlA=WC.style?"WebkitAppearance"in WC.style:!1);let e=!0;return WC.style&&!eqA(t)&&(e=t in WC.style,!e&&nlA&&(e="Webkit"+t.charAt(0).toUpperCase()+t.slice(1)in WC.style)),e}function tqA(){return typeof document<"u"?document.body:null}function oU(t,e){for(;e;){if(e===t)return!0;e=t7(e)}return!1}function rU(t,e,A){if(A)return Array.from(t.querySelectorAll(e));let i=t.querySelector(e);return i?[i]:[]}var iqA=1e3,sU="{{",nqA="}}",aU="ng-enter",i7="ng-leave",mf="ng-trigger",pf=".ng-trigger",cU="ng-animating",n7=".ng-animating";function Pg(t){if(typeof t=="number")return t;let e=t.match(/^(-?[\.\d]+)(m?s)/);return!e||e.length<2?0:eU(parseFloat(e[1]),e[2])}function eU(t,e){switch(e){case"s":return t*iqA;default:return t}}function wf(t,e,A){return t.hasOwnProperty("duration")?t:oqA(t,e,A)}function oqA(t,e,A){let i=/^(-?[\.\d]+)(m?s)(?:\s+(-?[\.\d]+)(m?s))?(?:\s+([-a-z]+(?:\(.+?\))?))?$/i,n,o=0,r="";if(typeof t=="string"){let s=t.match(i);if(s===null)return e.push(ilA(t)),{duration:0,delay:0,easing:""};n=eU(parseFloat(s[1]),s[2]);let a=s[3];a!=null&&(o=eU(parseFloat(a),s[4]));let c=s[5];c&&(r=c)}else n=t;if(!A){let s=!1,a=e.length;n<0&&(e.push(qjA()),s=!0),o<0&&(e.push(VjA()),s=!0),s&&e.splice(a,0,ilA(t))}return{duration:n,delay:o,easing:r}}function RlA(t){return t.length?t[0]instanceof Map?t:t.map(e=>new Map(Object.entries(e))):[]}function Nl(t,e,A){e.forEach((i,n)=>{let o=o7(n);A&&!A.has(n)&&A.set(n,t.style[o]),t.style[o]=i})}function q1(t,e){e.forEach((A,i)=>{let n=o7(i);t.style[n]=""})}function ph(t){return Array.isArray(t)?t.length==1?t[0]:tP(t):t}function LlA(t,e,A){let i=e.params||{},n=lU(t);n.length&&n.forEach(o=>{i.hasOwnProperty(o)||A.push(ZjA(o))})}var tU=new RegExp(`${sU}\\s*(.+?)\\s*${nqA}`,"g");function lU(t){let e=[];if(typeof t=="string"){let A;for(;A=tU.exec(t);)e.push(A[1]);tU.lastIndex=0}return e}function wh(t,e,A){let i=`${t}`,n=i.replace(tU,(o,r)=>{let s=e[r];return s==null&&(A.push(WjA(r)),s=""),s.toString()});return n==i?t:n}var rqA=/-+([a-z0-9])/g;function o7(t){return t.replace(rqA,(...e)=>e[1].toUpperCase())}function xlA(t,e){return t===0||e===0}function FlA(t,e,A){if(A.size&&e.length){let i=e[0],n=[];if(A.forEach((o,r)=>{i.has(r)||n.push(r),i.set(r,o)}),n.length)for(let o=1;o<e.length;o++){let r=e[o];n.forEach(s=>r.set(s,r7(t,s)))}}return e}function Ra(t,e,A){switch(e.type){case Wt.Trigger:return t.visitTrigger(e,A);case Wt.State:return t.visitState(e,A);case Wt.Transition:return t.visitTransition(e,A);case Wt.Sequence:return t.visitSequence(e,A);case Wt.Group:return t.visitGroup(e,A);case Wt.Animate:return t.visitAnimate(e,A);case Wt.Keyframes:return t.visitKeyframes(e,A);case Wt.Style:return t.visitStyle(e,A);case Wt.Reference:return t.visitReference(e,A);case Wt.AnimateChild:return t.visitAnimateChild(e,A);case Wt.AnimateRef:return t.visitAnimateRef(e,A);case Wt.Query:return t.visitQuery(e,A);case Wt.Stagger:return t.visitStagger(e,A);default:throw XjA(e.type)}}function r7(t,e){return window.getComputedStyle(t)[e]}var bU=(()=>{class t{validateStyleProperty(A){return SlA(A)}containsElement(A,i){return oU(A,i)}getParentElement(A){return t7(A)}query(A,i,n){return rU(A,i,n)}computeStyle(A,i,n){return n||""}animate(A,i,n,o,r,s=[],a){return new ag(n,o)}static \u0275fac=function(i){return new(i||t)};static \u0275prov=SA({token:t,factory:t.\u0275fac})}return t})(),$C=class{static NOOP=new bU},Ad=class{};var sqA=new Set(["width","height","minWidth","minHeight","maxWidth","maxHeight","left","top","bottom","right","fontSize","outlineWidth","outlineOffset","paddingTop","paddingLeft","paddingBottom","paddingRight","marginTop","marginLeft","marginBottom","marginRight","borderRadius","borderWidth","borderTopWidth","borderLeftWidth","borderRightWidth","borderBottomWidth","textIndent","perspective"]),g7=class extends Ad{normalizePropertyName(e,A){return o7(e)}normalizeStyleValue(e,A,i,n){let o="",r=i.toString().trim();if(sqA.has(A)&&i!==0&&i!=="0")if(typeof i=="number")o="px";else{let s=i.match(/^[+-]?[\d\.]+([a-z]*)$/);s&&s[1].length==0&&n.push(olA(e,i))}return r+o}};var I7="*";function aqA(t,e){let A=[];return typeof t=="string"?t.split(/\s*,\s*/).forEach(i=>cqA(i,A,e)):A.push(t),A}function cqA(t,e,A){if(t[0]==":"){let a=lqA(t,A);if(typeof a=="function"){e.push(a);return}t=a}let i=t.match(/^(\*|[-\w]+)\s*(<?[=-]>)\s*(\*|[-\w]+)$/);if(i==null||i.length<4)return A.push(hlA(t)),e;let n=i[1],o=i[2],r=i[3];e.push(NlA(n,r));let s=n==I7&&r==I7;o[0]=="<"&&!s&&e.push(NlA(r,n))}function lqA(t,e){switch(t){case":enter":return"void => *";case":leave":return"* => void";case":increment":return(A,i)=>parseFloat(i)>parseFloat(A);case":decrement":return(A,i)=>parseFloat(i)<parseFloat(A);default:return e.push(QlA(t)),"* => *"}}var s7=new Set(["true","1"]),a7=new Set(["false","0"]);function NlA(t,e){let A=s7.has(t)||a7.has(t),i=s7.has(e)||a7.has(e);return(n,o)=>{let r=t==I7||t==n,s=e==I7||e==o;return!r&&A&&typeof n=="boolean"&&(r=n?s7.has(t):a7.has(t)),!s&&i&&typeof o=="boolean"&&(s=o?s7.has(e):a7.has(e)),r&&s}}var OlA=":self",gqA=new RegExp(`s*${OlA}s*,?`,"g");function PlA(t,e,A,i){return new EU(t).build(e,A,i)}var _lA="",EU=class{_driver;constructor(e){this._driver=e}build(e,A,i){let n=new hU(A);return this._resetContextStyleTimingState(n),Ra(this,ph(e),n)}_resetContextStyleTimingState(e){e.currentQuerySelector=_lA,e.collectedStyles=new Map,e.collectedStyles.set(_lA,new Map),e.currentTime=0}visitTrigger(e,A){let i=A.queryCount=0,n=A.depCount=0,o=[],r=[];return e.name.charAt(0)=="@"&&A.errors.push(rlA()),e.definitions.forEach(s=>{if(this._resetContextStyleTimingState(A),s.type==Wt.State){let a=s,c=a.name;c.toString().split(/\s*,\s*/).forEach(l=>{a.name=l,o.push(this.visitState(a,A))}),a.name=c}else if(s.type==Wt.Transition){let a=this.visitTransition(s,A);i+=a.queryCount,n+=a.depCount,r.push(a)}else A.errors.push(slA())}),{type:Wt.Trigger,name:e.name,states:o,transitions:r,queryCount:i,depCount:n,options:null}}visitState(e,A){let i=this.visitStyle(e.styles,A),n=e.options&&e.options.params||null;if(i.containsDynamicStyles){let o=new Set,r=n||{};i.styles.forEach(s=>{s instanceof Map&&s.forEach(a=>{lU(a).forEach(c=>{r.hasOwnProperty(c)||o.add(c)})})}),o.size&&A.errors.push(alA(e.name,[...o.values()]))}return{type:Wt.State,name:e.name,style:i,options:n?{params:n}:null}}visitTransition(e,A){A.queryCount=0,A.depCount=0;let i=Ra(this,ph(e.animation),A),n=aqA(e.expr,A.errors);return{type:Wt.Transition,matchers:n,animation:i,queryCount:A.queryCount,depCount:A.depCount,options:XC(e.options)}}visitSequence(e,A){return{type:Wt.Sequence,steps:e.steps.map(i=>Ra(this,i,A)),options:XC(e.options)}}visitGroup(e,A){let i=A.currentTime,n=0,o=e.steps.map(r=>{A.currentTime=i;let s=Ra(this,r,A);return n=Math.max(n,A.currentTime),s});return A.currentTime=n,{type:Wt.Group,steps:o,options:XC(e.options)}}visitAnimate(e,A){let i=BqA(e.timings,A.errors);A.currentAnimateTimings=i;let n,o=e.styles?e.styles:ar({});if(o.type==Wt.Keyframes)n=this.visitKeyframes(o,A);else{let r=e.styles,s=!1;if(!r){s=!0;let c={};i.easing&&(c.easing=i.easing),r=ar(c)}A.currentTime+=i.duration+i.delay;let a=this.visitStyle(r,A);a.isEmptyStep=s,n=a}return A.currentAnimateTimings=null,{type:Wt.Animate,timings:i,style:n,options:null}}visitStyle(e,A){let i=this._makeStyleAst(e,A);return this._validateStyleAst(i,A),i}_makeStyleAst(e,A){let i=[],n=Array.isArray(e.styles)?e.styles:[e.styles];for(let s of n)typeof s=="string"?s===pc?i.push(s):A.errors.push(clA(s)):i.push(new Map(Object.entries(s)));let o=!1,r=null;return i.forEach(s=>{if(s instanceof Map&&(s.has("easing")&&(r=s.get("easing"),s.delete("easing")),!o)){for(let a of s.values())if(a.toString().indexOf(sU)>=0){o=!0;break}}}),{type:Wt.Style,styles:i,easing:r,offset:e.offset,containsDynamicStyles:o,options:null}}_validateStyleAst(e,A){let i=A.currentAnimateTimings,n=A.currentTime,o=A.currentTime;i&&o>0&&(o-=i.duration+i.delay),e.styles.forEach(r=>{typeof r!="string"&&r.forEach((s,a)=>{let c=A.collectedStyles.get(A.currentQuerySelector),l=c.get(a),I=!0;l&&(o!=n&&o>=l.startTime&&n<=l.endTime&&(A.errors.push(llA(a,l.startTime,l.endTime,o,n)),I=!1),o=l.startTime),I&&c.set(a,{startTime:o,endTime:n}),A.options&&LlA(s,A.options,A.errors)})})}visitKeyframes(e,A){let i={type:Wt.Keyframes,styles:[],options:null};if(!A.currentAnimateTimings)return A.errors.push(glA()),i;let n=1,o=0,r=[],s=!1,a=!1,c=0,l=e.steps.map(u=>{let v=this._makeStyleAst(u,A),L=v.offset!=null?v.offset:dqA(v.styles),x=0;return L!=null&&(o++,x=v.offset=L),a=a||x<0||x>1,s=s||x<c,c=x,r.push(x),v});a&&A.errors.push(IlA()),s&&A.errors.push(ClA());let I=e.steps.length,C=0;o>0&&o<I?A.errors.push(dlA()):o==0&&(C=n/(I-1));let d=I-1,B=A.currentTime,E=A.currentAnimateTimings,Q=E.duration;return l.forEach((u,v)=>{let L=C>0?v==d?1:C*v:r[v],x=L*Q;A.currentTime=B+E.delay+x,E.duration=x,this._validateStyleAst(u,A),u.offset=L,i.styles.push(u)}),i}visitReference(e,A){return{type:Wt.Reference,animation:Ra(this,ph(e.animation),A),options:XC(e.options)}}visitAnimateChild(e,A){return A.depCount++,{type:Wt.AnimateChild,options:XC(e.options)}}visitAnimateRef(e,A){return{type:Wt.AnimateRef,animation:this.visitReference(e.animation,A),options:XC(e.options)}}visitQuery(e,A){let i=A.currentQuerySelector,n=e.options||{};A.queryCount++,A.currentQuery=e;let[o,r]=IqA(e.selector);A.currentQuerySelector=i.length?i+" "+o:o,Sa(A.collectedStyles,A.currentQuerySelector,new Map);let s=Ra(this,ph(e.animation),A);return A.currentQuery=null,A.currentQuerySelector=i,{type:Wt.Query,selector:o,limit:n.limit||0,optional:!!n.optional,includeSelf:r,animation:s,originalSelector:e.selector,options:XC(e.options)}}visitStagger(e,A){A.currentQuery||A.errors.push(BlA());let i=e.timings==="full"?{duration:0,delay:0,easing:"full"}:wf(e.timings,A.errors,!0);return{type:Wt.Stagger,animation:Ra(this,ph(e.animation),A),timings:i,options:null}}};function IqA(t){let e=!!t.split(/\s*,\s*/).find(A=>A==OlA);return e&&(t=t.replace(gqA,"")),t=t.replace(/@\*/g,pf).replace(/@\w+/g,A=>pf+"-"+A.slice(1)).replace(/:animating/g,n7),[t,e]}function CqA(t){return t?nA({},t):null}var hU=class{errors;queryCount=0;depCount=0;currentTransition=null;currentQuery=null;currentQuerySelector=null;currentAnimateTimings=null;currentTime=0;collectedStyles=new Map;options=null;unsupportedCSSPropertiesFound=new Set;constructor(e){this.errors=e}};function dqA(t){if(typeof t=="string")return null;let e=null;if(Array.isArray(t))t.forEach(A=>{if(A instanceof Map&&A.has("offset")){let i=A;e=parseFloat(i.get("offset")),i.delete("offset")}});else if(t instanceof Map&&t.has("offset")){let A=t;e=parseFloat(A.get("offset")),A.delete("offset")}return e}function BqA(t,e){if(t.hasOwnProperty("duration"))return t;if(typeof t=="number"){let o=wf(t,e).duration;return gU(o,0,"")}let A=t;if(A.split(/\s+/).some(o=>o.charAt(0)=="{"&&o.charAt(1)=="{")){let o=gU(0,0,"");return o.dynamic=!0,o.strValue=A,o}let n=wf(A,e);return gU(n.duration,n.delay,n.easing)}function XC(t){return t?(t=nA({},t),t.params&&(t.params=CqA(t.params))):t={},t}function gU(t,e,A){return{duration:t,delay:e,easing:A}}function MU(t,e,A,i,n,o,r=null,s=!1){return{type:1,element:t,keyframes:e,preStyleProps:A,postStyleProps:i,duration:n,delay:o,totalTime:n+o,easing:r,subTimeline:s}}var yf=class{_map=new Map;get(e){return this._map.get(e)||[]}append(e,A){let i=this._map.get(e);i||this._map.set(e,i=[]),i.push(...A)}has(e){return this._map.has(e)}clear(){this._map.clear()}},EqA=1,hqA=":enter",QqA=new RegExp(hqA,"g"),uqA=":leave",fqA=new RegExp(uqA,"g");function jlA(t,e,A,i,n,o=new Map,r=new Map,s,a,c=[]){return new QU().buildKeyframes(t,e,A,i,n,o,r,s,a,c)}var QU=class{buildKeyframes(e,A,i,n,o,r,s,a,c,l=[]){c=c||new yf;let I=new uU(e,A,c,n,o,l,[]);I.options=a;let C=a.delay?Pg(a.delay):0;I.currentTimeline.delayNextStep(C),I.currentTimeline.setStyles([r],null,I.errors,a),Ra(this,i,I);let d=I.timelines.filter(B=>B.containsAnimation());if(d.length&&s.size){let B;for(let E=d.length-1;E>=0;E--){let Q=d[E];if(Q.element===A){B=Q;break}}B&&!B.allowOnlyTimelineStyles()&&B.setStyles([s],null,I.errors,a)}return d.length?d.map(B=>B.buildKeyframes()):[MU(A,[],[],[],0,C,"",!1)]}visitTrigger(e,A){}visitState(e,A){}visitTransition(e,A){}visitAnimateChild(e,A){let i=A.subInstructions.get(A.element);if(i){let n=A.createSubContext(e.options),o=A.currentTimeline.currentTime,r=this._visitSubInstructions(i,n,n.options);o!=r&&A.transformIntoNewTimeline(r)}A.previousNode=e}visitAnimateRef(e,A){let i=A.createSubContext(e.options);i.transformIntoNewTimeline(),this._applyAnimationRefDelays([e.options,e.animation.options],A,i),this.visitReference(e.animation,i),A.transformIntoNewTimeline(i.currentTimeline.currentTime),A.previousNode=e}_applyAnimationRefDelays(e,A,i){for(let n of e){let o=n?.delay;if(o){let r=typeof o=="number"?o:Pg(wh(o,n?.params??{},A.errors));i.delayNextStep(r)}}}_visitSubInstructions(e,A,i){let o=A.currentTimeline.currentTime,r=i.duration!=null?Pg(i.duration):null,s=i.delay!=null?Pg(i.delay):null;return r!==0&&e.forEach(a=>{let c=A.appendInstructionToTimeline(a,r,s);o=Math.max(o,c.duration+c.delay)}),o}visitReference(e,A){A.updateOptions(e.options,!0),Ra(this,e.animation,A),A.previousNode=e}visitSequence(e,A){let i=A.subContextCount,n=A,o=e.options;if(o&&(o.params||o.delay)&&(n=A.createSubContext(o),n.transformIntoNewTimeline(),o.delay!=null)){n.previousNode.type==Wt.Style&&(n.currentTimeline.snapshotCurrentStyles(),n.previousNode=C7);let r=Pg(o.delay);n.delayNextStep(r)}e.steps.length&&(e.steps.forEach(r=>Ra(this,r,n)),n.currentTimeline.applyStylesToKeyframe(),n.subContextCount>i&&n.transformIntoNewTimeline()),A.previousNode=e}visitGroup(e,A){let i=[],n=A.currentTimeline.currentTime,o=e.options&&e.options.delay?Pg(e.options.delay):0;e.steps.forEach(r=>{let s=A.createSubContext(e.options);o&&s.delayNextStep(o),Ra(this,r,s),n=Math.max(n,s.currentTimeline.currentTime),i.push(s.currentTimeline)}),i.forEach(r=>A.currentTimeline.mergeTimelineCollectedStyles(r)),A.transformIntoNewTimeline(n),A.previousNode=e}_visitTiming(e,A){if(e.dynamic){let i=e.strValue,n=A.params?wh(i,A.params,A.errors):i;return wf(n,A.errors)}else return{duration:e.duration,delay:e.delay,easing:e.easing}}visitAnimate(e,A){let i=A.currentAnimateTimings=this._visitTiming(e.timings,A),n=A.currentTimeline;i.delay&&(A.incrementTime(i.delay),n.snapshotCurrentStyles());let o=e.style;o.type==Wt.Keyframes?this.visitKeyframes(o,A):(A.incrementTime(i.duration),this.visitStyle(o,A),n.applyStylesToKeyframe()),A.currentAnimateTimings=null,A.previousNode=e}visitStyle(e,A){let i=A.currentTimeline,n=A.currentAnimateTimings;!n&&i.hasCurrentStyleProperties()&&i.forwardFrame();let o=n&&n.easing||e.easing;e.isEmptyStep?i.applyEmptyStep(o):i.setStyles(e.styles,o,A.errors,A.options),A.previousNode=e}visitKeyframes(e,A){let i=A.currentAnimateTimings,n=A.currentTimeline.duration,o=i.duration,s=A.createSubContext().currentTimeline;s.easing=i.easing,e.styles.forEach(a=>{let c=a.offset||0;s.forwardTime(c*o),s.setStyles(a.styles,a.easing,A.errors,A.options),s.applyStylesToKeyframe()}),A.currentTimeline.mergeTimelineCollectedStyles(s),A.transformIntoNewTimeline(n+o),A.previousNode=e}visitQuery(e,A){let i=A.currentTimeline.currentTime,n=e.options||{},o=n.delay?Pg(n.delay):0;o&&(A.previousNode.type===Wt.Style||i==0&&A.currentTimeline.hasCurrentStyleProperties())&&(A.currentTimeline.snapshotCurrentStyles(),A.previousNode=C7);let r=i,s=A.invokeQuery(e.selector,e.originalSelector,e.limit,e.includeSelf,!!n.optional,A.errors);A.currentQueryTotal=s.length;let a=null;s.forEach((c,l)=>{A.currentQueryIndex=l;let I=A.createSubContext(e.options,c);o&&I.delayNextStep(o),c===A.element&&(a=I.currentTimeline),Ra(this,e.animation,I),I.currentTimeline.applyStylesToKeyframe();let C=I.currentTimeline.currentTime;r=Math.max(r,C)}),A.currentQueryIndex=0,A.currentQueryTotal=0,A.transformIntoNewTimeline(r),a&&(A.currentTimeline.mergeTimelineCollectedStyles(a),A.currentTimeline.snapshotCurrentStyles()),A.previousNode=e}visitStagger(e,A){let i=A.parentContext,n=A.currentTimeline,o=e.timings,r=Math.abs(o.duration),s=r*(A.currentQueryTotal-1),a=r*A.currentQueryIndex;switch(o.duration<0?"reverse":o.easing){case"reverse":a=s-a;break;case"full":a=i.currentStaggerTime;break}let l=A.currentTimeline;a&&l.delayNextStep(a);let I=l.currentTime;Ra(this,e.animation,A),A.previousNode=e,i.currentStaggerTime=n.currentTime-I+(n.startTime-i.currentTimeline.startTime)}},C7={},uU=class t{_driver;element;subInstructions;_enterClassName;_leaveClassName;errors;timelines;parentContext=null;currentTimeline;currentAnimateTimings=null;previousNode=C7;subContextCount=0;options={};currentQueryIndex=0;currentQueryTotal=0;currentStaggerTime=0;constructor(e,A,i,n,o,r,s,a){this._driver=e,this.element=A,this.subInstructions=i,this._enterClassName=n,this._leaveClassName=o,this.errors=r,this.timelines=s,this.currentTimeline=a||new d7(this._driver,A,0),s.push(this.currentTimeline)}get params(){return this.options.params}updateOptions(e,A){if(!e)return;let i=e,n=this.options;i.duration!=null&&(n.duration=Pg(i.duration)),i.delay!=null&&(n.delay=Pg(i.delay));let o=i.params;if(o){let r=n.params;r||(r=this.options.params={}),Object.keys(o).forEach(s=>{(!A||!r.hasOwnProperty(s))&&(r[s]=wh(o[s],r,this.errors))})}}_copyOptions(){let e={};if(this.options){let A=this.options.params;if(A){let i=e.params={};Object.keys(A).forEach(n=>{i[n]=A[n]})}}return e}createSubContext(e=null,A,i){let n=A||this.element,o=new t(this._driver,n,this.subInstructions,this._enterClassName,this._leaveClassName,this.errors,this.timelines,this.currentTimeline.fork(n,i||0));return o.previousNode=this.previousNode,o.currentAnimateTimings=this.currentAnimateTimings,o.options=this._copyOptions(),o.updateOptions(e),o.currentQueryIndex=this.currentQueryIndex,o.currentQueryTotal=this.currentQueryTotal,o.parentContext=this,this.subContextCount++,o}transformIntoNewTimeline(e){return this.previousNode=C7,this.currentTimeline=this.currentTimeline.fork(this.element,e),this.timelines.push(this.currentTimeline),this.currentTimeline}appendInstructionToTimeline(e,A,i){let n={duration:A??e.duration,delay:this.currentTimeline.currentTime+(i??0)+e.delay,easing:""},o=new fU(this._driver,e.element,e.keyframes,e.preStyleProps,e.postStyleProps,n,e.stretchStartingKeyframe);return this.timelines.push(o),n}incrementTime(e){this.currentTimeline.forwardTime(this.currentTimeline.duration+e)}delayNextStep(e){e>0&&this.currentTimeline.delayNextStep(e)}invokeQuery(e,A,i,n,o,r){let s=[];if(n&&s.push(this.element),e.length>0){e=e.replace(QqA,"."+this._enterClassName),e=e.replace(fqA,"."+this._leaveClassName);let a=i!=1,c=this._driver.query(this.element,e,a);i!==0&&(c=i<0?c.slice(c.length+i,c.length):c.slice(0,i)),s.push(...c)}return!o&&s.length==0&&r.push(ElA(A)),s}},d7=class t{_driver;element;startTime;_elementTimelineStylesLookup;duration=0;easing=null;_previousKeyframe=new Map;_currentKeyframe=new Map;_keyframes=new Map;_styleSummary=new Map;_localTimelineStyles=new Map;_globalTimelineStyles;_pendingStyles=new Map;_backFill=new Map;_currentEmptyStepKeyframe=null;constructor(e,A,i,n){this._driver=e,this.element=A,this.startTime=i,this._elementTimelineStylesLookup=n,this._elementTimelineStylesLookup||(this._elementTimelineStylesLookup=new Map),this._globalTimelineStyles=this._elementTimelineStylesLookup.get(A),this._globalTimelineStyles||(this._globalTimelineStyles=this._localTimelineStyles,this._elementTimelineStylesLookup.set(A,this._localTimelineStyles)),this._loadKeyframe()}containsAnimation(){switch(this._keyframes.size){case 0:return!1;case 1:return this.hasCurrentStyleProperties();default:return!0}}hasCurrentStyleProperties(){return this._currentKeyframe.size>0}get currentTime(){return this.startTime+this.duration}delayNextStep(e){let A=this._keyframes.size===1&&this._pendingStyles.size;this.duration||A?(this.forwardTime(this.currentTime+e),A&&this.snapshotCurrentStyles()):this.startTime+=e}fork(e,A){return this.applyStylesToKeyframe(),new t(this._driver,e,A||this.currentTime,this._elementTimelineStylesLookup)}_loadKeyframe(){this._currentKeyframe&&(this._previousKeyframe=this._currentKeyframe),this._currentKeyframe=this._keyframes.get(this.duration),this._currentKeyframe||(this._currentKeyframe=new Map,this._keyframes.set(this.duration,this._currentKeyframe))}forwardFrame(){this.duration+=EqA,this._loadKeyframe()}forwardTime(e){this.applyStylesToKeyframe(),this.duration=e,this._loadKeyframe()}_updateStyle(e,A){this._localTimelineStyles.set(e,A),this._globalTimelineStyles.set(e,A),this._styleSummary.set(e,{time:this.currentTime,value:A})}allowOnlyTimelineStyles(){return this._currentEmptyStepKeyframe!==this._currentKeyframe}applyEmptyStep(e){e&&this._previousKeyframe.set("easing",e);for(let[A,i]of this._globalTimelineStyles)this._backFill.set(A,i||pc),this._currentKeyframe.set(A,pc);this._currentEmptyStepKeyframe=this._currentKeyframe}setStyles(e,A,i,n){A&&this._previousKeyframe.set("easing",A);let o=n&&n.params||{},r=mqA(e,this._globalTimelineStyles);for(let[s,a]of r){let c=wh(a,o,i);this._pendingStyles.set(s,c),this._localTimelineStyles.has(s)||this._backFill.set(s,this._globalTimelineStyles.get(s)??pc),this._updateStyle(s,c)}}applyStylesToKeyframe(){this._pendingStyles.size!=0&&(this._pendingStyles.forEach((e,A)=>{this._currentKeyframe.set(A,e)}),this._pendingStyles.clear(),this._localTimelineStyles.forEach((e,A)=>{this._currentKeyframe.has(A)||this._currentKeyframe.set(A,e)}))}snapshotCurrentStyles(){for(let[e,A]of this._localTimelineStyles)this._pendingStyles.set(e,A),this._updateStyle(e,A)}getFinalKeyframe(){return this._keyframes.get(this.duration)}get properties(){let e=[];for(let A in this._currentKeyframe)e.push(A);return e}mergeTimelineCollectedStyles(e){e._styleSummary.forEach((A,i)=>{let n=this._styleSummary.get(i);(!n||A.time>n.time)&&this._updateStyle(i,A.value)})}buildKeyframes(){this.applyStylesToKeyframe();let e=new Set,A=new Set,i=this._keyframes.size===1&&this.duration===0,n=[];this._keyframes.forEach((s,a)=>{let c=new Map([...this._backFill,...s]);c.forEach((l,I)=>{l===mB?e.add(I):l===pc&&A.add(I)}),i||c.set("offset",a/this.duration),n.push(c)});let o=[...e.values()],r=[...A.values()];if(i){let s=n[0],a=new Map(s);s.set("offset",0),a.set("offset",1),n=[s,a]}return MU(this.element,n,o,r,this.duration,this.startTime,this.easing,!1)}},fU=class extends d7{keyframes;preStyleProps;postStyleProps;_stretchStartingKeyframe;timings;constructor(e,A,i,n,o,r,s=!1){super(e,A,r.delay),this.keyframes=i,this.preStyleProps=n,this.postStyleProps=o,this._stretchStartingKeyframe=s,this.timings={duration:r.duration,delay:r.delay,easing:r.easing}}containsAnimation(){return this.keyframes.length>1}buildKeyframes(){let e=this.keyframes,{delay:A,duration:i,easing:n}=this.timings;if(this._stretchStartingKeyframe&&A){let o=[],r=i+A,s=A/r,a=new Map(e[0]);a.set("offset",0),o.push(a);let c=new Map(e[0]);c.set("offset",GlA(s)),o.push(c);let l=e.length-1;for(let I=1;I<=l;I++){let C=new Map(e[I]),d=C.get("offset"),B=A+d*i;C.set("offset",GlA(B/r)),o.push(C)}i=r,A=0,n="",e=o}return MU(this.element,e,this.preStyleProps,this.postStyleProps,i,A,n,!0)}};function GlA(t,e=3){let A=Math.pow(10,e-1);return Math.round(t*A)/A}function mqA(t,e){let A=new Map,i;return t.forEach(n=>{if(n==="*"){i??=e.keys();for(let o of i)A.set(o,pc)}else for(let[o,r]of n)A.set(o,r)}),A}function UlA(t,e,A,i,n,o,r,s,a,c,l,I,C){return{type:0,element:t,triggerName:e,isRemovalTransition:n,fromState:A,fromStyles:o,toState:i,toStyles:r,timelines:s,queriedElements:a,preStyleProps:c,postStyleProps:l,totalTime:I,errors:C}}var IU={},B7=class{_triggerName;ast;_stateStyles;constructor(e,A,i){this._triggerName=e,this.ast=A,this._stateStyles=i}match(e,A,i,n){return pqA(this.ast.matchers,e,A,i,n)}buildStyles(e,A,i){let n=this._stateStyles.get("*");return e!==void 0&&(n=this._stateStyles.get(e?.toString())||n),n?n.buildStyles(A,i):new Map}build(e,A,i,n,o,r,s,a,c,l){let I=[],C=this.ast.options&&this.ast.options.params||IU,d=s&&s.params||IU,B=this.buildStyles(i,d,I),E=a&&a.params||IU,Q=this.buildStyles(n,E,I),u=new Set,v=new Map,L=new Map,x=n==="void",y={params:qlA(E,C),delay:this.ast.options?.delay},F=l?[]:jlA(e,A,this.ast.animation,o,r,B,Q,y,c,I),U=0;return F.forEach(T=>{U=Math.max(T.duration+T.delay,U)}),I.length?UlA(A,this._triggerName,i,n,x,B,Q,[],[],v,L,U,I):(F.forEach(T=>{let N=T.element,K=Sa(v,N,new Set);T.preStyleProps.forEach(j=>K.add(j));let H=Sa(L,N,new Set);T.postStyleProps.forEach(j=>H.add(j)),N!==A&&u.add(N)}),UlA(A,this._triggerName,i,n,x,B,Q,F,[...u.values()],v,L,U))}};function pqA(t,e,A,i,n){return t.some(o=>o(e,A,i,n))}function qlA(t,e){let A=nA({},e);return Object.entries(t).forEach(([i,n])=>{n!=null&&(A[i]=n)}),A}var mU=class{styles;defaultParams;normalizer;constructor(e,A,i){this.styles=e,this.defaultParams=A,this.normalizer=i}buildStyles(e,A){let i=new Map,n=qlA(e,this.defaultParams);return this.styles.styles.forEach(o=>{typeof o!="string"&&o.forEach((r,s)=>{r&&(r=wh(r,n,A));let a=this.normalizer.normalizePropertyName(s,A);r=this.normalizer.normalizeStyleValue(s,a,r,A),i.set(s,r)})}),i}};function wqA(t,e,A){return new pU(t,e,A)}var pU=class{name;ast;_normalizer;transitionFactories=[];fallbackTransition;states=new Map;constructor(e,A,i){this.name=e,this.ast=A,this._normalizer=i,A.states.forEach(n=>{let o=n.options&&n.options.params||{};this.states.set(n.name,new mU(n.style,o,i))}),KlA(this.states,"true","1"),KlA(this.states,"false","0"),A.transitions.forEach(n=>{this.transitionFactories.push(new B7(e,n,this.states))}),this.fallbackTransition=DqA(e,this.states)}get containsQueries(){return this.ast.queryCount>0}matchTransition(e,A,i,n){return this.transitionFactories.find(r=>r.match(e,A,i,n))||null}matchStyles(e,A,i){return this.fallbackTransition.buildStyles(e,A,i)}};function DqA(t,e,A){let i=[(r,s)=>!0],n={type:Wt.Sequence,steps:[],options:null},o={type:Wt.Transition,animation:n,matchers:i,options:null,queryCount:0,depCount:0};return new B7(t,o,e)}function KlA(t,e,A){t.has(e)?t.has(A)||t.set(A,t.get(e)):t.has(A)&&t.set(e,t.get(A))}var yqA=new yf,wU=class{bodyNode;_driver;_normalizer;_animations=new Map;_playersById=new Map;players=[];constructor(e,A,i){this.bodyNode=e,this._driver=A,this._normalizer=i}register(e,A){let i=[],n=[],o=PlA(this._driver,A,i,n);if(i.length)throw flA(i);this._animations.set(e,o)}_buildPlayer(e,A,i){let n=e.element,o=iU(this._normalizer,e.keyframes,A,i);return this._driver.animate(n,o,e.duration,e.delay,e.easing,[],!0)}create(e,A,i={}){let n=[],o=this._animations.get(e),r,s=new Map;if(o?(r=jlA(this._driver,A,o,aU,i7,new Map,new Map,i,yqA,n),r.forEach(l=>{let I=Sa(s,l.element,new Map);l.postStyleProps.forEach(C=>I.set(C,null))})):(n.push(mlA()),r=[]),n.length)throw plA(n);s.forEach((l,I)=>{l.forEach((C,d)=>{l.set(d,this._driver.computeStyle(I,d,pc))})});let a=r.map(l=>{let I=s.get(l.element);return this._buildPlayer(l,new Map,I)}),c=n2(a);return this._playersById.set(e,c),c.onDestroy(()=>this.destroy(e)),this.players.push(c),c}destroy(e){let A=this._getPlayer(e);A.destroy(),this._playersById.delete(e);let i=this.players.indexOf(A);i>=0&&this.players.splice(i,1)}_getPlayer(e){let A=this._playersById.get(e);if(!A)throw wlA(e);return A}listen(e,A,i,n){let o=e7(A,"","","");return A7(this._getPlayer(e),i,o,n),()=>{}}command(e,A,i,n){if(i=="register"){this.register(e,n[0]);return}if(i=="create"){let r=n[0]||{};this.create(e,A,r);return}let o=this._getPlayer(e);switch(i){case"play":o.play();break;case"pause":o.pause();break;case"reset":o.reset();break;case"restart":o.restart();break;case"finish":o.finish();break;case"init":o.init();break;case"setPosition":o.setPosition(parseFloat(n[0]));break;case"destroy":this.destroy(e);break}}},YlA="ng-animate-queued",vqA=".ng-animate-queued",CU="ng-animate-disabled",bqA=".ng-animate-disabled",MqA="ng-star-inserted",kqA=".ng-star-inserted",SqA=[],VlA={namespaceId:"",setForRemoval:!1,setForMove:!1,hasAnimation:!1,removedBeforeQueried:!1},RqA={namespaceId:"",setForMove:!1,setForRemoval:!1,hasAnimation:!1,removedBeforeQueried:!0},_l="__ng_removed",vf=class{namespaceId;value;options;get params(){return this.options.params}constructor(e,A=""){this.namespaceId=A;let i=e&&e.hasOwnProperty("value"),n=i?e.value:e;if(this.value=xqA(n),i){let o=e,{value:r}=o,s=y7(o,["value"]);this.options=s}else this.options={};this.options.params||(this.options.params={})}absorbOptions(e){let A=e.params;if(A){let i=this.options.params;Object.keys(A).forEach(n=>{i[n]==null&&(i[n]=A[n])})}}},Df="void",dU=new vf(Df),DU=class{id;hostElement;_engine;players=[];_triggers=new Map;_queue=[];_elementListeners=new Map;_hostClassName;constructor(e,A,i){this.id=e,this.hostElement=A,this._engine=i,this._hostClassName="ng-tns-"+e,Hc(A,this._hostClassName)}listen(e,A,i,n){if(!this._triggers.has(A))throw DlA(i,A);if(i==null||i.length==0)throw ylA(A);if(!FqA(i))throw vlA(i,A);let o=Sa(this._elementListeners,e,[]),r={name:A,phase:i,callback:n};o.push(r);let s=Sa(this._engine.statesByElement,e,new Map);return s.has(A)||(Hc(e,mf),Hc(e,mf+"-"+A),s.set(A,dU)),()=>{this._engine.afterFlush(()=>{let a=o.indexOf(r);a>=0&&o.splice(a,1),this._triggers.has(A)||s.delete(A)})}}register(e,A){return this._triggers.has(e)?!1:(this._triggers.set(e,A),!0)}_getTrigger(e){let A=this._triggers.get(e);if(!A)throw blA(e);return A}trigger(e,A,i,n=!0){let o=this._getTrigger(A),r=new bf(this.id,A,e),s=this._engine.statesByElement.get(e);s||(Hc(e,mf),Hc(e,mf+"-"+A),this._engine.statesByElement.set(e,s=new Map));let a=s.get(A),c=new vf(i,this.id);if(!(i&&i.hasOwnProperty("value"))&&a&&c.absorbOptions(a.options),s.set(A,c),a||(a=dU),!(c.value===Df)&&a.value===c.value){if(!GqA(a.params,c.params)){let E=[],Q=o.matchStyles(a.value,a.params,E),u=o.matchStyles(c.value,c.params,E);E.length?this._engine.reportError(E):this._engine.afterFlush(()=>{q1(e,Q),Nl(e,u)})}return}let C=Sa(this._engine.playersByElement,e,[]);C.forEach(E=>{E.namespaceId==this.id&&E.triggerName==A&&E.queued&&E.destroy()});let d=o.matchTransition(a.value,c.value,e,c.params),B=!1;if(!d){if(!n)return;d=o.fallbackTransition,B=!0}return this._engine.totalQueuedPlayers++,this._queue.push({element:e,triggerName:A,transition:d,fromState:a,toState:c,player:r,isFallbackTransition:B}),B||(Hc(e,YlA),r.onStart(()=>{Dh(e,YlA)})),r.onDone(()=>{let E=this.players.indexOf(r);E>=0&&this.players.splice(E,1);let Q=this._engine.playersByElement.get(e);if(Q){let u=Q.indexOf(r);u>=0&&Q.splice(u,1)}}),this.players.push(r),C.push(r),r}deregister(e){this._triggers.delete(e),this._engine.statesByElement.forEach(A=>A.delete(e)),this._elementListeners.forEach((A,i)=>{this._elementListeners.set(i,A.filter(n=>n.name!=e))})}clearElementCache(e){this._engine.statesByElement.delete(e),this._elementListeners.delete(e);let A=this._engine.playersByElement.get(e);A&&(A.forEach(i=>i.destroy()),this._engine.playersByElement.delete(e))}_signalRemovalForInnerTriggers(e,A){let i=this._engine.driver.query(e,pf,!0);i.forEach(n=>{if(n[_l])return;let o=this._engine.fetchNamespacesByElement(n);o.size?o.forEach(r=>r.triggerLeaveAnimation(n,A,!1,!0)):this.clearElementCache(n)}),this._engine.afterFlushAnimationsDone(()=>i.forEach(n=>this.clearElementCache(n)))}triggerLeaveAnimation(e,A,i,n){let o=this._engine.statesByElement.get(e),r=new Map;if(o){let s=[];if(o.forEach((a,c)=>{if(r.set(c,a.value),this._triggers.has(c)){let l=this.trigger(e,c,Df,n);l&&s.push(l)}}),s.length)return this._engine.markElementAsRemoved(this.id,e,!0,A,r),i&&n2(s).onDone(()=>this._engine.processLeaveNode(e)),!0}return!1}prepareLeaveAnimationListeners(e){let A=this._elementListeners.get(e),i=this._engine.statesByElement.get(e);if(A&&i){let n=new Set;A.forEach(o=>{let r=o.name;if(n.has(r))return;n.add(r);let a=this._triggers.get(r).fallbackTransition,c=i.get(r)||dU,l=new vf(Df),I=new bf(this.id,r,e);this._engine.totalQueuedPlayers++,this._queue.push({element:e,triggerName:r,transition:a,fromState:c,toState:l,player:I,isFallbackTransition:!0})})}}removeNode(e,A){let i=this._engine;if(e.childElementCount&&this._signalRemovalForInnerTriggers(e,A),this.triggerLeaveAnimation(e,A,!0))return;let n=!1;if(i.totalAnimations){let o=i.players.length?i.playersByQueriedElement.get(e):[];if(o&&o.length)n=!0;else{let r=e;for(;r=r.parentNode;)if(i.statesByElement.get(r)){n=!0;break}}}if(this.prepareLeaveAnimationListeners(e),n)i.markElementAsRemoved(this.id,e,!1,A);else{let o=e[_l];(!o||o===VlA)&&(i.afterFlush(()=>this.clearElementCache(e)),i.destroyInnerAnimations(e),i._onRemovalComplete(e,A))}}insertNode(e,A){Hc(e,this._hostClassName)}drainQueuedTransitions(e){let A=[];return this._queue.forEach(i=>{let n=i.player;if(n.destroyed)return;let o=i.element,r=this._elementListeners.get(o);r&&r.forEach(s=>{if(s.name==i.triggerName){let a=e7(o,i.triggerName,i.fromState.value,i.toState.value);a._data=e,A7(i.player,s.phase,a,s.callback)}}),n.markedForDestroy?this._engine.afterFlush(()=>{n.destroy()}):A.push(i)}),this._queue=[],A.sort((i,n)=>{let o=i.transition.ast.depCount,r=n.transition.ast.depCount;return o==0||r==0?o-r:this._engine.driver.containsElement(i.element,n.element)?1:-1})}destroy(e){this.players.forEach(A=>A.destroy()),this._signalRemovalForInnerTriggers(this.hostElement,e)}},yU=class{bodyNode;driver;_normalizer;players=[];newHostElements=new Map;playersByElement=new Map;playersByQueriedElement=new Map;statesByElement=new Map;disabledNodes=new Set;totalAnimations=0;totalQueuedPlayers=0;_namespaceLookup={};_namespaceList=[];_flushFns=[];_whenQuietFns=[];namespacesByHostElement=new Map;collectedEnterElements=[];collectedLeaveElements=[];onRemovalComplete=(e,A)=>{};_onRemovalComplete(e,A){this.onRemovalComplete(e,A)}constructor(e,A,i){this.bodyNode=e,this.driver=A,this._normalizer=i}get queuedPlayers(){let e=[];return this._namespaceList.forEach(A=>{A.players.forEach(i=>{i.queued&&e.push(i)})}),e}createNamespace(e,A){let i=new DU(e,A,this);return this.bodyNode&&this.driver.containsElement(this.bodyNode,A)?this._balanceNamespaceList(i,A):(this.newHostElements.set(A,i),this.collectEnterElement(A)),this._namespaceLookup[e]=i}_balanceNamespaceList(e,A){let i=this._namespaceList,n=this.namespacesByHostElement;if(i.length-1>=0){let r=!1,s=this.driver.getParentElement(A);for(;s;){let a=n.get(s);if(a){let c=i.indexOf(a);i.splice(c+1,0,e),r=!0;break}s=this.driver.getParentElement(s)}r||i.unshift(e)}else i.push(e);return n.set(A,e),e}register(e,A){let i=this._namespaceLookup[e];return i||(i=this.createNamespace(e,A)),i}registerTrigger(e,A,i){let n=this._namespaceLookup[e];n&&n.register(A,i)&&this.totalAnimations++}destroy(e,A){e&&(this.afterFlush(()=>{}),this.afterFlushAnimationsDone(()=>{let i=this._fetchNamespace(e);this.namespacesByHostElement.delete(i.hostElement);let n=this._namespaceList.indexOf(i);n>=0&&this._namespaceList.splice(n,1),i.destroy(A),delete this._namespaceLookup[e]}))}_fetchNamespace(e){return this._namespaceLookup[e]}fetchNamespacesByElement(e){let A=new Set,i=this.statesByElement.get(e);if(i){for(let n of i.values())if(n.namespaceId){let o=this._fetchNamespace(n.namespaceId);o&&A.add(o)}}return A}trigger(e,A,i,n){if(c7(A)){let o=this._fetchNamespace(e);if(o)return o.trigger(A,i,n),!0}return!1}insertNode(e,A,i,n){if(!c7(A))return;let o=A[_l];if(o&&o.setForRemoval){o.setForRemoval=!1,o.setForMove=!0;let r=this.collectedLeaveElements.indexOf(A);r>=0&&this.collectedLeaveElements.splice(r,1)}if(e){let r=this._fetchNamespace(e);r&&r.insertNode(A,i)}n&&this.collectEnterElement(A)}collectEnterElement(e){this.collectedEnterElements.push(e)}markElementAsDisabled(e,A){A?this.disabledNodes.has(e)||(this.disabledNodes.add(e),Hc(e,CU)):this.disabledNodes.has(e)&&(this.disabledNodes.delete(e),Dh(e,CU))}removeNode(e,A,i){if(c7(A)){let n=e?this._fetchNamespace(e):null;n?n.removeNode(A,i):this.markElementAsRemoved(e,A,!1,i);let o=this.namespacesByHostElement.get(A);o&&o.id!==e&&o.removeNode(A,i)}else this._onRemovalComplete(A,i)}markElementAsRemoved(e,A,i,n,o){this.collectedLeaveElements.push(A),A[_l]={namespaceId:e,setForRemoval:n,hasAnimation:i,removedBeforeQueried:!1,previousTriggersValues:o}}listen(e,A,i,n,o){return c7(A)?this._fetchNamespace(e).listen(A,i,n,o):()=>{}}_buildInstruction(e,A,i,n,o){return e.transition.build(this.driver,e.element,e.fromState.value,e.toState.value,i,n,e.fromState.options,e.toState.options,A,o)}destroyInnerAnimations(e){let A=this.driver.query(e,pf,!0);A.forEach(i=>this.destroyActiveAnimationsForElement(i)),this.playersByQueriedElement.size!=0&&(A=this.driver.query(e,n7,!0),A.forEach(i=>this.finishActiveQueriedAnimationOnElement(i)))}destroyActiveAnimationsForElement(e){let A=this.playersByElement.get(e);A&&A.forEach(i=>{i.queued?i.markedForDestroy=!0:i.destroy()})}finishActiveQueriedAnimationOnElement(e){let A=this.playersByQueriedElement.get(e);A&&A.forEach(i=>i.finish())}whenRenderingDone(){return new Promise(e=>{if(this.players.length)return n2(this.players).onDone(()=>e());e()})}processLeaveNode(e){let A=e[_l];if(A&&A.setForRemoval){if(e[_l]=VlA,A.namespaceId){this.destroyInnerAnimations(e);let i=this._fetchNamespace(A.namespaceId);i&&i.clearElementCache(e)}this._onRemovalComplete(e,A.setForRemoval)}e.classList?.contains(CU)&&this.markElementAsDisabled(e,!1),this.driver.query(e,bqA,!0).forEach(i=>{this.markElementAsDisabled(i,!1)})}flush(e=-1){let A=[];if(this.newHostElements.size&&(this.newHostElements.forEach((i,n)=>this._balanceNamespaceList(i,n)),this.newHostElements.clear()),this.totalAnimations&&this.collectedEnterElements.length)for(let i=0;i<this.collectedEnterElements.length;i++){let n=this.collectedEnterElements[i];Hc(n,MqA)}if(this._namespaceList.length&&(this.totalQueuedPlayers||this.collectedLeaveElements.length)){let i=[];try{A=this._flushAnimations(i,e)}finally{for(let n=0;n<i.length;n++)i[n]()}}else for(let i=0;i<this.collectedLeaveElements.length;i++){let n=this.collectedLeaveElements[i];this.processLeaveNode(n)}if(this.totalQueuedPlayers=0,this.collectedEnterElements.length=0,this.collectedLeaveElements.length=0,this._flushFns.forEach(i=>i()),this._flushFns=[],this._whenQuietFns.length){let i=this._whenQuietFns;this._whenQuietFns=[],A.length?n2(A).onDone(()=>{i.forEach(n=>n())}):i.forEach(n=>n())}}reportError(e){throw MlA(e)}_flushAnimations(e,A){let i=new yf,n=[],o=new Map,r=[],s=new Map,a=new Map,c=new Map,l=new Set;this.disabledNodes.forEach(p=>{l.add(p);let V=this.driver.query(p,vqA,!0);for(let cA=0;cA<V.length;cA++)l.add(V[cA])});let I=this.bodyNode,C=Array.from(this.statesByElement.keys()),d=zlA(C,this.collectedEnterElements),B=new Map,E=0;d.forEach((p,V)=>{let cA=aU+E++;B.set(V,cA),p.forEach(aA=>Hc(aA,cA))});let Q=[],u=new Set,v=new Set;for(let p=0;p<this.collectedLeaveElements.length;p++){let V=this.collectedLeaveElements[p],cA=V[_l];cA&&cA.setForRemoval&&(Q.push(V),u.add(V),cA.hasAnimation?this.driver.query(V,kqA,!0).forEach(aA=>u.add(aA)):v.add(V))}let L=new Map,x=zlA(C,Array.from(u));x.forEach((p,V)=>{let cA=i7+E++;L.set(V,cA),p.forEach(aA=>Hc(aA,cA))}),e.push(()=>{d.forEach((p,V)=>{let cA=B.get(V);p.forEach(aA=>Dh(aA,cA))}),x.forEach((p,V)=>{let cA=L.get(V);p.forEach(aA=>Dh(aA,cA))}),Q.forEach(p=>{this.processLeaveNode(p)})});let y=[],F=[];for(let p=this._namespaceList.length-1;p>=0;p--)this._namespaceList[p].drainQueuedTransitions(A).forEach(cA=>{let aA=cA.player,jA=cA.element;if(y.push(aA),this.collectedEnterElements.length){let Re=jA[_l];if(Re&&Re.setForMove){if(Re.previousTriggersValues&&Re.previousTriggersValues.has(cA.triggerName)){let hA=Re.previousTriggersValues.get(cA.triggerName),eA=this.statesByElement.get(cA.element);if(eA&&eA.has(cA.triggerName)){let RA=eA.get(cA.triggerName);RA.value=hA,eA.set(cA.triggerName,RA)}}aA.destroy();return}}let VA=!I||!this.driver.containsElement(I,jA),ce=L.get(jA),EA=B.get(jA),sA=this._buildInstruction(cA,i,EA,ce,VA);if(sA.errors&&sA.errors.length){F.push(sA);return}if(VA){aA.onStart(()=>q1(jA,sA.fromStyles)),aA.onDestroy(()=>Nl(jA,sA.toStyles)),n.push(aA);return}if(cA.isFallbackTransition){aA.onStart(()=>q1(jA,sA.fromStyles)),aA.onDestroy(()=>Nl(jA,sA.toStyles)),n.push(aA);return}let TA=[];sA.timelines.forEach(Re=>{Re.stretchStartingKeyframe=!0,this.disabledNodes.has(Re.element)||TA.push(Re)}),sA.timelines=TA,i.append(jA,sA.timelines);let Ke={instruction:sA,player:aA,element:jA};r.push(Ke),sA.queriedElements.forEach(Re=>Sa(s,Re,[]).push(aA)),sA.preStyleProps.forEach((Re,hA)=>{if(Re.size){let eA=a.get(hA);eA||a.set(hA,eA=new Set),Re.forEach((RA,oA)=>eA.add(oA))}}),sA.postStyleProps.forEach((Re,hA)=>{let eA=c.get(hA);eA||c.set(hA,eA=new Set),Re.forEach((RA,oA)=>eA.add(oA))})});if(F.length){let p=[];F.forEach(V=>{p.push(klA(V.triggerName,V.errors))}),y.forEach(V=>V.destroy()),this.reportError(p)}let U=new Map,T=new Map;r.forEach(p=>{let V=p.element;i.has(V)&&(T.set(V,V),this._beforeAnimationBuild(p.player.namespaceId,p.instruction,U))}),n.forEach(p=>{let V=p.element;this._getPreviousPlayers(V,!1,p.namespaceId,p.triggerName,null).forEach(aA=>{Sa(U,V,[]).push(aA),aA.destroy()})});let N=Q.filter(p=>HlA(p,a,c)),K=new Map;TlA(K,this.driver,v,c,pc).forEach(p=>{HlA(p,a,c)&&N.push(p)});let j=new Map;d.forEach((p,V)=>{TlA(j,this.driver,new Set(p),a,mB)}),N.forEach(p=>{let V=K.get(p),cA=j.get(p);K.set(p,new Map([...V?.entries()??[],...cA?.entries()??[]]))});let IA=[],lA=[],uA={};r.forEach(p=>{let{element:V,player:cA,instruction:aA}=p;if(i.has(V)){if(l.has(V)){cA.onDestroy(()=>Nl(V,aA.toStyles)),cA.disabled=!0,cA.overrideTotalTime(aA.totalTime),n.push(cA);return}let jA=uA;if(T.size>1){let ce=V,EA=[];for(;ce=ce.parentNode;){let sA=T.get(ce);if(sA){jA=sA;break}EA.push(ce)}EA.forEach(sA=>T.set(sA,jA))}let VA=this._buildAnimation(cA.namespaceId,aA,U,o,j,K);if(cA.setRealPlayer(VA),jA===uA)IA.push(cA);else{let ce=this.playersByElement.get(jA);ce&&ce.length&&(cA.parentPlayer=n2(ce)),n.push(cA)}}else q1(V,aA.fromStyles),cA.onDestroy(()=>Nl(V,aA.toStyles)),lA.push(cA),l.has(V)&&n.push(cA)}),lA.forEach(p=>{let V=o.get(p.element);if(V&&V.length){let cA=n2(V);p.setRealPlayer(cA)}}),n.forEach(p=>{p.parentPlayer?p.syncPlayerEvents(p.parentPlayer):p.destroy()});for(let p=0;p<Q.length;p++){let V=Q[p],cA=V[_l];if(Dh(V,i7),cA&&cA.hasAnimation)continue;let aA=[];if(s.size){let VA=s.get(V);VA&&VA.length&&aA.push(...VA);let ce=this.driver.query(V,n7,!0);for(let EA=0;EA<ce.length;EA++){let sA=s.get(ce[EA]);sA&&sA.length&&aA.push(...sA)}}let jA=aA.filter(VA=>!VA.destroyed);jA.length?NqA(this,V,jA):this.processLeaveNode(V)}return Q.length=0,IA.forEach(p=>{this.players.push(p),p.onDone(()=>{p.destroy();let V=this.players.indexOf(p);this.players.splice(V,1)}),p.play()}),IA}afterFlush(e){this._flushFns.push(e)}afterFlushAnimationsDone(e){this._whenQuietFns.push(e)}_getPreviousPlayers(e,A,i,n,o){let r=[];if(A){let s=this.playersByQueriedElement.get(e);s&&(r=s)}else{let s=this.playersByElement.get(e);if(s){let a=!o||o==Df;s.forEach(c=>{c.queued||!a&&c.triggerName!=n||r.push(c)})}}return(i||n)&&(r=r.filter(s=>!(i&&i!=s.namespaceId||n&&n!=s.triggerName))),r}_beforeAnimationBuild(e,A,i){let n=A.triggerName,o=A.element,r=A.isRemovalTransition?void 0:e,s=A.isRemovalTransition?void 0:n;for(let a of A.timelines){let c=a.element,l=c!==o,I=Sa(i,c,[]);this._getPreviousPlayers(c,l,r,s,A.toState).forEach(d=>{let B=d.getRealPlayer();B.beforeDestroy&&B.beforeDestroy(),d.destroy(),I.push(d)})}q1(o,A.fromStyles)}_buildAnimation(e,A,i,n,o,r){let s=A.triggerName,a=A.element,c=[],l=new Set,I=new Set,C=A.timelines.map(B=>{let E=B.element;l.add(E);let Q=E[_l];if(Q&&Q.removedBeforeQueried)return new ag(B.duration,B.delay);let u=E!==a,v=_qA((i.get(E)||SqA).map(U=>U.getRealPlayer())).filter(U=>{let T=U;return T.element?T.element===E:!1}),L=o.get(E),x=r.get(E),y=iU(this._normalizer,B.keyframes,L,x),F=this._buildPlayer(B,y,v);if(B.subTimeline&&n&&I.add(E),u){let U=new bf(e,s,E);U.setRealPlayer(F),c.push(U)}return F});c.forEach(B=>{Sa(this.playersByQueriedElement,B.element,[]).push(B),B.onDone(()=>LqA(this.playersByQueriedElement,B.element,B))}),l.forEach(B=>Hc(B,cU));let d=n2(C);return d.onDestroy(()=>{l.forEach(B=>Dh(B,cU)),Nl(a,A.toStyles)}),I.forEach(B=>{Sa(n,B,[]).push(d)}),d}_buildPlayer(e,A,i){return A.length>0?this.driver.animate(e.element,A,e.duration,e.delay,e.easing,i):new ag(e.duration,e.delay)}},bf=class{namespaceId;triggerName;element;_player=new ag;_containsRealPlayer=!1;_queuedCallbacks=new Map;destroyed=!1;parentPlayer=null;markedForDestroy=!1;disabled=!1;queued=!0;totalTime=0;constructor(e,A,i){this.namespaceId=e,this.triggerName=A,this.element=i}setRealPlayer(e){this._containsRealPlayer||(this._player=e,this._queuedCallbacks.forEach((A,i)=>{A.forEach(n=>A7(e,i,void 0,n))}),this._queuedCallbacks.clear(),this._containsRealPlayer=!0,this.overrideTotalTime(e.totalTime),this.queued=!1)}getRealPlayer(){return this._player}overrideTotalTime(e){this.totalTime=e}syncPlayerEvents(e){let A=this._player;A.triggerCallback&&e.onStart(()=>A.triggerCallback("start")),e.onDone(()=>this.finish()),e.onDestroy(()=>this.destroy())}_queueEvent(e,A){Sa(this._queuedCallbacks,e,[]).push(A)}onDone(e){this.queued&&this._queueEvent("done",e),this._player.onDone(e)}onStart(e){this.queued&&this._queueEvent("start",e),this._player.onStart(e)}onDestroy(e){this.queued&&this._queueEvent("destroy",e),this._player.onDestroy(e)}init(){this._player.init()}hasStarted(){return this.queued?!1:this._player.hasStarted()}play(){!this.queued&&this._player.play()}pause(){!this.queued&&this._player.pause()}restart(){!this.queued&&this._player.restart()}finish(){this._player.finish()}destroy(){this.destroyed=!0,this._player.destroy()}reset(){!this.queued&&this._player.reset()}setPosition(e){this.queued||this._player.setPosition(e)}getPosition(){return this.queued?0:this._player.getPosition()}triggerCallback(e){let A=this._player;A.triggerCallback&&A.triggerCallback(e)}};function LqA(t,e,A){let i=t.get(e);if(i){if(i.length){let n=i.indexOf(A);i.splice(n,1)}i.length==0&&t.delete(e)}return i}function xqA(t){return t??null}function c7(t){return t&&t.nodeType===1}function FqA(t){return t=="start"||t=="done"}function JlA(t,e){let A=t.style.display;return t.style.display=e??"none",A}function TlA(t,e,A,i,n){let o=[];A.forEach(a=>o.push(JlA(a)));let r=[];i.forEach((a,c)=>{let l=new Map;a.forEach(I=>{let C=e.computeStyle(c,I,n);l.set(I,C),(!C||C.length==0)&&(c[_l]=RqA,r.push(c))}),t.set(c,l)});let s=0;return A.forEach(a=>JlA(a,o[s++])),r}function zlA(t,e){let A=new Map;if(t.forEach(s=>A.set(s,[])),e.length==0)return A;let i=1,n=new Set(e),o=new Map;function r(s){if(!s)return i;let a=o.get(s);if(a)return a;let c=s.parentNode;return A.has(c)?a=c:n.has(c)?a=i:a=r(c),o.set(s,a),a}return e.forEach(s=>{let a=r(s);a!==i&&A.get(a).push(s)}),A}function Hc(t,e){t.classList?.add(e)}function Dh(t,e){t.classList?.remove(e)}function NqA(t,e,A){n2(A).onDone(()=>t.processLeaveNode(e))}function _qA(t){let e=[];return ZlA(t,e),e}function ZlA(t,e){for(let A=0;A<t.length;A++){let i=t[A];i instanceof JI?ZlA(i.players,e):e.push(i)}}function GqA(t,e){let A=Object.keys(t),i=Object.keys(e);if(A.length!=i.length)return!1;for(let n=0;n<A.length;n++){let o=A[n];if(!e.hasOwnProperty(o)||t[o]!==e[o])return!1}return!0}function HlA(t,e,A){let i=A.get(t);if(!i)return!1;let n=e.get(t);return n?i.forEach(o=>n.add(o)):e.set(t,i),A.delete(t),!0}var yh=class{_driver;_normalizer;_transitionEngine;_timelineEngine;_triggerCache={};onRemovalComplete=(e,A)=>{};constructor(e,A,i){this._driver=A,this._normalizer=i,this._transitionEngine=new yU(e.body,A,i),this._timelineEngine=new wU(e.body,A,i),this._transitionEngine.onRemovalComplete=(n,o)=>this.onRemovalComplete(n,o)}registerTrigger(e,A,i,n,o){let r=e+"-"+n,s=this._triggerCache[r];if(!s){let a=[],c=[],l=PlA(this._driver,o,a,c);if(a.length)throw ulA(n,a);s=wqA(n,l,this._normalizer),this._triggerCache[r]=s}this._transitionEngine.registerTrigger(A,n,s)}register(e,A){this._transitionEngine.register(e,A)}destroy(e,A){this._transitionEngine.destroy(e,A)}onInsert(e,A,i,n){this._transitionEngine.insertNode(e,A,i,n)}onRemove(e,A,i){this._transitionEngine.removeNode(e,A,i)}disableAnimations(e,A){this._transitionEngine.markElementAsDisabled(e,A)}process(e,A,i,n){if(i.charAt(0)=="@"){let[o,r]=nU(i),s=n;this._timelineEngine.command(o,A,r,s)}else this._transitionEngine.trigger(e,A,i,n)}listen(e,A,i,n,o){if(i.charAt(0)=="@"){let[r,s]=nU(i);return this._timelineEngine.listen(r,A,s,o)}return this._transitionEngine.listen(e,A,i,n,o)}flush(e=-1){this._transitionEngine.flush(e)}get players(){return[...this._transitionEngine.players,...this._timelineEngine.players]}whenRenderingDone(){return this._transitionEngine.whenRenderingDone()}afterFlushAnimationsDone(e){this._transitionEngine.afterFlushAnimationsDone(e)}};function UqA(t,e){let A=null,i=null;return Array.isArray(e)&&e.length?(A=BU(e[0]),e.length>1&&(i=BU(e[e.length-1]))):e instanceof Map&&(A=BU(e)),A||i?new KqA(t,A,i):null}var KqA=(()=>{class t{_element;_startStyles;_endStyles;static initialStylesByElement=new WeakMap;_state=0;_initialStyles;constructor(A,i,n){this._element=A,this._startStyles=i,this._endStyles=n;let o=t.initialStylesByElement.get(A);o||t.initialStylesByElement.set(A,o=new Map),this._initialStyles=o}start(){this._state<1&&(this._startStyles&&Nl(this._element,this._startStyles,this._initialStyles),this._state=1)}finish(){this.start(),this._state<2&&(Nl(this._element,this._initialStyles),this._endStyles&&(Nl(this._element,this._endStyles),this._endStyles=null),this._state=1)}destroy(){this.finish(),this._state<3&&(t.initialStylesByElement.delete(this._element),this._startStyles&&(q1(this._element,this._startStyles),this._endStyles=null),this._endStyles&&(q1(this._element,this._endStyles),this._endStyles=null),Nl(this._element,this._initialStyles),this._state=3)}}return t})();function BU(t){let e=null;return t.forEach((A,i)=>{YqA(i)&&(e=e||new Map,e.set(i,A))}),e}function YqA(t){return t==="display"||t==="position"}var E7=class{element;keyframes;options;_specialStyles;_onDoneFns=[];_onStartFns=[];_onDestroyFns=[];_duration;_delay;_initialized=!1;_finished=!1;_started=!1;_destroyed=!1;_finalKeyframe;_originalOnDoneFns=[];_originalOnStartFns=[];domPlayer;time=0;parentPlayer=null;currentSnapshot=new Map;constructor(e,A,i,n){this.element=e,this.keyframes=A,this.options=i,this._specialStyles=n,this._duration=i.duration,this._delay=i.delay||0,this.time=this._duration+this._delay}_onFinish(){this._finished||(this._finished=!0,this._onDoneFns.forEach(e=>e()),this._onDoneFns=[])}init(){this._buildPlayer(),this._preparePlayerBeforeStart()}_buildPlayer(){if(this._initialized)return;this._initialized=!0;let e=this.keyframes;this.domPlayer=this._triggerWebAnimation(this.element,e,this.options),this._finalKeyframe=e.length?e[e.length-1]:new Map;let A=()=>this._onFinish();this.domPlayer.addEventListener("finish",A),this.onDestroy(()=>{this.domPlayer.removeEventListener("finish",A)})}_preparePlayerBeforeStart(){this._delay?this._resetDomPlayerState():this.domPlayer.pause()}_convertKeyframesToObject(e){let A=[];return e.forEach(i=>{A.push(Object.fromEntries(i))}),A}_triggerWebAnimation(e,A,i){return e.animate(this._convertKeyframesToObject(A),i)}onStart(e){this._originalOnStartFns.push(e),this._onStartFns.push(e)}onDone(e){this._originalOnDoneFns.push(e),this._onDoneFns.push(e)}onDestroy(e){this._onDestroyFns.push(e)}play(){this._buildPlayer(),this.hasStarted()||(this._onStartFns.forEach(e=>e()),this._onStartFns=[],this._started=!0,this._specialStyles&&this._specialStyles.start()),this.domPlayer.play()}pause(){this.init(),this.domPlayer.pause()}finish(){this.init(),this._specialStyles&&this._specialStyles.finish(),this._onFinish(),this.domPlayer.finish()}reset(){this._resetDomPlayerState(),this._destroyed=!1,this._finished=!1,this._started=!1,this._onStartFns=this._originalOnStartFns,this._onDoneFns=this._originalOnDoneFns}_resetDomPlayerState(){this.domPlayer&&this.domPlayer.cancel()}restart(){this.reset(),this.play()}hasStarted(){return this._started}destroy(){this._destroyed||(this._destroyed=!0,this._resetDomPlayerState(),this._onFinish(),this._specialStyles&&this._specialStyles.destroy(),this._onDestroyFns.forEach(e=>e()),this._onDestroyFns=[])}setPosition(e){this.domPlayer===void 0&&this.init(),this.domPlayer.currentTime=e*this.time}getPosition(){return+(this.domPlayer.currentTime??0)/this.time}get totalTime(){return this._delay+this._duration}beforeDestroy(){let e=new Map;this.hasStarted()&&this._finalKeyframe.forEach((i,n)=>{n!=="offset"&&e.set(n,this._finished?i:r7(this.element,n))}),this.currentSnapshot=e}triggerCallback(e){let A=e==="start"?this._onStartFns:this._onDoneFns;A.forEach(i=>i()),A.length=0}},h7=class{validateStyleProperty(e){return!0}validateAnimatableStyleProperty(e){return!0}containsElement(e,A){return oU(e,A)}getParentElement(e){return t7(e)}query(e,A,i){return rU(e,A,i)}computeStyle(e,A,i){return r7(e,A)}animate(e,A,i,n,o,r=[]){let s=n==0?"both":"forwards",a={duration:i,delay:n,fill:s};o&&(a.easing=o);let c=new Map,l=r.filter(d=>d instanceof E7);xlA(i,n)&&l.forEach(d=>{d.currentSnapshot.forEach((B,E)=>c.set(E,B))});let I=RlA(A).map(d=>new Map(d));I=FlA(e,I,c);let C=UqA(e,I);return new E7(e,I,a,C)}};var l7="@",WlA="@.disabled",Q7=class{namespaceId;delegate;engine;_onDestroy;\u0275type=0;constructor(e,A,i,n){this.namespaceId=e,this.delegate=A,this.engine=i,this._onDestroy=n}get data(){return this.delegate.data}destroyNode(e){this.delegate.destroyNode?.(e)}destroy(){this.engine.destroy(this.namespaceId,this.delegate),this.engine.afterFlushAnimationsDone(()=>{queueMicrotask(()=>{this.delegate.destroy()})}),this._onDestroy?.()}createElement(e,A){return this.delegate.createElement(e,A)}createComment(e){return this.delegate.createComment(e)}createText(e){return this.delegate.createText(e)}appendChild(e,A){this.delegate.appendChild(e,A),this.engine.onInsert(this.namespaceId,A,e,!1)}insertBefore(e,A,i,n=!0){this.delegate.insertBefore(e,A,i),this.engine.onInsert(this.namespaceId,A,e,n)}removeChild(e,A,i){this.parentNode(A)&&this.engine.onRemove(this.namespaceId,A,this.delegate)}selectRootElement(e,A){return this.delegate.selectRootElement(e,A)}parentNode(e){return this.delegate.parentNode(e)}nextSibling(e){return this.delegate.nextSibling(e)}setAttribute(e,A,i,n){this.delegate.setAttribute(e,A,i,n)}removeAttribute(e,A,i){this.delegate.removeAttribute(e,A,i)}addClass(e,A){this.delegate.addClass(e,A)}removeClass(e,A){this.delegate.removeClass(e,A)}setStyle(e,A,i,n){this.delegate.setStyle(e,A,i,n)}removeStyle(e,A,i){this.delegate.removeStyle(e,A,i)}setProperty(e,A,i){A.charAt(0)==l7&&A==WlA?this.disableAnimations(e,!!i):this.delegate.setProperty(e,A,i)}setValue(e,A){this.delegate.setValue(e,A)}listen(e,A,i,n){return this.delegate.listen(e,A,i,n)}disableAnimations(e,A){this.engine.disableAnimations(e,A)}},vU=class extends Q7{factory;constructor(e,A,i,n,o){super(A,i,n,o),this.factory=e,this.namespaceId=A}setProperty(e,A,i){A.charAt(0)==l7?A.charAt(1)=="."&&A==WlA?(i=i===void 0?!0:!!i,this.disableAnimations(e,i)):this.engine.process(this.namespaceId,e,A.slice(1),i):this.delegate.setProperty(e,A,i)}listen(e,A,i,n){if(A.charAt(0)==l7){let o=JqA(e),r=A.slice(1),s="";return r.charAt(0)!=l7&&([r,s]=TqA(r)),this.engine.listen(this.namespaceId,o,r,s,a=>{let c=a._data||-1;this.factory.scheduleListenerCallback(c,i,a)})}return this.delegate.listen(e,A,i,n)}};function JqA(t){switch(t){case"body":return document.body;case"document":return document;case"window":return window;default:return t}}function TqA(t){let e=t.indexOf("."),A=t.substring(0,e),i=t.slice(e+1);return[A,i]}var u7=class{delegate;engine;_zone;_currentId=0;_microtaskId=1;_animationCallbacksBuffer=[];_rendererCache=new Map;_cdRecurDepth=0;constructor(e,A,i){this.delegate=e,this.engine=A,this._zone=i,A.onRemovalComplete=(n,o)=>{o?.removeChild(null,n)}}createRenderer(e,A){let i="",n=this.delegate.createRenderer(e,A);if(!e||!A?.data?.animation){let c=this._rendererCache,l=c.get(n);if(!l){let I=()=>c.delete(n);l=new Q7(i,n,this.engine,I),c.set(n,l)}return l}let o=A.id,r=A.id+"-"+this._currentId;this._currentId++,this.engine.register(r,e);let s=c=>{Array.isArray(c)?c.forEach(s):this.engine.registerTrigger(o,r,e,c.name,c)};return A.data.animation.forEach(s),new vU(this,r,n,this.engine)}begin(){this._cdRecurDepth++,this.delegate.begin&&this.delegate.begin()}_scheduleCountTask(){queueMicrotask(()=>{this._microtaskId++})}scheduleListenerCallback(e,A,i){if(e>=0&&e<this._microtaskId){this._zone.run(()=>A(i));return}let n=this._animationCallbacksBuffer;n.length==0&&queueMicrotask(()=>{this._zone.run(()=>{n.forEach(o=>{let[r,s]=o;r(s)}),this._animationCallbacksBuffer=[]})}),n.push([A,i])}end(){this._cdRecurDepth--,this._cdRecurDepth==0&&this._zone.runOutsideAngular(()=>{this._scheduleCountTask(),this.engine.flush(this._microtaskId)}),this.delegate.end&&this.delegate.end()}whenRenderingDone(){return this.engine.whenRenderingDone()}componentReplaced(e){this.engine.flush(),this.delegate.componentReplaced?.(e)}};var HqA=(()=>{class t extends yh{constructor(A,i,n){super(A,i,n)}ngOnDestroy(){this.flush()}static \u0275fac=function(i){return new(i||t)(he(tt),he($C),he(Ad))};static \u0275prov=SA({token:t,factory:t.\u0275fac})}return t})();function OqA(){return new g7}function PqA(t,e,A){return new u7(t,e,A)}var $lA=[{provide:Ad,useFactory:OqA},{provide:yh,useClass:HqA},{provide:ds,useFactory:PqA,deps:[xQ,yh,de]}],jqA=[{provide:$C,useClass:bU},{provide:mi,useValue:"NoopAnimations"},...$lA],XlA=[{provide:$C,useFactory:()=>new h7},{provide:mi,useFactory:()=>"BrowserAnimations"},...$lA],f7=(()=>{class t{static withConfig(A){return{ngModule:t,providers:A.disableAnimations?jqA:XlA}}static \u0275fac=function(i){return new(i||t)};static \u0275mod=ge({type:t});static \u0275inj=le({providers:XlA,imports:[NQ]})}return t})();var qqA=new BA("mat-chips-default-options",{providedIn:"root",factory:()=>({separatorKeyCodes:[13]})});var AgA=(()=>{class t{static \u0275fac=function(i){return new(i||t)};static \u0275mod=ge({type:t});static \u0275inj=le({providers:[dB,{provide:qqA,useValue:{separatorKeyCodes:[13]}}],imports:[Ve,Xa,Ve]})}return t})();var VqA=["input"],ZqA=["formField"],WqA=["*"],kU=class{source;value;constructor(e,A){this.source=e,this.value=A}};var XqA=new BA("MatRadioGroup"),$qA=new BA("mat-radio-default-options",{providedIn:"root",factory:AVA});function AVA(){return{color:"accent",disabledInteractive:!1}}var eVA=(()=>{class t{_elementRef=m(te);_changeDetector=m(lt);_focusMonitor=m(Jr);_radioDispatcher=m(uB);_defaultOptions=m($qA,{optional:!0});_ngZone=m(de);_renderer=m(Gi);_uniqueId=m($i).getId("mat-radio-");_cleanupClick;id=this._uniqueId;name;ariaLabel;ariaLabelledby;ariaDescribedby;disableRipple=!1;tabIndex=0;get checked(){return this._checked}set checked(A){this._checked!==A&&(this._checked=A,A&&this.radioGroup&&this.radioGroup.value!==this.value?this.radioGroup.selected=this:!A&&this.radioGroup&&this.radioGroup.value===this.value&&(this.radioGroup.selected=null),A&&this._radioDispatcher.notify(this.id,this.name),this._changeDetector.markForCheck())}get value(){return this._value}set value(A){this._value!==A&&(this._value=A,this.radioGroup!==null&&(this.checked||(this.checked=this.radioGroup.value===A),this.checked&&(this.radioGroup.selected=this)))}get labelPosition(){return this._labelPosition||this.radioGroup&&this.radioGroup.labelPosition||"after"}set labelPosition(A){this._labelPosition=A}_labelPosition;get disabled(){return this._disabled||this.radioGroup!==null&&this.radioGroup.disabled}set disabled(A){this._setDisabled(A)}get required(){return this._required||this.radioGroup&&this.radioGroup.required}set required(A){this._required=A}get color(){return this._color||this.radioGroup&&this.radioGroup.color||this._defaultOptions&&this._defaultOptions.color||"accent"}set color(A){this._color=A}_color;get disabledInteractive(){return this._disabledInteractive||this.radioGroup!==null&&this.radioGroup.disabledInteractive}set disabledInteractive(A){this._disabledInteractive=A}_disabledInteractive;change=new XA;radioGroup;get inputId(){return`${this.id||this._uniqueId}-input`}_checked=!1;_disabled;_required;_value=null;_removeUniqueSelectionListener=()=>{};_previousTabIndex;_inputElement;_rippleTrigger;_noopAnimations;_injector=m(Dt);constructor(){m(Ln).load(Qr);let A=m(XqA,{optional:!0}),i=m(mi,{optional:!0}),n=m(new Er("tabindex"),{optional:!0});this.radioGroup=A,this._noopAnimations=i==="NoopAnimations",this._disabledInteractive=this._defaultOptions?.disabledInteractive??!1,n&&(this.tabIndex=Mi(n,0))}focus(A,i){i?this._focusMonitor.focusVia(this._inputElement,i,A):this._inputElement.nativeElement.focus(A)}_markForCheck(){this._changeDetector.markForCheck()}ngOnInit(){this.radioGroup&&(this.checked=this.radioGroup.value===this._value,this.checked&&(this.radioGroup.selected=this),this.name=this.radioGroup.name),this._removeUniqueSelectionListener=this._radioDispatcher.listen((A,i)=>{A!==this.id&&i===this.name&&(this.checked=!1)})}ngDoCheck(){this._updateTabIndex()}ngAfterViewInit(){this._updateTabIndex(),this._focusMonitor.monitor(this._elementRef,!0).subscribe(A=>{!A&&this.radioGroup&&this.radioGroup._touch()}),this._ngZone.runOutsideAngular(()=>{this._cleanupClick=this._renderer.listen(this._inputElement.nativeElement,"click",this._onInputClick)})}ngOnDestroy(){this._cleanupClick?.(),this._focusMonitor.stopMonitoring(this._elementRef),this._removeUniqueSelectionListener()}_emitChangeEvent(){this.change.emit(new kU(this,this._value))}_isRippleDisabled(){return this.disableRipple||this.disabled}_onInputInteraction(A){if(A.stopPropagation(),!this.checked&&!this.disabled){let i=this.radioGroup&&this.value!==this.radioGroup.value;this.checked=!0,this._emitChangeEvent(),this.radioGroup&&(this.radioGroup._controlValueAccessorChangeFn(this.value),i&&this.radioGroup._emitChangeEvent())}}_onTouchTargetClick(A){this._onInputInteraction(A),(!this.disabled||this.disabledInteractive)&&this._inputElement?.nativeElement.focus()}_setDisabled(A){this._disabled!==A&&(this._disabled=A,this._changeDetector.markForCheck())}_onInputClick=A=>{this.disabled&&this.disabledInteractive&&A.preventDefault()};_updateTabIndex(){let A=this.radioGroup,i;if(!A||!A.selected||this.disabled?i=this.tabIndex:i=A.selected===this?this.tabIndex:-1,i!==this._previousTabIndex){let n=this._inputElement?.nativeElement;n&&(n.setAttribute("tabindex",i+""),this._previousTabIndex=i,Vo(()=>{queueMicrotask(()=>{A&&A.selected&&A.selected!==this&&document.activeElement===n&&(A.selected?._inputElement.nativeElement.focus(),document.activeElement===n&&this._inputElement.nativeElement.blur())})},{injector:this._injector}))}}static \u0275fac=function(i){return new(i||t)};static \u0275cmp=YA({type:t,selectors:[["mat-radio-button"]],viewQuery:function(i,n){if(i&1&&(Ge(VqA,5),Ge(ZqA,7,te)),i&2){let o;$A(o=Ae())&&(n._inputElement=o.first),$A(o=Ae())&&(n._rippleTrigger=o.first)}},hostAttrs:[1,"mat-mdc-radio-button"],hostVars:19,hostBindings:function(i,n){i&1&&mA("focus",function(){return n._inputElement.nativeElement.focus()}),i&2&&(_e("id",n.id)("tabindex",null)("aria-label",null)("aria-labelledby",null)("aria-describedby",null),ue("mat-primary",n.color==="primary")("mat-accent",n.color==="accent")("mat-warn",n.color==="warn")("mat-mdc-radio-checked",n.checked)("mat-mdc-radio-disabled",n.disabled)("mat-mdc-radio-disabled-interactive",n.disabledInteractive)("_mat-animation-noopable",n._noopAnimations))},inputs:{id:"id",name:"name",ariaLabel:[0,"aria-label","ariaLabel"],ariaLabelledby:[0,"aria-labelledby","ariaLabelledby"],ariaDescribedby:[0,"aria-describedby","ariaDescribedby"],disableRipple:[2,"disableRipple","disableRipple",ae],tabIndex:[2,"tabIndex","tabIndex",A=>A==null?0:Mi(A)],checked:[2,"checked","checked",ae],value:"value",labelPosition:"labelPosition",disabled:[2,"disabled","disabled",ae],required:[2,"required","required",ae],color:"color",disabledInteractive:[2,"disabledInteractive","disabledInteractive",ae]},outputs:{change:"change"},exportAs:["matRadioButton"],ngContentSelectors:WqA,decls:13,vars:17,consts:[["formField",""],["input",""],["mat-internal-form-field","",3,"labelPosition"],[1,"mdc-radio"],[1,"mat-mdc-radio-touch-target",3,"click"],["type","radio",1,"mdc-radio__native-control",3,"change","id","checked","disabled","required"],[1,"mdc-radio__background"],[1,"mdc-radio__outer-circle"],[1,"mdc-radio__inner-circle"],["mat-ripple","",1,"mat-radio-ripple","mat-focus-indicator",3,"matRippleTrigger","matRippleDisabled","matRippleCentered"],[1,"mat-ripple-element","mat-radio-persistent-ripple"],[1,"mdc-label",3,"for"]],template:function(i,n){if(i&1){let o=De();Yt(),S(0,"div",2,0)(2,"div",3)(3,"div",4),mA("click",function(s){return LA(o),xA(n._onTouchTargetClick(s))}),R(),S(4,"input",5,1),mA("change",function(s){return LA(o),xA(n._onInputInteraction(s))}),R(),S(6,"div",6),UA(7,"div",7)(8,"div",8),R(),S(9,"div",9),UA(10,"div",10),R()(),S(11,"label",11),xe(12),R()()}i&2&&(vA("labelPosition",n.labelPosition),_(2),ue("mdc-radio--disabled",n.disabled),_(2),vA("id",n.inputId)("checked",n.checked)("disabled",n.disabled&&!n.disabledInteractive)("required",n.required),_e("name",n.name)("value",n.value)("aria-label",n.ariaLabel)("aria-labelledby",n.ariaLabelledby)("aria-describedby",n.ariaDescribedby)("aria-disabled",n.disabled&&n.disabledInteractive?"true":null),_(5),vA("matRippleTrigger",n._rippleTrigger.nativeElement)("matRippleDisabled",n._isRippleDisabled())("matRippleCentered",!0),_(2),vA("for",n.inputId))},dependencies:[Gs,BB],styles:['.mat-mdc-radio-button{-webkit-tap-highlight-color:rgba(0,0,0,0)}.mat-mdc-radio-button .mdc-radio{display:inline-block;position:relative;flex:0 0 auto;box-sizing:content-box;width:20px;height:20px;cursor:pointer;will-change:opacity,transform,border-color,color;padding:calc((var(--mdc-radio-state-layer-size, 40px) - 20px)/2)}.mat-mdc-radio-button .mdc-radio:hover .mdc-radio__native-control:not([disabled]):not(:focus)~.mdc-radio__background::before{opacity:.04;transform:scale(1)}.mat-mdc-radio-button .mdc-radio:hover .mdc-radio__native-control:not([disabled])~.mdc-radio__background .mdc-radio__outer-circle{border-color:var(--mdc-radio-unselected-hover-icon-color, var(--mat-sys-on-surface))}.mat-mdc-radio-button .mdc-radio:hover .mdc-radio__native-control:enabled:checked+.mdc-radio__background .mdc-radio__outer-circle,.mat-mdc-radio-button .mdc-radio:hover .mdc-radio__native-control:enabled:checked+.mdc-radio__background .mdc-radio__inner-circle{border-color:var(--mdc-radio-selected-hover-icon-color, var(--mat-sys-primary))}.mat-mdc-radio-button .mdc-radio:active .mdc-radio__native-control:enabled:not(:checked)+.mdc-radio__background .mdc-radio__outer-circle{border-color:var(--mdc-radio-unselected-pressed-icon-color, var(--mat-sys-on-surface))}.mat-mdc-radio-button .mdc-radio:active .mdc-radio__native-control:enabled:checked+.mdc-radio__background .mdc-radio__outer-circle,.mat-mdc-radio-button .mdc-radio:active .mdc-radio__native-control:enabled:checked+.mdc-radio__background .mdc-radio__inner-circle{border-color:var(--mdc-radio-selected-pressed-icon-color, var(--mat-sys-primary))}.mat-mdc-radio-button .mdc-radio__background{display:inline-block;position:relative;box-sizing:border-box;width:20px;height:20px}.mat-mdc-radio-button .mdc-radio__background::before{position:absolute;transform:scale(0, 0);border-radius:50%;opacity:0;pointer-events:none;content:"";transition:opacity 90ms cubic-bezier(0.4, 0, 0.6, 1),transform 90ms cubic-bezier(0.4, 0, 0.6, 1);width:var(--mdc-radio-state-layer-size, 40px);height:var(--mdc-radio-state-layer-size, 40px);top:calc(-1*(var(--mdc-radio-state-layer-size, 40px) - 20px)/2);left:calc(-1*(var(--mdc-radio-state-layer-size, 40px) - 20px)/2)}.mat-mdc-radio-button .mdc-radio__outer-circle{position:absolute;top:0;left:0;box-sizing:border-box;width:100%;height:100%;border-width:2px;border-style:solid;border-radius:50%;transition:border-color 90ms cubic-bezier(0.4, 0, 0.6, 1)}.mat-mdc-radio-button .mdc-radio__inner-circle{position:absolute;top:0;left:0;box-sizing:border-box;width:100%;height:100%;transform:scale(0, 0);border-width:10px;border-style:solid;border-radius:50%;transition:transform 90ms cubic-bezier(0.4, 0, 0.6, 1),border-color 90ms cubic-bezier(0.4, 0, 0.6, 1)}.mat-mdc-radio-button .mdc-radio__native-control{position:absolute;margin:0;padding:0;opacity:0;top:0;right:0;left:0;cursor:inherit;z-index:1;width:var(--mdc-radio-state-layer-size, 40px);height:var(--mdc-radio-state-layer-size, 40px)}.mat-mdc-radio-button .mdc-radio__native-control:checked+.mdc-radio__background,.mat-mdc-radio-button .mdc-radio__native-control:disabled+.mdc-radio__background{transition:opacity 90ms cubic-bezier(0, 0, 0.2, 1),transform 90ms cubic-bezier(0, 0, 0.2, 1)}.mat-mdc-radio-button .mdc-radio__native-control:checked+.mdc-radio__background .mdc-radio__outer-circle,.mat-mdc-radio-button .mdc-radio__native-control:disabled+.mdc-radio__background .mdc-radio__outer-circle{transition:border-color 90ms cubic-bezier(0, 0, 0.2, 1)}.mat-mdc-radio-button .mdc-radio__native-control:checked+.mdc-radio__background .mdc-radio__inner-circle,.mat-mdc-radio-button .mdc-radio__native-control:disabled+.mdc-radio__background .mdc-radio__inner-circle{transition:transform 90ms cubic-bezier(0, 0, 0.2, 1),border-color 90ms cubic-bezier(0, 0, 0.2, 1)}.mat-mdc-radio-button .mdc-radio__native-control:focus+.mdc-radio__background::before{transform:scale(1);opacity:.12;transition:opacity 90ms cubic-bezier(0, 0, 0.2, 1),transform 90ms cubic-bezier(0, 0, 0.2, 1)}.mat-mdc-radio-button .mdc-radio__native-control:disabled:not(:checked)+.mdc-radio__background .mdc-radio__outer-circle{border-color:var(--mdc-radio-disabled-unselected-icon-color, var(--mat-sys-on-surface));opacity:var(--mdc-radio-disabled-unselected-icon-opacity, 0.38)}.mat-mdc-radio-button .mdc-radio__native-control:disabled+.mdc-radio__background{cursor:default}.mat-mdc-radio-button .mdc-radio__native-control:disabled+.mdc-radio__background .mdc-radio__inner-circle,.mat-mdc-radio-button .mdc-radio__native-control:disabled+.mdc-radio__background .mdc-radio__outer-circle{border-color:var(--mdc-radio-disabled-selected-icon-color, var(--mat-sys-on-surface));opacity:var(--mdc-radio-disabled-selected-icon-opacity, 0.38)}.mat-mdc-radio-button .mdc-radio__native-control:enabled:not(:checked)+.mdc-radio__background .mdc-radio__outer-circle{border-color:var(--mdc-radio-unselected-icon-color, var(--mat-sys-on-surface-variant))}.mat-mdc-radio-button .mdc-radio__native-control:enabled:checked+.mdc-radio__background .mdc-radio__outer-circle,.mat-mdc-radio-button .mdc-radio__native-control:enabled:checked+.mdc-radio__background .mdc-radio__inner-circle{border-color:var(--mdc-radio-selected-icon-color, var(--mat-sys-primary))}.mat-mdc-radio-button .mdc-radio__native-control:enabled:focus:checked+.mdc-radio__background .mdc-radio__inner-circle,.mat-mdc-radio-button .mdc-radio__native-control:enabled:focus:checked+.mdc-radio__background .mdc-radio__outer-circle{border-color:var(--mdc-radio-selected-focus-icon-color, var(--mat-sys-primary))}.mat-mdc-radio-button .mdc-radio__native-control:checked+.mdc-radio__background .mdc-radio__inner-circle{transform:scale(0.5);transition:transform 90ms cubic-bezier(0, 0, 0.2, 1),border-color 90ms cubic-bezier(0, 0, 0.2, 1)}.mat-mdc-radio-button.mat-mdc-radio-disabled-interactive .mdc-radio--disabled{pointer-events:auto}.mat-mdc-radio-button.mat-mdc-radio-disabled-interactive .mdc-radio--disabled .mdc-radio__native-control:not(:checked)+.mdc-radio__background .mdc-radio__outer-circle{border-color:var(--mdc-radio-disabled-unselected-icon-color, var(--mat-sys-on-surface));opacity:var(--mdc-radio-disabled-unselected-icon-opacity, 0.38)}.mat-mdc-radio-button.mat-mdc-radio-disabled-interactive .mdc-radio--disabled:hover .mdc-radio__native-control:checked+.mdc-radio__background .mdc-radio__inner-circle,.mat-mdc-radio-button.mat-mdc-radio-disabled-interactive .mdc-radio--disabled:hover .mdc-radio__native-control:checked+.mdc-radio__background .mdc-radio__outer-circle,.mat-mdc-radio-button.mat-mdc-radio-disabled-interactive .mdc-radio--disabled .mdc-radio__native-control:checked:focus+.mdc-radio__background .mdc-radio__inner-circle,.mat-mdc-radio-button.mat-mdc-radio-disabled-interactive .mdc-radio--disabled .mdc-radio__native-control:checked:focus+.mdc-radio__background .mdc-radio__outer-circle,.mat-mdc-radio-button.mat-mdc-radio-disabled-interactive .mdc-radio--disabled .mdc-radio__native-control+.mdc-radio__background .mdc-radio__inner-circle,.mat-mdc-radio-button.mat-mdc-radio-disabled-interactive .mdc-radio--disabled .mdc-radio__native-control+.mdc-radio__background .mdc-radio__outer-circle{border-color:var(--mdc-radio-disabled-selected-icon-color, var(--mat-sys-on-surface));opacity:var(--mdc-radio-disabled-selected-icon-opacity, 0.38)}.mat-mdc-radio-button._mat-animation-noopable .mdc-radio__background::before,.mat-mdc-radio-button._mat-animation-noopable .mdc-radio__outer-circle,.mat-mdc-radio-button._mat-animation-noopable .mdc-radio__inner-circle{transition:none !important}.mat-mdc-radio-button .mdc-radio__background::before{background-color:var(--mat-radio-ripple-color, var(--mat-sys-on-surface))}.mat-mdc-radio-button.mat-mdc-radio-checked .mat-ripple-element,.mat-mdc-radio-button.mat-mdc-radio-checked .mdc-radio__background::before{background-color:var(--mat-radio-checked-ripple-color, var(--mat-sys-primary))}.mat-mdc-radio-button.mat-mdc-radio-disabled-interactive .mdc-radio--disabled .mat-ripple-element,.mat-mdc-radio-button.mat-mdc-radio-disabled-interactive .mdc-radio--disabled .mdc-radio__background::before{background-color:var(--mat-radio-ripple-color, var(--mat-sys-on-surface))}.mat-mdc-radio-button .mat-internal-form-field{color:var(--mat-radio-label-text-color, var(--mat-sys-on-surface));font-family:var(--mat-radio-label-text-font, var(--mat-sys-body-medium-font));line-height:var(--mat-radio-label-text-line-height, var(--mat-sys-body-medium-line-height));font-size:var(--mat-radio-label-text-size, var(--mat-sys-body-medium-size));letter-spacing:var(--mat-radio-label-text-tracking, var(--mat-sys-body-medium-tracking));font-weight:var(--mat-radio-label-text-weight, var(--mat-sys-body-medium-weight))}.mat-mdc-radio-button .mdc-radio--disabled+label{color:var(--mat-radio-disabled-label-color, color-mix(in srgb, var(--mat-sys-on-surface) 38%, transparent))}.mat-mdc-radio-button .mat-radio-ripple{top:0;left:0;right:0;bottom:0;position:absolute;pointer-events:none;border-radius:50%}.mat-mdc-radio-button .mat-radio-ripple .mat-ripple-element{opacity:.14}.mat-mdc-radio-button .mat-radio-ripple::before{border-radius:50%}.mat-mdc-radio-button .mdc-radio .mdc-radio__native-control:focus:enabled:not(:checked)~.mdc-radio__background .mdc-radio__outer-circle{border-color:var(--mdc-radio-unselected-focus-icon-color, var(--mat-sys-on-surface))}.mat-mdc-radio-button.cdk-focused .mat-focus-indicator::before{content:""}.mat-mdc-radio-disabled{cursor:default;pointer-events:none}.mat-mdc-radio-disabled.mat-mdc-radio-disabled-interactive{pointer-events:auto}.mat-mdc-radio-touch-target{position:absolute;top:50%;left:50%;height:48px;width:48px;transform:translate(-50%, -50%);display:var(--mat-radio-touch-target-display, block)}[dir=rtl] .mat-mdc-radio-touch-target{left:auto;right:50%;transform:translate(50%, -50%)}'],encapsulation:2,changeDetection:0})}return t})(),egA=(()=>{class t{static \u0275fac=function(i){return new(i||t)};static \u0275mod=ge({type:t});static \u0275inj=le({imports:[Ve,Xa,eVA,Ve]})}return t})();var m7=class t{static \u0275fac=function(A){return new(A||t)};static \u0275mod=ge({type:t});static \u0275inj=le({imports:[g0,e6,scA,rq,f0,Ty,KI,fP,ecA,acA,gcA,QcA,egA,a8,PaA,haA,NaA,$cA,c8,pcA,f7,VaA,zcA.forRoot(),HcA,EH,AgA,$j,ncA]})};var Mf=class t{static \u0275fac=function(A){return new(A||t)};static \u0275mod=ge({type:t,bootstrap:[mh]});static \u0275inj=le({providers:[Jg,K2,Tg,Eh,hh,j1,zc,Bh,J2,zg],imports:[m7,NQ,e6,Vb,$y,Ty,f0,KI,f7]})};fetch("./assets/config/runtime-config.json").then(t=>t.json()).then(t=>{window.runtimeConfig=t,Gp().bootstrapModule(Mf).catch(e=>console.error(e))});Gp().bootstrapModule(Mf).catch(t=>console.error(t));
