diff --git a/notebooks/meetings_workshops/workshop_osm_2022/Cloud_DirectDownload_AmazonRiver_Estuary_Exploration.ipynb b/notebooks/meetings_workshops/workshop_osm_2022/Cloud_DirectDownload_AmazonRiver_Estuary_Exploration.ipynb index f42dfa4b..0762baf7 100644 --- a/notebooks/meetings_workshops/workshop_osm_2022/Cloud_DirectDownload_AmazonRiver_Estuary_Exploration.ipynb +++ b/notebooks/meetings_workshops/workshop_osm_2022/Cloud_DirectDownload_AmazonRiver_Estuary_Exploration.ipynb @@ -20,7 +20,7 @@ "\n", "### Learning Objectives\n", " - Compare cloud access methods (in tandem with notebook \"Amazon Estuary Exploration: In Cloud AWS Version\")\n", - " - Search for data products using Earthdata Search GUI\n", + " - Search for data products using `earthaccess` Python library\n", " - Access datasets using xarray and visualize using hvplot or plot tools\n", "\n", "This tutorial explores the relationships between river height, land water equivalent thickness, sea surface salinity, and sea surface temperature in the Amazon River estuary and coastal region from multiple datasets listed below. The contents are useful for the ocean, coastal, and terrestrial hydrosphere communities, showcasing how to use cloud datasets and services. This notebook is meant to be executed locally.\n", @@ -28,9 +28,9 @@ "## Cloud Datasets\n", "The tutorial itself will use four different datasets: \n", "\n", - "1\\. **TELLUS_GRAC-GRFO_MASCON_CRI_GRID_RL06_V2** \n", + "1\\. **TELLUS_GRAC-GRFO_MASCON_CRI_GRID_RL06.1_V3** \n", " \n", - ">DOI: [https://doi.org/10.5067/TEMSC-3JC62](https://doi.org/10.5067/TEMSC-3JC62) \n", + ">DOI: [https://doi.org/10.5067/TEMSC-3JC63](https://doi.org/10.5067/TEMSC-3JC63) \n", " \n", " The Gravity Recovery And Climate Experiment Follow-On (GRACE-FO) satellite land water equivalent (LWE) thicknesses will be used to observe seasonal changes in water storage around the river. When discharge is high, the change in water storage will increase, thus highlighting a wet season. \n", "\n", @@ -58,7 +58,7 @@ "More details on available collections are on the [PO.DAAC Cloud Earthdata Search Portal](https://search.earthdata.nasa.gov/portal/podaac-cloud/search). For more information on the PO.DAAC transition to the cloud, please visit: https://podaac.jpl.nasa.gov/cloud-datasets/about\n", "\n", "#### Note: NASA Earthdata Login Required\n", - "An Earthdata Login account is required to access data, as well as discover restricted data, from the NASA Earthdata system. Please visit https://urs.earthdata.nasa.gov to register and manage your Earthdata Login account. This account is free to create and only takes a moment to set up.\n" + "An Earthdata Login account is required to access data, as well as discover restricted data, from the NASA Earthdata system. Thus, to access NASA data, you need Earthdata Login. Please visit https://urs.earthdata.nasa.gov to register and manage your Earthdata Login account. This account is free to create and only takes a moment to set up. We use earthaccess to authenticate your login credentials below.\n" ] }, { @@ -78,7 +78,6 @@ { "data": { "application/javascript": [ - "\n", "(function(root) {\n", " function now() {\n", " return new Date();\n", @@ -123,7 +122,6 @@ " return null;\n", " }\n", " console.debug(\"Bokeh: BokehJS not loaded, scheduling load and callback at\", now());\n", - " root._bokeh_is_loading = css_urls.length + js_urls.length + js_modules.length;\n", "\n", " function on_load() {\n", " root._bokeh_is_loading--;\n", @@ -151,12 +149,35 @@ "\n", " var skip = [];\n", " if (window.requirejs) {\n", - " window.requirejs.config({'packages': {}, 'paths': {}, 'shim': {}});\n", - " \n", - " }\n", - " for (var i = 0; i < js_urls.length; i++) {\n", + " window.requirejs.config({'packages': {}, 'paths': {'gridstack': 'https://cdn.jsdelivr.net/npm/gridstack@4.2.5/dist/gridstack-h5', 'notyf': 'https://cdn.jsdelivr.net/npm/notyf@3/notyf.min'}, 'shim': {'gridstack': {'exports': 'GridStack'}}});\n", + " require([\"gridstack\"], function(GridStack) {\n", + "\twindow.GridStack = GridStack\n", + "\ton_load()\n", + " })\n", + " require([\"notyf\"], function() {\n", + "\ton_load()\n", + " })\n", + " root._bokeh_is_loading = css_urls.length + 2;\n", + " } else {\n", + " root._bokeh_is_loading = css_urls.length + js_urls.length + js_modules.length;\n", + " } if (((window['GridStack'] !== undefined) && (!(window['GridStack'] instanceof HTMLElement))) || window.requirejs) {\n", + " var urls = ['https://cdn.holoviz.org/panel/0.14.3/dist/bundled/gridstack/gridstack@4.2.5/dist/gridstack-h5.js'];\n", + " for (var i = 0; i < urls.length; i++) {\n", + " skip.push(urls[i])\n", + " }\n", + " } if (((window['Notyf'] !== undefined) && (!(window['Notyf'] instanceof HTMLElement))) || window.requirejs) {\n", + " var urls = ['https://cdn.holoviz.org/panel/0.14.3/dist/bundled/notificationarea/notyf@3/notyf.min.js'];\n", + " for (var i = 0; i < urls.length; i++) {\n", + " skip.push(urls[i])\n", + " }\n", + " } for (var i = 0; i < js_urls.length; i++) {\n", " var url = js_urls[i];\n", - " if (skip.indexOf(url) >= 0) { on_load(); continue; }\n", + " if (skip.indexOf(url) >= 0) {\n", + "\tif (!window.requirejs) {\n", + "\t on_load();\n", + "\t}\n", + "\tcontinue;\n", + " }\n", " var element = document.createElement('script');\n", " element.onload = on_load;\n", " element.onerror = on_error;\n", @@ -167,7 +188,12 @@ " }\n", " for (var i = 0; i < js_modules.length; i++) {\n", " var url = js_modules[i];\n", - " if (skip.indexOf(url) >= 0) { on_load(); continue; }\n", + " if (skip.indexOf(url) >= 0) {\n", + "\tif (!window.requirejs) {\n", + "\t on_load();\n", + "\t}\n", + "\tcontinue;\n", + " }\n", " var element = document.createElement('script');\n", " element.onload = on_load;\n", " element.onerror = on_error;\n", @@ -191,35 +217,28 @@ " var js_urls = [];\n", " var js_modules = [];\n", " var css_urls = [];\n", - " var inline_js = [\n", - " function(Bokeh) {\n", - " inject_raw_css(\".bk.alert {\\n padding: 0.75rem 1.25rem;\\n border: 1px solid transparent;\\n border-radius: 0.25rem;\\n /* Don't set margin because that will not render correctly! */\\n /* margin-bottom: 1rem; */\\n margin-top: 15px;\\n margin-bottom: 15px;\\n}\\n.bk.alert a {\\n color: rgb(11, 46, 19); /* #002752; */\\n font-weight: 700;\\n text-decoration: rgb(11, 46, 19);\\n text-decoration-color: rgb(11, 46, 19);\\n text-decoration-line: none;\\n text-decoration-style: solid;\\n text-decoration-thickness: auto;\\n }\\n.bk.alert a:hover {\\n color: rgb(11, 46, 19);\\n font-weight: 700;\\n text-decoration: underline;\\n}\\n\\n.bk.alert-primary {\\n color: #004085;\\n background-color: #cce5ff;\\n border-color: #b8daff;\\n}\\n.bk.alert-primary hr {\\n border-top-color: #9fcdff;\\n}\\n\\n.bk.alert-secondary {\\n color: #383d41;\\n background-color: #e2e3e5;\\n border-color: #d6d8db;\\n }\\n.bk.alert-secondary hr {\\n border-top-color: #c8cbcf;\\n}\\n\\n.bk.alert-success {\\n color: #155724;\\n background-color: #d4edda;\\n border-color: #c3e6cb;\\n }\\n\\n.bk.alert-success hr {\\n border-top-color: #b1dfbb;\\n}\\n\\n.bk.alert-info {\\n color: #0c5460;\\n background-color: #d1ecf1;\\n border-color: #bee5eb;\\n }\\n.bk.alert-info hr {\\n border-top-color: #abdde5;\\n}\\n\\n.bk.alert-warning {\\n color: #856404;\\n background-color: #fff3cd;\\n border-color: #ffeeba;\\n }\\n\\n.bk.alert-warning hr {\\n border-top-color: #ffe8a1;\\n}\\n\\n.bk.alert-danger {\\n color: #721c24;\\n background-color: #f8d7da;\\n border-color: #f5c6cb;\\n}\\n.bk.alert-danger hr {\\n border-top-color: #f1b0b7;\\n}\\n\\n.bk.alert-light {\\n color: #818182;\\n background-color: #fefefe;\\n border-color: #fdfdfe;\\n }\\n.bk.alert-light hr {\\n border-top-color: #ececf6;\\n}\\n\\n.bk.alert-dark {\\n color: #1b1e21;\\n background-color: #d6d8d9;\\n border-color: #c6c8ca;\\n }\\n.bk.alert-dark hr {\\n border-top-color: #b9bbbe;\\n}\\n\\n\\n/* adjf\\u00e6l */\\n\\n.bk.alert-primary a {\\n color: #002752;\\n}\\n\\n.bk.alert-secondary a {\\n color: #202326;\\n}\\n\\n\\n.bk.alert-success a {\\n color: #0b2e13;\\n}\\n\\n\\n.bk.alert-info a {\\n color: #062c33;\\n}\\n\\n\\n.bk.alert-warning a {\\n color: #533f03;\\n}\\n\\n\\n.bk.alert-danger a {\\n color: #491217;\\n}\\n\\n.bk.alert-light a {\\n color: #686868;\\n}\\n\\n.bk.alert-dark a {\\n color: #040505;\\n}\");\n", - " },\n", - " function(Bokeh) {\n", - " inject_raw_css(\".bk.card {\\n border: 1px solid rgba(0,0,0,.125);\\n border-radius: 0.25rem;\\n}\\n.bk.accordion {\\n border: 1px solid rgba(0,0,0,.125);\\n}\\n.bk.card-header {\\n align-items: center;\\n background-color: rgba(0, 0, 0, 0.03);\\n border-radius: 0.25rem;\\n display: inline-flex;\\n justify-content: start;\\n width: 100%;\\n}\\n.bk.accordion-header {\\n align-items: center;\\n background-color: rgba(0, 0, 0, 0.03);\\n border-radius: 0;\\n display: flex;\\n justify-content: start;\\n width: 100%;\\n}\\n.bk.card-button {\\n background-color: transparent;\\n margin-left: 0.5em;\\n}\\n.bk.card-header-row {\\n position: relative !important;\\n}\\n.bk.card-title {\\n align-items: center;\\n font-size: 1.4em;\\n font-weight: bold;\\n overflow-wrap: break-word;\\n}\\n.bk.card-header-row > .bk {\\n padding-right: 1.5em !important;\\n overflow-wrap: break-word;\\n}\\n\");\n", - " },\n", - " function(Bokeh) {\n", - " inject_raw_css(\"table.panel-df {\\n margin-left: auto;\\n margin-right: auto;\\n border: none;\\n border-collapse: collapse;\\n border-spacing: 0;\\n color: black;\\n font-size: 12px;\\n table-layout: fixed;\\n width: 100%;\\n}\\n\\n.panel-df tr, .panel-df th, .panel-df td {\\n text-align: right;\\n vertical-align: middle;\\n padding: 0.5em 0.5em !important;\\n line-height: normal;\\n white-space: normal;\\n max-width: none;\\n border: none;\\n}\\n\\n.panel-df tbody {\\n display: table-row-group;\\n vertical-align: middle;\\n border-color: inherit;\\n}\\n\\n.panel-df tbody tr:nth-child(odd) {\\n background: #f5f5f5;\\n}\\n\\n.panel-df thead {\\n border-bottom: 1px solid black;\\n vertical-align: bottom;\\n}\\n\\n.panel-df tr:hover {\\n background: lightblue !important;\\n cursor: pointer;\\n}\\n\");\n", - " },\n", - " function(Bokeh) {\n", + " var inline_js = [ function(Bokeh) {\n", + " inject_raw_css(\".bk.debugger-card {\\n border: 1px solid rgba(0,0,0,1);\\n color: rgba(255,255,255,1);\\n background-color: rgba(0,0,0,1);\\n border-radius: 0rem;\\n}\\n.bk.debugger-card-header {\\n align-items: center;\\n text-align: left;\\n background-color: rgba(0, 0, 0, 1)!important;\\n color: rgba(255, 255, 255, 1);\\n border-radius: 0rem;\\n display: inline-flex;\\n justify-content: start;\\n width: 100%;\\n}\\n.bk.debugger-card-button {\\n background-color: transparent;\\n color: rgba(255, 255, 255, 1);\\n margin-left: 0.5em;\\n}\\n.bk.debugger-card-title {\\n align-items: center;\\n text-align: left;\\n color: rgba(255, 255, 255, 1);\\n font-size: 1em;\\n overflow-wrap: break-word;\\n}\\n\\n/* Special debugger buttons for clearing and saving */\\n.bk button.special_btn {\\n width: 25px;\\n height: 25px;\\n background-color: black;\\n color: white;\\n display: inline-block;\\n}\\n\\n\\n.bk button.special_btn .tooltiptext {\\n visibility: hidden;\\n width: 100px;\\n background-color: darkgray;\\n color: #fff;\\n text-align: center;\\n border-radius: 6px;\\n padding: 5px 0;\\n\\n /* Position the tooltip */\\n position: relative;\\n z-index: 1;\\n top: 100%;\\n left: 100%;\\n margin-left: -100px;\\n display: block;\\n}\\n\\n.bk button.special_btn:hover .tooltiptext {\\n visibility: visible;\\n}\\n\\n\\n\\n.bk button.clear_btn:hover .shown { display: none;}\\n.bk button.clear_btn:hover:before { content: \\\"\\u2611\\\"; }\\n\");\n", + " }, function(Bokeh) {\n", + " inject_raw_css(\".bk.alert {\\n padding: 0.75rem 1.25rem;\\n border: 1px solid transparent;\\n border-radius: 0.25rem;\\n /* Don't set margin because that will not render correctly! */\\n /* margin-bottom: 1rem; */\\n margin-top: 15px;\\n margin-bottom: 15px;\\n}\\n.bk.alert a {\\n color: rgb(11, 46, 19); /* #002752; */\\n font-weight: 700;\\n text-decoration: rgb(11, 46, 19);\\n text-decoration-color: rgb(11, 46, 19);\\n text-decoration-line: none;\\n text-decoration-style: solid;\\n text-decoration-thickness: auto;\\n }\\n.bk.alert a:hover {\\n color: rgb(11, 46, 19);\\n font-weight: 700;\\n text-decoration: underline;\\n}\\n\\n.bk.alert-primary {\\n color: #004085;\\n background-color: #cce5ff;\\n border-color: #b8daff;\\n}\\n.bk.alert-primary hr {\\n border-top-color: #9fcdff;\\n}\\n\\n.bk.alert-secondary {\\n color: #383d41;\\n background-color: #e2e3e5;\\n border-color: #d6d8db;\\n }\\n.bk.alert-secondary hr {\\n border-top-color: #c8cbcf;\\n}\\n\\n.bk.alert-success {\\n color: #155724;\\n background-color: #d4edda;\\n border-color: #c3e6cb;\\n }\\n\\n.bk.alert-success hr {\\n border-top-color: #b1dfbb;\\n}\\n\\n.bk.alert-info {\\n color: #0c5460;\\n background-color: #d1ecf1;\\n border-color: #bee5eb;\\n }\\n.bk.alert-info hr {\\n border-top-color: #abdde5;\\n}\\n\\n.bk.alert-warning {\\n color: #856404;\\n background-color: #fff3cd;\\n border-color: #ffeeba;\\n }\\n\\n.bk.alert-warning hr {\\n border-top-color: #ffe8a1;\\n}\\n\\n.bk.alert-danger {\\n color: #721c24;\\n background-color: #f8d7da;\\n border-color: #f5c6cb;\\n}\\n.bk.alert-danger hr {\\n border-top-color: #f1b0b7;\\n}\\n\\n.bk.alert-light {\\n color: #818182;\\n background-color: #fefefe;\\n border-color: #fdfdfe;\\n }\\n.bk.alert-light hr {\\n border-top-color: #ececf6;\\n}\\n\\n.bk.alert-dark {\\n color: #1b1e21;\\n background-color: #d6d8d9;\\n border-color: #c6c8ca;\\n }\\n.bk.alert-dark hr {\\n border-top-color: #b9bbbe;\\n}\\n\\n\\n/* adjf\\u00e6l */\\n\\n.bk.alert-primary a {\\n color: #002752;\\n}\\n\\n.bk.alert-secondary a {\\n color: #202326;\\n}\\n\\n\\n.bk.alert-success a {\\n color: #0b2e13;\\n}\\n\\n\\n.bk.alert-info a {\\n color: #062c33;\\n}\\n\\n\\n.bk.alert-warning a {\\n color: #533f03;\\n}\\n\\n\\n.bk.alert-danger a {\\n color: #491217;\\n}\\n\\n.bk.alert-light a {\\n color: #686868;\\n}\\n\\n.bk.alert-dark a {\\n color: #040505;\\n}\\n\");\n", + " }, function(Bokeh) {\n", + " inject_raw_css(\".bk.card {\\n border: 1px solid rgba(0,0,0,.125);\\n border-radius: 0.25rem;\\n}\\n.bk.accordion {\\n border: 1px solid rgba(0,0,0,.125);\\n}\\n.bk.card-header {\\n align-items: center;\\n background-color: rgba(0, 0, 0, 0.03);\\n border-radius: 0.25rem;\\n display: inline-flex;\\n justify-content: start;\\n width: 100%;\\n}\\n.bk.accordion-header {\\n align-items: center;\\n background-color: rgba(0, 0, 0, 0.03);\\n border-radius: 0;\\n display: flex;\\n justify-content: start;\\n width: 100%;\\n}\\n.bk.card-button {\\n background-color: transparent;\\n margin-left: 0.5em;\\n}\\n.bk.card-header-row {\\n position: relative !important;\\n}\\n.bk.card-title {\\n align-items: center;\\n font-size: 1.4em;\\n font-weight: bold;\\n overflow-wrap: break-word;\\n}\\n.bk.card-header-row > .bk {\\n overflow-wrap: break-word;\\n text-align: center;\\n}\\n\");\n", + " }, function(Bokeh) {\n", + " inject_raw_css(\".bk.panel-widget-box {\\n min-height: 20px;\\n background-color: #f5f5f5;\\n border: 1px solid #e3e3e3;\\n border-radius: 4px;\\n -webkit-box-shadow: inset 0 1px 1px rgba(0,0,0,.05);\\n box-shadow: inset 0 1px 1px rgba(0,0,0,.05);\\n overflow-x: hidden;\\n overflow-y: hidden;\\n}\\n\\n.scrollable {\\n overflow: scroll;\\n}\\n\\nprogress {\\n appearance: none;\\n -moz-appearance: none;\\n -webkit-appearance: none;\\n border: none;\\n height: 20px;\\n background-color: whiteSmoke;\\n border-radius: 3px;\\n box-shadow: 0 2px 3px rgba(0,0,0,.5) inset;\\n color: royalblue;\\n position: relative;\\n margin: 0 0 1.5em;\\n}\\n\\nprogress[value]::-webkit-progress-bar {\\n background-color: whiteSmoke;\\n border-radius: 3px;\\n box-shadow: 0 2px 3px rgba(0,0,0,.5) inset;\\n}\\n\\nprogress[value]::-webkit-progress-value {\\n position: relative;\\n background-size: 35px 20px, 100% 100%, 100% 100%;\\n border-radius:3px;\\n}\\n\\nprogress.active:not([value])::before {\\n background-position: 10%;\\n animation-name: stripes;\\n animation-duration: 3s;\\n animation-timing-function: linear;\\n animation-iteration-count: infinite;\\n}\\n\\nprogress[value]::-moz-progress-bar {\\n background-size: 35px 20px, 100% 100%, 100% 100%;\\n border-radius:3px;\\n}\\n\\nprogress:not([value])::-moz-progress-bar {\\n border-radius:3px;\\n background: linear-gradient(-45deg, transparent 33%, rgba(0, 0, 0, 0.2) 33%, rgba(0, 0, 0, 0.2) 66%, transparent 66%) left/2.5em 1.5em;\\n}\\n\\nprogress.active:not([value])::-moz-progress-bar {\\n background-position: 10%;\\n animation-name: stripes;\\n animation-duration: 3s;\\n animation-timing-function: linear;\\n animation-iteration-count: infinite;\\n}\\n\\nprogress.active:not([value])::-webkit-progress-bar {\\n background-position: 10%;\\n animation-name: stripes;\\n animation-duration: 3s;\\n animation-timing-function: linear;\\n animation-iteration-count: infinite;\\n}\\n\\nprogress.primary[value]::-webkit-progress-value { background-color: #007bff; }\\nprogress.primary:not([value])::before { background-color: #007bff; }\\nprogress.primary:not([value])::-webkit-progress-bar { background-color: #007bff; }\\nprogress.primary::-moz-progress-bar { background-color: #007bff; }\\n\\nprogress.secondary[value]::-webkit-progress-value { background-color: #6c757d; }\\nprogress.secondary:not([value])::before { background-color: #6c757d; }\\nprogress.secondary:not([value])::-webkit-progress-bar { background-color: #6c757d; }\\nprogress.secondary::-moz-progress-bar { background-color: #6c757d; }\\n\\nprogress.success[value]::-webkit-progress-value { background-color: #28a745; }\\nprogress.success:not([value])::before { background-color: #28a745; }\\nprogress.success:not([value])::-webkit-progress-bar { background-color: #28a745; }\\nprogress.success::-moz-progress-bar { background-color: #28a745; }\\n\\nprogress.danger[value]::-webkit-progress-value { background-color: #dc3545; }\\nprogress.danger:not([value])::before { background-color: #dc3545; }\\nprogress.danger:not([value])::-webkit-progress-bar { background-color: #dc3545; }\\nprogress.danger::-moz-progress-bar { background-color: #dc3545; }\\n\\nprogress.warning[value]::-webkit-progress-value { background-color: #ffc107; }\\nprogress.warning:not([value])::before { background-color: #ffc107; }\\nprogress.warning:not([value])::-webkit-progress-bar { background-color: #ffc107; }\\nprogress.warning::-moz-progress-bar { background-color: #ffc107; }\\n\\nprogress.info[value]::-webkit-progress-value { background-color: #17a2b8; }\\nprogress.info:not([value])::before { background-color: #17a2b8; }\\nprogress.info:not([value])::-webkit-progress-bar { background-color: #17a2b8; }\\nprogress.info::-moz-progress-bar { background-color: #17a2b8; }\\n\\nprogress.light[value]::-webkit-progress-value { background-color: #f8f9fa; }\\nprogress.light:not([value])::before { background-color: #f8f9fa; }\\nprogress.light:not([value])::-webkit-progress-bar { background-color: #f8f9fa; }\\nprogress.light::-moz-progress-bar { background-color: #f8f9fa; }\\n\\nprogress.dark[value]::-webkit-progress-value { background-color: #343a40; }\\nprogress.dark:not([value])::-webkit-progress-bar { background-color: #343a40; }\\nprogress.dark:not([value])::before { background-color: #343a40; }\\nprogress.dark::-moz-progress-bar { background-color: #343a40; }\\n\\nprogress:not([value])::-webkit-progress-bar {\\n border-radius: 3px;\\n background: linear-gradient(-45deg, transparent 33%, rgba(0, 0, 0, 0.2) 33%, rgba(0, 0, 0, 0.2) 66%, transparent 66%) left/2.5em 1.5em;\\n}\\nprogress:not([value])::before {\\n content:\\\" \\\";\\n position:absolute;\\n height: 20px;\\n top:0;\\n left:0;\\n right:0;\\n bottom:0;\\n border-radius: 3px;\\n background: linear-gradient(-45deg, transparent 33%, rgba(0, 0, 0, 0.2) 33%, rgba(0, 0, 0, 0.2) 66%, transparent 66%) left/2.5em 1.5em;\\n}\\n\\n@keyframes stripes {\\n from {background-position: 0%}\\n to {background-position: 100%}\\n}\\n\\n.bk-root .bk.loader {\\n overflow: hidden;\\n}\\n\\n.bk.loader::after {\\n content: \\\"\\\";\\n border-radius: 50%;\\n -webkit-mask-image: radial-gradient(transparent 50%, rgba(0, 0, 0, 1) 54%);\\n width: 100%;\\n height: 100%;\\n left: 0;\\n top: 0;\\n position: absolute;\\n}\\n\\n.bk-root .bk.loader.dark::after {\\n background: #0f0f0f;\\n}\\n\\n.bk-root .bk.loader.light::after {\\n background: #f0f0f0;\\n}\\n\\n.bk-root .bk.loader.spin::after {\\n animation: spin 2s linear infinite;\\n}\\n\\n.bk-root div.bk.loader.spin.primary-light::after {\\n background: linear-gradient(135deg, #f0f0f0 50%, transparent 50%), linear-gradient(45deg, #f0f0f0 50%, #007bff 50%);\\n}\\n\\n.bk-root div.bk.loader.spin.secondary-light::after {\\n background: linear-gradient(135deg, #f0f0f0 50%, transparent 50%), linear-gradient(45deg, #f0f0f0 50%, #6c757d 50%);\\n}\\n\\n.bk-root div.bk.loader.spin.success-light::after {\\n background: linear-gradient(135deg, #f0f0f0 50%, transparent 50%), linear-gradient(45deg, #f0f0f0 50%, #28a745 50%);\\n}\\n\\n.bk-root div.bk.loader.spin.danger-light::after {\\n background: linear-gradient(135deg, #f0f0f0 50%, transparent 50%), linear-gradient(45deg, #f0f0f0 50%, #dc3545 50%);\\n}\\n\\n.bk-root div.bk.loader.spin.warning-light::after {\\n background: linear-gradient(135deg, #f0f0f0 50%, transparent 50%), linear-gradient(45deg, #f0f0f0 50%, #ffc107 50%);\\n}\\n\\n.bk-root div.bk.loader.spin.info-light::after {\\n background: linear-gradient(135deg, #f0f0f0 50%, transparent 50%), linear-gradient(45deg, #f0f0f0 50%, #17a2b8 50%);\\n}\\n\\n.bk-root div.bk.loader.spin.light-light::after {\\n background: linear-gradient(135deg, #f0f0f0 50%, transparent 50%), linear-gradient(45deg, #f0f0f0 50%, #f8f9fa 50%);\\n}\\n\\n.bk-root div.bk.loader.dark-light::after {\\n background: linear-gradient(135deg, #f0f0f0 50%, transparent 50%), linear-gradient(45deg, #f0f0f0 50%, #343a40 50%);\\n}\\n\\n.bk-root div.bk.loader.spin.primary-dark::after {\\n background: linear-gradient(135deg, #0f0f0f 50%, transparent 50%), linear-gradient(45deg, #0f0f0f 50%, #007bff 50%);\\n}\\n\\n.bk-root div.bk.loader.spin.secondary-dark::after {\\n background: linear-gradient(135deg, #0f0f0f 50%, transparent 50%), linear-gradient(45deg, #0f0f0f 50%, #6c757d 50%);\\n}\\n\\n.bk-root div.bk.loader.spin.success-dark::after {\\n background: linear-gradient(135deg, #0f0f0f 50%, transparent 50%), linear-gradient(45deg, #0f0f0f 50%, #28a745 50%);\\n}\\n\\n.bk-root div.bk.loader.spin.danger-dark::after {\\n background: linear-gradient(135deg, #0f0f0f 50%, transparent 50%), linear-gradient(45deg, #0f0f0f 50%, #dc3545 50%)\\n}\\n\\n.bk-root div.bk.loader.spin.warning-dark::after {\\n background: linear-gradient(135deg, #0f0f0f 50%, transparent 50%), linear-gradient(45deg, #0f0f0f 50%, #ffc107 50%);\\n}\\n\\n.bk-root div.bk.loader.spin.info-dark::after {\\n background: linear-gradient(135deg, #0f0f0f 50%, transparent 50%), linear-gradient(45deg, #0f0f0f 50%, #17a2b8 50%);\\n}\\n\\n.bk-root div.bk.loader.spin.light-dark::after {\\n background: linear-gradient(135deg, #0f0f0f 50%, transparent 50%), linear-gradient(45deg, #0f0f0f 50%, #f8f9fa 50%);\\n}\\n\\n.bk-root div.bk.loader.spin.dark-dark::after {\\n background: linear-gradient(135deg, #0f0f0f 50%, transparent 50%), linear-gradient(45deg, #0f0f0f 50%, #343a40 50%);\\n}\\n\\n/* Safari */\\n@-webkit-keyframes spin {\\n 0% { -webkit-transform: rotate(0deg); }\\n 100% { -webkit-transform: rotate(360deg); }\\n}\\n\\n@keyframes spin {\\n 0% { transform: rotate(0deg); }\\n 100% { transform: rotate(360deg); }\\n}\\n\\n.dot div {\\n height: 100%;\\n width: 100%;\\n border: 1px solid #000 !important;\\n background-color: #fff;\\n border-radius: 50%;\\n display: inline-block;\\n}\\n\\n.dot-filled div {\\n height: 100%;\\n width: 100%;\\n border: 1px solid #000 !important;\\n border-radius: 50%;\\n display: inline-block;\\n}\\n\\n.dot-filled.primary div {\\n background-color: #007bff;\\n}\\n\\n.dot-filled.secondary div {\\n background-color: #6c757d;\\n}\\n\\n.dot-filled.success div {\\n background-color: #28a745;\\n}\\n\\n.dot-filled.danger div {\\n background-color: #dc3545;\\n}\\n\\n.dot-filled.warning div {\\n background-color: #ffc107;\\n}\\n\\n.dot-filled.info div {\\n background-color: #17a2b8;\\n}\\n\\n.dot-filled.dark div {\\n background-color: #343a40;\\n}\\n\\n.dot-filled.light div {\\n background-color: #f8f9fa;\\n}\\n\\n/* Slider editor */\\n.slider-edit .bk-input-group .bk-input {\\n border: 0;\\n border-radius: 0;\\n min-height: 0;\\n padding-left: 0;\\n padding-right: 0;\\n font-weight: bold;\\n}\\n\\n.slider-edit .bk-input-group .bk-spin-wrapper {\\n display: contents;\\n}\\n\\n.slider-edit .bk-input-group .bk-spin-wrapper .bk.bk-spin-btn-up {\\n top: -6px;\\n}\\n\\n.slider-edit .bk-input-group .bk-spin-wrapper .bk.bk-spin-btn-down {\\n bottom: 3px;\\n}\\n\\n/* JSON Pane */\\n.bk-root .json-formatter-row .json-formatter-string, .bk-root .json-formatter-row .json-formatter-stringifiable {\\n white-space: pre-wrap;\\n}\\n\\n.ql-bubble .ql-editor {\\n border: 1px solid #ccc;\\n}\\n\");\n", + " }, function(Bokeh) {\n", + " inject_raw_css(\".codehilite .hll { background-color: #ffffcc }\\n.codehilite { background: #f8f8f8; }\\n.codehilite .c { color: #408080; font-style: italic } /* Comment */\\n.codehilite .err { border: 1px solid #FF0000 } /* Error */\\n.codehilite .k { color: #008000; font-weight: bold } /* Keyword */\\n.codehilite .o { color: #666666 } /* Operator */\\n.codehilite .ch { color: #408080; font-style: italic } /* Comment.Hashbang */\\n.codehilite .cm { color: #408080; font-style: italic } /* Comment.Multiline */\\n.codehilite .cp { color: #BC7A00 } /* Comment.Preproc */\\n.codehilite .cpf { color: #408080; font-style: italic } /* Comment.PreprocFile */\\n.codehilite .c1 { color: #408080; font-style: italic } /* Comment.Single */\\n.codehilite .cs { color: #408080; font-style: italic } /* Comment.Special */\\n.codehilite .gd { color: #A00000 } /* Generic.Deleted */\\n.codehilite .ge { font-style: italic } /* Generic.Emph */\\n.codehilite .gr { color: #FF0000 } /* Generic.Error */\\n.codehilite .gh { color: #000080; font-weight: bold } /* Generic.Heading */\\n.codehilite .gi { color: #00A000 } /* Generic.Inserted */\\n.codehilite .go { color: #888888 } /* Generic.Output */\\n.codehilite .gp { color: #000080; font-weight: bold } /* Generic.Prompt */\\n.codehilite .gs { font-weight: bold } /* Generic.Strong */\\n.codehilite .gu { color: #800080; font-weight: bold } /* Generic.Subheading */\\n.codehilite .gt { color: #0044DD } /* Generic.Traceback */\\n.codehilite .kc { color: #008000; font-weight: bold } /* Keyword.Constant */\\n.codehilite .kd { color: #008000; font-weight: bold } /* Keyword.Declaration */\\n.codehilite .kn { color: #008000; font-weight: bold } /* Keyword.Namespace */\\n.codehilite .kp { color: #008000 } /* Keyword.Pseudo */\\n.codehilite .kr { color: #008000; font-weight: bold } /* Keyword.Reserved */\\n.codehilite .kt { color: #B00040 } /* Keyword.Type */\\n.codehilite .m { color: #666666 } /* Literal.Number */\\n.codehilite .s { color: #BA2121 } /* Literal.String */\\n.codehilite .na { color: #7D9029 } /* Name.Attribute */\\n.codehilite .nb { color: #008000 } /* Name.Builtin */\\n.codehilite .nc { color: #0000FF; font-weight: bold } /* Name.Class */\\n.codehilite .no { color: #880000 } /* Name.Constant */\\n.codehilite .nd { color: #AA22FF } /* Name.Decorator */\\n.codehilite .ni { color: #999999; font-weight: bold } /* Name.Entity */\\n.codehilite .ne { color: #D2413A; font-weight: bold } /* Name.Exception */\\n.codehilite .nf { color: #0000FF } /* Name.Function */\\n.codehilite .nl { color: #A0A000 } /* Name.Label */\\n.codehilite .nn { color: #0000FF; font-weight: bold } /* Name.Namespace */\\n.codehilite .nt { color: #008000; font-weight: bold } /* Name.Tag */\\n.codehilite .nv { color: #19177C } /* Name.Variable */\\n.codehilite .ow { color: #AA22FF; font-weight: bold } /* Operator.Word */\\n.codehilite .w { color: #bbbbbb } /* Text.Whitespace */\\n.codehilite .mb { color: #666666 } /* Literal.Number.Bin */\\n.codehilite .mf { color: #666666 } /* Literal.Number.Float */\\n.codehilite .mh { color: #666666 } /* Literal.Number.Hex */\\n.codehilite .mi { color: #666666 } /* Literal.Number.Integer */\\n.codehilite .mo { color: #666666 } /* Literal.Number.Oct */\\n.codehilite .sa { color: #BA2121 } /* Literal.String.Affix */\\n.codehilite .sb { color: #BA2121 } /* Literal.String.Backtick */\\n.codehilite .sc { color: #BA2121 } /* Literal.String.Char */\\n.codehilite .dl { color: #BA2121 } /* Literal.String.Delimiter */\\n.codehilite .sd { color: #BA2121; font-style: italic } /* Literal.String.Doc */\\n.codehilite .s2 { color: #BA2121 } /* Literal.String.Double */\\n.codehilite .se { color: #BB6622; font-weight: bold } /* Literal.String.Escape */\\n.codehilite .sh { color: #BA2121 } /* Literal.String.Heredoc */\\n.codehilite .si { color: #BB6688; font-weight: bold } /* Literal.String.Interpol */\\n.codehilite .sx { color: #008000 } /* Literal.String.Other */\\n.codehilite .sr { color: #BB6688 } /* Literal.String.Regex */\\n.codehilite .s1 { color: #BA2121 } /* Literal.String.Single */\\n.codehilite .ss { color: #19177C } /* Literal.String.Symbol */\\n.codehilite .bp { color: #008000 } /* Name.Builtin.Pseudo */\\n.codehilite .fm { color: #0000FF } /* Name.Function.Magic */\\n.codehilite .vc { color: #19177C } /* Name.Variable.Class */\\n.codehilite .vg { color: #19177C } /* Name.Variable.Global */\\n.codehilite .vi { color: #19177C } /* Name.Variable.Instance */\\n.codehilite .vm { color: #19177C } /* Name.Variable.Magic */\\n.codehilite .il { color: #666666 } /* Literal.Number.Integer.Long */\\n\\n.markdown h1 { margin-block-start: 0.34em }\\n.markdown h2 { margin-block-start: 0.42em }\\n.markdown h3 { margin-block-start: 0.5em }\\n.markdown h4 { margin-block-start: 0.67em }\\n.markdown h5 { margin-block-start: 0.84em }\\n.markdown h6 { margin-block-start: 1.17em }\\n.markdown ul { padding-inline-start: 2em }\\n.markdown ol { padding-inline-start: 2em }\\n.markdown strong { font-weight: 600 }\\n.markdown a { color: -webkit-link }\\n.markdown a { color: -moz-hyperlinkText }\\n\\n.markdown .codehilite {\\n padding: 1rem 1.25rem;\\n margin-top: 1rem;\\n margin-bottom: 1rem;\\n border-radius: 0.25rem;\\n}\\n\");\n", + " }, function(Bokeh) {\n", " inject_raw_css(\".json-formatter-row {\\n font-family: monospace;\\n}\\n.json-formatter-row,\\n.json-formatter-row a,\\n.json-formatter-row a:hover {\\n color: black;\\n text-decoration: none;\\n}\\n.json-formatter-row .json-formatter-row {\\n margin-left: 1rem;\\n}\\n.json-formatter-row .json-formatter-children.json-formatter-empty {\\n opacity: 0.5;\\n margin-left: 1rem;\\n}\\n.json-formatter-row .json-formatter-children.json-formatter-empty:after {\\n display: none;\\n}\\n.json-formatter-row .json-formatter-children.json-formatter-empty.json-formatter-object:after {\\n content: \\\"No properties\\\";\\n}\\n.json-formatter-row .json-formatter-children.json-formatter-empty.json-formatter-array:after {\\n content: \\\"[]\\\";\\n}\\n.json-formatter-row .json-formatter-string,\\n.json-formatter-row .json-formatter-stringifiable {\\n color: green;\\n white-space: pre;\\n word-wrap: break-word;\\n}\\n.json-formatter-row .json-formatter-number {\\n color: blue;\\n}\\n.json-formatter-row .json-formatter-boolean {\\n color: red;\\n}\\n.json-formatter-row .json-formatter-null {\\n color: #855A00;\\n}\\n.json-formatter-row .json-formatter-undefined {\\n color: #ca0b69;\\n}\\n.json-formatter-row .json-formatter-function {\\n color: #FF20ED;\\n}\\n.json-formatter-row .json-formatter-date {\\n background-color: rgba(0, 0, 0, 0.05);\\n}\\n.json-formatter-row .json-formatter-url {\\n text-decoration: underline;\\n color: blue;\\n cursor: pointer;\\n}\\n.json-formatter-row .json-formatter-bracket {\\n color: blue;\\n}\\n.json-formatter-row .json-formatter-key {\\n color: #00008B;\\n padding-right: 0.2rem;\\n}\\n.json-formatter-row .json-formatter-toggler-link {\\n cursor: pointer;\\n}\\n.json-formatter-row .json-formatter-toggler {\\n line-height: 1.2rem;\\n font-size: 0.7rem;\\n vertical-align: middle;\\n opacity: 0.6;\\n cursor: pointer;\\n padding-right: 0.2rem;\\n}\\n.json-formatter-row .json-formatter-toggler:after {\\n display: inline-block;\\n transition: transform 100ms ease-in;\\n content: \\\"\\\\25BA\\\";\\n}\\n.json-formatter-row > a > .json-formatter-preview-text {\\n opacity: 0;\\n transition: opacity 0.15s ease-in;\\n font-style: italic;\\n}\\n.json-formatter-row:hover > a > .json-formatter-preview-text {\\n opacity: 0.6;\\n}\\n.json-formatter-row.json-formatter-open > .json-formatter-toggler-link .json-formatter-toggler:after {\\n transform: rotate(90deg);\\n}\\n.json-formatter-row.json-formatter-open > .json-formatter-children:after {\\n display: inline-block;\\n}\\n.json-formatter-row.json-formatter-open > a > .json-formatter-preview-text {\\n display: none;\\n}\\n.json-formatter-row.json-formatter-open.json-formatter-empty:after {\\n display: block;\\n}\\n.json-formatter-dark.json-formatter-row {\\n font-family: monospace;\\n}\\n.json-formatter-dark.json-formatter-row,\\n.json-formatter-dark.json-formatter-row a,\\n.json-formatter-dark.json-formatter-row a:hover {\\n color: white;\\n text-decoration: none;\\n}\\n.json-formatter-dark.json-formatter-row .json-formatter-row {\\n margin-left: 1rem;\\n}\\n.json-formatter-dark.json-formatter-row .json-formatter-children.json-formatter-empty {\\n opacity: 0.5;\\n margin-left: 1rem;\\n}\\n.json-formatter-dark.json-formatter-row .json-formatter-children.json-formatter-empty:after {\\n display: none;\\n}\\n.json-formatter-dark.json-formatter-row .json-formatter-children.json-formatter-empty.json-formatter-object:after {\\n content: \\\"No properties\\\";\\n}\\n.json-formatter-dark.json-formatter-row .json-formatter-children.json-formatter-empty.json-formatter-array:after {\\n content: \\\"[]\\\";\\n}\\n.json-formatter-dark.json-formatter-row .json-formatter-string,\\n.json-formatter-dark.json-formatter-row .json-formatter-stringifiable {\\n color: #31F031;\\n white-space: pre;\\n word-wrap: break-word;\\n}\\n.json-formatter-dark.json-formatter-row .json-formatter-number {\\n color: #66C2FF;\\n}\\n.json-formatter-dark.json-formatter-row .json-formatter-boolean {\\n color: #EC4242;\\n}\\n.json-formatter-dark.json-formatter-row .json-formatter-null {\\n color: #EEC97D;\\n}\\n.json-formatter-dark.json-formatter-row .json-formatter-undefined {\\n color: #ef8fbe;\\n}\\n.json-formatter-dark.json-formatter-row .json-formatter-function {\\n color: #FD48CB;\\n}\\n.json-formatter-dark.json-formatter-row .json-formatter-date {\\n background-color: rgba(255, 255, 255, 0.05);\\n}\\n.json-formatter-dark.json-formatter-row .json-formatter-url {\\n text-decoration: underline;\\n color: #027BFF;\\n cursor: pointer;\\n}\\n.json-formatter-dark.json-formatter-row .json-formatter-bracket {\\n color: #9494FF;\\n}\\n.json-formatter-dark.json-formatter-row .json-formatter-key {\\n color: #23A0DB;\\n padding-right: 0.2rem;\\n}\\n.json-formatter-dark.json-formatter-row .json-formatter-toggler-link {\\n cursor: pointer;\\n}\\n.json-formatter-dark.json-formatter-row .json-formatter-toggler {\\n line-height: 1.2rem;\\n font-size: 0.7rem;\\n vertical-align: middle;\\n opacity: 0.6;\\n cursor: pointer;\\n padding-right: 0.2rem;\\n}\\n.json-formatter-dark.json-formatter-row .json-formatter-toggler:after {\\n display: inline-block;\\n transition: transform 100ms ease-in;\\n content: \\\"\\\\25BA\\\";\\n}\\n.json-formatter-dark.json-formatter-row > a > .json-formatter-preview-text {\\n opacity: 0;\\n transition: opacity 0.15s ease-in;\\n font-style: italic;\\n}\\n.json-formatter-dark.json-formatter-row:hover > a > .json-formatter-preview-text {\\n opacity: 0.6;\\n}\\n.json-formatter-dark.json-formatter-row.json-formatter-open > .json-formatter-toggler-link .json-formatter-toggler:after {\\n transform: rotate(90deg);\\n}\\n.json-formatter-dark.json-formatter-row.json-formatter-open > .json-formatter-children:after {\\n display: inline-block;\\n}\\n.json-formatter-dark.json-formatter-row.json-formatter-open > a > .json-formatter-preview-text {\\n display: none;\\n}\\n.json-formatter-dark.json-formatter-row.json-formatter-open.json-formatter-empty:after {\\n display: block;\\n}\\n\");\n", - " },\n", - " function(Bokeh) {\n", - " inject_raw_css(\".bk.pn-loading:before {\\n position: absolute;\\n height: 100%;\\n width: 100%;\\n content: '';\\n z-index: 1000;\\n background-color: rgb(255,255,255,0.50);\\n border-color: lightgray;\\n background-repeat: no-repeat;\\n background-position: center;\\n background-size: auto 50%;\\n border-width: 1px;\\n cursor: progress;\\n}\\n.bk.pn-loading.arcs:hover:before {\\n cursor: progress;\\n}\\n\");\n", - " },\n", - " function(Bokeh) {\n", - " inject_raw_css(\".codehilite .hll { background-color: #ffffcc }\\n.codehilite { background: #f8f8f8; }\\n.codehilite .c { color: #408080; font-style: italic } /* Comment */\\n.codehilite .err { border: 1px solid #FF0000 } /* Error */\\n.codehilite .k { color: #008000; font-weight: bold } /* Keyword */\\n.codehilite .o { color: #666666 } /* Operator */\\n.codehilite .ch { color: #408080; font-style: italic } /* Comment.Hashbang */\\n.codehilite .cm { color: #408080; font-style: italic } /* Comment.Multiline */\\n.codehilite .cp { color: #BC7A00 } /* Comment.Preproc */\\n.codehilite .cpf { color: #408080; font-style: italic } /* Comment.PreprocFile */\\n.codehilite .c1 { color: #408080; font-style: italic } /* Comment.Single */\\n.codehilite .cs { color: #408080; font-style: italic } /* Comment.Special */\\n.codehilite .gd { color: #A00000 } /* Generic.Deleted */\\n.codehilite .ge { font-style: italic } /* Generic.Emph */\\n.codehilite .gr { color: #FF0000 } /* Generic.Error */\\n.codehilite .gh { color: #000080; font-weight: bold } /* Generic.Heading */\\n.codehilite .gi { color: #00A000 } /* Generic.Inserted */\\n.codehilite .go { color: #888888 } /* Generic.Output */\\n.codehilite .gp { color: #000080; font-weight: bold } /* Generic.Prompt */\\n.codehilite .gs { font-weight: bold } /* Generic.Strong */\\n.codehilite .gu { color: #800080; font-weight: bold } /* Generic.Subheading */\\n.codehilite .gt { color: #0044DD } /* Generic.Traceback */\\n.codehilite .kc { color: #008000; font-weight: bold } /* Keyword.Constant */\\n.codehilite .kd { color: #008000; font-weight: bold } /* Keyword.Declaration */\\n.codehilite .kn { color: #008000; font-weight: bold } /* Keyword.Namespace */\\n.codehilite .kp { color: #008000 } /* Keyword.Pseudo */\\n.codehilite .kr { color: #008000; font-weight: bold } /* Keyword.Reserved */\\n.codehilite .kt { color: #B00040 } /* Keyword.Type */\\n.codehilite .m { color: #666666 } /* Literal.Number */\\n.codehilite .s { color: #BA2121 } /* Literal.String */\\n.codehilite .na { color: #7D9029 } /* Name.Attribute */\\n.codehilite .nb { color: #008000 } /* Name.Builtin */\\n.codehilite .nc { color: #0000FF; font-weight: bold } /* Name.Class */\\n.codehilite .no { color: #880000 } /* Name.Constant */\\n.codehilite .nd { color: #AA22FF } /* Name.Decorator */\\n.codehilite .ni { color: #999999; font-weight: bold } /* Name.Entity */\\n.codehilite .ne { color: #D2413A; font-weight: bold } /* Name.Exception */\\n.codehilite .nf { color: #0000FF } /* Name.Function */\\n.codehilite .nl { color: #A0A000 } /* Name.Label */\\n.codehilite .nn { color: #0000FF; font-weight: bold } /* Name.Namespace */\\n.codehilite .nt { color: #008000; font-weight: bold } /* Name.Tag */\\n.codehilite .nv { color: #19177C } /* Name.Variable */\\n.codehilite .ow { color: #AA22FF; font-weight: bold } /* Operator.Word */\\n.codehilite .w { color: #bbbbbb } /* Text.Whitespace */\\n.codehilite .mb { color: #666666 } /* Literal.Number.Bin */\\n.codehilite .mf { color: #666666 } /* Literal.Number.Float */\\n.codehilite .mh { color: #666666 } /* Literal.Number.Hex */\\n.codehilite .mi { color: #666666 } /* Literal.Number.Integer */\\n.codehilite .mo { color: #666666 } /* Literal.Number.Oct */\\n.codehilite .sa { color: #BA2121 } /* Literal.String.Affix */\\n.codehilite .sb { color: #BA2121 } /* Literal.String.Backtick */\\n.codehilite .sc { color: #BA2121 } /* Literal.String.Char */\\n.codehilite .dl { color: #BA2121 } /* Literal.String.Delimiter */\\n.codehilite .sd { color: #BA2121; font-style: italic } /* Literal.String.Doc */\\n.codehilite .s2 { color: #BA2121 } /* Literal.String.Double */\\n.codehilite .se { color: #BB6622; font-weight: bold } /* Literal.String.Escape */\\n.codehilite .sh { color: #BA2121 } /* Literal.String.Heredoc */\\n.codehilite .si { color: #BB6688; font-weight: bold } /* Literal.String.Interpol */\\n.codehilite .sx { color: #008000 } /* Literal.String.Other */\\n.codehilite .sr { color: #BB6688 } /* Literal.String.Regex */\\n.codehilite .s1 { color: #BA2121 } /* Literal.String.Single */\\n.codehilite .ss { color: #19177C } /* Literal.String.Symbol */\\n.codehilite .bp { color: #008000 } /* Name.Builtin.Pseudo */\\n.codehilite .fm { color: #0000FF } /* Name.Function.Magic */\\n.codehilite .vc { color: #19177C } /* Name.Variable.Class */\\n.codehilite .vg { color: #19177C } /* Name.Variable.Global */\\n.codehilite .vi { color: #19177C } /* Name.Variable.Instance */\\n.codehilite .vm { color: #19177C } /* Name.Variable.Magic */\\n.codehilite .il { color: #666666 } /* Literal.Number.Integer.Long */\\n\\n.markdown h1 { margin-block-start: 0.34em }\\n.markdown h2 { margin-block-start: 0.42em }\\n.markdown h3 { margin-block-start: 0.5em }\\n.markdown h4 { margin-block-start: 0.67em }\\n.markdown h5 { margin-block-start: 0.84em }\\n.markdown h6 { margin-block-start: 1.17em }\\n.markdown ul { padding-inline-start: 2em }\\n.markdown ol { padding-inline-start: 2em }\\n.markdown strong { font-weight: 600 }\\n.markdown a { color: -webkit-link }\\n.markdown a { color: -moz-hyperlinkText }\\n\");\n", - " },\n", - " function(Bokeh) {\n", - " inject_raw_css(\".bk.panel-widget-box {\\n min-height: 20px;\\n background-color: #f5f5f5;\\n border: 1px solid #e3e3e3;\\n border-radius: 4px;\\n -webkit-box-shadow: inset 0 1px 1px rgba(0,0,0,.05);\\n box-shadow: inset 0 1px 1px rgba(0,0,0,.05);\\n overflow-x: hidden;\\n overflow-y: hidden;\\n}\\n\\n.scrollable {\\n overflow: scroll;\\n}\\n\\nprogress {\\n appearance: none;\\n -moz-appearance: none;\\n -webkit-appearance: none;\\n border: none;\\n height: 20px;\\n background-color: whiteSmoke;\\n border-radius: 3px;\\n box-shadow: 0 2px 3px rgba(0,0,0,.5) inset;\\n color: royalblue;\\n position: relative;\\n margin: 0 0 1.5em;\\n}\\n\\nprogress[value]::-webkit-progress-bar {\\n background-color: whiteSmoke;\\n border-radius: 3px;\\n box-shadow: 0 2px 3px rgba(0,0,0,.5) inset;\\n}\\n\\nprogress[value]::-webkit-progress-value {\\n position: relative;\\n background-size: 35px 20px, 100% 100%, 100% 100%;\\n border-radius:3px;\\n}\\n\\nprogress.active:not([value])::before {\\n background-position: 10%;\\n animation-name: stripes;\\n animation-duration: 3s;\\n animation-timing-function: linear;\\n animation-iteration-count: infinite;\\n}\\n\\nprogress[value]::-moz-progress-bar {\\n background-size: 35px 20px, 100% 100%, 100% 100%;\\n border-radius:3px;\\n}\\n\\nprogress:not([value])::-moz-progress-bar {\\n border-radius:3px;\\n background: linear-gradient(-45deg, transparent 33%, rgba(0, 0, 0, 0.2) 33%, rgba(0, 0, 0, 0.2) 66%, transparent 66%) left/2.5em 1.5em;\\n}\\n\\nprogress.active:not([value])::-moz-progress-bar {\\n background-position: 10%;\\n animation-name: stripes;\\n animation-duration: 3s;\\n animation-timing-function: linear;\\n animation-iteration-count: infinite;\\n}\\n\\nprogress.active:not([value])::-webkit-progress-bar {\\n background-position: 10%;\\n animation-name: stripes;\\n animation-duration: 3s;\\n animation-timing-function: linear;\\n animation-iteration-count: infinite;\\n}\\n\\nprogress.primary[value]::-webkit-progress-value { background-color: #007bff; }\\nprogress.primary:not([value])::before { background-color: #007bff; }\\nprogress.primary:not([value])::-webkit-progress-bar { background-color: #007bff; }\\nprogress.primary::-moz-progress-bar { background-color: #007bff; }\\n\\nprogress.secondary[value]::-webkit-progress-value { background-color: #6c757d; }\\nprogress.secondary:not([value])::before { background-color: #6c757d; }\\nprogress.secondary:not([value])::-webkit-progress-bar { background-color: #6c757d; }\\nprogress.secondary::-moz-progress-bar { background-color: #6c757d; }\\n\\nprogress.success[value]::-webkit-progress-value { background-color: #28a745; }\\nprogress.success:not([value])::before { background-color: #28a745; }\\nprogress.success:not([value])::-webkit-progress-bar { background-color: #28a745; }\\nprogress.success::-moz-progress-bar { background-color: #28a745; }\\n\\nprogress.danger[value]::-webkit-progress-value { background-color: #dc3545; }\\nprogress.danger:not([value])::before { background-color: #dc3545; }\\nprogress.danger:not([value])::-webkit-progress-bar { background-color: #dc3545; }\\nprogress.danger::-moz-progress-bar { background-color: #dc3545; }\\n\\nprogress.warning[value]::-webkit-progress-value { background-color: #ffc107; }\\nprogress.warning:not([value])::before { background-color: #ffc107; }\\nprogress.warning:not([value])::-webkit-progress-bar { background-color: #ffc107; }\\nprogress.warning::-moz-progress-bar { background-color: #ffc107; }\\n\\nprogress.info[value]::-webkit-progress-value { background-color: #17a2b8; }\\nprogress.info:not([value])::before { background-color: #17a2b8; }\\nprogress.info:not([value])::-webkit-progress-bar { background-color: #17a2b8; }\\nprogress.info::-moz-progress-bar { background-color: #17a2b8; }\\n\\nprogress.light[value]::-webkit-progress-value { background-color: #f8f9fa; }\\nprogress.light:not([value])::before { background-color: #f8f9fa; }\\nprogress.light:not([value])::-webkit-progress-bar { background-color: #f8f9fa; }\\nprogress.light::-moz-progress-bar { background-color: #f8f9fa; }\\n\\nprogress.dark[value]::-webkit-progress-value { background-color: #343a40; }\\nprogress.dark:not([value])::-webkit-progress-bar { background-color: #343a40; }\\nprogress.dark:not([value])::before { background-color: #343a40; }\\nprogress.dark::-moz-progress-bar { background-color: #343a40; }\\n\\nprogress:not([value])::-webkit-progress-bar {\\n border-radius: 3px;\\n background: linear-gradient(-45deg, transparent 33%, rgba(0, 0, 0, 0.2) 33%, rgba(0, 0, 0, 0.2) 66%, transparent 66%) left/2.5em 1.5em;\\n}\\nprogress:not([value])::before {\\n content:\\\" \\\";\\n position:absolute;\\n height: 20px;\\n top:0;\\n left:0;\\n right:0;\\n bottom:0;\\n border-radius: 3px;\\n background: linear-gradient(-45deg, transparent 33%, rgba(0, 0, 0, 0.2) 33%, rgba(0, 0, 0, 0.2) 66%, transparent 66%) left/2.5em 1.5em;\\n}\\n\\n@keyframes stripes {\\n from {background-position: 0%}\\n to {background-position: 100%}\\n}\\n\\n.bk-root .bk.loader {\\n overflow: hidden;\\n}\\n\\n.bk.loader::after {\\n content: \\\"\\\";\\n border-radius: 50%;\\n -webkit-mask-image: radial-gradient(transparent 50%, rgba(0, 0, 0, 1) 54%);\\n width: 100%;\\n height: 100%;\\n left: 0;\\n top: 0;\\n position: absolute;\\n}\\n\\n.bk-root .bk.loader.dark::after {\\n background: #0f0f0f;\\n}\\n\\n.bk-root .bk.loader.light::after {\\n background: #f0f0f0;\\n}\\n\\n.bk-root .bk.loader.spin::after {\\n animation: spin 2s linear infinite;\\n}\\n\\n.bk-root div.bk.loader.spin.primary-light::after {\\n background: linear-gradient(135deg, #f0f0f0 50%, transparent 50%), linear-gradient(45deg, #f0f0f0 50%, #007bff 50%);\\n}\\n\\n.bk-root div.bk.loader.spin.secondary-light::after {\\n background: linear-gradient(135deg, #f0f0f0 50%, transparent 50%), linear-gradient(45deg, #f0f0f0 50%, #6c757d 50%);\\n}\\n\\n.bk-root div.bk.loader.spin.success-light::after {\\n background: linear-gradient(135deg, #f0f0f0 50%, transparent 50%), linear-gradient(45deg, #f0f0f0 50%, #28a745 50%);\\n}\\n\\n.bk-root div.bk.loader.spin.danger-light::after {\\n background: linear-gradient(135deg, #f0f0f0 50%, transparent 50%), linear-gradient(45deg, #f0f0f0 50%, #dc3545 50%);\\n}\\n\\n.bk-root div.bk.loader.spin.warning-light::after {\\n background: linear-gradient(135deg, #f0f0f0 50%, transparent 50%), linear-gradient(45deg, #f0f0f0 50%, #ffc107 50%);\\n}\\n\\n.bk-root div.bk.loader.spin.info-light::after {\\n background: linear-gradient(135deg, #f0f0f0 50%, transparent 50%), linear-gradient(45deg, #f0f0f0 50%, #17a2b8 50%);\\n}\\n\\n.bk-root div.bk.loader.spin.light-light::after {\\n background: linear-gradient(135deg, #f0f0f0 50%, transparent 50%), linear-gradient(45deg, #f0f0f0 50%, #f8f9fa 50%);\\n}\\n\\n.bk-root div.bk.loader.dark-light::after {\\n background: linear-gradient(135deg, #f0f0f0 50%, transparent 50%), linear-gradient(45deg, #f0f0f0 50%, #343a40 50%);\\n}\\n\\n.bk-root div.bk.loader.spin.primary-dark::after {\\n background: linear-gradient(135deg, #0f0f0f 50%, transparent 50%), linear-gradient(45deg, #0f0f0f 50%, #007bff 50%);\\n}\\n\\n.bk-root div.bk.loader.spin.secondary-dark::after {\\n background: linear-gradient(135deg, #0f0f0f 50%, transparent 50%), linear-gradient(45deg, #0f0f0f 50%, #6c757d 50%);\\n}\\n\\n.bk-root div.bk.loader.spin.success-dark::after {\\n background: linear-gradient(135deg, #0f0f0f 50%, transparent 50%), linear-gradient(45deg, #0f0f0f 50%, #28a745 50%);\\n}\\n\\n.bk-root div.bk.loader.spin.danger-dark::after {\\n background: linear-gradient(135deg, #0f0f0f 50%, transparent 50%), linear-gradient(45deg, #0f0f0f 50%, #dc3545 50%)\\n}\\n\\n.bk-root div.bk.loader.spin.warning-dark::after {\\n background: linear-gradient(135deg, #0f0f0f 50%, transparent 50%), linear-gradient(45deg, #0f0f0f 50%, #ffc107 50%);\\n}\\n\\n.bk-root div.bk.loader.spin.info-dark::after {\\n background: linear-gradient(135deg, #0f0f0f 50%, transparent 50%), linear-gradient(45deg, #0f0f0f 50%, #17a2b8 50%);\\n}\\n\\n.bk-root div.bk.loader.spin.light-dark::after {\\n background: linear-gradient(135deg, #0f0f0f 50%, transparent 50%), linear-gradient(45deg, #0f0f0f 50%, #f8f9fa 50%);\\n}\\n\\n.bk-root div.bk.loader.spin.dark-dark::after {\\n background: linear-gradient(135deg, #0f0f0f 50%, transparent 50%), linear-gradient(45deg, #0f0f0f 50%, #343a40 50%);\\n}\\n\\n/* Safari */\\n@-webkit-keyframes spin {\\n 0% { -webkit-transform: rotate(0deg); }\\n 100% { -webkit-transform: rotate(360deg); }\\n}\\n\\n@keyframes spin {\\n 0% { transform: rotate(0deg); }\\n 100% { transform: rotate(360deg); }\\n}\\n\\n.dot div {\\n height: 100%;\\n width: 100%;\\n border: 1px solid #000 !important;\\n background-color: #fff;\\n border-radius: 50%;\\n display: inline-block;\\n}\\n\\n.dot-filled div {\\n height: 100%;\\n width: 100%;\\n border: 1px solid #000 !important;\\n border-radius: 50%;\\n display: inline-block;\\n}\\n\\n.dot-filled.primary div {\\n background-color: #007bff;\\n}\\n\\n.dot-filled.secondary div {\\n background-color: #6c757d;\\n}\\n\\n.dot-filled.success div {\\n background-color: #28a745;\\n}\\n\\n.dot-filled.danger div {\\n background-color: #dc3545;\\n}\\n\\n.dot-filled.warning div {\\n background-color: #ffc107;\\n}\\n\\n.dot-filled.info div {\\n background-color: #17a2b8;\\n}\\n\\n.dot-filled.dark div {\\n background-color: #343a40;\\n}\\n\\n.dot-filled.light div {\\n background-color: #f8f9fa;\\n}\\n\\n/* Slider editor */\\n.slider-edit .bk-input-group .bk-input {\\n border: 0;\\n border-radius: 0;\\n min-height: 0;\\n padding-left: 0;\\n padding-right: 0;\\n font-weight: bold;\\n}\\n\\n.slider-edit .bk-input-group .bk-spin-wrapper {\\n display: contents;\\n}\\n\\n.slider-edit .bk-input-group .bk-spin-wrapper .bk.bk-spin-btn-up {\\n top: -6px;\\n}\\n\\n.slider-edit .bk-input-group .bk-spin-wrapper .bk.bk-spin-btn-down {\\n bottom: 3px;\\n}\\n\\n/* JSON Pane */\\n.bk-root .json-formatter-row .json-formatter-string, .bk-root .json-formatter-row .json-formatter-stringifiable {\\n white-space: pre-wrap;\\n}\\n\");\n", - " },\n", - " function(Bokeh) {\n", - " inject_raw_css(\"\\n .bk.pn-loading.arcs:before {\\n background-image: url(\\\"data:image/svg+xml;base64,PHN2ZyB4bWxucz0iaHR0cDovL3d3dy53My5vcmcvMjAwMC9zdmciIHhtbG5zOnhsaW5rPSJodHRwOi8vd3d3LnczLm9yZy8xOTk5L3hsaW5rIiBzdHlsZT0ibWFyZ2luOiBhdXRvOyBiYWNrZ3JvdW5kOiBub25lOyBkaXNwbGF5OiBibG9jazsgc2hhcGUtcmVuZGVyaW5nOiBhdXRvOyIgdmlld0JveD0iMCAwIDEwMCAxMDAiIHByZXNlcnZlQXNwZWN0UmF0aW89InhNaWRZTWlkIj4gIDxjaXJjbGUgY3g9IjUwIiBjeT0iNTAiIHI9IjMyIiBzdHJva2Utd2lkdGg9IjgiIHN0cm9rZT0iI2MzYzNjMyIgc3Ryb2tlLWRhc2hhcnJheT0iNTAuMjY1NDgyNDU3NDM2NjkgNTAuMjY1NDgyNDU3NDM2NjkiIGZpbGw9Im5vbmUiIHN0cm9rZS1saW5lY2FwPSJyb3VuZCI+ICAgIDxhbmltYXRlVHJhbnNmb3JtIGF0dHJpYnV0ZU5hbWU9InRyYW5zZm9ybSIgdHlwZT0icm90YXRlIiByZXBlYXRDb3VudD0iaW5kZWZpbml0ZSIgZHVyPSIxcyIga2V5VGltZXM9IjA7MSIgdmFsdWVzPSIwIDUwIDUwOzM2MCA1MCA1MCI+PC9hbmltYXRlVHJhbnNmb3JtPiAgPC9jaXJjbGU+PC9zdmc+\\\")\\n }\\n \");\n", - " },\n", - " function(Bokeh) {\n", + " }, function(Bokeh) {\n", + " inject_raw_css(\".bk.pn-loading {\\n overflow: hidden;\\n}\\n.bk.pn-loading:before {\\n position: absolute;\\n height: 100%;\\n width: 100%;\\n content: '';\\n z-index: 1000;\\n background-color: rgb(255,255,255,0.50);\\n border-color: lightgray;\\n background-repeat: no-repeat;\\n background-position: center;\\n background-size: auto 50%;\\n border-width: 1px;\\n cursor: progress;\\n}\\n.bk.pn-loading.arcs:hover:before {\\n cursor: progress;\\n}\\n.bk.pn-loading .pn-loading-msg {\\n position: absolute;\\n top: 72%;\\n font-size: 2em;\\n color: black;\\n width: 100%;\\n text-align: center;\\n}\\n\");\n", + " }, function(Bokeh) {\n", + " inject_raw_css(\"table.panel-df {\\n margin-left: auto;\\n margin-right: auto;\\n border: none;\\n border-collapse: collapse;\\n border-spacing: 0;\\n color: black;\\n font-size: 12px;\\n table-layout: fixed;\\n width: 100%;\\n}\\n\\n.panel-df tr, .panel-df th, .panel-df td {\\n text-align: right;\\n vertical-align: middle;\\n padding: 0.5em 0.5em !important;\\n line-height: normal;\\n white-space: normal;\\n max-width: none;\\n border: none;\\n}\\n\\n.panel-df tbody {\\n display: table-row-group;\\n vertical-align: middle;\\n border-color: inherit;\\n}\\n\\n.panel-df tbody tr:nth-child(odd) {\\n background: #f5f5f5;\\n}\\n\\n.panel-df thead {\\n border-bottom: 1px solid black;\\n vertical-align: bottom;\\n}\\n\\n.panel-df tr:hover {\\n background: lightblue !important;\\n cursor: pointer;\\n}\\n\");\n", + " }, function(Bokeh) {\n", + " inject_raw_css(\"\\n .bk.pn-loading.arc:before {\\n background-image: url(\\\"data:image/svg+xml;base64,PHN2ZyB4bWxucz0iaHR0cDovL3d3dy53My5vcmcvMjAwMC9zdmciIHN0eWxlPSJtYXJnaW46IGF1dG87IGJhY2tncm91bmQ6IG5vbmU7IGRpc3BsYXk6IGJsb2NrOyBzaGFwZS1yZW5kZXJpbmc6IGF1dG87IiB2aWV3Qm94PSIwIDAgMTAwIDEwMCIgcHJlc2VydmVBc3BlY3RSYXRpbz0ieE1pZFlNaWQiPiAgPGNpcmNsZSBjeD0iNTAiIGN5PSI1MCIgZmlsbD0ibm9uZSIgc3Ryb2tlPSIjYzNjM2MzIiBzdHJva2Utd2lkdGg9IjEwIiByPSIzNSIgc3Ryb2tlLWRhc2hhcnJheT0iMTY0LjkzMzYxNDMxMzQ2NDE1IDU2Ljk3Nzg3MTQzNzgyMTM4Ij4gICAgPGFuaW1hdGVUcmFuc2Zvcm0gYXR0cmlidXRlTmFtZT0idHJhbnNmb3JtIiB0eXBlPSJyb3RhdGUiIHJlcGVhdENvdW50PSJpbmRlZmluaXRlIiBkdXI9IjFzIiB2YWx1ZXM9IjAgNTAgNTA7MzYwIDUwIDUwIiBrZXlUaW1lcz0iMDsxIj48L2FuaW1hdGVUcmFuc2Zvcm0+ICA8L2NpcmNsZT48L3N2Zz4=\\\");\\n background-size: auto calc(min(50%, 400px));\\n }\\n \");\n", + " }, function(Bokeh) {\n", " /* BEGIN bokeh.min.js */\n", " /*!\n", - " * Copyright (c) 2012 - 2021, Anaconda, Inc., and Bokeh Contributors\n", + " * Copyright (c) 2012 - 2022, Anaconda, Inc., and Bokeh Contributors\n", " * All rights reserved.\n", " * \n", " * Redistribution and use in source and binary forms, with or without modification,\n", @@ -379,10 +398,10 @@ " function _(t,_,n,o,r){o();(0,t(1).__exportStar)(t(2),n)},\n", " function _(t,e,r,n,o){n();var a=function(t,e){return a=Object.setPrototypeOf||{__proto__:[]}instanceof Array&&function(t,e){t.__proto__=e}||function(t,e){for(var r in e)Object.prototype.hasOwnProperty.call(e,r)&&(t[r]=e[r])},a(t,e)};r.__extends=function(t,e){if(\"function\"!=typeof e&&null!==e)throw new TypeError(\"Class extends value \"+String(e)+\" is not a constructor or null\");function r(){this.constructor=t}a(t,e),t.prototype=null===e?Object.create(e):(r.prototype=e.prototype,new r)};function i(t){var e=\"function\"==typeof Symbol&&Symbol.iterator,r=e&&t[e],n=0;if(r)return r.call(t);if(t&&\"number\"==typeof t.length)return{next:function(){return t&&n>=t.length&&(t=void 0),{value:t&&t[n++],done:!t}}};throw new TypeError(e?\"Object is not iterable.\":\"Symbol.iterator is not defined.\")}function c(t,e){var r=\"function\"==typeof Symbol&&t[Symbol.iterator];if(!r)return t;var n,o,a=r.call(t),i=[];try{for(;(void 0===e||e-- >0)&&!(n=a.next()).done;)i.push(n.value)}catch(t){o={error:t}}finally{try{n&&!n.done&&(r=a.return)&&r.call(a)}finally{if(o)throw o.error}}return i}function u(t){return this instanceof u?(this.v=t,this):new u(t)}r.__assign=function(){return r.__assign=Object.assign||function(t){for(var e,r=1,n=arguments.length;r=0;c--)(o=t[c])&&(i=(a<3?o(i):a>3?o(e,r,i):o(e,r))||i);return a>3&&i&&Object.defineProperty(e,r,i),i},r.__param=function(t,e){return function(r,n){e(r,n,t)}},r.__metadata=function(t,e){if(\"object\"==typeof Reflect&&\"function\"==typeof Reflect.metadata)return Reflect.metadata(t,e)},r.__awaiter=function(t,e,r,n){return new(r||(r=Promise))((function(o,a){function i(t){try{u(n.next(t))}catch(t){a(t)}}function c(t){try{u(n.throw(t))}catch(t){a(t)}}function u(t){var e;t.done?o(t.value):(e=t.value,e instanceof r?e:new r((function(t){t(e)}))).then(i,c)}u((n=n.apply(t,e||[])).next())}))},r.__generator=function(t,e){var r,n,o,a,i={label:0,sent:function(){if(1&o[0])throw o[1];return o[1]},trys:[],ops:[]};return a={next:c(0),throw:c(1),return:c(2)},\"function\"==typeof Symbol&&(a[Symbol.iterator]=function(){return this}),a;function c(a){return function(c){return function(a){if(r)throw new TypeError(\"Generator is already executing.\");for(;i;)try{if(r=1,n&&(o=2&a[0]?n.return:a[0]?n.throw||((o=n.return)&&o.call(n),0):n.next)&&!(o=o.call(n,a[1])).done)return o;switch(n=0,o&&(a=[2&a[0],o.value]),a[0]){case 0:case 1:o=a;break;case 4:return i.label++,{value:a[1],done:!1};case 5:i.label++,n=a[1],a=[0];continue;case 7:a=i.ops.pop(),i.trys.pop();continue;default:if(!(o=i.trys,(o=o.length>0&&o[o.length-1])||6!==a[0]&&2!==a[0])){i=0;continue}if(3===a[0]&&(!o||a[1]>o[0]&&a[1]1||c(t,e)}))})}function c(t,e){try{(r=o[t](e)).value instanceof u?Promise.resolve(r.value.v).then(f,l):s(a[0][2],r)}catch(t){s(a[0][3],t)}var r}function f(t){c(\"next\",t)}function l(t){c(\"throw\",t)}function s(t,e){t(e),a.shift(),a.length&&c(a[0][0],a[0][1])}},r.__asyncDelegator=function(t){var e,r;return e={},n(\"next\"),n(\"throw\",(function(t){throw t})),n(\"return\"),e[Symbol.iterator]=function(){return this},e;function n(n,o){e[n]=t[n]?function(e){return(r=!r)?{value:u(t[n](e)),done:\"return\"===n}:o?o(e):e}:o}},r.__asyncValues=function(t){if(!Symbol.asyncIterator)throw new TypeError(\"Symbol.asyncIterator is not defined.\");var e,r=t[Symbol.asyncIterator];return r?r.call(t):(t=i(t),e={},n(\"next\"),n(\"throw\"),n(\"return\"),e[Symbol.asyncIterator]=function(){return this},e);function n(r){e[r]=t[r]&&function(e){return new Promise((function(n,o){(function(t,e,r,n){Promise.resolve(n).then((function(e){t({value:e,done:r})}),e)})(n,o,(e=t[r](e)).done,e.value)}))}}},r.__makeTemplateObject=function(t,e){return Object.defineProperty?Object.defineProperty(t,\"raw\",{value:e}):t.raw=e,t};var f=Object.create?function(t,e){Object.defineProperty(t,\"default\",{enumerable:!0,value:e})}:function(t,e){t.default=e};r.__importStar=function(t){if(t&&t.__esModule)return t;var e={};if(null!=t)for(var n in t)\"default\"!==n&&Object.prototype.hasOwnProperty.call(t,n)&&(0,r.__createBinding)(e,t,n);return f(e,t),e},r.__importDefault=function(t){return t&&t.__esModule?t:{default:t}},r.__classPrivateFieldGet=function(t,e,r,n){if(\"a\"===r&&!n)throw new TypeError(\"Private accessor was defined without a getter\");if(\"function\"==typeof e?t!==e||!n:!e.has(t))throw new TypeError(\"Cannot read private member from an object whose class did not declare it\");return\"m\"===r?n:\"a\"===r?n.call(t):n?n.value:e.get(t)},r.__classPrivateFieldSet=function(t,e,r,n,o){if(\"m\"===n)throw new TypeError(\"Private method is not writable\");if(\"a\"===n&&!o)throw new TypeError(\"Private accessor was defined without a setter\");if(\"function\"==typeof e?t!==e||!o:!e.has(t))throw new TypeError(\"Cannot write private member to an object whose class did not declare it\");return\"a\"===n?o.call(t,r):o?o.value=r:e.set(t,r),r}},\n", " function _(e,t,o,s,l){s();const n=e(1);l(\"version\",e(3).version),l(\"index\",e(4).index),o.embed=(0,n.__importStar)(e(4)),o.protocol=(0,n.__importStar)(e(406)),o._testing=(0,n.__importStar)(e(407));var r=e(19);l(\"logger\",r.logger),l(\"set_log_level\",r.set_log_level),l(\"settings\",e(28).settings),l(\"Models\",e(7).Models),l(\"documents\",e(5).documents),l(\"safely\",e(408).safely)},\n", - " function _(n,i,o,c,e){c(),o.version=\"2.4.1\"},\n", + " function _(n,i,o,c,e){c(),o.version=\"2.4.3\"},\n", " function _(e,o,t,n,s){n();const d=e(5),r=e(19),_=e(34),c=e(13),i=e(8),a=e(16),u=e(397),l=e(399),m=e(398);var f=e(397);s(\"add_document_standalone\",f.add_document_standalone),s(\"index\",f.index),s(\"add_document_from_session\",e(399).add_document_from_session);var g=e(404);async function w(e,o,t,n){(0,i.isString)(e)&&(e=JSON.parse((0,_.unescape)(e)));const s={};for(const[o,t]of(0,c.entries)(e))s[o]=d.Document.from_json(t);const a=[];for(const e of o){const o=(0,m._resolve_element)(e),d=(0,m._resolve_root_elements)(e);if(null!=e.docid)a.push(await(0,u.add_document_standalone)(s[e.docid],o,d,e.use_for_title));else{if(null==e.token)throw new Error(\"Error rendering Bokeh items: either 'docid' or 'token' was expected.\");{const s=(0,l._get_ws_url)(t,n);r.logger.debug(`embed: computed ws url: ${s}`);try{a.push(await(0,l.add_document_from_session)(s,e.token,o,d,e.use_for_title)),console.log(\"Bokeh items were rendered successfully\")}catch(e){console.log(\"Error rendering Bokeh items:\",e)}}}}return a}s(\"embed_items_notebook\",g.embed_items_notebook),s(\"kernels\",g.kernels),s(\"BOKEH_ROOT\",e(398).BOKEH_ROOT),t.embed_item=async function(e,o){const t={},n=(0,_.uuid4)();t[n]=e.doc,null==o&&(o=e.target_id);const s=document.getElementById(o);null!=s&&s.classList.add(m.BOKEH_ROOT);const d={roots:{[e.root_id]:o},root_ids:[e.root_id],docid:n};await(0,a.defer)();const[r]=await w(t,[d]);return r},t.embed_items=async function(e,o,t,n){return await(0,a.defer)(),w(e,o,t,n)}},\n", " function _(t,_,o,r,n){r();const a=t(1);(0,a.__exportStar)(t(6),o),(0,a.__exportStar)(t(35),o)},\n", - " function _(e,t,s,o,n){o();const i=e(1),r=e(7),l=e(3),a=e(19),_=e(251),c=e(14),d=e(30),h=e(15),f=e(17),u=e(31),m=e(29),g=e(9),v=e(13),p=(0,i.__importStar)(e(77)),w=e(26),b=e(8),y=e(309),k=e(75),M=e(53),j=e(396),S=e(35);class z{constructor(e){this.document=e,this.session=null,this.subscribed_models=new Set}send_event(e){const t=new S.MessageSentEvent(this.document,\"bokeh_event\",e.to_json());this.document._trigger_on_change(t)}trigger(e){for(const t of this.subscribed_models)null!=e.origin&&e.origin!=t||t._process_event(e)}}s.EventManager=z,z.__name__=\"EventManager\",s.documents=[],s.DEFAULT_TITLE=\"Bokeh Application\";class E{constructor(e){var t;s.documents.push(this),this._init_timestamp=Date.now(),this._resolver=null!==(t=null==e?void 0:e.resolver)&&void 0!==t?t:new r.ModelResolver,this._title=s.DEFAULT_TITLE,this._roots=[],this._all_models=new Map,this._all_models_freeze_count=0,this._callbacks=new Map,this._message_callbacks=new Map,this.event_manager=new z(this),this.idle=new h.Signal0(this,\"idle\"),this._idle_roots=new WeakMap,this._interactive_timestamp=null,this._interactive_plot=null}get layoutables(){return this._roots.filter((e=>e instanceof y.LayoutDOM))}get is_idle(){for(const e of this.layoutables)if(!this._idle_roots.has(e))return!1;return!0}notify_idle(e){this._idle_roots.set(e,!0),this.is_idle&&(a.logger.info(`document idle at ${Date.now()-this._init_timestamp} ms`),this.event_manager.send_event(new _.DocumentReady),this.idle.emit())}clear(){this._push_all_models_freeze();try{for(;this._roots.length>0;)this.remove_root(this._roots[0])}finally{this._pop_all_models_freeze()}}interactive_start(e,t=null){null==this._interactive_plot&&(this._interactive_plot=e,this._interactive_plot.trigger_event(new _.LODStart)),this._interactive_finalize=t,this._interactive_timestamp=Date.now()}interactive_stop(){null!=this._interactive_plot&&(this._interactive_plot.trigger_event(new _.LODEnd),null!=this._interactive_finalize&&this._interactive_finalize()),this._interactive_plot=null,this._interactive_timestamp=null,this._interactive_finalize=null}interactive_duration(){return null==this._interactive_timestamp?-1:Date.now()-this._interactive_timestamp}destructively_move(e){if(e===this)throw new Error(\"Attempted to overwrite a document with itself\");e.clear();const t=(0,g.copy)(this._roots);this.clear();for(const e of t)if(null!=e.document)throw new Error(`Somehow we didn't detach ${e}`);if(0!=this._all_models.size)throw new Error(`this._all_models still had stuff in it: ${this._all_models}`);for(const s of t)e.add_root(s);e.set_title(this._title)}_push_all_models_freeze(){this._all_models_freeze_count+=1}_pop_all_models_freeze(){this._all_models_freeze_count-=1,0===this._all_models_freeze_count&&this._recompute_all_models()}_invalidate_all_models(){a.logger.debug(\"invalidating document models\"),0===this._all_models_freeze_count&&this._recompute_all_models()}_recompute_all_models(){let e=new Set;for(const t of this._roots)e=p.union(e,t.references());const t=new Set(this._all_models.values()),s=p.difference(t,e),o=p.difference(e,t),n=new Map;for(const t of e)n.set(t.id,t);for(const e of s)e.detach_document();for(const e of o)e.attach_document(this);this._all_models=n}roots(){return this._roots}add_root(e,t){if(a.logger.debug(`Adding root: ${e}`),!(0,g.includes)(this._roots,e)){this._push_all_models_freeze();try{this._roots.push(e)}finally{this._pop_all_models_freeze()}this._trigger_on_change(new S.RootAddedEvent(this,e,t))}}remove_root(e,t){const s=this._roots.indexOf(e);if(!(s<0)){this._push_all_models_freeze();try{this._roots.splice(s,1)}finally{this._pop_all_models_freeze()}this._trigger_on_change(new S.RootRemovedEvent(this,e,t))}}title(){return this._title}set_title(e,t){e!==this._title&&(this._title=e,this._trigger_on_change(new S.TitleChangedEvent(this,e,t)))}get_model_by_id(e){var t;return null!==(t=this._all_models.get(e))&&void 0!==t?t:null}get_model_by_name(e){const t=[];for(const s of this._all_models.values())s instanceof M.Model&&s.name==e&&t.push(s);switch(t.length){case 0:return null;case 1:return t[0];default:throw new Error(`Multiple models are named '${e}'`)}}on_message(e,t){const s=this._message_callbacks.get(e);null==s?this._message_callbacks.set(e,new Set([t])):s.add(t)}remove_on_message(e,t){var s;null===(s=this._message_callbacks.get(e))||void 0===s||s.delete(t)}_trigger_on_message(e,t){const s=this._message_callbacks.get(e);if(null!=s)for(const e of s)e(t)}on_change(e,t=!1){this._callbacks.has(e)||this._callbacks.set(e,t)}remove_on_change(e){this._callbacks.delete(e)}_trigger_on_change(e){for(const[t,s]of this._callbacks)if(!s&&e instanceof S.DocumentEventBatch)for(const s of e.events)t(s);else t(e)}_notify_change(e,t,s,o,n){this._trigger_on_change(new S.ModelChangedEvent(this,e,t,s,o,null==n?void 0:n.setter_id,null==n?void 0:n.hint))}static _instantiate_object(e,t,s,o){const n=Object.assign(Object.assign({},s),{id:e,__deferred__:!0});return new(o.get(t))(n)}static _instantiate_references_json(e,t,s){var o;const n=new Map;for(const i of e){const e=i.id,r=i.type,l=null!==(o=i.attributes)&&void 0!==o?o:{};let a=t.get(e);null==a&&(a=E._instantiate_object(e,r,l,s),null!=i.subtype&&a.set_subtype(i.subtype)),n.set(a.id,a)}return n}static _resolve_refs(e,t,s,o){function n(e){var i;if((0,f.is_ref)(e)){const o=null!==(i=t.get(e.id))&&void 0!==i?i:s.get(e.id);if(null!=o)return o;throw new Error(`reference ${JSON.stringify(e)} isn't known (not in Document?)`)}if((0,u.is_NDArray_ref)(e)){const{buffer:t,dtype:s,shape:n}=(0,u.decode_NDArray)(e,o);return(0,m.ndarray)(t,{dtype:s,shape:n})}return(0,b.isArray)(e)?function(e){const t=[];for(const s of e)t.push(n(s));return t}(e):(0,b.isPlainObject)(e)?function(e){const t={};for(const[s,o]of(0,v.entries)(e))t[s]=n(o);return t}(e):e}return n(e)}static _initialize_references_json(e,t,s,o){const n=new Map;for(const{id:i,attributes:r}of e){const e=!t.has(i),l=e?s.get(i):t.get(i),a=E._resolve_refs(r,t,s,o);l.setv(a,{silent:!0}),n.set(i,{instance:l,is_new:e})}const i=[],r=new Set;function l(e){if(e instanceof c.HasProps){if(n.has(e.id)&&!r.has(e.id)){r.add(e.id);const{instance:t,is_new:s}=n.get(e.id),{attributes:o}=t;for(const e of(0,v.values)(o))l(e);s&&(t.finalize(),i.push(t))}}else if((0,b.isArray)(e))for(const t of e)l(t);else if((0,b.isPlainObject)(e))for(const t of(0,v.values)(e))l(t)}for(const e of n.values())l(e.instance);for(const e of i)e.connect_signals()}static _event_for_attribute_change(e,t,s,o,n){if(o.get_model_by_id(e.id).property(t).syncable){const i={kind:\"ModelChanged\",model:{id:e.id},attr:t,new:s};return c.HasProps._json_record_references(o,s,n,{recursive:!0}),i}return null}static _events_to_sync_objects(e,t,s,o){const n=Object.keys(e.attributes),i=Object.keys(t.attributes),r=(0,g.difference)(n,i),l=(0,g.difference)(i,n),_=(0,g.intersection)(n,i),c=[];for(const e of r)a.logger.warn(`Server sent key ${e} but we don't seem to have it in our JSON`);for(const n of l){const i=t.attributes[n];c.push(E._event_for_attribute_change(e,n,i,s,o))}for(const n of _){const i=e.attributes[n],r=t.attributes[n];null==i&&null==r||(null==i||null==r?c.push(E._event_for_attribute_change(e,n,r,s,o)):(0,w.is_equal)(i,r)||c.push(E._event_for_attribute_change(e,n,r,s,o)))}return c.filter((e=>null!=e))}static _compute_patch_since_json(e,t){const s=t.to_json(!1);function o(e){const t=new Map;for(const s of e.roots.references)t.set(s.id,s);return t}const n=o(e),i=new Map,r=[];for(const t of e.roots.root_ids)i.set(t,n.get(t)),r.push(t);const l=o(s),a=new Map,_=[];for(const e of s.roots.root_ids)a.set(e,l.get(e)),_.push(e);if(r.sort(),_.sort(),(0,g.difference)(r,_).length>0||(0,g.difference)(_,r).length>0)throw new Error(\"Not implemented: computing add/remove of document roots\");const c=new Set;let h=[];for(const e of t._all_models.keys())if(n.has(e)){const s=E._events_to_sync_objects(n.get(e),l.get(e),t,c);h=h.concat(s)}const f=new d.Serializer({include_defaults:!1});return f.to_serializable([...c]),{references:[...f.definitions],events:h}}to_json_string(e=!0){return JSON.stringify(this.to_json(e))}to_json(e=!0){const t=new d.Serializer({include_defaults:e}),s=t.to_serializable(this._roots);return{version:l.version,title:this._title,roots:{root_ids:s.map((e=>e.id)),references:[...t.definitions]}}}static from_json_string(e){const t=JSON.parse(e);return E.from_json(t)}static from_json(e){a.logger.debug(\"Creating Document from JSON\");const t=e.version,s=-1!==t.indexOf(\"+\")||-1!==t.indexOf(\"-\"),o=`Library versions: JS (${l.version}) / Python (${t})`;s||l.version.replace(/-(dev|rc)\\./,\"$1\")==t?a.logger.debug(o):(a.logger.warn(\"JS/Python version mismatch\"),a.logger.warn(o));const n=new r.ModelResolver;null!=e.defs&&(0,j.resolve_defs)(e.defs,n);const i=e.roots,_=i.root_ids,c=i.references,d=E._instantiate_references_json(c,new Map,n);E._initialize_references_json(c,new Map,d,new Map);const h=new E({resolver:n});for(const e of _){const t=d.get(e);null!=t&&h.add_root(t)}return h.set_title(e.title),h}replace_with_json(e){E.from_json(e).destructively_move(this)}create_json_patch_string(e){return JSON.stringify(this.create_json_patch(e))}create_json_patch(e){for(const t of e)if(t.document!=this)throw new Error(\"Cannot create a patch using events from a different document\");const t=new d.Serializer,s=t.to_serializable(e);for(const e of this._all_models.values())t.remove_def(e);return{events:s,references:[...t.definitions]}}apply_json_patch(e,t=new Map,s){const o=e.references,n=e.events,i=E._instantiate_references_json(o,this._all_models,this._resolver);t instanceof Map||(t=new Map(t));for(const e of n)switch(e.kind){case\"RootAdded\":case\"RootRemoved\":case\"ModelChanged\":{const t=e.model.id,s=this._all_models.get(t);if(null!=s)i.set(t,s);else if(!i.has(t))throw a.logger.warn(`Got an event for unknown model ${e.model}\"`),new Error(\"event model wasn't known\");break}}const r=new Map(this._all_models),l=new Map;for(const[e,t]of i)r.has(e)||l.set(e,t);E._initialize_references_json(o,r,l,t);for(const e of n)switch(e.kind){case\"MessageSent\":{const{msg_type:s,msg_data:o}=e;let n;if(void 0===o){if(1!=t.size)throw new Error(\"expected exactly one buffer\");{const[[,e]]=t;n=e}}else n=E._resolve_refs(o,r,l,t);this._trigger_on_message(s,n);break}case\"ModelChanged\":{const o=e.model.id,n=this._all_models.get(o);if(null==n)throw new Error(`Cannot apply patch to ${o} which is not in the document`);const i=e.attr,a=E._resolve_refs(e.new,r,l,t);n.setv({[i]:a},{setter_id:s});break}case\"ColumnDataChanged\":{const o=e.column_source.id,n=this._all_models.get(o);if(null==n)throw new Error(`Cannot stream to ${o} which is not in the document`);const i=E._resolve_refs(e.new,new Map,new Map,t);if(null!=e.cols)for(const e in n.data)e in i||(i[e]=n.data[e]);n.setv({data:i},{setter_id:s,check_eq:!1});break}case\"ColumnsStreamed\":{const t=e.column_source.id,o=this._all_models.get(t);if(null==o)throw new Error(`Cannot stream to ${t} which is not in the document`);if(!(o instanceof k.ColumnDataSource))throw new Error(\"Cannot stream to non-ColumnDataSource\");const n=e.data,i=e.rollover;o.stream(n,i,s);break}case\"ColumnsPatched\":{const t=e.column_source.id,o=this._all_models.get(t);if(null==o)throw new Error(`Cannot patch ${t} which is not in the document`);if(!(o instanceof k.ColumnDataSource))throw new Error(\"Cannot patch non-ColumnDataSource\");const n=e.patches;o.patch(n,s);break}case\"RootAdded\":{const t=e.model.id,o=i.get(t);this.add_root(o,s);break}case\"RootRemoved\":{const t=e.model.id,o=i.get(t);this.remove_root(o,s);break}case\"TitleChanged\":this.set_title(e.title,s);break;default:throw new Error(`Unknown patch event ${JSON.stringify(e)}`)}}}s.Document=E,E.__name__=\"Document\"},\n", + " function _(e,t,s,o,n){o();const i=e(1),r=e(7),l=e(3),_=e(19),a=e(251),c=e(14),d=e(30),h=e(15),f=e(17),u=e(31),m=e(29),g=e(9),v=e(13),p=(0,i.__importStar)(e(77)),w=e(26),b=e(8),y=e(309),k=e(75),M=e(53),j=e(396),z=e(35);class S{constructor(e){this.document=e,this.session=null,this.subscribed_models=new Set}send_event(e){const t=new z.MessageSentEvent(this.document,\"bokeh_event\",e.to_json());this.document._trigger_on_change(t)}trigger(e){for(const t of this.subscribed_models)null!=e.origin&&e.origin!=t||t._process_event(e)}}s.EventManager=S,S.__name__=\"EventManager\",s.documents=[],s.DEFAULT_TITLE=\"Bokeh Application\";class E{constructor(e){var t;s.documents.push(this),this._init_timestamp=Date.now(),this._resolver=null!==(t=null==e?void 0:e.resolver)&&void 0!==t?t:new r.ModelResolver,this._title=s.DEFAULT_TITLE,this._roots=[],this._all_models=new Map,this._all_models_freeze_count=0,this._callbacks=new Map,this._message_callbacks=new Map,this.event_manager=new S(this),this.idle=new h.Signal0(this,\"idle\"),this._idle_roots=new WeakMap,this._interactive_timestamp=null,this._interactive_plot=null}get layoutables(){return this._roots.filter((e=>e instanceof y.LayoutDOM))}get is_idle(){for(const e of this.layoutables)if(!this._idle_roots.has(e))return!1;return!0}notify_idle(e){this._idle_roots.set(e,!0),this.is_idle&&(_.logger.info(`document idle at ${Date.now()-this._init_timestamp} ms`),this.event_manager.send_event(new a.DocumentReady),this.idle.emit())}clear(){this._push_all_models_freeze();try{for(;this._roots.length>0;)this.remove_root(this._roots[0])}finally{this._pop_all_models_freeze()}}interactive_start(e,t=null){null==this._interactive_plot&&(this._interactive_plot=e,this._interactive_plot.trigger_event(new a.LODStart)),this._interactive_finalize=t,this._interactive_timestamp=Date.now()}interactive_stop(){null!=this._interactive_plot&&(this._interactive_plot.trigger_event(new a.LODEnd),null!=this._interactive_finalize&&this._interactive_finalize()),this._interactive_plot=null,this._interactive_timestamp=null,this._interactive_finalize=null}interactive_duration(){return null==this._interactive_timestamp?-1:Date.now()-this._interactive_timestamp}destructively_move(e){if(e===this)throw new Error(\"Attempted to overwrite a document with itself\");e.clear();const t=(0,g.copy)(this._roots);this.clear();for(const e of t)if(null!=e.document)throw new Error(`Somehow we didn't detach ${e}`);if(0!=this._all_models.size)throw new Error(`this._all_models still had stuff in it: ${this._all_models}`);for(const s of t)e.add_root(s);e.set_title(this._title)}_push_all_models_freeze(){this._all_models_freeze_count+=1}_pop_all_models_freeze(){this._all_models_freeze_count-=1,0===this._all_models_freeze_count&&this._recompute_all_models()}_invalidate_all_models(){_.logger.debug(\"invalidating document models\"),0===this._all_models_freeze_count&&this._recompute_all_models()}_recompute_all_models(){let e=new Set;for(const t of this._roots)e=p.union(e,t.references());const t=new Set(this._all_models.values()),s=p.difference(t,e),o=p.difference(e,t),n=new Map;for(const t of e)n.set(t.id,t);for(const e of s)e.detach_document();for(const e of o)e.attach_document(this);this._all_models=n}roots(){return this._roots}add_root(e,t){if(_.logger.debug(`Adding root: ${e}`),!(0,g.includes)(this._roots,e)){this._push_all_models_freeze();try{this._roots.push(e)}finally{this._pop_all_models_freeze()}this._trigger_on_change(new z.RootAddedEvent(this,e,t))}}remove_root(e,t){const s=this._roots.indexOf(e);if(!(s<0)){this._push_all_models_freeze();try{this._roots.splice(s,1)}finally{this._pop_all_models_freeze()}this._trigger_on_change(new z.RootRemovedEvent(this,e,t))}}title(){return this._title}set_title(e,t){e!==this._title&&(this._title=e,this._trigger_on_change(new z.TitleChangedEvent(this,e,t)))}get_model_by_id(e){var t;return null!==(t=this._all_models.get(e))&&void 0!==t?t:null}get_model_by_name(e){const t=[];for(const s of this._all_models.values())s instanceof M.Model&&s.name==e&&t.push(s);switch(t.length){case 0:return null;case 1:return t[0];default:throw new Error(`Multiple models are named '${e}'`)}}on_message(e,t){const s=this._message_callbacks.get(e);null==s?this._message_callbacks.set(e,new Set([t])):s.add(t)}remove_on_message(e,t){var s;null===(s=this._message_callbacks.get(e))||void 0===s||s.delete(t)}_trigger_on_message(e,t){const s=this._message_callbacks.get(e);if(null!=s)for(const e of s)e(t)}on_change(e,t=!1){this._callbacks.has(e)||this._callbacks.set(e,t)}remove_on_change(e){this._callbacks.delete(e)}_trigger_on_change(e){for(const[t,s]of this._callbacks)if(!s&&e instanceof z.DocumentEventBatch)for(const s of e.events)t(s);else t(e)}_notify_change(e,t,s,o,n){this._trigger_on_change(new z.ModelChangedEvent(this,e,t,s,o,null==n?void 0:n.setter_id,null==n?void 0:n.hint))}static _instantiate_object(e,t,s,o){const n=Object.assign(Object.assign({},s),{id:e,__deferred__:!0});return new(o.get(t))(n)}static _instantiate_references_json(e,t,s){var o;const n=new Map;for(const i of e){const e=i.id,r=i.type,l=null!==(o=i.attributes)&&void 0!==o?o:{};let _=t.get(e);null==_&&(_=E._instantiate_object(e,r,l,s),null!=i.subtype&&_.set_subtype(i.subtype)),n.set(_.id,_)}return n}static _resolve_refs(e,t,s,o){function n(e){var i;if((0,f.is_ref)(e)){const o=null!==(i=t.get(e.id))&&void 0!==i?i:s.get(e.id);if(null!=o)return o;throw new Error(`reference ${JSON.stringify(e)} isn't known (not in Document?)`)}if((0,u.is_NDArray_ref)(e)){const{buffer:t,dtype:s,shape:n}=(0,u.decode_NDArray)(e,o);return(0,m.ndarray)(t,{dtype:s,shape:n})}return(0,b.isArray)(e)?function(e){const t=[];for(const s of e)t.push(n(s));return t}(e):(0,b.isPlainObject)(e)?function(e){const t={};for(const[s,o]of(0,v.entries)(e))t[s]=n(o);return t}(e):e}return n(e)}static _initialize_references_json(e,t,s,o){const n=new Map;for(const{id:i,attributes:r}of e){const e=!t.has(i),l=e?s.get(i):t.get(i),_=E._resolve_refs(r,t,s,o);l.setv(_,{silent:!0}),n.set(i,{instance:l,is_new:e})}const i=[],r=new Set;function l(e){if(e instanceof c.HasProps){if(n.has(e.id)&&!r.has(e.id)){r.add(e.id);const{instance:t,is_new:s}=n.get(e.id),{attributes:o}=t;for(const e of(0,v.values)(o))l(e);s&&(t.finalize(),i.push(t))}}else if((0,b.isArray)(e))for(const t of e)l(t);else if((0,b.isPlainObject)(e))for(const t of(0,v.values)(e))l(t)}for(const e of n.values())l(e.instance);for(const e of i)e.connect_signals()}static _event_for_attribute_change(e,t,s,o,n){if(o.get_model_by_id(e.id).property(t).syncable){const i={kind:\"ModelChanged\",model:{id:e.id},attr:t,new:s};return c.HasProps._json_record_references(o,s,n,{recursive:!0}),i}return null}static _events_to_sync_objects(e,t,s,o){const n=Object.keys(e.attributes),i=Object.keys(t.attributes),r=(0,g.difference)(n,i),l=(0,g.difference)(i,n),a=(0,g.intersection)(n,i),c=[];for(const e of r)_.logger.warn(`Server sent key ${e} but we don't seem to have it in our JSON`);for(const n of l){const i=t.attributes[n];c.push(E._event_for_attribute_change(e,n,i,s,o))}for(const n of a){const i=e.attributes[n],r=t.attributes[n];null==i&&null==r||(null==i||null==r?c.push(E._event_for_attribute_change(e,n,r,s,o)):\"data\"==n||(0,w.is_equal)(i,r)||c.push(E._event_for_attribute_change(e,n,r,s,o)))}return c.filter((e=>null!=e))}static _compute_patch_since_json(e,t){const s=t.to_json(!1);function o(e){const t=new Map;for(const s of e.roots.references)t.set(s.id,s);return t}const n=o(e),i=new Map,r=[];for(const t of e.roots.root_ids)i.set(t,n.get(t)),r.push(t);const l=o(s),_=new Map,a=[];for(const e of s.roots.root_ids)_.set(e,l.get(e)),a.push(e);if(r.sort(),a.sort(),(0,g.difference)(r,a).length>0||(0,g.difference)(a,r).length>0)throw new Error(\"Not implemented: computing add/remove of document roots\");const c=new Set;let h=[];for(const e of t._all_models.keys())if(n.has(e)){const s=E._events_to_sync_objects(n.get(e),l.get(e),t,c);h=h.concat(s)}const f=new d.Serializer({include_defaults:!1});return f.to_serializable([...c]),{references:[...f.definitions],events:h}}to_json_string(e=!0){return JSON.stringify(this.to_json(e))}to_json(e=!0){const t=new d.Serializer({include_defaults:e}),s=t.to_serializable(this._roots);return{version:l.version,title:this._title,roots:{root_ids:s.map((e=>e.id)),references:[...t.definitions]}}}static from_json_string(e){const t=JSON.parse(e);return E.from_json(t)}static from_json(e){_.logger.debug(\"Creating Document from JSON\");const t=e.version,s=-1!==t.indexOf(\"+\")||-1!==t.indexOf(\"-\"),o=`Library versions: JS (${l.version}) / Python (${t})`;s||l.version.replace(/-(dev|rc)\\./,\"$1\")==t?_.logger.debug(o):(_.logger.warn(\"JS/Python version mismatch\"),_.logger.warn(o));const n=new r.ModelResolver;null!=e.defs&&(0,j.resolve_defs)(e.defs,n);const i=e.roots,a=i.root_ids,c=i.references,d=E._instantiate_references_json(c,new Map,n);E._initialize_references_json(c,new Map,d,new Map);const h=new E({resolver:n});h._push_all_models_freeze();for(const e of a){const t=d.get(e);null!=t&&h.add_root(t)}return h._pop_all_models_freeze(),h.set_title(e.title),h}replace_with_json(e){E.from_json(e).destructively_move(this)}create_json_patch_string(e){return JSON.stringify(this.create_json_patch(e))}create_json_patch(e){for(const t of e)if(t.document!=this)throw new Error(\"Cannot create a patch using events from a different document\");const t=new d.Serializer,s=t.to_serializable(e);for(const e of this._all_models.values())t.remove_def(e);return{events:s,references:[...t.definitions]}}apply_json_patch(e,t=new Map,s){const o=e.references,n=e.events,i=E._instantiate_references_json(o,this._all_models,this._resolver);t instanceof Map||(t=new Map(t));for(const e of n)switch(e.kind){case\"RootAdded\":case\"RootRemoved\":case\"ModelChanged\":{const t=e.model.id,s=this._all_models.get(t);if(null!=s)i.set(t,s);else if(!i.has(t))throw _.logger.warn(`Got an event for unknown model ${e.model}\"`),new Error(\"event model wasn't known\");break}}const r=new Map(this._all_models),l=new Map;for(const[e,t]of i)r.has(e)||l.set(e,t);E._initialize_references_json(o,r,l,t);for(const e of n)switch(e.kind){case\"MessageSent\":{const{msg_type:s,msg_data:o}=e;let n;if(void 0===o){if(1!=t.size)throw new Error(\"expected exactly one buffer\");{const[[,e]]=t;n=e}}else n=E._resolve_refs(o,r,l,t);this._trigger_on_message(s,n);break}case\"ModelChanged\":{const o=e.model.id,n=this._all_models.get(o);if(null==n)throw new Error(`Cannot apply patch to ${o} which is not in the document`);const i=e.attr,_=E._resolve_refs(e.new,r,l,t);n.setv({[i]:_},{setter_id:s});break}case\"ColumnDataChanged\":{const o=e.column_source.id,n=this._all_models.get(o);if(null==n)throw new Error(`Cannot stream to ${o} which is not in the document`);const i=E._resolve_refs(e.new,new Map,new Map,t);if(null!=e.cols)for(const e in n.data)e in i||(i[e]=n.data[e]);n.setv({data:i},{setter_id:s,check_eq:!1});break}case\"ColumnsStreamed\":{const t=e.column_source.id,o=this._all_models.get(t);if(null==o)throw new Error(`Cannot stream to ${t} which is not in the document`);if(!(o instanceof k.ColumnDataSource))throw new Error(\"Cannot stream to non-ColumnDataSource\");const n=e.data,i=e.rollover;o.stream(n,i,s);break}case\"ColumnsPatched\":{const t=e.column_source.id,o=this._all_models.get(t);if(null==o)throw new Error(`Cannot patch ${t} which is not in the document`);if(!(o instanceof k.ColumnDataSource))throw new Error(\"Cannot patch non-ColumnDataSource\");const n=e.patches;o.patch(n,s);break}case\"RootAdded\":{const t=e.model.id,o=i.get(t);this.add_root(o,s);break}case\"RootRemoved\":{const t=e.model.id,o=i.get(t);this.remove_root(o,s);break}case\"TitleChanged\":this.set_title(e.title,s);break;default:throw new Error(`Unknown patch event ${JSON.stringify(e)}`)}}}s.Document=E,E.__name__=\"Document\"},\n", " function _(e,o,s,r,t){r();const l=e(1),i=e(8),d=e(13),n=e(14);s.overrides={};const a=new Map;s.Models=e=>{const o=s.Models.get(e);if(null!=o)return o;throw new Error(`Model '${e}' does not exist. This could be due to a widget or a custom model not being registered before first usage.`)},s.Models.get=e=>{var o;return null!==(o=s.overrides[e])&&void 0!==o?o:a.get(e)},s.Models.register=(e,o)=>{s.overrides[e]=o},s.Models.unregister=e=>{delete s.overrides[e]},s.Models.register_models=(e,o=!1,s)=>{var r;if(null!=e)for(const t of(0,i.isArray)(e)?e:(0,d.values)(e))if(r=t,(0,i.isObject)(r)&&r.prototype instanceof n.HasProps){const e=t.__qualified__;o||!a.has(e)?a.set(e,t):null!=s?s(e):console.warn(`Model '${e}' was already registered`)}},s.register_models=s.Models.register_models,s.Models.registered_names=()=>[...a.keys()];class _{constructor(){this._known_models=new Map}get(e,o){var r;const t=null!==(r=s.Models.get(e))&&void 0!==r?r:this._known_models.get(e);if(null!=t)return t;if(void 0!==o)return o;throw new Error(`Model '${e}' does not exist. This could be due to a widget or a custom model not being registered before first usage.`)}register(e){const o=e.__qualified__;null==this.get(o,null)?this._known_models.set(o,e):console.warn(`Model '${o}' was already registered with this resolver`)}}s.ModelResolver=_,_.__name__=\"ModelResolver\";const g=(0,l.__importStar)(e(38));(0,s.register_models)(g);const u=(0,l.__importStar)(e(392));(0,s.register_models)(u)},\n", " function _(n,t,r,e,i){e();\n", " // (c) 2009-2015 Jeremy Ashkenas, DocumentCloud and Investigative Reporters & Editors\n", @@ -392,7 +411,7 @@ " // (c) 2009-2015 Jeremy Ashkenas, DocumentCloud and Investigative Reporters & Editors\n", " // Underscore may be freely distributed under the MIT license.\n", " const i=n(10),u=n(11),c=n(12);o(\"map\",c.map),o(\"reduce\",c.reduce),o(\"min\",c.min),o(\"min_by\",c.min_by),o(\"max\",c.max),o(\"max_by\",c.max_by),o(\"sum\",c.sum),o(\"cumsum\",c.cumsum),o(\"every\",c.every),o(\"some\",c.some),o(\"find\",c.find),o(\"find_last\",c.find_last),o(\"find_index\",c.find_index),o(\"find_last_index\",c.find_last_index),o(\"sorted_index\",c.sorted_index),o(\"is_empty\",c.is_empty);const f=Array.prototype.slice;function s(n){return f.call(n)}function a(n){return[].concat(...n)}function l(n,t){return-1!==n.indexOf(t)}function m(n,t,e=1){(0,u.assert)(e>0,\"'step' must be a positive number\"),null==t&&(t=n,n=0);const{max:r,ceil:o,abs:i}=Math,c=n<=t?e:-e,f=r(o(i(t-n)/e),0),s=new Array(f);for(let t=0;t=0?t:n.length+t]},e.zip=function(...n){if(0==n.length)return[];const t=(0,c.min)(n.map((n=>n.length))),e=n.length,r=new Array(t);for(let o=0;on.length))),r=Array(e);for(let n=0;nn[t]))},e.argmax=function(n){return(0,c.max_by)(m(n.length),(t=>n[t]))},e.sort_by=function(n,t){const e=n.map(((n,e)=>({value:n,index:e,key:t(n)})));return e.sort(((n,t)=>{const e=n.key,r=t.key;if(e!==r){if(e>r||void 0===e)return 1;if(en.value))},e.uniq=function(n){const t=new Set;for(const e of n)t.add(e);return[...t]},e.uniq_by=function(n,t){const e=[],r=[];for(const o of n){const n=t(o);l(r,n)||(r.push(n),e.push(o))}return e},e.union=function(...n){const t=new Set;for(const e of n)for(const n of e)t.add(n);return[...t]},e.intersection=function(n,...t){const e=[];n:for(const r of n)if(!l(e,r)){for(const n of t)if(!l(n,r))continue n;e.push(r)}return e},e.difference=function(n,...t){const e=a(t);return n.filter((n=>!l(e,n)))},e.remove_at=function(n,t){const e=s(n);return e.splice(t,1),e},e.remove_by=function(n,t){for(let e=0;e2*u;)n-=2*u;return n}function c(n,r){return a(n-r)}function f(){return Math.random()}function i(n){switch(n){case\"deg\":return u/180;case\"rad\":return 1;case\"grad\":return u/200;case\"turn\":return 2*u}}t.angle_norm=a,t.angle_dist=c,t.angle_between=function(n,r,t,e=!1){const o=c(r,t);if(0==o)return!1;if(o==2*u)return!0;const f=a(n),i=c(r,f)<=o&&c(f,t)<=o;return e?!i:i},t.random=f,t.randomIn=function(n,r){return null==r&&(r=n,n=0),n+Math.floor(Math.random()*(r-n+1))},t.atan2=function(n,r){return Math.atan2(r[1]-n[1],r[0]-n[0])},t.radians=function(n){return n*(u/180)},t.degrees=function(n){return n/(u/180)},t.resolve_angle=function(n,r){return-i(r)*n},t.to_radians_coeff=i,t.rnorm=function(n,r){let t,e;for(;t=f(),e=f(),e=(2*e-1)*Math.sqrt(1/Math.E*2),!(-4*t*t*Math.log(t)>=e*e););let o=e/t;return o=n+r*o,o},t.clamp=function(n,r,t){return nt?t:n},t.log=function(n,r=Math.E){return Math.log(n)/Math.log(r)}},\n", + " function _(n,t,r,e,o){e();const{PI:a}=Math;function u(n){if(0==n)return 0;for(;n<=0;)n+=2*a;for(;n>2*a;)n-=2*a;return n}function c(n,t){return u(n-t)}function f(){return Math.random()}function i(n){switch(n){case\"deg\":return a/180;case\"rad\":return 1;case\"grad\":return a/200;case\"turn\":return 2*a}}r.angle_norm=u,r.angle_dist=c,r.angle_between=function(n,t,r,e=!1){const o=c(t,r);if(0==o)return!1;if(o==2*a)return!0;const f=u(n),i=c(t,f)<=o&&c(f,r)<=o;return e?!i:i},r.random=f,r.randomIn=function(n,t){return null==t&&(t=n,n=0),n+Math.floor(Math.random()*(t-n+1))},r.atan2=function(n,t){return Math.atan2(t[1]-n[1],t[0]-n[0])},r.radians=function(n){return n*(a/180)},r.degrees=function(n){return n/(a/180)},r.resolve_angle=function(n,t){return-i(t)*n},r.to_radians_coeff=i,r.rnorm=function(n,t){let r,e;for(;r=f(),e=f(),e=(2*e-1)*Math.sqrt(1/Math.E*2),!(-4*r*r*Math.log(r)>=e*e););let o=e/r;return o=n+t*o,o},r.clamp=function(n,t,r){return nr?r:n},r.log=function(n,t=Math.E){return Math.log(n)/Math.log(t)},r.float32_epsilon=1.1920928955078125e-7},\n", " function _(r,n,e,o,s){o();class t extends Error{}e.AssertionError=t,t.__name__=\"AssertionError\",e.assert=function(r,n){if(!(!0===r||!1!==r&&r()))throw new t(null!=n?n:\"Assertion failed\")},e.unreachable=function(){throw new Error(\"unreachable code\")}},\n", " function _(n,t,e,r,o){r();const i=n(10);function l(n,t,e,...r){const o=n.length;t<0&&(t+=o),t<0?t=0:t>o&&(t=o),null==e||e>o-t?e=o-t:e<0&&(e=0);const i=o-e+r.length,l=new n.constructor(i);let u=0;for(;u0?0:r-1;for(;o>=0&&ot[t.length-1])return t.length;let e=0,r=t.length-1;for(;r-e!=1;){const o=e+Math.floor((r-e)/2);n>=t[o]?e=o:r=o}return e}e.is_empty=function(n){return 0==n.length},e.copy=function(n){return Array.isArray(n)?n.slice():new n.constructor(n)},e.splice=l,e.head=u,e.insert=function(n,t,e){return l(n,e,0,t)},e.append=function(n,t){return l(n,n.length,0,t)},e.prepend=function(n,t){return l(n,0,0,t)},e.indexOf=function(n,t){for(let e=0,r=n.length;ee&&(e=t);return e},e.minmax=function(n){let t,e=1/0,r=-1/0;for(let o=0,i=n.length;or&&(r=t));return[e,r]},e.minmax2=function(n,t){let e,r,o=1/0,i=-1/0,l=1/0,u=-1/0;const c=Math.min(n.length,t.length);for(let f=0;fi&&(i=e),ru&&(u=r));return[o,i,l,u]},e.min_by=function(n,t){if(0==n.length)throw new Error(\"min_by() called with an empty array\");let e=n[0],r=t(e);for(let o=1,i=n.length;or&&(e=i,r=l)}return e},e.sum=function(n){let t=0;for(let e=0,r=n.length;et[r]=n+e),0),t},e.every=function(n,t){for(let e=0,r=n.length;e(n-t)/r))}},\n", " function _(t,e,n,c,o){c();const s=t(9),{hasOwnProperty:r}=Object.prototype;function i(t){return Object.keys(t).length}function u(t){return 0==i(t)}n.keys=Object.keys,n.values=Object.values,n.entries=Object.entries,n.extend=Object.assign,n.clone=function(t){return Object.assign({},t)},n.merge=function(t,e){const n=Object.create(Object.prototype),c=(0,s.concat)([Object.keys(t),Object.keys(e)]);for(const o of c){const c=r.call(t,o)?t[o]:[],i=r.call(e,o)?e[o]:[];n[o]=(0,s.union)(c,i)}return n},n.size=i,n.is_empty=u,n.isEmpty=u,n.to_object=function(t){const e={};for(const[n,c]of t)e[n]=c;return e}},\n", @@ -410,7 +429,7 @@ " function _(t,s,r,e,i){var n;e();const o=t(26),a=t(11);class _{constructor(t,s=0){this.size=t,this[n]=\"BitSet\",this._count=null,this._nwords=Math.ceil(t/32),0==s||1==s?(this._array=new Uint32Array(this._nwords),1==s&&this._array.fill(4294967295)):((0,a.assert)(s.length==this._nwords,\"Initializer size mismatch\"),this._array=s)}clone(){return new _(this.size,new Uint32Array(this._array))}[(n=Symbol.toStringTag,o.equals)](t,s){if(!s.eq(this.size,t.size))return!1;const{_nwords:r}=this,e=this.size%r,i=0==e?r:r-1;for(let s=0;s>>5,r=31&t;return!!(this._array[s]>>r&1)}set(t,s=!0){this._check_bounds(t),this._count=null;const r=t>>>5,e=31&t;s?this._array[r]|=1<>>t&1&&(e+=1)}return e}*ones(){const{_array:t,_nwords:s,size:r}=this;for(let e=0,i=0;i>>t&1&&(yield e);else e+=32}}*zeros(){const{_array:t,_nwords:s,size:r}=this;for(let e=0,i=0;i>>t&1||(yield e);else e+=32}}_check_size(t){(0,a.assert)(this.size==t.size,\"Size mismatch\")}add(t){this._check_size(t);for(let s=0;s{if(a(t)&&a(e))return t[r.equals](e,this);switch(n){case\"[object Array]\":case\"[object Uint8Array]\":case\"[object Int8Array]\":case\"[object Uint16Array]\":case\"[object Int16Array]\":case\"[object Uint32Array]\":case\"[object Int32Array]\":case\"[object Float32Array]\":case\"[object Float64Array]\":return this.arrays(t,e);case\"[object Map]\":return this.maps(t,e);case\"[object Set]\":return this.sets(t,e);case\"[object Object]\":if(t.constructor==e.constructor&&(null==t.constructor||t.constructor===Object))return this.objects(t,e);case\"[object Function]\":if(t.constructor==e.constructor&&t.constructor===Function)return this.eq(`${t}`,`${e}`)}if(t instanceof Node)return this.nodes(t,e);throw Error(`can't compare objects of type ${n}`)})();return s.pop(),o.pop(),u}numbers(t,e){return Object.is(t,e)}arrays(t,e){const{length:r}=t;if(r!=e.length)return!1;for(let n=0;n{const n=navigator.userAgent;return n.includes(\"MSIE\")||n.includes(\"Trident\")||n.includes(\"Edge\")})(),e.is_mobile=\"undefined\"!=typeof window&&(\"ontouchstart\"in window||navigator.maxTouchPoints>0),e.is_little_endian=(()=>{const n=new ArrayBuffer(4),i=new Uint8Array(n);new Uint32Array(n)[1]=168496141;let e=!0;return 10==i[4]&&11==i[5]&&12==i[6]&&13==i[7]&&(e=!1),e})(),e.BYTE_ORDER=e.is_little_endian?\"little\":\"big\",e.to_big_endian=function(n){if(e.is_little_endian){const i=new Uint32Array(n.length),e=new DataView(i.buffer);let t=0;for(const i of n)e.setUint32(t,i),t+=4;return i}return n}},\n", - " function _(e,t,r,i,s){i();class _{constructor(){this._dev=!1,this._wireframe=!1}set dev(e){this._dev=e}get dev(){return this._dev}set wireframe(e){this._wireframe=e}get wireframe(){return this._wireframe}}r.Settings=_,_.__name__=\"Settings\",r.settings=new _},\n", + " function _(e,t,r,s,_){s();class i{constructor(){this._dev=!1,this._wireframe=!1,this._force_webgl=!1}set dev(e){this._dev=e}get dev(){return this._dev}set wireframe(e){this._wireframe=e}get wireframe(){return this._wireframe}set force_webgl(e){this._force_webgl=e}get force_webgl(){return this._force_webgl}}r.Settings=i,i.__name__=\"Settings\",r.settings=new i},\n", " function _(e,s,t,i,r){var a,n,l,h,u,o,p,c;i();const y=e(8),_=e(11),A=e(26),q=e(30),d=e(31),z=Symbol(\"__ndarray__\");class D extends Uint8Array{constructor(e,s){super(e),this[a]=!0,this.dtype=\"uint8\",this.shape=null!=s?s:x(e)?e.shape:[this.length],this.dimension=this.shape.length,null==this[A.equals]&&(this[A.equals]=(e,s)=>D.prototype[A.equals].call(this,e,s)),null==this[q.serialize]&&(this[q.serialize]=e=>D.prototype[q.serialize].call(this,e))}[(a=z,A.equals)](e,s){return s.eq(this.shape,e.shape)&&s.arrays(this,e)}[q.serialize](e){return(0,d.encode_NDArray)(this)}}t.Uint8NDArray=D,D.__name__=\"Uint8NDArray\";class N extends Int8Array{constructor(e,s){super(e),this[n]=!0,this.dtype=\"int8\",this.shape=null!=s?s:x(e)?e.shape:[this.length],this.dimension=this.shape.length,null==this[A.equals]&&(this[A.equals]=(e,s)=>N.prototype[A.equals].call(this,e,s)),null==this[q.serialize]&&(this[q.serialize]=e=>N.prototype[q.serialize].call(this,e))}[(n=z,A.equals)](e,s){return s.eq(this.shape,e.shape)&&s.arrays(this,e)}[q.serialize](e){return(0,d.encode_NDArray)(this)}}t.Int8NDArray=N,N.__name__=\"Int8NDArray\";class f extends Uint16Array{constructor(e,s){super(e),this[l]=!0,this.dtype=\"uint16\",this.shape=null!=s?s:x(e)?e.shape:[this.length],this.dimension=this.shape.length,null==this[A.equals]&&(this[A.equals]=(e,s)=>f.prototype[A.equals].call(this,e,s)),null==this[q.serialize]&&(this[q.serialize]=e=>f.prototype[q.serialize].call(this,e))}[(l=z,A.equals)](e,s){return s.eq(this.shape,e.shape)&&s.arrays(this,e)}[q.serialize](e){return(0,d.encode_NDArray)(this)}}t.Uint16NDArray=f,f.__name__=\"Uint16NDArray\";class m extends Int16Array{constructor(e,s){super(e),this[h]=!0,this.dtype=\"int16\",this.shape=null!=s?s:x(e)?e.shape:[this.length],this.dimension=this.shape.length,null==this[A.equals]&&(this[A.equals]=(e,s)=>m.prototype[A.equals].call(this,e,s)),null==this[q.serialize]&&(this[q.serialize]=e=>m.prototype[q.serialize].call(this,e))}[(h=z,A.equals)](e,s){return s.eq(this.shape,e.shape)&&s.arrays(this,e)}[q.serialize](e){return(0,d.encode_NDArray)(this)}}t.Int16NDArray=m,m.__name__=\"Int16NDArray\";class g extends Uint32Array{constructor(e,s){super(e),this[u]=!0,this.dtype=\"uint32\",this.shape=null!=s?s:x(e)?e.shape:[this.length],this.dimension=this.shape.length,null==this[A.equals]&&(this[A.equals]=(e,s)=>g.prototype[A.equals].call(this,e,s)),null==this[q.serialize]&&(this[q.serialize]=e=>g.prototype[q.serialize].call(this,e))}[(u=z,A.equals)](e,s){return s.eq(this.shape,e.shape)&&s.arrays(this,e)}[q.serialize](e){return(0,d.encode_NDArray)(this)}}t.Uint32NDArray=g,g.__name__=\"Uint32NDArray\";class I extends Int32Array{constructor(e,s){super(e),this[o]=!0,this.dtype=\"int32\",this.shape=null!=s?s:x(e)?e.shape:[this.length],this.dimension=this.shape.length,null==this[A.equals]&&(this[A.equals]=(e,s)=>I.prototype[A.equals].call(this,e,s)),null==this[q.serialize]&&(this[q.serialize]=e=>I.prototype[q.serialize].call(this,e))}[(o=z,A.equals)](e,s){return s.eq(this.shape,e.shape)&&s.arrays(this,e)}[q.serialize](e){return(0,d.encode_NDArray)(this)}}t.Int32NDArray=I,I.__name__=\"Int32NDArray\";class U extends Float32Array{constructor(e,s){super(e),this[p]=!0,this.dtype=\"float32\",this.shape=null!=s?s:x(e)?e.shape:[this.length],this.dimension=this.shape.length,null==this[A.equals]&&(this[A.equals]=(e,s)=>U.prototype[A.equals].call(this,e,s)),null==this[q.serialize]&&(this[q.serialize]=e=>U.prototype[q.serialize].call(this,e))}[(p=z,A.equals)](e,s){return s.eq(this.shape,e.shape)&&s.arrays(this,e)}[q.serialize](e){return(0,d.encode_NDArray)(this)}}t.Float32NDArray=U,U.__name__=\"Float32NDArray\";class w extends Float64Array{constructor(e,s){super(e),this[c]=!0,this.dtype=\"float64\",this.shape=null!=s?s:x(e)?e.shape:[this.length],this.dimension=this.shape.length,null==this[A.equals]&&(this[A.equals]=(e,s)=>w.prototype[A.equals].call(this,e,s)),null==this[q.serialize]&&(this[q.serialize]=e=>w.prototype[q.serialize].call(this,e))}[(c=z,A.equals)](e,s){return s.eq(this.shape,e.shape)&&s.arrays(this,e)}[q.serialize](e){return(0,d.encode_NDArray)(this)}}function x(e){return(0,y.isObject)(e)&&void 0!==e[z]}t.Float64NDArray=w,w.__name__=\"Float64NDArray\",t.is_NDArray=x,t.ndarray=function(e,s={}){let{dtype:t}=s;null==t&&(t=e instanceof ArrayBuffer||(0,y.isArray)(e)?\"float64\":(()=>{switch(!0){case e instanceof Uint8Array:return\"uint8\";case e instanceof Int8Array:return\"int8\";case e instanceof Uint16Array:return\"uint16\";case e instanceof Int16Array:return\"int16\";case e instanceof Uint32Array:return\"uint32\";case e instanceof Int32Array:return\"int32\";case e instanceof Float32Array:return\"float32\";case e instanceof Float64Array:return\"float64\";default:(0,_.unreachable)()}})());const{shape:i}=s;switch(t){case\"uint8\":return new D(e,i);case\"int8\":return new N(e,i);case\"uint16\":return new f(e,i);case\"int16\":return new m(e,i);case\"uint32\":return new g(e,i);case\"int32\":return new I(e,i);case\"float32\":return new U(e,i);case\"float64\":return new w(e,i)}}},\n", " function _(e,r,t,i,s){i();const n=e(11),a=e(13),l=e(8);t.serialize=Symbol(\"serialize\");class o extends Error{}t.SerializationError=o,o.__name__=\"SerializationError\";class f{constructor(e){var r;this._references=new Map,this._definitions=new Map,this._refmap=new Map,this.include_defaults=null===(r=null==e?void 0:e.include_defaults)||void 0===r||r}get_ref(e){return this._references.get(e)}add_ref(e,r){(0,n.assert)(!this._references.has(e)),this._references.set(e,r)}add_def(e,r){const t=this.get_ref(e);(0,n.assert)(null!=t),this._definitions.set(e,r),this._refmap.set(t,r)}get objects(){return new Set(this._references.keys())}get references(){return new Set(this._references.values())}get definitions(){return new Set(this._definitions.values())}resolve_ref(e){return this._refmap.get(e)}remove_ref(e){return this._references.delete(e)}remove_def(e){return this._definitions.delete(e)}to_serializable(e){const r=this.get_ref(e);if(null!=r)return r;if(function(e){return(0,l.isObject)(e)&&void 0!==e[t.serialize]}(e))return e[t.serialize](this);if((0,l.isArray)(e)||(0,l.isTypedArray)(e)){const r=e.length,t=new Array(r);for(let i=0;i(0,s.buffer_to_base64)(_.buffer)};return Object.assign({__ndarray__:e},r)}}},\n", @@ -445,7 +464,7 @@ " function _(n,c,o,s,e){s();const t=n(55);class u extends t.Scale{constructor(n){super(n)}}o.ContinuousScale=u,u.__name__=\"ContinuousScale\"},\n", " function _(t,e,a,o,s){o();const r=t(60);class n extends r.ContinuousScale{constructor(t){super(t)}get s_compute(){const[t,e,a,o]=this._compute_state();return s=>{if(0==a)return 0;{const r=(Math.log(s)-o)/a;return isFinite(r)?r*t+e:NaN}}}get s_invert(){const[t,e,a,o]=this._compute_state();return s=>{const r=(s-e)/t;return Math.exp(a*r+o)}}_get_safe_factor(t,e){let a=t<0?0:t,o=e<0?0:e;if(a==o)if(0==a)[a,o]=[1,10];else{const t=Math.log(a)/Math.log(10);a=10**Math.floor(t),o=Math.ceil(t)!=Math.floor(t)?10**Math.ceil(t):10**(Math.ceil(t)+1)}return[a,o]}_compute_state(){const t=this.source_range.start,e=this.source_range.end,a=this.target_range.start,o=this.target_range.end-a,[s,r]=this._get_safe_factor(t,e);let n,c;0==s?(n=Math.log(r),c=0):(n=Math.log(r)-Math.log(s),c=Math.log(s));return[o,a,n,c]}}a.LogScale=n,n.__name__=\"LogScale\"},\n", " function _(t,e,c,a,s){a();const n=t(55),r=t(59),{_linear_compute_state:o}=r.LinearScale.prototype;class l extends n.Scale{constructor(t){super(t)}get s_compute(){const[t,e]=o.call(this),c=this.source_range;return a=>t*c.synthetic(a)+e}get s_invert(){const[t,e]=o.call(this);return c=>(c-e)/t}}c.CategoricalScale=l,l.__name__=\"CategoricalScale\"},\n", - " function _(t,i,n,a,e){a();const s=t(1);var l;const _=t(64),o=t(20),r=t(9),h=t(19),d=(0,s.__importStar)(t(65)),u=t(66);class g extends _.DataRange{constructor(t){super(t),this.have_updated_interactively=!1}initialize(){super.initialize(),this._initial_start=this.start,this._initial_end=this.end,this._initial_range_padding=this.range_padding,this._initial_range_padding_units=this.range_padding_units,this._initial_follow=this.follow,this._initial_follow_interval=this.follow_interval,this._initial_default_span=this.default_span,this._plot_bounds=new Map}get min(){return Math.min(this.start,this.end)}get max(){return Math.max(this.start,this.end)}computed_renderers(){const{renderers:t,names:i}=this,n=(0,r.concat)(this.plots.map((t=>t.data_renderers)));return(0,u.compute_renderers)(0==t.length?\"auto\":t,n,i)}_compute_plot_bounds(t,i){let n=d.empty();for(const a of t){const t=i.get(a);null==t||!a.visible&&this.only_visible||(n=d.union(n,t))}return n}adjust_bounds_for_aspect(t,i){const n=d.empty();let a=t.x1-t.x0;a<=0&&(a=1);let e=t.y1-t.y0;e<=0&&(e=1);const s=.5*(t.x1+t.x0),l=.5*(t.y1+t.y0);return al&&(\"start\"==this.follow?e=a+s*l:\"end\"==this.follow&&(a=e-s*l)),[a,e]}update(t,i,n,a){if(this.have_updated_interactively)return;const e=this.computed_renderers();let s=this._compute_plot_bounds(e,t);null!=a&&(s=this.adjust_bounds_for_aspect(s,a)),this._plot_bounds.set(n,s);const[l,_]=this._compute_min_max(this._plot_bounds.values(),i);let[o,r]=this._compute_range(l,_);null!=this._initial_start&&(\"log\"==this.scale_hint?this._initial_start>0&&(o=this._initial_start):o=this._initial_start),null!=this._initial_end&&(\"log\"==this.scale_hint?this._initial_end>0&&(r=this._initial_end):r=this._initial_end);let h=!1;\"auto\"==this.bounds&&(this.setv({bounds:[o,r]},{silent:!0}),h=!0);const[d,u]=[this.start,this.end];if(o!=d||r!=u){const t={};o!=d&&(t.start=o),r!=u&&(t.end=r),this.setv(t),h=!1}h&&this.change.emit()}reset(){this.have_updated_interactively=!1,this.setv({range_padding:this._initial_range_padding,range_padding_units:this._initial_range_padding_units,follow:this._initial_follow,follow_interval:this._initial_follow_interval,default_span:this._initial_default_span},{silent:!0}),this.change.emit()}}n.DataRange1d=g,l=g,g.__name__=\"DataRange1d\",l.define((({Boolean:t,Number:i,Nullable:n})=>({start:[i],end:[i],range_padding:[i,.1],range_padding_units:[o.PaddingUnits,\"percent\"],flipped:[t,!1],follow:[n(o.StartEnd),null],follow_interval:[n(i),null],default_span:[i,2],only_visible:[t,!1]}))),l.internal((({Enum:t})=>({scale_hint:[t(\"log\",\"auto\"),\"auto\"]})))},\n", + " function _(t,i,n,e,a){e();const s=t(1);var l;const _=t(64),o=t(20),r=t(9),h=t(19),d=(0,s.__importStar)(t(65)),u=t(66);class g extends _.DataRange{constructor(t){super(t),this.have_updated_interactively=!1}initialize(){super.initialize(),this._initial_start=this.start,this._initial_end=this.end,this._initial_range_padding=this.range_padding,this._initial_range_padding_units=this.range_padding_units,this._initial_follow=this.follow,this._initial_follow_interval=this.follow_interval,this._initial_default_span=this.default_span,this._plot_bounds=new Map}get min(){return Math.min(this.start,this.end)}get max(){return Math.max(this.start,this.end)}computed_renderers(){const{renderers:t,names:i}=this,n=(0,r.concat)(this.plots.map((t=>t.data_renderers)));return(0,u.compute_renderers)(0==t.length?\"auto\":t,n,i)}_compute_plot_bounds(t,i){let n=d.empty();for(const e of t){const t=i.get(e);null==t||!e.visible&&this.only_visible||(n=d.union(n,t))}return n}adjust_bounds_for_aspect(t,i){const n=d.empty();let e=t.x1-t.x0;e<=0&&(e=1);let a=t.y1-t.y0;a<=0&&(a=1);const s=.5*(t.x1+t.x0),l=.5*(t.y1+t.y0);return el&&(\"start\"==this.follow?a=e+s*l:\"end\"==this.follow&&(e=a-s*l)),[e,a]}update(t,i,n,e){if(this.have_updated_interactively)return;const a=this.computed_renderers();let s=this._compute_plot_bounds(a,t);null!=e&&(s=this.adjust_bounds_for_aspect(s,e)),this._plot_bounds.set(n,s);const[l,_]=this._compute_min_max(this._plot_bounds.entries(),i);let[o,r]=this._compute_range(l,_);null!=this._initial_start&&(\"log\"==this.scale_hint?this._initial_start>0&&(o=this._initial_start):o=this._initial_start),null!=this._initial_end&&(\"log\"==this.scale_hint?this._initial_end>0&&(r=this._initial_end):r=this._initial_end);let h=!1;\"auto\"==this.bounds&&(this.setv({bounds:[o,r]},{silent:!0}),h=!0);const[d,u]=[this.start,this.end];if(o!=d||r!=u){const t={};o!=d&&(t.start=o),r!=u&&(t.end=r),this.setv(t),h=!1}h&&this.change.emit()}reset(){this.have_updated_interactively=!1,this.setv({range_padding:this._initial_range_padding,range_padding_units:this._initial_range_padding_units,follow:this._initial_follow,follow_interval:this._initial_follow_interval,default_span:this._initial_default_span},{silent:!0}),this.change.emit()}}n.DataRange1d=g,l=g,g.__name__=\"DataRange1d\",l.define((({Boolean:t,Number:i,Nullable:n})=>({start:[i],end:[i],range_padding:[i,.1],range_padding_units:[o.PaddingUnits,\"percent\"],flipped:[t,!1],follow:[n(o.StartEnd),null],follow_interval:[n(i),null],default_span:[i,2],only_visible:[t,!1]}))),l.internal((({Enum:t})=>({scale_hint:[t(\"log\",\"auto\"),\"auto\"]})))},\n", " function _(e,n,a,r,s){var t;r();const c=e(57);class _ extends c.Range{constructor(e){super(e)}}a.DataRange=_,t=_,_.__name__=\"DataRange\",t.define((({String:e,Array:n,AnyRef:a})=>({names:[n(e),[]],renderers:[n(a()),[]]})))},\n", " function _(t,i,e,h,r){h();const s=t(24),n=t(26),{min:x,max:y}=Math;e.empty=function(){return{x0:1/0,y0:1/0,x1:-1/0,y1:-1/0}},e.positive_x=function(){return{x0:Number.MIN_VALUE,y0:-1/0,x1:1/0,y1:1/0}},e.positive_y=function(){return{x0:-1/0,y0:Number.MIN_VALUE,x1:1/0,y1:1/0}},e.union=function(t,i){return{x0:x(t.x0,i.x0),x1:y(t.x1,i.x1),y0:x(t.y0,i.y0),y1:y(t.y1,i.y1)}};class o{constructor(t){if(null==t)this.x0=0,this.y0=0,this.x1=0,this.y1=0;else if(\"x0\"in t){const{x0:i,y0:e,x1:h,y1:r}=t;if(!(i<=h&&e<=r))throw new Error(`invalid bbox {x0: ${i}, y0: ${e}, x1: ${h}, y1: ${r}}`);this.x0=i,this.y0=e,this.x1=h,this.y1=r}else if(\"x\"in t){const{x:i,y:e,width:h,height:r}=t;if(!(h>=0&&r>=0))throw new Error(`invalid bbox {x: ${i}, y: ${e}, width: ${h}, height: ${r}}`);this.x0=i,this.y0=e,this.x1=i+h,this.y1=e+r}else{let i,e,h,r;if(\"width\"in t)if(\"left\"in t)i=t.left,e=i+t.width;else if(\"right\"in t)e=t.right,i=e-t.width;else{const h=t.width/2;i=t.hcenter-h,e=t.hcenter+h}else i=t.left,e=t.right;if(\"height\"in t)if(\"top\"in t)h=t.top,r=h+t.height;else if(\"bottom\"in t)r=t.bottom,h=r-t.height;else{const i=t.height/2;h=t.vcenter-i,r=t.vcenter+i}else h=t.top,r=t.bottom;if(!(i<=e&&h<=r))throw new Error(`invalid bbox {left: ${i}, top: ${h}, right: ${e}, bottom: ${r}}`);this.x0=i,this.y0=h,this.x1=e,this.y1=r}}static from_rect({left:t,right:i,top:e,bottom:h}){return new o({x0:Math.min(t,i),y0:Math.min(e,h),x1:Math.max(t,i),y1:Math.max(e,h)})}equals(t){return this.x0==t.x0&&this.y0==t.y0&&this.x1==t.x1&&this.y1==t.y1}[n.equals](t,i){return i.eq(this.x0,t.x0)&&i.eq(this.y0,t.y0)&&i.eq(this.x1,t.x1)&&i.eq(this.y1,t.y1)}toString(){return`BBox({left: ${this.left}, top: ${this.top}, width: ${this.width}, height: ${this.height}})`}get left(){return this.x0}get top(){return this.y0}get right(){return this.x1}get bottom(){return this.y1}get p0(){return[this.x0,this.y0]}get p1(){return[this.x1,this.y1]}get x(){return this.x0}get y(){return this.y0}get width(){return this.x1-this.x0}get height(){return this.y1-this.y0}get size(){return{width:this.width,height:this.height}}get rect(){const{x0:t,y0:i,x1:e,y1:h}=this;return{p0:{x:t,y:i},p1:{x:e,y:i},p2:{x:e,y:h},p3:{x:t,y:h}}}get box(){const{x:t,y:i,width:e,height:h}=this;return{x:t,y:i,width:e,height:h}}get h_range(){return{start:this.x0,end:this.x1}}get v_range(){return{start:this.y0,end:this.y1}}get ranges(){return[this.h_range,this.v_range]}get aspect(){return this.width/this.height}get hcenter(){return(this.left+this.right)/2}get vcenter(){return(this.top+this.bottom)/2}get area(){return this.width*this.height}relative(){const{width:t,height:i}=this;return new o({x:0,y:0,width:t,height:i})}translate(t,i){const{x:e,y:h,width:r,height:s}=this;return new o({x:t+e,y:i+h,width:r,height:s})}relativize(t,i){return[t-this.x,i-this.y]}contains(t,i){return this.x0<=t&&t<=this.x1&&this.y0<=i&&i<=this.y1}clip(t,i){return tthis.x1&&(t=this.x1),ithis.y1&&(i=this.y1),[t,i]}grow_by(t){return new o({left:this.left-t,right:this.right+t,top:this.top-t,bottom:this.bottom+t})}shrink_by(t){return new o({left:this.left+t,right:this.right-t,top:this.top+t,bottom:this.bottom-t})}union(t){return new o({x0:x(this.x0,t.x0),y0:x(this.y0,t.y0),x1:y(this.x1,t.x1),y1:y(this.y1,t.y1)})}intersection(t){return this.intersects(t)?new o({x0:y(this.x0,t.x0),y0:y(this.y0,t.y0),x1:x(this.x1,t.x1),y1:x(this.y1,t.y1)}):null}intersects(t){return!(t.x1this.x1||t.y1this.y1)}get xview(){return{compute:t=>this.left+t,v_compute:t=>{const i=new s.ScreenArray(t.length),e=this.left;for(let h=0;hthis.bottom-t,v_compute:t=>{const i=new s.ScreenArray(t.length),e=this.bottom;for(let h=0;h0&&(r=r.filter((n=>(0,l.includes)(t,n.name)))),r}},\n", @@ -519,7 +538,7 @@ " function _(n,e,t,i,r){i();const s=n(135),l=n(139),d=[{start:\"$$\",end:\"$$\",inline:!1},{start:\"\\\\[\",end:\"\\\\]\",inline:!1},{start:\"\\\\(\",end:\"\\\\)\",inline:!0}];t.parse_delimited_string=function(n){for(const e of d){const t=n.indexOf(e.start),i=t+e.start.length;if(0==t){const t=n.indexOf(e.end,i),r=t;if(t==n.length-e.end.length)return new s.TeX({text:n.slice(i,r),inline:e.inline});break}}return new l.PlainText({text:n})}},\n", " function _(t,e,s,i,n){var o,r,a;i();const h=t(8),_=t(136),l=t(22),c=t(120),d=t(121),u=t(122),g=t(65),p=t(133),x=t(137);class m extends p.BaseTextView{constructor(){super(...arguments),this._position={sx:0,sy:0},this.align=\"left\",this._x_anchor=\"left\",this._y_anchor=\"center\",this._base_font_size=13,this.font_size_scale=1,this.svg_image=null}graphics(){return this}infer_text_height(){return\"ascent_descent\"}set base_font_size(t){null!=t&&(this._base_font_size=t)}get base_font_size(){return this._base_font_size}get has_image_loaded(){return null!=this.svg_image}_rect(){const{width:t,height:e}=this._size(),{x:s,y:i}=this._computed_position();return new g.BBox({x:s,y:i,width:t,height:e}).rect}set position(t){this._position=t}get position(){return this._position}get text(){return this.model.text}get provider(){return x.default_provider}async lazy_initialize(){await super.lazy_initialize(),\"not_started\"==this.provider.status&&await this.provider.fetch(),\"not_started\"!=this.provider.status&&\"loading\"!=this.provider.status||this.provider.ready.connect((()=>this.load_image())),\"loaded\"==this.provider.status&&await this.load_image()}connect_signals(){super.connect_signals(),this.on_change(this.model.properties.text,(()=>this.load_image()))}set visuals(t){const e=t.color,s=t.alpha,i=t.font_style;let n=t.font_size;const o=t.font,{font_size_scale:r,_base_font_size:a}=this,h=(0,d.parse_css_font_size)(n);if(null!=h){let{value:t,unit:e}=h;t*=r,\"em\"==e&&a&&(t*=a,e=\"px\"),n=`${t}${e}`}const _=`${i} ${n} ${o}`;this.font=_,this.color=(0,l.color2css)(e,s)}_computed_position(){const{width:t,height:e}=this._size(),{sx:s,sy:i,x_anchor:n=this._x_anchor,y_anchor:o=this._y_anchor}=this.position;return{x:s-(()=>{if((0,h.isNumber)(n))return n*t;switch(n){case\"left\":return 0;case\"center\":return.5*t;case\"right\":return t}})(),y:i-(()=>{if((0,h.isNumber)(o))return o*e;switch(o){case\"top\":return 0;case\"center\":return.5*e;case\"bottom\":return e;case\"baseline\":return.5*e}})()}}size(){const{width:t,height:e}=this._size(),{angle:s}=this;if(s){const i=Math.cos(Math.abs(s)),n=Math.sin(Math.abs(s));return{width:Math.abs(t*i+e*n),height:Math.abs(t*n+e*i)}}return{width:t,height:e}}get_text_dimensions(){return{width:(0,c.text_width)(this.model.text,this.font),height:(0,d.font_metrics)(this.font).height}}get_image_dimensions(){var t,e,s,i;const n=parseFloat(null!==(e=null===(t=this.svg_element.getAttribute(\"height\"))||void 0===t?void 0:t.replace(/([A-z])/g,\"\"))&&void 0!==e?e:\"0\"),o=parseFloat(null!==(i=null===(s=this.svg_element.getAttribute(\"width\"))||void 0===s?void 0:s.replace(/([A-z])/g,\"\"))&&void 0!==i?i:\"0\");return{width:(0,d.font_metrics)(this.font).x_height*o,height:(0,d.font_metrics)(this.font).x_height*n}}_size(){return this.has_image_loaded?this.get_image_dimensions():this.get_text_dimensions()}bbox(){const{p0:t,p1:e,p2:s,p3:i}=this.rect(),n=Math.min(t.x,e.x,s.x,i.x),o=Math.min(t.y,e.y,s.y,i.y),r=Math.max(t.x,e.x,s.x,i.x),a=Math.max(t.y,e.y,s.y,i.y);return new g.BBox({left:n,right:r,top:o,bottom:a})}rect(){const t=this._rect(),{angle:e}=this;if(e){const{sx:s,sy:i}=this.position,n=new u.AffineTransform;return n.translate(s,i),n.rotate(e),n.translate(-s,-i),n.apply_rect(t)}return t}paint_rect(t){const{p0:e,p1:s,p2:i,p3:n}=this.rect();t.save(),t.strokeStyle=\"red\",t.lineWidth=1,t.beginPath();const{round:o}=Math;t.moveTo(o(e.x),o(e.y)),t.lineTo(o(s.x),o(s.y)),t.lineTo(o(i.x),o(i.y)),t.lineTo(o(n.x),o(n.y)),t.closePath(),t.stroke(),t.restore()}paint_bbox(t){const{x:e,y:s,width:i,height:n}=this.bbox();t.save(),t.strokeStyle=\"blue\",t.lineWidth=1,t.beginPath();const{round:o}=Math;t.moveTo(o(e),o(s)),t.lineTo(o(e),o(s+n)),t.lineTo(o(e+i),o(s+n)),t.lineTo(o(e+i),o(s)),t.closePath(),t.stroke(),t.restore()}async load_image(){if(null==this.provider.MathJax)return null;const t=this._process_text(this.model.text);if(null==t)return this._has_finished=!0,null;const e=t.children[0];this.svg_element=e,e.setAttribute(\"font\",this.font),e.setAttribute(\"stroke\",this.color);const s=e.outerHTML,i=new Blob([s],{type:\"image/svg+xml\"}),n=URL.createObjectURL(i);try{this.svg_image=await(0,_.load_image)(n)}finally{URL.revokeObjectURL(n)}return this.parent.request_layout(),this.svg_image}paint(t){t.save();const{sx:e,sy:s}=this.position;this.angle&&(t.translate(e,s),t.rotate(this.angle),t.translate(-e,-s));const{x:i,y:n}=this._computed_position();if(null!=this.svg_image){const{width:e,height:s}=this.get_image_dimensions();t.drawImage(this.svg_image,i,n,e,s)}else t.fillStyle=this.color,t.font=this.font,t.textAlign=\"left\",t.textBaseline=\"alphabetic\",t.fillText(this.model.text,i,n+(0,d.font_metrics)(this.font).ascent);t.restore(),this._has_finished||\"failed\"!=this.provider.status&&!this.has_image_loaded||(this._has_finished=!0,this.parent.notify_finished_after_paint())}}s.MathTextView=m,m.__name__=\"MathTextView\";class f extends p.BaseText{constructor(t){super(t)}}s.MathText=f,f.__name__=\"MathText\";class v extends m{_process_text(t){}}s.AsciiView=v,v.__name__=\"AsciiView\";class y extends f{constructor(t){super(t)}}s.Ascii=y,o=y,y.__name__=\"Ascii\",o.prototype.default_view=v;class w extends m{_process_text(t){var e;return null===(e=this.provider.MathJax)||void 0===e?void 0:e.mathml2svg(t.trim())}}s.MathMLView=w,w.__name__=\"MathMLView\";class b extends f{constructor(t){super(t)}}s.MathML=b,r=b,b.__name__=\"MathML\",r.prototype.default_view=w;class M extends m{_process_text(t){var e;return null===(e=this.provider.MathJax)||void 0===e?void 0:e.tex2svg(t,void 0,this.model.macros)}}s.TeXView=M,M.__name__=\"TeXView\";class T extends f{constructor(t){super(t)}}s.TeX=T,a=T,T.__name__=\"TeX\",a.prototype.default_view=M,a.define((({Boolean:t,Number:e,String:s,Dict:i,Tuple:n,Or:o})=>({macros:[i(o(s,n(s,e))),{}],inline:[t,!1]})))},\n", " function _(i,e,t,s,o){s();const a=i(19);t.load_image=async function(i,e){return new n(i,e).promise};class n{constructor(i,e={}){this._image=new Image,this._finished=!1;const{attempts:t=1,timeout:s=1}=e;this.promise=new Promise(((o,n)=>{this._image.crossOrigin=\"anonymous\";let r=0;this._image.onerror=()=>{if(++r==t){const s=`unable to load ${i} image after ${t} attempts`;if(a.logger.warn(s),null==this._image.crossOrigin)return void(null!=e.failed&&e.failed());a.logger.warn(`attempting to load ${i} without a cross origin policy`),this._image.crossOrigin=null,r=0}setTimeout((()=>this._image.src=i),s)},this._image.onload=()=>{this._finished=!0,null!=e.loaded&&e.loaded(this._image),o(this._image)},this._image.src=i}))}get finished(){return this._finished}get image(){if(this._finished)return this._image;throw new Error(\"not loaded yet\")}}t.ImageLoader=n,n.__name__=\"ImageLoader\"},\n", - " function _(t,e,a,s,n){var r=this&&this.__createBinding||(Object.create?function(t,e,a,s){void 0===s&&(s=a),Object.defineProperty(t,s,{enumerable:!0,get:function(){return e[a]}})}:function(t,e,a,s){void 0===s&&(s=a),t[s]=e[a]}),i=this&&this.__setModuleDefault||(Object.create?function(t,e){Object.defineProperty(t,\"default\",{enumerable:!0,value:e})}:function(t,e){t.default=e}),d=this&&this.__importStar||function(t){if(t&&t.__esModule)return t;var e={};if(null!=t)for(var a in t)\"default\"!==a&&Object.prototype.hasOwnProperty.call(t,a)&&r(e,t,a);return i(e,t),e};s();const o=t(15),u=t(138);class c{constructor(){this.ready=new o.Signal0(this,\"ready\"),this.status=\"not_started\"}}a.MathJaxProvider=c,c.__name__=\"MathJaxProvider\";class h extends c{get MathJax(){return null}async fetch(){this.status=\"failed\"}}a.NoProvider=h,h.__name__=\"NoProvider\";class l extends c{get MathJax(){return\"undefined\"!=typeof MathJax?MathJax:null}async fetch(){const t=document.createElement(\"script\");t.src=\"https://cdn.jsdelivr.net/npm/mathjax@3/es5/tex-svg.js\",t.onload=()=>{this.status=\"loaded\",this.ready.emit()},t.onerror=()=>{this.status=\"failed\"},this.status=\"loading\",document.head.appendChild(t)}}a.CDNProvider=l,l.__name__=\"CDNProvider\";class _ extends c{get MathJax(){return this._mathjax}async fetch(){this.status=\"loading\";try{const e=await(0,u.load_module)(Promise.resolve().then((()=>d(t(515)))));this._mathjax=e,this.status=\"loaded\",this.ready.emit()}catch(t){this.status=\"failed\"}}}a.BundleProvider=_,_.__name__=\"BundleProvider\",a.default_provider=new _},\n", + " function _(t,e,a,s,n){var r=this&&this.__createBinding||(Object.create?function(t,e,a,s){void 0===s&&(s=a),Object.defineProperty(t,s,{enumerable:!0,get:function(){return e[a]}})}:function(t,e,a,s){void 0===s&&(s=a),t[s]=e[a]}),i=this&&this.__setModuleDefault||(Object.create?function(t,e){Object.defineProperty(t,\"default\",{enumerable:!0,value:e})}:function(t,e){t.default=e}),d=this&&this.__importStar||function(t){if(t&&t.__esModule)return t;var e={};if(null!=t)for(var a in t)\"default\"!==a&&Object.prototype.hasOwnProperty.call(t,a)&&r(e,t,a);return i(e,t),e};s();const o=t(15),u=t(138);class c{constructor(){this.ready=new o.Signal0(this,\"ready\"),this.status=\"not_started\"}}a.MathJaxProvider=c,c.__name__=\"MathJaxProvider\";class h extends c{get MathJax(){return null}async fetch(){this.status=\"failed\"}}a.NoProvider=h,h.__name__=\"NoProvider\";class l extends c{get MathJax(){return\"undefined\"!=typeof MathJax?MathJax:null}async fetch(){const t=document.createElement(\"script\");t.src=\"https://cdn.jsdelivr.net/npm/mathjax@3/es5/tex-svg.js\",t.onload=()=>{this.status=\"loaded\",this.ready.emit()},t.onerror=()=>{this.status=\"failed\"},this.status=\"loading\",document.head.appendChild(t)}}a.CDNProvider=l,l.__name__=\"CDNProvider\";class _ extends c{get MathJax(){return this._mathjax}async fetch(){this.status=\"loading\";try{const e=await(0,u.load_module)(Promise.resolve().then((()=>d(t(519)))));this._mathjax=e,this.status=\"loaded\",this.ready.emit()}catch(t){this.status=\"failed\"}}}a.BundleProvider=_,_.__name__=\"BundleProvider\",a.default_provider=new _},\n", " function _(n,r,o,t,c){t(),o.load_module=async function(n){try{return await n}catch(n){if((r=n)instanceof Error&&\"code\"in r&&\"MODULE_NOT_FOUND\"===n.code)return null;throw n}var r}},\n", " function _(e,t,i,n,s){var a;n();const x=e(133),_=e(120);class l extends x.BaseTextView{initialize(){super.initialize(),this._has_finished=!0}graphics(){return new _.TextBox({text:this.model.text})}}i.PlainTextView=l,l.__name__=\"PlainTextView\";class r extends x.BaseText{constructor(e){super(e)}}i.PlainText=r,a=r,r.__name__=\"PlainText\",a.prototype.default_view=l},\n", " function _(t,s,o,e,i){e();const r=t(1);var a;const l=t(128),_=t(141),n=t(142),p=(0,r.__importStar)(t(48)),c=t(20),h=t(120),m=t(8);class u extends l.AxisView{_paint(t,s,o){this._draw_group_separators(t,s,o)}_draw_group_separators(t,s,o){const[e]=this.ranges,[i,r]=this.computed_bounds;if(!e.tops||e.tops.length<2||!this.visuals.separator_line.doit)return;const a=this.dimension,l=(a+1)%2,_=[[],[]];let n=0;for(let t=0;ti&&pnew h.GraphicsBoxes(t.map((t=>(0,m.isString)(t)?new h.TextBox({text:t}):t))),_=t=>l(this.model.formatter.doFormat(t,this));if(1==t.levels){const t=_(i.major);a.push([t,r.major,this.model.major_label_orientation,this.visuals.major_label_text])}else if(2==t.levels){const t=_(i.major.map((t=>t[1])));a.push([t,r.major,this.model.major_label_orientation,this.visuals.major_label_text]),a.push([l(i.tops),r.tops,this.model.group_label_orientation,this.visuals.group_text])}else if(3==t.levels){const t=_(i.major.map((t=>t[2]))),s=i.mids.map((t=>t[1]));a.push([t,r.major,this.model.major_label_orientation,this.visuals.major_label_text]),a.push([l(s),r.mids,this.model.subgroup_label_orientation,this.visuals.subgroup_text]),a.push([l(i.tops),r.tops,this.model.group_label_orientation,this.visuals.group_text])}return a}get tick_coords(){const t=this.dimension,s=(t+1)%2,[o]=this.ranges,[e,i]=this.computed_bounds,r=this.model.ticker.get_ticks(e,i,o,this.loc),a={major:[[],[]],mids:[[],[]],tops:[[],[]],minor:[[],[]]};return a.major[t]=r.major,a.major[s]=r.major.map((()=>this.loc)),3==o.levels&&(a.mids[t]=r.mids,a.mids[s]=r.mids.map((()=>this.loc))),o.levels>1&&(a.tops[t]=r.tops,a.tops[s]=r.tops.map((()=>this.loc))),a}}o.CategoricalAxisView=u,u.__name__=\"CategoricalAxisView\";class d extends l.Axis{constructor(t){super(t)}}o.CategoricalAxis=d,a=d,d.__name__=\"CategoricalAxis\",a.prototype.default_view=u,a.mixins([[\"separator_\",p.Line],[\"group_\",p.Text],[\"subgroup_\",p.Text]]),a.define((({Number:t,Or:s})=>({group_label_orientation:[s(c.TickLabelOrientation,t),\"parallel\"],subgroup_label_orientation:[s(c.TickLabelOrientation,t),\"parallel\"]}))),a.override({ticker:()=>new _.CategoricalTicker,formatter:()=>new n.CategoricalTickFormatter,separator_line_color:\"lightgrey\",separator_line_width:2,group_text_font_style:\"bold\",group_text_font_size:\"11px\",group_text_color:\"grey\",subgroup_text_font_style:\"bold\",subgroup_text_font_size:\"11px\"})},\n", @@ -565,11 +584,11 @@ " function _(t,e,o,n,s){var l;n();const c=t(173),i=t(175),a=t(9),h=t(8);class r extends c.ColorMapper{constructor(t){super(t),this._scan_data=null}connect_signals(){super.connect_signals();const t=()=>{for(const[t]of this.domain)this.connect(t.view.change,(()=>this.update_data())),this.connect(t.data_source.selected.change,(()=>this.update_data()))};this.connect(this.properties.domain.change,(()=>t())),t()}update_data(){const{domain:t,palette:e}=this,o=[...this._collect(t)];this._scan_data=this.scan(o,e.length),this.metrics_change.emit(),this.change.emit()}get metrics(){return null==this._scan_data&&this.update_data(),this._scan_data}*_collect(t){for(const[e,o]of t)for(const t of(0,h.isArray)(o)?o:[o]){let o=e.data_source.get_column(t);o=e.view.indices.select(o);const n=e.view.masked,s=e.data_source.selected.indices;let l;if(null!=n&&s.length>0?l=(0,a.intersection)([...n],s):null!=n?l=[...n]:s.length>0&&(l=s),null!=l&&(o=(0,a.map)(l,(t=>o[t]))),o.length>0&&!(0,h.isNumber)(o[0]))for(const t of o)yield*t;else yield*o}}_v_compute(t,e,o,n){const{nan_color:s}=n;let{low_color:l,high_color:c}=n;null==l&&(l=o[0]),null==c&&(c=o[o.length-1]);const{domain:i}=this,h=(0,a.is_empty)(i)?t:[...this._collect(i)];this._scan_data=this.scan(h,o.length),this.metrics_change.emit();for(let n=0,i=t.length;n({high:[a(t),null],low:[a(t),null],high_color:[a(n),null],low_color:[a(n),null],domain:[c(l(o(i.GlyphRenderer),s(e,c(e)))),[]]})))},\n", " function _(e,r,t,n,o){var a;n();const c=e(174),i=e(15),_=e(24),l=e(22),s=e(27);function p(e){return(0,l.encode_rgba)((0,l.color2rgba)(e))}function u(e){const r=new Uint32Array(e.length);for(let t=0,n=e.length;te))),r}get rgba_mapper(){const e=this,r=u(this.palette),t=this._colors(p);return{v_compute(n){const o=new _.ColorArray(n.length);return e._v_compute(n,o,r,t),new Uint8ClampedArray((0,s.to_big_endian)(o).buffer)}}}_colors(e){return{nan_color:e(this.nan_color)}}}t.ColorMapper=h,a=h,h.__name__=\"ColorMapper\",a.define((({Color:e,Array:r})=>({palette:[r(e)],nan_color:[e,\"gray\"]})))},\n", " function _(r,e,n,s,o){s();const p=r(56);class t extends p.Transform{constructor(r){super(r)}compute(r){throw new Error(\"mapping single values is not supported\")}}n.Mapper=t,t.__name__=\"Mapper\"},\n", - " function _(e,t,i,s,l){var h;s();const n=e(176),o=e(177),a=e(186),c=e(187),_=e(189),r=e(179),d=e(70),p=e(190),g=e(24),u=e(12),y=e(13),m=e(113),v=e(67),f={fill:{},line:{}},w={fill:{fill_alpha:.3,fill_color:\"grey\"},line:{line_alpha:.3,line_color:\"grey\"}},b={fill:{fill_alpha:.2},line:{}},V={fill:{},line:{}},x={fill:{fill_alpha:.2},line:{}};class G extends n.DataRendererView{get glyph_view(){return this.glyph}async lazy_initialize(){var e;await super.lazy_initialize();const t=this.model.glyph;this.glyph=await this.build_glyph_view(t);const i=\"fill\"in this.glyph.visuals,s=\"line\"in this.glyph.visuals,l=Object.assign({},t.attributes);function h(e){const h=(0,y.clone)(l);return i&&(0,y.extend)(h,e.fill),s&&(0,y.extend)(h,e.line),new t.constructor(h)}function n(e,t){return t instanceof r.Glyph?t:h(\"auto\"==t?e:{fill:{},line:{}})}delete l.id;let{selection_glyph:o,nonselection_glyph:a,hover_glyph:c,muted_glyph:_}=this.model;o=n(f,o),this.selection_glyph=await this.build_glyph_view(o),a=n(b,a),this.nonselection_glyph=await this.build_glyph_view(a),c=n(V,c),this.hover_glyph=await this.build_glyph_view(c),_=n(x,_),this.muted_glyph=await this.build_glyph_view(_);const d=n(w,\"auto\");this.decimated_glyph=await this.build_glyph_view(d),this.selection_glyph.set_base(this.glyph),this.nonselection_glyph.set_base(this.glyph),null===(e=this.hover_glyph)||void 0===e||e.set_base(this.glyph),this.muted_glyph.set_base(this.glyph),this.decimated_glyph.set_base(this.glyph),this.set_data()}async build_glyph_view(e){return(0,m.build_view)(e,{parent:this})}remove(){var e;this.glyph.remove(),this.selection_glyph.remove(),this.nonselection_glyph.remove(),null===(e=this.hover_glyph)||void 0===e||e.remove(),this.muted_glyph.remove(),this.decimated_glyph.remove(),super.remove()}connect_signals(){super.connect_signals();const e=()=>this.request_render(),t=()=>this.update_data();this.connect(this.model.change,e),this.connect(this.glyph.model.change,t),this.connect(this.selection_glyph.model.change,t),this.connect(this.nonselection_glyph.model.change,t),null!=this.hover_glyph&&this.connect(this.hover_glyph.model.change,t),this.connect(this.muted_glyph.model.change,t),this.connect(this.decimated_glyph.model.change,t),this.connect(this.model.data_source.change,t),this.connect(this.model.data_source.streaming,t),this.connect(this.model.data_source.patching,(e=>this.update_data(e))),this.connect(this.model.data_source.selected.change,e),this.connect(this.model.data_source._select,e),null!=this.hover_glyph&&this.connect(this.model.data_source.inspect,e),this.connect(this.model.properties.view.change,t),this.connect(this.model.view.properties.indices.change,t),this.connect(this.model.view.properties.masked.change,(()=>this.set_visuals())),this.connect(this.model.properties.visible.change,(()=>this.plot_view.invalidate_dataranges=!0));const{x_ranges:i,y_ranges:s}=this.plot_view.frame;for(const[,e]of i)e instanceof v.FactorRange&&this.connect(e.change,t);for(const[,e]of s)e instanceof v.FactorRange&&this.connect(e.change,t);const{transformchange:l,exprchange:h}=this.model.glyph;this.connect(l,t),this.connect(h,t)}_update_masked_indices(){const e=this.glyph.mask_data();return this.model.view.masked=e,e}update_data(e){this.set_data(e),this.request_render()}set_data(e){const t=this.model.data_source;this.all_indices=this.model.view.indices;const{all_indices:i}=this;this.glyph.set_data(t,i,e),this.set_visuals(),this._update_masked_indices();const{lod_factor:s}=this.plot_model,l=this.all_indices.count;this.decimated=new g.Indices(l);for(let e=0;e!n||n.is_empty()?[]:n.selected_glyph?this.model.view.convert_indices_from_subset(i):n.indices.length>0?n.indices:Object.keys(n.multiline_indices).map((e=>parseInt(e))))()),d=(0,u.filter)(i,(e=>r.has(t[e]))),{lod_threshold:p}=this.plot_model;let g,y,m;if(null!=this.model.document&&this.model.document.interactive_duration()>0&&!e&&null!=p&&t.length>p?(i=[...this.decimated],g=this.decimated_glyph,y=this.decimated_glyph,m=this.selection_glyph):(g=this.model.muted&&null!=this.muted_glyph?this.muted_glyph:this.glyph,y=this.nonselection_glyph,m=this.selection_glyph),null!=this.hover_glyph&&d.length){const e=new Set(i);for(const t of d)e.delete(t);i=[...e]}if(h.length){const e={};for(const t of h)e[t]=!0;const l=new Array,n=new Array;if(this.glyph instanceof o.LineView)for(const i of t)null!=e[i]?l.push(i):n.push(i);else for(const s of i)null!=e[t[s]]?l.push(s):n.push(s);y.render(s,n),m.render(s,l),null!=this.hover_glyph&&(this.glyph instanceof o.LineView?this.hover_glyph.render(s,this.model.view.convert_indices_from_subset(d)):this.hover_glyph.render(s,d))}else if(this.glyph instanceof o.LineView)this.hover_glyph&&d.length?this.hover_glyph.render(s,this.model.view.convert_indices_from_subset(d)):g.render(s,t);else if(this.glyph instanceof a.PatchView||this.glyph instanceof c.HAreaView||this.glyph instanceof _.VAreaView)if(0==n.selected_glyphs.length||null==this.hover_glyph)g.render(s,t);else for(const e of n.selected_glyphs)e==this.glyph.model&&this.hover_glyph.render(s,t);else g.render(s,i),this.hover_glyph&&d.length&&this.hover_glyph.render(s,d);s.restore()}draw_legend(e,t,i,s,l,h,n,o){0!=this.glyph.data_size&&(null==o&&(o=this.model.get_reference_point(h,n)),this.glyph.draw_legend_for_index(e,{x0:t,x1:i,y0:s,y1:l},o))}hit_test(e){if(!this.model.visible)return null;const t=this.glyph.hit_test(e);return null==t?null:this.model.view.convert_selection_from_subset(t)}}i.GlyphRendererView=G,G.__name__=\"GlyphRendererView\";class R extends n.DataRenderer{constructor(e){super(e)}initialize(){super.initialize(),this.view.source!=this.data_source&&(this.view.source=this.data_source,this.view.compute_indices())}get_reference_point(e,t){if(null!=e){const i=this.data_source.get_column(e);if(null!=i)for(const[e,s]of Object.entries(this.view.indices_map))if(i[parseInt(e)]==t)return s}return 0}get_selection_manager(){return this.data_source.selection_manager}}i.GlyphRenderer=R,h=R,R.__name__=\"GlyphRenderer\",h.prototype.default_view=G,h.define((({Boolean:e,Auto:t,Or:i,Ref:s,Null:l,Nullable:h})=>({data_source:[s(d.ColumnarDataSource)],view:[s(p.CDSView),e=>new p.CDSView({source:e.data_source})],glyph:[s(r.Glyph)],hover_glyph:[h(s(r.Glyph)),null],nonselection_glyph:[i(s(r.Glyph),t,l),\"auto\"],selection_glyph:[i(s(r.Glyph),t,l),\"auto\"],muted_glyph:[i(s(r.Glyph),t,l),\"auto\"],muted:[e,!1]})))},\n", + " function _(e,t,i,s,l){var h;s();const n=e(176),o=e(177),a=e(186),c=e(187),_=e(189),r=e(179),d=e(70),p=e(190),g=e(24),u=e(12),y=e(13),m=e(113),v=e(67),f={fill:{},line:{}},w={fill:{fill_alpha:.3,fill_color:\"grey\"},line:{line_alpha:.3,line_color:\"grey\"}},b={fill:{fill_alpha:.2},line:{}},V={fill:{fill_alpha:.2},line:{}};class x extends n.DataRendererView{get glyph_view(){return this.glyph}async lazy_initialize(){var e;await super.lazy_initialize();const t=this.model.glyph;this.glyph=await this.build_glyph_view(t);const i=\"fill\"in this.glyph.visuals,s=\"line\"in this.glyph.visuals,l=Object.assign({},t.attributes);function h(e){const h=(0,y.clone)(l);return i&&(0,y.extend)(h,e.fill),s&&(0,y.extend)(h,e.line),new t.constructor(h)}function n(e,t){return t instanceof r.Glyph?t:h(\"auto\"==t?e:{fill:{},line:{}})}delete l.id;let{selection_glyph:o,nonselection_glyph:a,hover_glyph:c,muted_glyph:_}=this.model;o=n(f,o),this.selection_glyph=await this.build_glyph_view(o),a=n(b,a),this.nonselection_glyph=await this.build_glyph_view(a),null!=c&&(this.hover_glyph=await this.build_glyph_view(c)),_=n(V,_),this.muted_glyph=await this.build_glyph_view(_);const d=n(w,\"auto\");this.decimated_glyph=await this.build_glyph_view(d),this.selection_glyph.set_base(this.glyph),this.nonselection_glyph.set_base(this.glyph),null===(e=this.hover_glyph)||void 0===e||e.set_base(this.glyph),this.muted_glyph.set_base(this.glyph),this.decimated_glyph.set_base(this.glyph),this.set_data()}async build_glyph_view(e){return(0,m.build_view)(e,{parent:this})}remove(){var e;this.glyph.remove(),this.selection_glyph.remove(),this.nonselection_glyph.remove(),null===(e=this.hover_glyph)||void 0===e||e.remove(),this.muted_glyph.remove(),this.decimated_glyph.remove(),super.remove()}connect_signals(){super.connect_signals();const e=()=>this.request_render(),t=()=>this.update_data();this.connect(this.model.change,e),this.connect(this.glyph.model.change,t),this.connect(this.selection_glyph.model.change,t),this.connect(this.nonselection_glyph.model.change,t),null!=this.hover_glyph&&this.connect(this.hover_glyph.model.change,t),this.connect(this.muted_glyph.model.change,t),this.connect(this.decimated_glyph.model.change,t),this.connect(this.model.data_source.change,t),this.connect(this.model.data_source.streaming,t),this.connect(this.model.data_source.patching,(e=>this.update_data(e))),this.connect(this.model.data_source.selected.change,e),this.connect(this.model.data_source._select,e),null!=this.hover_glyph&&this.connect(this.model.data_source.inspect,e),this.connect(this.model.properties.view.change,t),this.connect(this.model.view.properties.indices.change,t),this.connect(this.model.view.properties.masked.change,(()=>this.set_visuals())),this.connect(this.model.properties.visible.change,(()=>this.plot_view.invalidate_dataranges=!0));const{x_ranges:i,y_ranges:s}=this.plot_view.frame;for(const[,e]of i)e instanceof v.FactorRange&&this.connect(e.change,t);for(const[,e]of s)e instanceof v.FactorRange&&this.connect(e.change,t);const{transformchange:l,exprchange:h}=this.model.glyph;this.connect(l,t),this.connect(h,t)}_update_masked_indices(){const e=this.glyph.mask_data();return this.model.view.masked=e,e}update_data(e){this.set_data(e),this.request_render()}set_data(e){const t=this.model.data_source;this.all_indices=this.model.view.indices;const{all_indices:i}=this;this.glyph.set_data(t,i,e),this.set_visuals(),this._update_masked_indices();const{lod_factor:s}=this.plot_model,l=this.all_indices.count;this.decimated=new g.Indices(l);for(let e=0;e!n||n.is_empty()?[]:n.selected_glyph?this.model.view.convert_indices_from_subset(i):n.indices.length>0?n.indices:Object.keys(n.multiline_indices).map((e=>parseInt(e))))()),d=(0,u.filter)(i,(e=>r.has(t[e]))),{lod_threshold:p}=this.plot_model;let g,y,m;if(null!=this.model.document&&this.model.document.interactive_duration()>0&&!e&&null!=p&&t.length>p?(i=[...this.decimated],g=this.decimated_glyph,y=this.decimated_glyph,m=this.selection_glyph):(g=this.model.muted?this.muted_glyph:this.glyph,y=this.nonselection_glyph,m=this.selection_glyph),null!=this.hover_glyph&&d.length){const e=new Set(i);for(const t of d)e.delete(t);i=[...e]}if(h.length){const e={};for(const t of h)e[t]=!0;const l=new Array,n=new Array;if(this.glyph instanceof o.LineView)for(const i of t)null!=e[i]?l.push(i):n.push(i);else for(const s of i)null!=e[t[s]]?l.push(s):n.push(s);y.render(s,n),m.render(s,l),null!=this.hover_glyph&&(this.glyph instanceof o.LineView?this.hover_glyph.render(s,this.model.view.convert_indices_from_subset(d)):this.hover_glyph.render(s,d))}else if(this.glyph instanceof o.LineView)this.hover_glyph&&d.length?this.hover_glyph.render(s,this.model.view.convert_indices_from_subset(d)):g.render(s,t);else if(this.glyph instanceof a.PatchView||this.glyph instanceof c.HAreaView||this.glyph instanceof _.VAreaView)if(0==n.selected_glyphs.length||null==this.hover_glyph)g.render(s,t);else for(const e of n.selected_glyphs)e==this.glyph.model&&this.hover_glyph.render(s,t);else g.render(s,i),this.hover_glyph&&d.length&&this.hover_glyph.render(s,d);s.restore()}draw_legend(e,t,i,s,l,h,n,o){0!=this.glyph.data_size&&(null==o&&(o=this.model.get_reference_point(h,n)),this.glyph.draw_legend_for_index(e,{x0:t,x1:i,y0:s,y1:l},o))}hit_test(e){if(!this.model.visible)return null;const t=this.glyph.hit_test(e);return null==t?null:this.model.view.convert_selection_from_subset(t)}}i.GlyphRendererView=x,x.__name__=\"GlyphRendererView\";class G extends n.DataRenderer{constructor(e){super(e)}initialize(){super.initialize(),this.view.source!=this.data_source&&(this.view.source=this.data_source,this.view.compute_indices())}get_reference_point(e,t){if(null!=e){const i=this.data_source.get_column(e);if(null!=i)for(const[e,s]of Object.entries(this.view.indices_map))if(i[parseInt(e)]==t)return s}return 0}get_selection_manager(){return this.data_source.selection_manager}}i.GlyphRenderer=G,h=G,G.__name__=\"GlyphRenderer\",h.prototype.default_view=x,h.define((({Boolean:e,Auto:t,Or:i,Ref:s,Null:l,Nullable:h})=>({data_source:[s(d.ColumnarDataSource)],view:[s(p.CDSView),e=>new p.CDSView({source:e.data_source})],glyph:[s(r.Glyph)],hover_glyph:[h(s(r.Glyph)),null],nonselection_glyph:[i(s(r.Glyph),t,l),\"auto\"],selection_glyph:[i(s(r.Glyph),t,l),\"auto\"],muted_glyph:[i(s(r.Glyph),t,l),\"auto\"],muted:[e,!1]})))},\n", " function _(e,r,t,a,n){var s;a();const c=e(41);class _ extends c.RendererView{get xscale(){return this.coordinates.x_scale}get yscale(){return this.coordinates.y_scale}}t.DataRendererView=_,_.__name__=\"DataRendererView\";class i extends c.Renderer{constructor(e){super(e)}get selection_manager(){return this.get_selection_manager()}}t.DataRenderer=i,s=i,i.__name__=\"DataRenderer\",s.override({level:\"glyph\"})},\n", - " function _(e,t,i,s,n){s();const l=e(1);var _;const r=e(178),o=e(184),a=(0,l.__importStar)(e(48)),h=(0,l.__importStar)(e(185)),c=e(72);class d extends r.XYGlyphView{async lazy_initialize(){await super.lazy_initialize();const{webgl:t}=this.renderer.plot_view.canvas_view;if(null==t?void 0:t.regl_wrapper.has_webgl){const{LineGL:i}=await Promise.resolve().then((()=>(0,l.__importStar)(e(421))));this.glglyph=new i(t.regl_wrapper,this)}}_render(e,t,i){const{sx:s,sy:n}=null!=i?i:this;let l=null;const _=e=>null!=l&&e-l!=1;let r=!0;e.beginPath();for(const i of t){const t=s[i],o=n[i];isFinite(t+o)?r||_(i)?(e.moveTo(t,o),r=!1):e.lineTo(t,o):r=!0,l=i}this.visuals.line.set_value(e),e.stroke()}_hit_point(e){const t=new c.Selection,i={x:e.sx,y:e.sy};let s=9999;const n=Math.max(2,this.line_width.value/2);for(let e=0,l=this.sx.length-1;e(0,l.__importStar)(e(426))));this.glglyph=new i(t.regl_wrapper,this)}}_render(e,t,i){const{sx:s,sy:n}=null!=i?i:this;let l=null;const _=e=>null!=l&&e-l!=1;let r=!0;e.beginPath();for(const i of t){const t=s[i],o=n[i];isFinite(t+o)?r||_(i)?(e.moveTo(t,o),r=!1):e.lineTo(t,o):r=!0,l=i}this.visuals.line.set_value(e),e.stroke()}_hit_point(e){const t=new c.Selection,i={x:e.sx,y:e.sy};let s=9999;const n=Math.max(2,this.line_width.value/2);for(let e=0,l=this.sx.length-1;e({x:[c.XCoordinateSpec,{field:\"x\"}],y:[c.YCoordinateSpec,{field:\"y\"}]})))},\n", - " function _(e,t,s,i,n){i();const r=e(1),a=(0,r.__importStar)(e(18)),o=(0,r.__importStar)(e(65)),_=(0,r.__importStar)(e(45)),l=e(42),c=e(53),h=e(19),d=e(24),u=e(8),f=e(180),p=e(12),g=e(26),y=e(181),x=e(67),v=e(72),{abs:b,ceil:m}=Math;class w extends l.View{constructor(){super(...arguments),this._index=null,this._data_size=null,this._nohit_warned=new Set}get renderer(){return this.parent}get has_webgl(){return null!=this.glglyph}get index(){const{_index:e}=this;if(null!=e)return e;throw new Error(`${this}.index_data() wasn't called`)}get data_size(){const{_data_size:e}=this;if(null!=e)return e;throw new Error(`${this}.set_data() wasn't called`)}initialize(){super.initialize(),this.visuals=new _.Visuals(this)}request_render(){this.parent.request_render()}get canvas(){return this.renderer.parent.canvas_view}render(e,t,s){var i;null!=this.glglyph&&(this.renderer.needs_webgl_blit=this.glglyph.render(e,t,null!==(i=this.base)&&void 0!==i?i:this),this.renderer.needs_webgl_blit)||this._render(e,t,null!=s?s:this.base)}has_finished(){return!0}notify_finished(){this.renderer.notify_finished()}_bounds(e){return e}bounds(){return this._bounds(this.index.bbox)}log_bounds(){const{x0:e,x1:t}=this.index.bounds(o.positive_x()),{y0:s,y1:i}=this.index.bounds(o.positive_y());return this._bounds({x0:e,y0:s,x1:t,y1:i})}get_anchor_point(e,t,[s,i]){switch(e){case\"center\":case\"center_center\":{const[e,n]=this.scenterxy(t,s,i);return{x:e,y:n}}default:return null}}scenterx(e,t,s){return this.scenterxy(e,t,s)[0]}scentery(e,t,s){return this.scenterxy(e,t,s)[1]}sdist(e,t,s,i=\"edge\",n=!1){const r=t.length,a=new d.ScreenArray(r),o=e.s_compute;if(\"center\"==i)for(let e=0;em(e))),a}draw_legend_for_index(e,t,s){}hit_test(e){switch(e.type){case\"point\":if(null!=this._hit_point)return this._hit_point(e);break;case\"span\":if(null!=this._hit_span)return this._hit_span(e);break;case\"rect\":if(null!=this._hit_rect)return this._hit_rect(e);break;case\"poly\":if(null!=this._hit_poly)return this._hit_poly(e)}return this._nohit_warned.has(e.type)||(h.logger.debug(`'${e.type}' selection not available for ${this.model.type}`),this._nohit_warned.add(e.type)),null}_hit_rect_against_index(e){const{sx0:t,sx1:s,sy0:i,sy1:n}=e,[r,a]=this.renderer.coordinates.x_scale.r_invert(t,s),[o,_]=this.renderer.coordinates.y_scale.r_invert(i,n),l=[...this.index.indices({x0:r,x1:a,y0:o,y1:_})];return new v.Selection({indices:l})}_project_data(){}*_iter_visuals(){for(const e of this.visuals)for(const t of e)(t instanceof a.VectorSpec||t instanceof a.ScalarSpec)&&(yield t)}set_base(e){e!=this&&e instanceof this.constructor&&(this.base=e)}_configure(e,t){Object.defineProperty(this,(0,u.isString)(e)?e:e.attr,Object.assign({configurable:!0,enumerable:!0},t))}set_visuals(e,t){var s;for(const s of this._iter_visuals()){const{base:i}=this;if(null!=i){const e=i.model.properties[s.attr];if(null!=e&&(0,g.is_equal)(s.get_value(),e.get_value())){this._configure(s,{get:()=>i[`${s.attr}`]});continue}}const n=s.uniform(e).select(t);this._configure(s,{value:n})}for(const e of this.visuals)e.update();this._set_visuals(),null===(s=this.glglyph)||void 0===s||s.set_visuals_changed()}_set_visuals(){}set_data(e,t,s){var i;const{x_source:n,y_source:r}=this.renderer.coordinates,o=new Set(this._iter_visuals());this._data_size=t.count;for(const s of this.model)if((s instanceof a.VectorSpec||s instanceof a.ScalarSpec)&&!o.has(s))if(s instanceof a.BaseCoordinateSpec){const i=s.array(e);let o=t.select(i);const _=\"x\"==s.dimension?n:r;if(_ instanceof x.FactorRange)if(s instanceof a.CoordinateSpec)o=_.v_synthetic(o);else if(s instanceof a.CoordinateSeqSpec)for(let e=0;em(e))),a}draw_legend_for_index(e,t,s){}hit_test(e){switch(e.type){case\"point\":if(null!=this._hit_point)return this._hit_point(e);break;case\"span\":if(null!=this._hit_span)return this._hit_span(e);break;case\"rect\":if(null!=this._hit_rect)return this._hit_rect(e);break;case\"poly\":if(null!=this._hit_poly)return this._hit_poly(e)}return this._nohit_warned.has(e.type)||(h.logger.debug(`'${e.type}' selection not available for ${this.model.type}`),this._nohit_warned.add(e.type)),null}_hit_rect_against_index(e){const{sx0:t,sx1:s,sy0:i,sy1:n}=e,[r,a]=this.renderer.coordinates.x_scale.r_invert(t,s),[o,_]=this.renderer.coordinates.y_scale.r_invert(i,n),l=[...this.index.indices({x0:r,x1:a,y0:o,y1:_})];return new v.Selection({indices:l})}_project_data(){}*_iter_visuals(){for(const e of this.visuals)for(const t of e)(t instanceof a.VectorSpec||t instanceof a.ScalarSpec)&&(yield t)}set_base(e){e!=this&&e instanceof this.constructor&&(this.base=e)}_configure(e,t){Object.defineProperty(this,(0,u.isString)(e)?e:e.attr,Object.assign({configurable:!0,enumerable:!0},t))}set_visuals(e,t){var s;for(const s of this._iter_visuals()){const{base:i}=this;if(null!=i){const e=i.model.properties[s.attr];if(null!=e&&(0,g.is_equal)(s.get_value(),e.get_value())){this._configure(s,{get:()=>i[`${s.attr}`]});continue}}const n=s.uniform(e).select(t);this._configure(s,{value:n})}for(const e of this.visuals)e.update();null===(s=this.glglyph)||void 0===s||s.set_visuals_changed()}set_data(e,t,s){var i;const{x_source:n,y_source:r}=this.renderer.coordinates,o=new Set(this._iter_visuals());this._data_size=t.count;for(const s of this.model)if((s instanceof a.VectorSpec||s instanceof a.ScalarSpec)&&!o.has(s))if(s instanceof a.BaseCoordinateSpec){const i=s.array(e);let o=t.select(i);const _=\"x\"==s.dimension?n:r;if(_ instanceof x.FactorRange)if(s instanceof a.CoordinateSpec)o=_.v_synthetic(o);else if(s instanceof a.CoordinateSeqSpec)for(let e=0;e{const s=new Uint32Array(r);for(let a=0;a>1;t[s]>i?e=s:n=s+1}return t[n]}class r extends d.default{get boxes(){return this._boxes}search_indices(i,t,n,e){if(this._pos!==this._boxes.length)throw new Error(\"Data not yet indexed - call index.finish().\");let s=this._boxes.length-4;const d=[],x=new o.Indices(this.numItems);for(;void 0!==s;){const o=Math.min(s+4*this.nodeSize,h(s,this._levelBounds));for(let h=s;h>2],r=this._boxes[h+0],l=this._boxes[h+1],a=this._boxes[h+2],_=this._boxes[h+3];na||t>_||(s<4*this.numItems?x.set(o):d.push(o)))}s=d.pop()}return x}}r.__name__=\"_FlatBush\";class l{constructor(i){this.index=null,i>0&&(this.index=new r(i))}add_rect(i,t,n,e){var s;isFinite(i+t+n+e)?null===(s=this.index)||void 0===s||s.add(i,t,n,e):this.add_empty()}add_point(i,t){var n;isFinite(i+t)?null===(n=this.index)||void 0===n||n.add(i,t,i,t):this.add_empty()}add_empty(){var i;null===(i=this.index)||void 0===i||i.add(1/0,1/0,-1/0,-1/0)}finish(){var i;null===(i=this.index)||void 0===i||i.finish()}_normalize(i){let{x0:t,y0:n,x1:e,y1:s}=i;return t>e&&([t,e]=[e,t]),n>s&&([n,s]=[s,n]),{x0:t,y0:n,x1:e,y1:s}}get bbox(){if(null==this.index)return(0,x.empty)();{const{minX:i,minY:t,maxX:n,maxY:e}=this.index;return{x0:i,y0:t,x1:n,y1:e}}}indices(i){if(null==this.index)return new o.Indices(0);{const{x0:t,y0:n,x1:e,y1:s}=this._normalize(i);return this.index.search_indices(t,n,e,s)}}bounds(i){const t=(0,x.empty)();if(null==this.index)return t;const{boxes:n}=this.index;for(const e of this.indices(i)){const s=n[4*e+0],d=n[4*e+1],o=n[4*e+2],x=n[4*e+3];s>=i.x0&&st.x1&&(t.x1=o),d>=i.y0&&dt.y1&&(t.y1=x)}return t}}n.SpatialIndex=l,l.__name__=\"SpatialIndex\"},\n", " function _(t,s,i,e,h){e();const n=(0,t(1).__importDefault)(t(183)),o=[Int8Array,Uint8Array,Uint8ClampedArray,Int16Array,Uint16Array,Int32Array,Uint32Array,Float32Array,Float64Array];class r{static from(t){if(!(t instanceof ArrayBuffer))throw new Error(\"Data must be an instance of ArrayBuffer.\");const[s,i]=new Uint8Array(t,0,2);if(251!==s)throw new Error(\"Data does not appear to be in a Flatbush format.\");if(i>>4!=3)throw new Error(`Got v${i>>4} data when expected v3.`);const[e]=new Uint16Array(t,2,1),[h]=new Uint32Array(t,4,1);return new r(h,e,o[15&i],t)}constructor(t,s=16,i=Float64Array,e){if(void 0===t)throw new Error(\"Missing required argument: numItems.\");if(isNaN(t)||t<=0)throw new Error(`Unpexpected numItems value: ${t}.`);this.numItems=+t,this.nodeSize=Math.min(Math.max(+s,2),65535);let h=t,r=h;this._levelBounds=[4*h];do{h=Math.ceil(h/this.nodeSize),r+=h,this._levelBounds.push(4*r)}while(1!==h);this.ArrayType=i||Float64Array,this.IndexArrayType=r<16384?Uint16Array:Uint32Array;const a=o.indexOf(this.ArrayType),_=4*r*this.ArrayType.BYTES_PER_ELEMENT;if(a<0)throw new Error(`Unexpected typed array class: ${i}.`);e&&e instanceof ArrayBuffer?(this.data=e,this._boxes=new this.ArrayType(this.data,8,4*r),this._indices=new this.IndexArrayType(this.data,8+_,r),this._pos=4*r,this.minX=this._boxes[this._pos-4],this.minY=this._boxes[this._pos-3],this.maxX=this._boxes[this._pos-2],this.maxY=this._boxes[this._pos-1]):(this.data=new ArrayBuffer(8+_+r*this.IndexArrayType.BYTES_PER_ELEMENT),this._boxes=new this.ArrayType(this.data,8,4*r),this._indices=new this.IndexArrayType(this.data,8+_,r),this._pos=0,this.minX=1/0,this.minY=1/0,this.maxX=-1/0,this.maxY=-1/0,new Uint8Array(this.data,0,2).set([251,48+a]),new Uint16Array(this.data,2,1)[0]=s,new Uint32Array(this.data,4,1)[0]=t),this._queue=new n.default}add(t,s,i,e){const h=this._pos>>2;return this._indices[h]=h,this._boxes[this._pos++]=t,this._boxes[this._pos++]=s,this._boxes[this._pos++]=i,this._boxes[this._pos++]=e,tthis.maxX&&(this.maxX=i),e>this.maxY&&(this.maxY=e),h}finish(){if(this._pos>>2!==this.numItems)throw new Error(`Added ${this._pos>>2} items when expected ${this.numItems}.`);if(this.numItems<=this.nodeSize)return this._boxes[this._pos++]=this.minX,this._boxes[this._pos++]=this.minY,this._boxes[this._pos++]=this.maxX,void(this._boxes[this._pos++]=this.maxY);const t=this.maxX-this.minX,s=this.maxY-this.minY,i=new Uint32Array(this.numItems);for(let e=0;e>2]=t,this._boxes[this._pos++]=e,this._boxes[this._pos++]=h,this._boxes[this._pos++]=n,this._boxes[this._pos++]=o}}}search(t,s,i,e,h){if(this._pos!==this._boxes.length)throw new Error(\"Data not yet indexed - call index.finish().\");let n=this._boxes.length-4;const o=[],r=[];for(;void 0!==n;){const a=Math.min(n+4*this.nodeSize,_(n,this._levelBounds));for(let _=n;_>2];ithis._boxes[_+2]||s>this._boxes[_+3]||(n<4*this.numItems?(void 0===h||h(a))&&r.push(a):o.push(a)))}n=o.pop()}return r}neighbors(t,s,i=1/0,e=1/0,h){if(this._pos!==this._boxes.length)throw new Error(\"Data not yet indexed - call index.finish().\");let n=this._boxes.length-4;const o=this._queue,r=[],x=e*e;for(;void 0!==n;){const e=Math.min(n+4*this.nodeSize,_(n,this._levelBounds));for(let i=n;i>2],r=a(t,this._boxes[i],this._boxes[i+2]),_=a(s,this._boxes[i+1],this._boxes[i+3]),x=r*r+_*_;n<4*this.numItems?(void 0===h||h(e))&&o.push(-e-1,x):o.push(e,x)}for(;o.length&&o.peek()<0;){if(o.peekValue()>x)return o.clear(),r;if(r.push(-o.pop()-1),r.length===i)return o.clear(),r}n=o.pop()}return o.clear(),r}}function a(t,s,i){return t>1;s[h]>t?e=h:i=h+1}return s[i]}function x(t,s,i,e,h,n){if(Math.floor(e/n)>=Math.floor(h/n))return;const o=t[e+h>>1];let r=e-1,a=h+1;for(;;){do{r++}while(t[r]o);if(r>=a)break;d(t,s,i,r,a)}x(t,s,i,e,a,n),x(t,s,i,a+1,h,n)}function d(t,s,i,e,h){const n=t[e];t[e]=t[h],t[h]=n;const o=4*e,r=4*h,a=s[o],_=s[o+1],x=s[o+2],d=s[o+3];s[o]=s[r],s[o+1]=s[r+1],s[o+2]=s[r+2],s[o+3]=s[r+3],s[r]=a,s[r+1]=_,s[r+2]=x,s[r+3]=d;const m=i[e];i[e]=i[h],i[h]=m}function m(t,s){let i=t^s,e=65535^i,h=65535^(t|s),n=t&(65535^s),o=i|e>>1,r=i>>1^i,a=h>>1^e&n>>1^h,_=i&h>>1^n>>1^n;i=o,e=r,h=a,n=_,o=i&i>>2^e&e>>2,r=i&e>>2^e&(i^e)>>2,a^=i&h>>2^e&n>>2,_^=e&h>>2^(i^e)&n>>2,i=o,e=r,h=a,n=_,o=i&i>>4^e&e>>4,r=i&e>>4^e&(i^e)>>4,a^=i&h>>4^e&n>>4,_^=e&h>>4^(i^e)&n>>4,i=o,e=r,h=a,n=_,a^=i&h>>8^e&n>>8,_^=e&h>>8^(i^e)&n>>8,i=a^a>>1,e=_^_>>1;let x=t^s,d=e|65535^(x|i);return x=16711935&(x|x<<8),x=252645135&(x|x<<4),x=858993459&(x|x<<2),x=1431655765&(x|x<<1),d=16711935&(d|d<<8),d=252645135&(d|d<<4),d=858993459&(d|d<<2),d=1431655765&(d|d<<1),(d<<1|x)>>>0}i.default=r},\n", @@ -577,9 +596,9 @@ " function _(e,n,a,t,i){t();const l=(0,e(1).__importStar)(e(185));function r(e,n,{x0:a,x1:t,y0:i,y1:l},r){n.save(),n.beginPath(),n.moveTo(a,(i+l)/2),n.lineTo(t,(i+l)/2),e.line.apply(n,r),n.restore()}function c(e,n,{x0:a,x1:t,y0:i,y1:l},r){var c,o;const _=.1*Math.abs(t-a),s=.1*Math.abs(l-i),y=a+_,p=t-_,g=i+s,h=l-s;n.beginPath(),n.rect(y,g,p-y,h-g),e.fill.apply(n,r),null===(c=e.hatch)||void 0===c||c.apply(n,r),null===(o=e.line)||void 0===o||o.apply(n,r)}a.generic_line_scalar_legend=function(e,n,{x0:a,x1:t,y0:i,y1:l}){n.save(),n.beginPath(),n.moveTo(a,(i+l)/2),n.lineTo(t,(i+l)/2),e.line.apply(n),n.restore()},a.generic_line_vector_legend=r,a.generic_line_legend=r,a.generic_area_scalar_legend=function(e,n,{x0:a,x1:t,y0:i,y1:l}){var r,c;const o=.1*Math.abs(t-a),_=.1*Math.abs(l-i),s=a+o,y=t-o,p=i+_,g=l-_;n.beginPath(),n.rect(s,p,y-s,g-p),e.fill.apply(n),null===(r=e.hatch)||void 0===r||r.apply(n),null===(c=e.line)||void 0===c||c.apply(n)},a.generic_area_vector_legend=c,a.generic_area_legend=c,a.line_interpolation=function(e,n,a,t,i,r){const{sx:c,sy:o}=n;let _,s,y,p;\"point\"==n.type?([y,p]=e.yscale.r_invert(o-1,o+1),[_,s]=e.xscale.r_invert(c-1,c+1)):\"v\"==n.direction?([y,p]=e.yscale.r_invert(o,o),[_,s]=[Math.min(a-1,i-1),Math.max(a+1,i+1)]):([_,s]=e.xscale.r_invert(c,c),[y,p]=[Math.min(t-1,r-1),Math.max(t+1,r+1)]);const{x:g,y:h}=l.check_2_segments_intersect(_,y,s,p,a,t,i,r);return[g,h]}},\n", " function _(t,n,e,i,r){function s(t,n){return(t.x-n.x)**2+(t.y-n.y)**2}function o(t,n,e){const i=s(n,e);if(0==i)return s(t,n);const r=((t.x-n.x)*(e.x-n.x)+(t.y-n.y)*(e.y-n.y))/i;if(r<0)return s(t,n);if(r>1)return s(t,e);return s(t,{x:n.x+r*(e.x-n.x),y:n.y+r*(e.y-n.y)})}i(),e.point_in_poly=function(t,n,e,i){let r=!1,s=e[e.length-1],o=i[i.length-1];for(let u=0;u0&&_<1&&h>0&&h<1,x:t+_*(e-t),y:n+_*(i-n)}}}},\n", " function _(t,s,e,i,a){i();const l=t(1);var n;const _=t(178),o=t(184),c=(0,l.__importStar)(t(185)),h=(0,l.__importStar)(t(48)),r=t(72);class p extends _.XYGlyphView{_render(t,s,e){const{sx:i,sy:a}=null!=e?e:this;let l=!0;t.beginPath();for(const e of s){const s=i[e],n=a[e];isFinite(s+n)?l?(t.moveTo(s,n),l=!1):t.lineTo(s,n):(t.closePath(),l=!0)}t.closePath(),this.visuals.fill.apply(t),this.visuals.hatch.apply(t),this.visuals.line.apply(t)}draw_legend_for_index(t,s,e){(0,o.generic_area_scalar_legend)(this.visuals,t,s)}_hit_point(t){const s=new r.Selection;return c.point_in_poly(t.sx,t.sy,this.sx,this.sy)&&(s.add_to_selected_glyphs(this.model),s.view=this),s}}e.PatchView=p,p.__name__=\"PatchView\";class d extends _.XYGlyph{constructor(t){super(t)}}e.Patch=d,n=d,d.__name__=\"Patch\",n.prototype.default_view=p,n.mixins([h.LineScalar,h.FillScalar,h.HatchScalar])},\n", - " function _(e,t,s,i,r){i();const n=e(1);var a;const _=e(24),h=e(188),o=(0,n.__importStar)(e(185)),l=(0,n.__importStar)(e(18)),c=e(72);class d extends h.AreaView{_index_data(e){const{min:t,max:s}=Math,{data_size:i}=this;for(let r=0;r=0;t--)e.lineTo(r[t],n[t]);e.closePath(),this.visuals.fill.apply(e),this.visuals.hatch.apply(e)}_hit_point(e){const t=this.sy.length,s=new _.ScreenArray(2*t),i=new _.ScreenArray(2*t);for(let e=0,r=t;e({x1:[l.XCoordinateSpec,{field:\"x1\"}],x2:[l.XCoordinateSpec,{field:\"x2\"}],y:[l.YCoordinateSpec,{field:\"y\"}]})))},\n", + " function _(t,s,e,i,n){i();const h=t(1);var r;const a=t(188),_=(0,h.__importStar)(t(185)),o=(0,h.__importStar)(t(18)),l=t(72);class c extends a.AreaView{_index_data(t){const{min:s,max:e}=Math,{data_size:i}=this;for(let n=0;n=0;s--)t.lineTo(n[s],h[s]);t.closePath(),this.visuals.fill.apply(t),this.visuals.hatch.apply(t)}_hit_point(t){const s=this.sy.length,e=new l.Selection;for(let i=0,n=s-1;i({x1:[o.XCoordinateSpec,{field:\"x1\"}],x2:[o.XCoordinateSpec,{field:\"x2\"}],y:[o.YCoordinateSpec,{field:\"y\"}]})))},\n", " function _(e,a,r,_,s){_();const n=e(1);var c;const i=e(179),l=e(184),t=(0,n.__importStar)(e(48));class o extends i.GlyphView{draw_legend_for_index(e,a,r){(0,l.generic_area_scalar_legend)(this.visuals,e,a)}}r.AreaView=o,o.__name__=\"AreaView\";class d extends i.Glyph{constructor(e){super(e)}}r.Area=d,c=d,d.__name__=\"Area\",c.mixins([t.FillScalar,t.HatchScalar])},\n", - " function _(e,t,s,i,r){i();const n=e(1);var a;const _=e(24),h=e(188),o=(0,n.__importStar)(e(185)),l=(0,n.__importStar)(e(18)),c=e(72);class y extends h.AreaView{_index_data(e){const{min:t,max:s}=Math,{data_size:i}=this;for(let r=0;r=0;t--)e.lineTo(i[t],n[t]);e.closePath(),this.visuals.fill.apply(e),this.visuals.hatch.apply(e)}scenterxy(e){return[this.sx[e],(this.sy1[e]+this.sy2[e])/2]}_hit_point(e){const t=this.sx.length,s=new _.ScreenArray(2*t),i=new _.ScreenArray(2*t);for(let e=0,r=t;e({x:[l.XCoordinateSpec,{field:\"x\"}],y1:[l.YCoordinateSpec,{field:\"y1\"}],y2:[l.YCoordinateSpec,{field:\"y2\"}]})))},\n", + " function _(t,s,e,i,n){i();const h=t(1);var r;const a=t(188),_=(0,h.__importStar)(t(185)),o=(0,h.__importStar)(t(18)),l=t(72);class c extends a.AreaView{_index_data(t){const{min:s,max:e}=Math,{data_size:i}=this;for(let n=0;n=0;s--)t.lineTo(i[s],h[s]);t.closePath(),this.visuals.fill.apply(t),this.visuals.hatch.apply(t)}scenterxy(t){return[this.sx[t],(this.sy1[t]+this.sy2[t])/2]}_hit_point(t){const s=this.sx.length,e=new l.Selection;for(let i=0,n=s-1;i({x:[o.XCoordinateSpec,{field:\"x\"}],y1:[o.YCoordinateSpec,{field:\"y1\"}],y2:[o.YCoordinateSpec,{field:\"y2\"}]})))},\n", " function _(e,i,s,t,n){var c;t();const o=e(53),r=e(24),u=e(191),_=e(70);class a extends o.Model{constructor(e){super(e)}initialize(){super.initialize(),this.compute_indices()}connect_signals(){super.connect_signals(),this.connect(this.properties.filters.change,(()=>this.compute_indices()));const e=()=>{const e=()=>this.compute_indices();null!=this.source&&(this.connect(this.source.change,e),this.source instanceof _.ColumnarDataSource&&(this.connect(this.source.streaming,e),this.connect(this.source.patching,e)))};let i=null!=this.source;i?e():this.connect(this.properties.source.change,(()=>{i||(e(),i=!0)}))}compute_indices(){var e;const{source:i}=this;if(null==i)return;const s=null!==(e=i.get_length())&&void 0!==e?e:1,t=r.Indices.all_set(s);for(const e of this.filters)t.intersect(e.compute_indices(i));this.indices=t,this._indices=[...t],this.indices_map_to_subset()}indices_map_to_subset(){this.indices_map={};for(let e=0;ethis._indices[e]))}convert_selection_to_subset(e){return e.map((e=>this.indices_map[e]))}convert_indices_from_subset(e){return e.map((e=>this._indices[e]))}}s.CDSView=a,c=a,a.__name__=\"CDSView\",c.define((({Array:e,Ref:i})=>({filters:[e(i(u.Filter)),[]],source:[i(_.ColumnarDataSource)]}))),c.internal((({Int:e,Dict:i,Ref:s,Nullable:t})=>({indices:[s(r.Indices)],indices_map:[i(e),{}],masked:[t(s(r.Indices)),null]})))},\n", " function _(e,t,n,s,c){s();const o=e(53);class r extends o.Model{constructor(e){super(e)}}n.Filter=r,r.__name__=\"Filter\"},\n", " function _(t,r,a,e,c){e(),c(\"BasicTickFormatter\",t(146).BasicTickFormatter),c(\"CategoricalTickFormatter\",t(142).CategoricalTickFormatter),c(\"DatetimeTickFormatter\",t(150).DatetimeTickFormatter),c(\"FuncTickFormatter\",t(193).FuncTickFormatter),c(\"LogTickFormatter\",t(163).LogTickFormatter),c(\"MercatorTickFormatter\",t(166).MercatorTickFormatter),c(\"NumeralTickFormatter\",t(194).NumeralTickFormatter),c(\"PrintfTickFormatter\",t(195).PrintfTickFormatter),c(\"TickFormatter\",t(131).TickFormatter)},\n", @@ -593,7 +612,7 @@ " function _(t,e,a,r,n){var s;r();const c=t(198),l=t(67),p=t(174),u=t(20);class o extends p.Mapper{constructor(t){super(t)}v_compute(t){const e=new Array(t.length);return(0,c.cat_v_compute)(t,this.factors,this.patterns,e,this.start,this.end,this.default_value),e}}a.CategoricalPatternMapper=o,s=o,o.__name__=\"CategoricalPatternMapper\",s.define((({Number:t,Array:e,Nullable:a})=>({factors:[l.FactorSeq],patterns:[e(u.HatchPatternType)],start:[t,0],end:[a(t),null],default_value:[u.HatchPatternType,\" \"]})))},\n", " function _(n,r,o,t,a){t();const e=n(172),i=n(12);class s extends e.ContinuousColorMapper{constructor(n){super(n)}scan(n,r){const o=null!=this.low?this.low:(0,i.min)(n),t=null!=this.high?this.high:(0,i.max)(n);return{max:t,min:o,norm_factor:1/(t-o),normed_interval:1/r}}cmap(n,r,o,t,a){const e=r.length-1;if(n==a.max)return r[e];const i=(n-a.min)*a.norm_factor,s=Math.floor(i/a.normed_interval);return s<0?o:s>e?t:r[s]}}o.LinearColorMapper=s,s.__name__=\"LinearColorMapper\"},\n", " function _(o,t,n,r,l){r();const a=o(172),s=o(12);class e extends a.ContinuousColorMapper{constructor(o){super(o)}scan(o,t){const n=null!=this.low?this.low:(0,s.min)(o),r=null!=this.high?this.high:(0,s.max)(o);return{max:r,min:n,scale:t/(Math.log(r)-Math.log(n))}}cmap(o,t,n,r,l){const a=t.length-1;if(o>l.max)return r;if(o==l.max)return t[a];if(oa&&(e=a),t[e]}}n.LogColorMapper=e,e.__name__=\"LogColorMapper\"},\n", - " function _(n,t,e,i,o){var s;i();const r=n(171),a=n(12),l=n(9),c=n(19);class h extends r.ScanningColorMapper{constructor(n){super(n)}scan(n,t){const e=null!=this.low?this.low:(0,a.min)(n),i=null!=this.high?this.high:(0,a.max)(n),o=this.bins,s=(0,l.linspace)(e,i,o+1),r=(0,a.bin_counts)(n,s),h=new Array(o);for(let n=0,t=s.length;nn/p));let m=t-1,f=[],M=0,_=2*t;for(;m!=t&&M<4&&0!=m;){const n=_/m;if(n>1e3)break;_=Math.round(Math.max(t*n,t));const e=(0,l.range)(0,_),i=(0,a.map)(u,(n=>n*(_-1)));f=(0,a.interpolate)(e,i,h);m=(0,l.uniq)(f).length-1,M++}if(0==m){f=[e,i];for(let n=0;n({bins:[n,65536]})))},\n", + " function _(e,n,s,t,l){var i;t();const r=e(171),o=e(12),c=e(9);class a extends r.ScanningColorMapper{constructor(e){super(e)}scan(e,n){let s=null!=this.low?this.low:(0,o.min)(e);const t=null!=this.high?this.high:(0,o.max)(e),l=this.bins,i=(0,c.linspace)(s,t,l+1),r=(0,o.bin_counts)(e,i);let a=0;for(let e=0;e1&&(f=1-n)}const d=(0,c.linspace)(f,1,n+1),g=(0,o.interpolate)(d,p,_);return this.rescale_discrete_levels?s=g[0]:g[0]=s,g[g.length-1]=t,{min:s,max:t,binning:g}}}s.EqHistColorMapper=a,i=a,a.__name__=\"EqHistColorMapper\",i.define((({Boolean:e,Int:n})=>({bins:[n,65536],rescale_discrete_levels:[e,!1]})))},\n", " function _(a,e,l,c,n){c(),n(\"CategoricalScale\",a(62).CategoricalScale),n(\"ContinuousScale\",a(60).ContinuousScale),n(\"LinearScale\",a(59).LinearScale),n(\"LinearInterpolationScale\",a(205).LinearInterpolationScale),n(\"LogScale\",a(61).LogScale),n(\"Scale\",a(55).Scale)},\n", " function _(e,r,n,t,a){var i;t();const s=e(55),o=e(59),c=e(12);class _ extends s.Scale{constructor(e){super(e)}connect_signals(){super.connect_signals();const{source_range:e,target_range:r}=this.properties;this.on_change([e,r],(()=>{this.linear_scale=new o.LinearScale({source_range:this.source_range,target_range:this.target_range})}))}get s_compute(){throw new Error(\"not implemented\")}get s_invert(){throw new Error(\"not implemented\")}compute(e){return e}v_compute(e){const{binning:r}=this,{start:n,end:t}=this.source_range,a=n,i=t,s=r.length,o=(t-n)/(s-1),_=new Float64Array(s);for(let e=0;e{if(ei)return i;const n=(0,c.left_edge_index)(e,r);if(-1==n)return a;if(n>=s-1)return i;const t=r[n],o=(e-t)/(r[n+1]-t),l=_[n];return l+o*(_[n+1]-l)}));return this.linear_scale.v_compute(l)}invert(e){return e}v_invert(e){return new Float64Array(e)}}n.LinearInterpolationScale=_,i=_,_.__name__=\"LinearInterpolationScale\",i.internal((({Arrayable:e,Ref:r})=>({binning:[e],linear_scale:[r(o.LinearScale),e=>new o.LinearScale({source_range:e.source_range,target_range:e.target_range})]})))},\n", " function _(a,n,e,g,R){g(),R(\"DataRange\",a(64).DataRange),R(\"DataRange1d\",a(63).DataRange1d),R(\"FactorRange\",a(67).FactorRange),R(\"Range\",a(57).Range),R(\"Range1d\",a(58).Range1d)},\n", @@ -632,7 +651,7 @@ " function _(t,o,e,l,i){l();const s=t(1);var n,a;const r=t(19),c=t(43),h=t(113),_=t(226),u=t(20),v=t(9),d=t(234),p=t(13),b=t(8),g=t(235),f=t(65),m=t(53),w=t(222),y=t(223),T=t(238),z=t(239),x=t(232),B=t(230),C=(0,s.__importStar)(t(227)),k=C,L=(0,s.__importStar)(t(240)),M=L;class S extends m.Model{constructor(t){super(t)}get visible(){var t;return!this.autohide||null!==(t=this._visible)&&void 0!==t&&t}}e.ToolbarViewModel=S,n=S,S.__name__=\"ToolbarViewModel\",n.define((({Boolean:t})=>({autohide:[t,!1]}))),n.internal((({Boolean:t,Nullable:o})=>({_visible:[o(t),null]})));class $ extends _.DOMView{constructor(){super(...arguments),this.layout={bbox:new f.BBox}}initialize(){super.initialize(),this._tool_button_views=new Map,this._toolbar_view_model=new S({autohide:this.model.autohide});const{toolbar_location:t}=this.model,o=\"left\"==t||\"above\"==t,e=this.model.horizontal?\"vertical\":\"horizontal\";this._overflow_menu=new B.ContextMenu([],{orientation:e,reversed:o})}async lazy_initialize(){await super.lazy_initialize(),await this._build_tool_button_views()}connect_signals(){super.connect_signals(),this.connect(this.model.properties.tools.change,(async()=>{await this._build_tool_button_views(),this.render()})),this.connect(this.model.properties.autohide.change,(()=>{this._toolbar_view_model.autohide=this.model.autohide,this._on_visible_change()})),this.connect(this._toolbar_view_model.properties._visible.change,(()=>this._on_visible_change()))}styles(){return[...super.styles(),C.default,L.default]}remove(){(0,h.remove_views)(this._tool_button_views),super.remove()}async _build_tool_button_views(){const t=null!=this.model._proxied_tools?this.model._proxied_tools:this.model.tools;await(0,h.build_views)(this._tool_button_views,t,{parent:this},(t=>t.button_view))}set_visibility(t){t!=this._toolbar_view_model._visible&&(this._toolbar_view_model._visible=t)}_on_visible_change(){const{visible:t}=this._toolbar_view_model;(0,c.classes)(this.el).toggle(k.toolbar_hidden,!t)}render(){(0,c.empty)(this.el),this.el.classList.add(k.toolbar),this.el.classList.add(k[this.model.toolbar_location]),this._toolbar_view_model.autohide=this.model.autohide,this._on_visible_change();const{horizontal:t}=this.model;let o=0;if(null!=this.model.logo){const e=\"grey\"===this.model.logo?M.grey:null,l=(0,c.a)({href:\"https://bokeh.org/\",target:\"_blank\",class:[M.logo,M.logo_small,e]});this.el.appendChild(l);const{width:i,height:s}=l.getBoundingClientRect();o+=t?i:s}for(const[,t]of this._tool_button_views)t.render();const e=[],l=t=>this._tool_button_views.get(t).el,{gestures:i}=this.model;for(const t of(0,p.values)(i))e.push(t.tools.map(l));e.push(this.model.actions.map(l)),e.push(this.model.inspectors.filter((t=>t.toggleable)).map(l));const s=e.filter((t=>0!=t.length)),n=()=>(0,c.div)({class:k.divider}),{bbox:a}=this.layout;let r=!1;this.root.el.appendChild(this._overflow_menu.el);const h=(0,c.div)({class:k.tool_overflow,tabIndex:0},t?\"\\u22ee\":\"\\u22ef\"),_=()=>{const t=(()=>{switch(this.model.toolbar_location){case\"right\":return{left_of:h};case\"left\":return{right_of:h};case\"above\":return{below:h};case\"below\":return{above:h}}})();this._overflow_menu.toggle(t)};h.addEventListener(\"click\",(()=>{_()})),h.addEventListener(\"keydown\",(t=>{t.keyCode==c.Keys.Enter&&_()}));for(const e of(0,d.join)(s,n))if(r)this._overflow_menu.items.push({content:e,class:t?k.right:k.above});else{this.el.appendChild(e);const{width:l,height:i}=e.getBoundingClientRect();if(o+=t?l:i,r=t?o>a.width-15:o>a.height-15,r){this.el.removeChild(e),this.el.appendChild(h);const{items:t}=this._overflow_menu;t.splice(0,t.length),t.push({content:e})}}}update_layout(){}update_position(){}after_layout(){this._has_finished=!0}export(t,o=!0){const e=\"png\"==t?\"canvas\":\"svg\",l=new g.CanvasLayer(e,o);return l.resize(0,0),l}}function V(){return{pan:{tools:[],active:null},scroll:{tools:[],active:null},pinch:{tools:[],active:null},tap:{tools:[],active:null},doubletap:{tools:[],active:null},press:{tools:[],active:null},pressup:{tools:[],active:null},rotate:{tools:[],active:null},move:{tools:[],active:null},multi:{tools:[],active:null}}}e.ToolbarBaseView=$,$.__name__=\"ToolbarBaseView\";class A extends m.Model{constructor(t){super(t)}initialize(){super.initialize(),this._init_tools()}_init_tools(){const t=function(t,o){if(t.length!=o.length)return!0;const e=new Set(o.map((t=>t.id)));return(0,v.some)(t,(t=>!e.has(t.id)))},o=this.tools.filter((t=>t instanceof x.InspectTool));t(this.inspectors,o)&&(this.inspectors=o);const e=this.tools.filter((t=>t instanceof z.HelpTool));t(this.help,e)&&(this.help=e);const l=this.tools.filter((t=>t instanceof T.ActionTool));t(this.actions,l)&&(this.actions=l);const i=(t,o)=>{t in this.gestures||r.logger.warn(`Toolbar: unknown event type '${t}' for tool: ${o}`)},s={pan:{tools:[],active:null},scroll:{tools:[],active:null},pinch:{tools:[],active:null},tap:{tools:[],active:null},doubletap:{tools:[],active:null},press:{tools:[],active:null},pressup:{tools:[],active:null},rotate:{tools:[],active:null},move:{tools:[],active:null},multi:{tools:[],active:null}};for(const t of this.tools)if(t instanceof y.GestureTool&&t.event_type)if((0,b.isString)(t.event_type))s[t.event_type].tools.push(t),i(t.event_type,t);else{s.multi.tools.push(t);for(const o of t.event_type)i(o,t)}for(const o of Object.keys(s)){const e=this.gestures[o];t(e.tools,s[o].tools)&&(e.tools=s[o].tools),e.active&&(0,v.every)(e.tools,(t=>t.id!=e.active.id))&&(e.active=null)}}get horizontal(){return\"above\"===this.toolbar_location||\"below\"===this.toolbar_location}get vertical(){return\"left\"===this.toolbar_location||\"right\"===this.toolbar_location}_active_change(t){const{event_type:o}=t;if(null==o)return;const e=(0,b.isString)(o)?[o]:o;for(const o of e)if(t.active){const e=this.gestures[o].active;null!=e&&t!=e&&(r.logger.debug(`Toolbar: deactivating tool: ${e} for event type '${o}'`),e.active=!1),this.gestures[o].active=t,r.logger.debug(`Toolbar: activating tool: ${t} for event type '${o}'`)}else this.gestures[o].active=null}}e.ToolbarBase=A,a=A,A.__name__=\"ToolbarBase\",a.prototype.default_view=$,a.define((({Boolean:t,Array:o,Ref:e,Nullable:l})=>({tools:[o(e(w.Tool)),[]],logo:[l(u.Logo),\"normal\"],autohide:[t,!1]}))),a.internal((({Array:t,Struct:o,Ref:e,Nullable:l})=>{const i=o({tools:t(e(y.GestureTool)),active:l(e(w.Tool))});return{gestures:[o({pan:i,scroll:i,pinch:i,tap:i,doubletap:i,press:i,pressup:i,rotate:i,move:i,multi:i}),V],actions:[t(e(T.ActionTool)),[]],inspectors:[t(e(x.InspectTool)),[]],help:[t(e(z.HelpTool)),[]],toolbar_location:[u.Location,\"right\"]}}))},\n", " function _(n,o,e,t,f){t();const r=n(9);function*i(n,o){const e=n.length;if(o>e)return;const t=(0,r.range)(o);for(yield t.map((o=>n[o]));;){let f;for(const n of(0,r.reversed)((0,r.range)(o)))if(t[n]!=n+e-o){f=n;break}if(null==f)return;t[f]+=1;for(const n of(0,r.range)(f+1,o))t[n]=t[n-1]+1;yield t.map((o=>n[o]))}}e.enumerate=function*(n){let o=0;for(const e of n)yield[e,o++]},e.join=function*(n,o){let e=!0;for(const t of n)e?e=!1:null!=o&&(yield o()),yield*t},e.combinations=i,e.subsets=function*(n){for(const o of(0,r.range)(n.length+1))yield*i(n,o)}},\n", " function _(t,e,s,i,n){i();const o=t(236),a=t(65),r=t(43);function h(t){!function(t){void 0===t.lineDash&&Object.defineProperty(t,\"lineDash\",{get:()=>t.getLineDash(),set:e=>t.setLineDash(e)})}(t),function(t){t.setImageSmoothingEnabled=e=>{t.imageSmoothingEnabled=e,t.mozImageSmoothingEnabled=e,t.oImageSmoothingEnabled=e,t.webkitImageSmoothingEnabled=e,t.msImageSmoothingEnabled=e},t.getImageSmoothingEnabled=()=>{const e=t.imageSmoothingEnabled;return null==e||e}}(t),function(t){t.ellipse||(t.ellipse=function(e,s,i,n,o,a,r,h=!1){const l=.551784;t.translate(e,s),t.rotate(o);let c=i,g=n;h&&(c=-i,g=-n),t.moveTo(-c,0),t.bezierCurveTo(-c,g*l,-c*l,g,0,g),t.bezierCurveTo(c*l,g,c,g*l,c,0),t.bezierCurveTo(c,-g*l,c*l,-g,0,-g),t.bezierCurveTo(-c*l,-g,-c,-g*l,-c,0),t.rotate(-o),t.translate(-e,-s)})}(t)}const l={position:\"absolute\",top:\"0\",left:\"0\",width:\"100%\",height:\"100%\"};class c{constructor(t,e){switch(this.backend=t,this.hidpi=e,this.pixel_ratio=1,this.bbox=new a.BBox,t){case\"webgl\":case\"canvas\":{this._el=this._canvas=(0,r.canvas)({style:l});const t=this.canvas.getContext(\"2d\");if(null==t)throw new Error(\"unable to obtain 2D rendering context\");this._ctx=t,e&&(this.pixel_ratio=devicePixelRatio);break}case\"svg\":{const t=new o.SVGRenderingContext2D;this._ctx=t,this._canvas=t.get_svg(),this._el=(0,r.div)({style:l},this._canvas);break}}this._ctx.layer=this,h(this._ctx)}get canvas(){return this._canvas}get ctx(){return this._ctx}get el(){return this._el}resize(t,e){this.bbox=new a.BBox({left:0,top:0,width:t,height:e});const s=this._ctx instanceof o.SVGRenderingContext2D?this._ctx:this.canvas;s.width=t*this.pixel_ratio,s.height=e*this.pixel_ratio}undo_transform(t){const{ctx:e}=this;if(void 0===e.getTransform)t(e);else{const s=e.getTransform();e.setTransform(this._base_transform);try{t(e)}finally{e.setTransform(s)}}}prepare(){const{ctx:t,hidpi:e,pixel_ratio:s}=this;t.save(),e&&(t.scale(s,s),t.translate(.5,.5)),void 0!==t.getTransform&&(this._base_transform=t.getTransform()),this.clear()}clear(){const{x:t,y:e,width:s,height:i}=this.bbox;this.ctx.clearRect(t,e,s,i)}finish(){this.ctx.restore()}to_blob(){const{_canvas:t}=this;if(t instanceof HTMLCanvasElement)return null!=t.msToBlob?Promise.resolve(t.msToBlob()):new Promise(((e,s)=>{t.toBlob((t=>null!=t?e(t):s()),\"image/png\")}));{const t=this._ctx.get_serialized_svg(!0),e=new Blob([t],{type:\"image/svg+xml\"});return Promise.resolve(e)}}}s.CanvasLayer=c,c.__name__=\"CanvasLayer\"},\n", - " function _(t,e,i,s,r){s();const n=t(122),a=t(8),o=t(237),l=t(43);function h(t){var e;const i={left:\"start\",right:\"end\",center:\"middle\",start:\"start\",end:\"end\"};return null!==(e=i[t])&&void 0!==e?e:i.start}function _(t){var e;const i={alphabetic:\"alphabetic\",hanging:\"hanging\",top:\"text-before-edge\",bottom:\"text-after-edge\",middle:\"central\"};return null!==(e=i[t])&&void 0!==e?e:i.alphabetic}const c=function(t,e){const i=new Map,s=t.split(\",\");e=null!=e?e:10;for(let t=0;t=0?Math.acos(e):-Math.acos(e)}const v=b(f),A=b(g);this.lineTo(d+f[0]*r,m+f[1]*r),this.arc(d,m,r,v,A)}stroke(){\"path\"===this.__currentElement.nodeName&&this.__currentElement.setAttribute(\"paint-order\",\"fill\"),this.__applyCurrentDefaultPath(),this.__applyStyleToCurrentElement(\"stroke\"),null!=this._clip_path&&this.__currentElement.setAttribute(\"clip-path\",this._clip_path)}fill(t,e){let i=null;if(t instanceof Path2D)i=t;else{if(\"evenodd\"!=t&&\"nonzero\"!=t&&null!=t||null!=e)throw new Error(\"invalid arguments\");e=t}if(null!=i)throw new Error(\"not implemented\");\"none\"!=this.__currentElement.getAttribute(\"fill\")&&this.__init_element(),\"path\"===this.__currentElement.nodeName&&this.__currentElement.setAttribute(\"paint-order\",\"stroke\"),this.__applyCurrentDefaultPath(),this.__applyStyleToCurrentElement(\"fill\"),null!=e&&this.__currentElement.setAttribute(\"fill-rule\",e),null!=this._clip_path&&this.__currentElement.setAttribute(\"clip-path\",this._clip_path)}rect(t,e,i,s){isFinite(t+e+i+s)&&(this.moveTo(t,e),this.lineTo(t+i,e),this.lineTo(t+i,e+s),this.lineTo(t,e+s),this.lineTo(t,e))}fillRect(t,e,i,s){isFinite(t+e+i+s)&&(this.beginPath(),this.rect(t,e,i,s),this.fill())}strokeRect(t,e,i,s){isFinite(t+e+i+s)&&(this.beginPath(),this.rect(t,e,i,s),this.stroke())}__clearCanvas(){(0,l.empty)(this.__defs),(0,l.empty)(this.__root),this.__root.appendChild(this.__defs),this.__currentElement=this.__root}clearRect(t,e,i,s){if(!isFinite(t+e+i+s))return;if(0===t&&0===e&&i===this.width&&s===this.height)return void this.__clearCanvas();const r=this.__createElement(\"rect\",{x:t,y:e,width:i,height:s,fill:\"#FFFFFF\"},!0);this._apply_transform(r),this.__root.appendChild(r)}createLinearGradient(t,e,i,s){if(!isFinite(t+e+i+s))throw new Error(\"The provided double value is non-finite\");const[r,n]=this._transform.apply(t,e),[a,o]=this._transform.apply(i,s),l=this.__createElement(\"linearGradient\",{id:this._random_string(),x1:`${r}px`,x2:`${a}px`,y1:`${n}px`,y2:`${o}px`,gradientUnits:\"userSpaceOnUse\"},!1);return this.__defs.appendChild(l),new u(l,this)}createRadialGradient(t,e,i,s,r,n){if(!isFinite(t+e+i+s+r+n))throw new Error(\"The provided double value is non-finite\");const[a,o]=this._transform.apply(t,e),[l,h]=this._transform.apply(s,r),_=this.__createElement(\"radialGradient\",{id:this._random_string(),cx:`${l}px`,cy:`${h}px`,r:`${n}px`,r0:`${i}px`,fx:`${a}px`,fy:`${o}px`,gradientUnits:\"userSpaceOnUse\"},!1);return this.__defs.appendChild(_),new u(_,this)}__parseFont(){var t,e,i,s,r;const n=/^\\s*(?=(?:(?:[-a-z]+\\s*){0,2}(italic|oblique))?)(?=(?:(?:[-a-z]+\\s*){0,2}(small-caps))?)(?=(?:(?:[-a-z]+\\s*){0,2}(bold(?:er)?|lighter|[1-9]00))?)(?:(?:normal|\\1|\\2|\\3)\\s*){0,3}((?:xx?-)?(?:small|large)|medium|smaller|larger|[.\\d]+(?:\\%|in|[cem]m|ex|p[ctx]))(?:\\s*\\/\\s*(normal|[.\\d]+(?:\\%|in|[cem]m|ex|p[ctx])))?\\s*([-,\\'\\\"\\sa-z0-9]+?)\\s*$/i.exec(this.font);return{style:null!==(t=n[1])&&void 0!==t?t:\"normal\",size:null!==(e=n[4])&&void 0!==e?e:\"10px\",family:null!==(i=n[6])&&void 0!==i?i:\"sans-serif\",weight:null!==(s=n[3])&&void 0!==s?s:\"normal\",decoration:null!==(r=n[2])&&void 0!==r?r:\"normal\"}}__applyText(t,e,i,s){const r=this.__parseFont(),n=this.__createElement(\"text\",{\"font-family\":r.family,\"font-size\":r.size,\"font-style\":r.style,\"font-weight\":r.weight,\"text-decoration\":r.decoration,x:e,y:i,\"text-anchor\":h(this.textAlign),\"dominant-baseline\":_(this.textBaseline)},!0);n.appendChild(this.__document.createTextNode(t)),this._apply_transform(n),this.__currentElement=n,this.__applyStyleToCurrentElement(s);const a=(()=>{if(null!=this._clip_path){const t=this.__createElement(\"g\");return t.setAttribute(\"clip-path\",this._clip_path),t.appendChild(n),t}return n})();this.__root.appendChild(a)}fillText(t,e,i){null!=t&&isFinite(e+i)&&this.__applyText(t,e,i,\"fill\")}strokeText(t,e,i){null!=t&&isFinite(e+i)&&this.__applyText(t,e,i,\"stroke\")}measureText(t){return this.__ctx.font=this.font,this.__ctx.measureText(t)}arc(t,e,i,s,r,n=!1){this.ellipse(t,e,i,i,0,s,r,n)}ellipse(t,e,i,s,r,n,a,o=!1){if(!isFinite(t+e+i+s+r+n+a))return;if(i<0||s<0)throw new DOMException(\"IndexSizeError, radius can't be negative\");(n%=2*Math.PI)===(a%=2*Math.PI)&&(a=(a+2*Math.PI-.001*(o?-1:1))%(2*Math.PI));const l=t+i*Math.cos(a),h=e+s*Math.sin(a),_=t+i*Math.cos(n),c=e+s*Math.sin(n),p=o?0:1;let u=0,d=a-n;d<0&&(d+=2*Math.PI),u=o?d>Math.PI?0:1:d>Math.PI?1:0,this.lineTo(_,c);const[m,f]=this._transform.apply(l,h),g=180*r/Math.PI;this.__addPathCommand(m,f,`A ${i} ${s} ${g} ${u} ${p} ${m} ${f}`)}clip(){const t=this.__createElement(\"clipPath\"),e=this._random_string();this.__applyCurrentDefaultPath(),t.setAttribute(\"id\",e),t.appendChild(this.__currentElement),this.__defs.appendChild(t),this._clip_path=`url(#${e})`}drawImage(t,...e){let i,s,r,n,a,o,l,h;if(2==e.length){if([i,s]=e,!isFinite(i+s))return;a=0,o=0,l=t.width,h=t.height,r=l,n=h}else if(4==e.length){if([i,s,r,n]=e,!isFinite(i+s+r+n))return;a=0,o=0,l=t.width,h=t.height}else{if(8!==e.length)throw new Error(`Inavlid number of arguments passed to drawImage: ${arguments.length}`);if([a,o,l,h,i,s,r,n]=e,!isFinite(a+o+l+h+i+s+r+n))return}const _=this.__root,c=this._transform.clone().translate(i,s);if(t instanceof m||t instanceof SVGSVGElement){const e=(t instanceof SVGSVGElement?t:t.get_svg()).cloneNode(!0);let i;c.is_identity&&1==this.globalAlpha&&null==this._clip_path?i=_:(i=this.__createElement(\"g\"),c.is_identity||this._apply_transform(i,c),1!=this.globalAlpha&&i.setAttribute(\"opacity\",`${this.globalAlpha}`),null!=this._clip_path&&i.setAttribute(\"clip-path\",this._clip_path),_.appendChild(i));for(const t of[...e.childNodes])if(t instanceof SVGDefsElement){for(const e of[...t.childNodes])if(e instanceof Element){const t=e.getAttribute(\"id\");this.__ids.add(t),this.__defs.appendChild(e.cloneNode(!0))}}else i.appendChild(t.cloneNode(!0))}else if(t instanceof HTMLImageElement||t instanceof SVGImageElement){const e=this.__createElement(\"image\");if(e.setAttribute(\"width\",`${r}`),e.setAttribute(\"height\",`${n}`),e.setAttribute(\"preserveAspectRatio\",\"none\"),1!=this.globalAlpha&&e.setAttribute(\"opacity\",`${this.globalAlpha}`),a||o||l!==t.width||h!==t.height){const e=this.__document.createElement(\"canvas\");e.width=r,e.height=n;e.getContext(\"2d\").drawImage(t,a,o,l,h,0,0,r,n),t=e}this._apply_transform(e,c);const i=t instanceof HTMLCanvasElement?t.toDataURL():t.getAttribute(\"src\");if(e.setAttribute(\"href\",i),null!=this._clip_path){const t=this.__createElement(\"g\");t.setAttribute(\"clip-path\",this._clip_path),t.appendChild(e),_.appendChild(t)}else _.appendChild(e)}else if(t instanceof HTMLCanvasElement){const e=this.__createElement(\"image\");e.setAttribute(\"width\",`${r}`),e.setAttribute(\"height\",`${n}`),e.setAttribute(\"preserveAspectRatio\",\"none\"),1!=this.globalAlpha&&e.setAttribute(\"opacity\",`${this.globalAlpha}`);const i=this.__document.createElement(\"canvas\");i.width=r,i.height=n;const s=i.getContext(\"2d\");if(s.imageSmoothingEnabled=!1,s.drawImage(t,a,o,l,h,0,0,r,n),t=i,this._apply_transform(e,c),e.setAttribute(\"href\",t.toDataURL()),null!=this._clip_path){const t=this.__createElement(\"g\");t.setAttribute(\"clip-path\",this._clip_path),t.appendChild(e),_.appendChild(t)}else _.appendChild(e)}}createPattern(t,e){const i=this.__document.createElementNS(\"http://www.w3.org/2000/svg\",\"pattern\"),s=this._random_string();if(i.setAttribute(\"id\",s),i.setAttribute(\"width\",`${this._to_number(t.width)}`),i.setAttribute(\"height\",`${this._to_number(t.height)}`),i.setAttribute(\"patternUnits\",\"userSpaceOnUse\"),t instanceof HTMLCanvasElement||t instanceof HTMLImageElement||t instanceof SVGImageElement){const e=this.__document.createElementNS(\"http://www.w3.org/2000/svg\",\"image\"),s=t instanceof HTMLCanvasElement?t.toDataURL():t.getAttribute(\"src\");e.setAttribute(\"href\",s),i.appendChild(e),this.__defs.appendChild(i)}else if(t instanceof m){for(const e of[...t.__root.childNodes])e instanceof SVGDefsElement||i.appendChild(e.cloneNode(!0));this.__defs.appendChild(i)}else{if(!(t instanceof SVGSVGElement))throw new Error(\"unsupported\");for(const e of[...t.childNodes])e instanceof SVGDefsElement||i.appendChild(e.cloneNode(!0));this.__defs.appendChild(i)}return new d(i,this)}getLineDash(){const{lineDash:t}=this;return(0,a.isString)(t)?t.split(\",\").map((t=>parseInt(t))):null==t?[]:t}setLineDash(t){t&&t.length>0?this.lineDash=t.join(\",\"):this.lineDash=null}_to_number(t){return(0,a.isNumber)(t)?t:t.baseVal.value}getTransform(){return this._transform.to_DOMMatrix()}setTransform(...t){let e;e=(0,a.isNumber)(t[0])?new DOMMatrix(t):t[0]instanceof DOMMatrix?t[0]:new DOMMatrix(Object.values(!t[0])),this._transform=n.AffineTransform.from_DOMMatrix(e)}resetTransform(){this._transform=new n.AffineTransform}isPointInPath(...t){throw new Error(\"not implemented\")}isPointInStroke(...t){throw new Error(\"not implemented\")}createImageData(...t){throw new Error(\"not implemented\")}getImageData(t,e,i,s){throw new Error(\"not implemented\")}putImageData(...t){throw new Error(\"not implemented\")}drawFocusIfNeeded(...t){throw new Error(\"not implemented\")}scrollPathIntoView(...t){throw new Error(\"not implemented\")}}i.SVGRenderingContext2D=m,m.__name__=\"SVGRenderingContext2D\",m.__random=o.random},\n", + " function _(t,e,i,s,r){s();const n=t(122),a=t(8),o=t(237),l=t(10),h=t(43);function _(t){var e;const i={left:\"start\",right:\"end\",center:\"middle\",start:\"start\",end:\"end\"};return null!==(e=i[t])&&void 0!==e?e:i.start}function c(t){var e;const i={alphabetic:\"alphabetic\",hanging:\"hanging\",top:\"text-before-edge\",bottom:\"text-after-edge\",middle:\"central\"};return null!==(e=i[t])&&void 0!==e?e:i.alphabetic}const p=function(t,e){const i=new Map,s=t.split(\",\");e=null!=e?e:10;for(let t=0;t=0?Math.acos(e):-Math.acos(e)}const v=b(f),A=b(g);this.lineTo(d+f[0]*r,m+f[1]*r),this.arc(d,m,r,v,A)}stroke(){\"path\"===this.__currentElement.nodeName&&this.__currentElement.setAttribute(\"paint-order\",\"fill\"),this.__applyCurrentDefaultPath(),this.__applyStyleToCurrentElement(\"stroke\"),null!=this._clip_path&&this.__currentElement.setAttribute(\"clip-path\",this._clip_path)}fill(t,e){let i=null;if(t instanceof Path2D)i=t;else{if(\"evenodd\"!=t&&\"nonzero\"!=t&&null!=t||null!=e)throw new Error(\"invalid arguments\");e=t}if(null!=i)throw new Error(\"not implemented\");\"none\"!=this.__currentElement.getAttribute(\"fill\")&&this.__init_element(),\"path\"===this.__currentElement.nodeName&&this.__currentElement.setAttribute(\"paint-order\",\"stroke\"),this.__applyCurrentDefaultPath(),this.__applyStyleToCurrentElement(\"fill\"),null!=e&&this.__currentElement.setAttribute(\"fill-rule\",e),null!=this._clip_path&&this.__currentElement.setAttribute(\"clip-path\",this._clip_path)}rect(t,e,i,s){isFinite(t+e+i+s)&&(this.moveTo(t,e),this.lineTo(t+i,e),this.lineTo(t+i,e+s),this.lineTo(t,e+s),this.lineTo(t,e))}fillRect(t,e,i,s){isFinite(t+e+i+s)&&(this.beginPath(),this.rect(t,e,i,s),this.fill())}strokeRect(t,e,i,s){isFinite(t+e+i+s)&&(this.beginPath(),this.rect(t,e,i,s),this.stroke())}__clearCanvas(){(0,h.empty)(this.__defs),(0,h.empty)(this.__root),this.__root.appendChild(this.__defs),this.__currentElement=this.__root}clearRect(t,e,i,s){if(!isFinite(t+e+i+s))return;if(0===t&&0===e&&i===this.width&&s===this.height)return void this.__clearCanvas();const r=this.__createElement(\"rect\",{x:t,y:e,width:i,height:s,fill:\"#FFFFFF\"},!0);this._apply_transform(r),this.__root.appendChild(r)}createLinearGradient(t,e,i,s){if(!isFinite(t+e+i+s))throw new Error(\"The provided double value is non-finite\");const[r,n]=this._transform.apply(t,e),[a,o]=this._transform.apply(i,s),l=this.__createElement(\"linearGradient\",{id:this._random_string(),x1:`${r}px`,x2:`${a}px`,y1:`${n}px`,y2:`${o}px`,gradientUnits:\"userSpaceOnUse\"},!1);return this.__defs.appendChild(l),new d(l,this)}createRadialGradient(t,e,i,s,r,n){if(!isFinite(t+e+i+s+r+n))throw new Error(\"The provided double value is non-finite\");const[a,o]=this._transform.apply(t,e),[l,h]=this._transform.apply(s,r),_=this.__createElement(\"radialGradient\",{id:this._random_string(),cx:`${l}px`,cy:`${h}px`,r:`${n}px`,r0:`${i}px`,fx:`${a}px`,fy:`${o}px`,gradientUnits:\"userSpaceOnUse\"},!1);return this.__defs.appendChild(_),new d(_,this)}__parseFont(){var t,e,i,s,r;const n=/^\\s*(?=(?:(?:[-a-z]+\\s*){0,2}(italic|oblique))?)(?=(?:(?:[-a-z]+\\s*){0,2}(small-caps))?)(?=(?:(?:[-a-z]+\\s*){0,2}(bold(?:er)?|lighter|[1-9]00))?)(?:(?:normal|\\1|\\2|\\3)\\s*){0,3}((?:xx?-)?(?:small|large)|medium|smaller|larger|[.\\d]+(?:\\%|in|[cem]m|ex|p[ctx]))(?:\\s*\\/\\s*(normal|[.\\d]+(?:\\%|in|[cem]m|ex|p[ctx])))?\\s*([-,\\'\\\"\\sa-z0-9]+?)\\s*$/i.exec(this.font);return{style:null!==(t=n[1])&&void 0!==t?t:\"normal\",size:null!==(e=n[4])&&void 0!==e?e:\"10px\",family:null!==(i=n[6])&&void 0!==i?i:\"sans-serif\",weight:null!==(s=n[3])&&void 0!==s?s:\"normal\",decoration:null!==(r=n[2])&&void 0!==r?r:\"normal\"}}__applyText(t,e,i,s){const r=this.__parseFont(),n=this.__createElement(\"text\",{\"font-family\":r.family,\"font-size\":r.size,\"font-style\":r.style,\"font-weight\":r.weight,\"text-decoration\":r.decoration,x:e,y:i,\"text-anchor\":_(this.textAlign),\"dominant-baseline\":c(this.textBaseline)},!0);n.appendChild(this.__document.createTextNode(t)),this._apply_transform(n),this.__currentElement=n,this.__applyStyleToCurrentElement(s);const a=(()=>{if(null!=this._clip_path){const t=this.__createElement(\"g\");return t.setAttribute(\"clip-path\",this._clip_path),t.appendChild(n),t}return n})();this.__root.appendChild(a)}fillText(t,e,i){null!=t&&isFinite(e+i)&&this.__applyText(t,e,i,\"fill\")}strokeText(t,e,i){null!=t&&isFinite(e+i)&&this.__applyText(t,e,i,\"stroke\")}measureText(t){return this.__ctx.font=this.font,this.__ctx.measureText(t)}arc(t,e,i,s,r,n=!1){this.ellipse(t,e,i,i,0,s,r,n)}ellipse(t,e,i,s,r,n,a,o=!1){if(!isFinite(t+e+i+s+r+n+a))return;if(i<0||s<0)throw new DOMException(\"IndexSizeError, radius can't be negative\");const h=o?a-n:n-a;n%=2*Math.PI,a%=2*Math.PI;const _=t+i*Math.cos(n),c=e+s*Math.sin(n);this.lineTo(_,c);const p=180*r/Math.PI,u=o?0:1;if(Math.abs(n-a)<2*l.float32_epsilon&&!(Math.abs(h)<2*l.float32_epsilon&&h<0)){const r=t+i*Math.cos(n+Math.PI),a=e+s*Math.sin(n+Math.PI),[o,l]=this._transform.apply(_,c),[h,d]=this._transform.apply(r,a);this.__addPathCommand(o,l,`A ${i} ${s} ${p} 0 ${u} ${h} ${d} A ${i} ${s} ${p} 0 ${u} ${o} ${l}`)}else{const r=t+i*Math.cos(a),l=e+s*Math.sin(a);let h=a-n;h<0&&(h+=2*Math.PI);const _=o!==h>Math.PI?1:0,[c,d]=this._transform.apply(r,l);this.__addPathCommand(c,d,`A ${i} ${s} ${p} ${_} ${u} ${c} ${d}`)}}clip(){const t=this.__createElement(\"clipPath\"),e=this._random_string();this.__applyCurrentDefaultPath(),t.setAttribute(\"id\",e),t.appendChild(this.__currentElement),this.__defs.appendChild(t),this._clip_path=`url(#${e})`}drawImage(t,...e){let i,s,r,n,a,o,l,h;if(2==e.length){if([i,s]=e,!isFinite(i+s))return;a=0,o=0,l=t.width,h=t.height,r=l,n=h}else if(4==e.length){if([i,s,r,n]=e,!isFinite(i+s+r+n))return;a=0,o=0,l=t.width,h=t.height}else{if(8!==e.length)throw new Error(`Inavlid number of arguments passed to drawImage: ${arguments.length}`);if([a,o,l,h,i,s,r,n]=e,!isFinite(a+o+l+h+i+s+r+n))return}const _=this.__root,c=this._transform.clone().translate(i,s);if(t instanceof f||t instanceof SVGSVGElement){const e=(t instanceof SVGSVGElement?t:t.get_svg()).cloneNode(!0);let i;c.is_identity&&1==this.globalAlpha&&null==this._clip_path?i=_:(i=this.__createElement(\"g\"),c.is_identity||this._apply_transform(i,c),1!=this.globalAlpha&&i.setAttribute(\"opacity\",`${this.globalAlpha}`),null!=this._clip_path&&i.setAttribute(\"clip-path\",this._clip_path),_.appendChild(i));for(const t of[...e.childNodes])if(t instanceof SVGDefsElement){for(const e of[...t.childNodes])if(e instanceof Element){const t=e.getAttribute(\"id\");this.__ids.add(t),this.__defs.appendChild(e.cloneNode(!0))}}else i.appendChild(t.cloneNode(!0))}else if(t instanceof HTMLImageElement||t instanceof SVGImageElement){const e=this.__createElement(\"image\");if(e.setAttribute(\"width\",`${r}`),e.setAttribute(\"height\",`${n}`),e.setAttribute(\"preserveAspectRatio\",\"none\"),1!=this.globalAlpha&&e.setAttribute(\"opacity\",`${this.globalAlpha}`),a||o||l!==t.width||h!==t.height){const e=this.__document.createElement(\"canvas\");e.width=r,e.height=n;e.getContext(\"2d\").drawImage(t,a,o,l,h,0,0,r,n),t=e}this._apply_transform(e,c);const i=t instanceof HTMLCanvasElement?t.toDataURL():t.getAttribute(\"src\");if(e.setAttribute(\"href\",i),null!=this._clip_path){const t=this.__createElement(\"g\");t.setAttribute(\"clip-path\",this._clip_path),t.appendChild(e),_.appendChild(t)}else _.appendChild(e)}else if(t instanceof HTMLCanvasElement){const e=this.__createElement(\"image\");e.setAttribute(\"width\",`${r}`),e.setAttribute(\"height\",`${n}`),e.setAttribute(\"preserveAspectRatio\",\"none\"),1!=this.globalAlpha&&e.setAttribute(\"opacity\",`${this.globalAlpha}`);const i=this.__document.createElement(\"canvas\");i.width=r,i.height=n;const s=i.getContext(\"2d\");if(s.imageSmoothingEnabled=!1,s.drawImage(t,a,o,l,h,0,0,r,n),t=i,this._apply_transform(e,c),e.setAttribute(\"href\",t.toDataURL()),null!=this._clip_path){const t=this.__createElement(\"g\");t.setAttribute(\"clip-path\",this._clip_path),t.appendChild(e),_.appendChild(t)}else _.appendChild(e)}}createPattern(t,e){const i=this.__document.createElementNS(\"http://www.w3.org/2000/svg\",\"pattern\"),s=this._random_string();if(i.setAttribute(\"id\",s),i.setAttribute(\"width\",`${this._to_number(t.width)}`),i.setAttribute(\"height\",`${this._to_number(t.height)}`),i.setAttribute(\"patternUnits\",\"userSpaceOnUse\"),t instanceof HTMLCanvasElement||t instanceof HTMLImageElement||t instanceof SVGImageElement){const e=this.__document.createElementNS(\"http://www.w3.org/2000/svg\",\"image\"),s=t instanceof HTMLCanvasElement?t.toDataURL():t.getAttribute(\"src\");e.setAttribute(\"href\",s),i.appendChild(e),this.__defs.appendChild(i)}else if(t instanceof f){for(const e of[...t.__root.childNodes])e instanceof SVGDefsElement||i.appendChild(e.cloneNode(!0));this.__defs.appendChild(i)}else{if(!(t instanceof SVGSVGElement))throw new Error(\"unsupported\");for(const e of[...t.childNodes])e instanceof SVGDefsElement||i.appendChild(e.cloneNode(!0));this.__defs.appendChild(i)}return new m(i,this)}getLineDash(){const{lineDash:t}=this;return(0,a.isString)(t)?t.split(\",\").map((t=>parseInt(t))):null==t?[]:t}setLineDash(t){t&&t.length>0?this.lineDash=t.join(\",\"):this.lineDash=null}_to_number(t){return(0,a.isNumber)(t)?t:t.baseVal.value}getTransform(){return this._transform.to_DOMMatrix()}setTransform(...t){let e;e=(0,a.isNumber)(t[0])?new DOMMatrix(t):t[0]instanceof DOMMatrix?t[0]:new DOMMatrix(Object.values(!t[0])),this._transform=n.AffineTransform.from_DOMMatrix(e)}resetTransform(){this._transform=new n.AffineTransform}isPointInPath(...t){throw new Error(\"not implemented\")}isPointInStroke(...t){throw new Error(\"not implemented\")}createImageData(...t){throw new Error(\"not implemented\")}getImageData(t,e,i,s){throw new Error(\"not implemented\")}putImageData(...t){throw new Error(\"not implemented\")}drawFocusIfNeeded(...t){throw new Error(\"not implemented\")}scrollPathIntoView(...t){throw new Error(\"not implemented\")}}i.SVGRenderingContext2D=f,f.__name__=\"SVGRenderingContext2D\",f.__random=o.random},\n", " function _(e,t,s,n,r){n();const o=2147483647;class i{constructor(e){this.seed=e%o,this.seed<=0&&(this.seed+=2147483646)}integer(){return this.seed=48271*this.seed%o,this.seed}float(){return(this.integer()-1)/2147483646}floats(e,t=0,s=1){const n=new Array(e);for(let r=0;rthis.doit(o)))}}n.ActionToolView=_,_.__name__=\"ActionToolView\";class d extends s.ButtonTool{constructor(o){super(o),this.button_view=l,this.do=new c.Signal(this,\"do\")}}n.ActionTool=d,d.__name__=\"ActionTool\"},\n", " function _(o,e,t,l,i){var s;l();const n=o(238),r=o(228);class c extends n.ActionToolView{doit(){window.open(this.model.redirect)}}t.HelpToolView=c,c.__name__=\"HelpToolView\";class _ extends n.ActionTool{constructor(o){super(o),this.tool_name=\"Help\",this.icon=r.tool_icon_help}}t.HelpTool=_,s=_,_.__name__=\"HelpTool\",s.prototype.default_view=c,s.define((({String:o})=>({redirect:[o,\"https://docs.bokeh.org/en/latest/docs/user_guide/tools.html\"]}))),s.override({description:\"Click the question mark to learn more about Bokeh plot tools.\"}),s.register_alias(\"help\",(()=>new _))},\n", @@ -645,8 +664,8 @@ " function _(c,a,l,n,s){n();const e=c(53);class o extends e.Model{constructor(c){super(c)}}l.Callback=o,o.__name__=\"Callback\"},\n", " function _(e,t,n,o,i){var s;o();const c=e(246),r=e(152),a=e(8);class d extends c.Callback{constructor(e){super(e)}navigate(e){this.same_tab?window.location.href=e:window.open(e)}execute(e,{source:t}){const n=e=>{const n=(0,r.replace_placeholders)(this.url,t,e,void 0,void 0,encodeURI);if(!(0,a.isString)(n))throw new Error(\"HTML output is not supported in this context\");this.navigate(n)},{selected:o}=t;for(const e of o.indices)n(e);for(const e of o.line_indices)n(e)}}n.OpenURL=d,s=d,d.__name__=\"OpenURL\",s.define((({Boolean:e,String:t})=>({url:[t,\"http://\"],same_tab:[e,!1]})))},\n", " function _(a,n,i,e,r){e(),r(\"Canvas\",a(249).Canvas),r(\"CartesianFrame\",a(126).CartesianFrame),r(\"CoordinateMapping\",a(54).CoordinateMapping)},\n", - " function _(e,t,i,s,a){var r,l=this&&this.__createBinding||(Object.create?function(e,t,i,s){void 0===s&&(s=i),Object.defineProperty(e,s,{enumerable:!0,get:function(){return t[i]}})}:function(e,t,i,s){void 0===s&&(s=i),e[s]=t[i]}),n=this&&this.__setModuleDefault||(Object.create?function(e,t){Object.defineProperty(e,\"default\",{enumerable:!0,value:t})}:function(e,t){e.default=t}),o=this&&this.__importStar||function(e){if(e&&e.__esModule)return e;var t={};if(null!=e)for(var i in e)\"default\"!==i&&Object.prototype.hasOwnProperty.call(e,i)&&l(t,e,i);return n(t,e),t};s();const h=e(14),c=e(226),u=e(19),_=e(43),d=e(20),p=e(13),b=e(250),v=e(65),g=e(138),w=e(235);const y=(()=>{let t;return async()=>void 0!==t?t:t=await async function(){const t=document.createElement(\"canvas\"),i=t.getContext(\"webgl\",{premultipliedAlpha:!0});if(null!=i){const s=await(0,g.load_module)(Promise.resolve().then((()=>o(e(410)))));if(null!=s){const e=s.get_regl(i);if(e.has_webgl)return{canvas:t,regl_wrapper:e};u.logger.trace(\"WebGL is supported, but not the required extensions\")}else u.logger.trace(\"WebGL is supported, but bokehjs(.min).js bundle is not available\")}else u.logger.trace(\"WebGL is not supported\");return null}()})(),m={position:\"absolute\",top:\"0\",left:\"0\",width:\"100%\",height:\"100%\"};class f extends c.DOMView{constructor(){super(...arguments),this.bbox=new v.BBox,this.webgl=null}initialize(){super.initialize(),this.underlays_el=(0,_.div)({style:m}),this.primary=this.create_layer(),this.overlays=this.create_layer(),this.overlays_el=(0,_.div)({style:m}),this.events_el=(0,_.div)({class:\"bk-canvas-events\",style:m});const e=[this.underlays_el,this.primary.el,this.overlays.el,this.overlays_el,this.events_el];(0,p.extend)(this.el.style,m),(0,_.append)(this.el,...e),this.ui_event_bus=new b.UIEventBus(this)}async lazy_initialize(){await super.lazy_initialize(),\"webgl\"==this.model.output_backend&&(this.webgl=await y())}remove(){this.ui_event_bus.destroy(),super.remove()}add_underlay(e){this.underlays_el.appendChild(e)}add_overlay(e){this.overlays_el.appendChild(e)}add_event(e){this.events_el.appendChild(e)}get pixel_ratio(){return this.primary.pixel_ratio}resize(e,t){this.bbox=new v.BBox({left:0,top:0,width:e,height:t}),this.primary.resize(e,t),this.overlays.resize(e,t)}prepare_webgl(e){const{webgl:t}=this;if(null!=t){const{width:i,height:s}=this.bbox;t.canvas.width=this.pixel_ratio*i,t.canvas.height=this.pixel_ratio*s;const[a,r,l,n]=e,{xview:o,yview:h}=this.bbox,c=o.compute(a),u=h.compute(r+n),_=this.pixel_ratio;t.regl_wrapper.set_scissor(_*c,_*u,_*l,_*n),this._clear_webgl()}}blit_webgl(e){const{webgl:t}=this;if(null!=t){if(u.logger.debug(\"Blitting WebGL canvas\"),e.restore(),e.drawImage(t.canvas,0,0),e.save(),this.model.hidpi){const t=this.pixel_ratio;e.scale(t,t),e.translate(.5,.5)}this._clear_webgl()}}_clear_webgl(){const{webgl:e}=this;if(null!=e){const{regl_wrapper:t,canvas:i}=e;t.clear(i.width,i.height)}}compose(){const e=this.create_layer(),{width:t,height:i}=this.bbox;return e.resize(t,i),e.ctx.drawImage(this.primary.canvas,0,0),e.ctx.drawImage(this.overlays.canvas,0,0),e}create_layer(){const{output_backend:e,hidpi:t}=this.model;return new w.CanvasLayer(e,t)}to_blob(){return this.compose().to_blob()}}i.CanvasView=f,f.__name__=\"CanvasView\";class x extends h.HasProps{constructor(e){super(e)}}i.Canvas=x,r=x,x.__name__=\"Canvas\",r.prototype.default_view=f,r.internal((({Boolean:e})=>({hidpi:[e,!0],output_backend:[d.OutputBackend,\"canvas\"]})))},\n", - " function _(t,e,s,n,i){n();const r=t(1),a=(0,r.__importDefault)(t(225)),_=t(15),h=t(19),o=t(43),l=(0,r.__importStar)(t(251)),c=t(252),p=t(9),u=t(8),v=t(27),d=t(230);class g{constructor(t){this.canvas_view=t,this.pan_start=new _.Signal(this,\"pan:start\"),this.pan=new _.Signal(this,\"pan\"),this.pan_end=new _.Signal(this,\"pan:end\"),this.pinch_start=new _.Signal(this,\"pinch:start\"),this.pinch=new _.Signal(this,\"pinch\"),this.pinch_end=new _.Signal(this,\"pinch:end\"),this.rotate_start=new _.Signal(this,\"rotate:start\"),this.rotate=new _.Signal(this,\"rotate\"),this.rotate_end=new _.Signal(this,\"rotate:end\"),this.tap=new _.Signal(this,\"tap\"),this.doubletap=new _.Signal(this,\"doubletap\"),this.press=new _.Signal(this,\"press\"),this.pressup=new _.Signal(this,\"pressup\"),this.move_enter=new _.Signal(this,\"move:enter\"),this.move=new _.Signal(this,\"move\"),this.move_exit=new _.Signal(this,\"move:exit\"),this.scroll=new _.Signal(this,\"scroll\"),this.keydown=new _.Signal(this,\"keydown\"),this.keyup=new _.Signal(this,\"keyup\"),this.hammer=new a.default(this.hit_area,{touchAction:\"auto\",inputClass:a.default.TouchMouseInput}),this._prev_move=null,this._curr_pan=null,this._curr_pinch=null,this._curr_rotate=null,this._configure_hammerjs(),this.hit_area.addEventListener(\"mousemove\",(t=>this._mouse_move(t))),this.hit_area.addEventListener(\"mouseenter\",(t=>this._mouse_enter(t))),this.hit_area.addEventListener(\"mouseleave\",(t=>this._mouse_exit(t))),this.hit_area.addEventListener(\"contextmenu\",(t=>this._context_menu(t))),this.hit_area.addEventListener(\"wheel\",(t=>this._mouse_wheel(t))),document.addEventListener(\"keydown\",this),document.addEventListener(\"keyup\",this),this.menu=new d.ContextMenu([],{prevent_hide:t=>2==t.button&&t.target==this.hit_area}),this.hit_area.appendChild(this.menu.el)}get hit_area(){return this.canvas_view.events_el}destroy(){this.menu.remove(),this.hammer.destroy(),document.removeEventListener(\"keydown\",this),document.removeEventListener(\"keyup\",this)}handleEvent(t){\"keydown\"==t.type?this._key_down(t):\"keyup\"==t.type&&this._key_up(t)}_configure_hammerjs(){this.hammer.get(\"doubletap\").recognizeWith(\"tap\"),this.hammer.get(\"tap\").requireFailure(\"doubletap\"),this.hammer.get(\"doubletap\").dropRequireFailure(\"tap\"),this.hammer.on(\"doubletap\",(t=>this._doubletap(t))),this.hammer.on(\"tap\",(t=>this._tap(t))),this.hammer.on(\"press\",(t=>this._press(t))),this.hammer.on(\"pressup\",(t=>this._pressup(t))),this.hammer.get(\"pan\").set({direction:a.default.DIRECTION_ALL}),this.hammer.on(\"panstart\",(t=>this._pan_start(t))),this.hammer.on(\"pan\",(t=>this._pan(t))),this.hammer.on(\"panend\",(t=>this._pan_end(t))),this.hammer.get(\"pinch\").set({enable:!0}),this.hammer.on(\"pinchstart\",(t=>this._pinch_start(t))),this.hammer.on(\"pinch\",(t=>this._pinch(t))),this.hammer.on(\"pinchend\",(t=>this._pinch_end(t))),this.hammer.get(\"rotate\").set({enable:!0}),this.hammer.on(\"rotatestart\",(t=>this._rotate_start(t))),this.hammer.on(\"rotate\",(t=>this._rotate(t))),this.hammer.on(\"rotateend\",(t=>this._rotate_end(t)))}register_tool(t){const e=t.model.event_type;null!=e&&((0,u.isString)(e)?this._register_tool(t,e):e.forEach(((e,s)=>this._register_tool(t,e,s<1))))}_register_tool(t,e,s=!0){const n=t,{id:i}=n.model,r=t=>e=>{e.id==i&&t(e.e)},a=t=>e=>{t(e.e)};switch(e){case\"pan\":null!=n._pan_start&&n.connect(this.pan_start,r(n._pan_start.bind(n))),null!=n._pan&&n.connect(this.pan,r(n._pan.bind(n))),null!=n._pan_end&&n.connect(this.pan_end,r(n._pan_end.bind(n)));break;case\"pinch\":null!=n._pinch_start&&n.connect(this.pinch_start,r(n._pinch_start.bind(n))),null!=n._pinch&&n.connect(this.pinch,r(n._pinch.bind(n))),null!=n._pinch_end&&n.connect(this.pinch_end,r(n._pinch_end.bind(n)));break;case\"rotate\":null!=n._rotate_start&&n.connect(this.rotate_start,r(n._rotate_start.bind(n))),null!=n._rotate&&n.connect(this.rotate,r(n._rotate.bind(n))),null!=n._rotate_end&&n.connect(this.rotate_end,r(n._rotate_end.bind(n)));break;case\"move\":null!=n._move_enter&&n.connect(this.move_enter,r(n._move_enter.bind(n))),null!=n._move&&n.connect(this.move,r(n._move.bind(n))),null!=n._move_exit&&n.connect(this.move_exit,r(n._move_exit.bind(n)));break;case\"tap\":null!=n._tap&&n.connect(this.tap,r(n._tap.bind(n))),null!=n._doubletap&&n.connect(this.doubletap,r(n._doubletap.bind(n)));break;case\"press\":null!=n._press&&n.connect(this.press,r(n._press.bind(n))),null!=n._pressup&&n.connect(this.pressup,r(n._pressup.bind(n)));break;case\"scroll\":null!=n._scroll&&n.connect(this.scroll,r(n._scroll.bind(n)));break;default:throw new Error(`unsupported event_type: ${e}`)}s&&(null!=n._keydown&&n.connect(this.keydown,a(n._keydown.bind(n))),null!=n._keyup&&n.connect(this.keyup,a(n._keyup.bind(n))),v.is_mobile&&null!=n._scroll&&\"pinch\"==e&&(h.logger.debug(\"Registering scroll on touch screen\"),n.connect(this.scroll,r(n._scroll.bind(n)))))}_hit_test_renderers(t,e,s){var n;const i=t.get_renderer_views();for(const t of(0,p.reversed)(i))if(null===(n=t.interactive_hit)||void 0===n?void 0:n.call(t,e,s))return t;return null}set_cursor(t=\"default\"){this.hit_area.style.cursor=t}_hit_test_frame(t,e,s){return t.frame.bbox.contains(e,s)}_hit_test_canvas(t,e,s){return t.layout.bbox.contains(e,s)}_hit_test_plot(t,e){for(const s of this.canvas_view.plot_views)if(s.layout.bbox.relative().contains(t,e))return s;return null}_trigger(t,e,s){var n;const{sx:i,sy:r}=e,a=this._hit_test_plot(i,r),_=t=>{const[s,n]=[i,r];return Object.assign(Object.assign({},e),{sx:s,sy:n})};if(\"panstart\"==e.type||\"pan\"==e.type||\"panend\"==e.type){let n;if(\"panstart\"==e.type&&null!=a?(this._curr_pan={plot_view:a},n=a):\"pan\"==e.type&&null!=this._curr_pan?n=this._curr_pan.plot_view:\"panend\"==e.type&&null!=this._curr_pan?(n=this._curr_pan.plot_view,this._curr_pan=null):n=null,null!=n){const e=_();this.__trigger(n,t,e,s)}}else if(\"pinchstart\"==e.type||\"pinch\"==e.type||\"pinchend\"==e.type){let n;if(\"pinchstart\"==e.type&&null!=a?(this._curr_pinch={plot_view:a},n=a):\"pinch\"==e.type&&null!=this._curr_pinch?n=this._curr_pinch.plot_view:\"pinchend\"==e.type&&null!=this._curr_pinch?(n=this._curr_pinch.plot_view,this._curr_pinch=null):n=null,null!=n){const e=_();this.__trigger(n,t,e,s)}}else if(\"rotatestart\"==e.type||\"rotate\"==e.type||\"rotateend\"==e.type){let n;if(\"rotatestart\"==e.type&&null!=a?(this._curr_rotate={plot_view:a},n=a):\"rotate\"==e.type&&null!=this._curr_rotate?n=this._curr_rotate.plot_view:\"rotateend\"==e.type&&null!=this._curr_rotate?(n=this._curr_rotate.plot_view,this._curr_rotate=null):n=null,null!=n){const e=_();this.__trigger(n,t,e,s)}}else if(\"mouseenter\"==e.type||\"mousemove\"==e.type||\"mouseleave\"==e.type){const h=null===(n=this._prev_move)||void 0===n?void 0:n.plot_view;if(null!=h&&(\"mouseleave\"==e.type||h!=a)){const{sx:t,sy:e}=_();this.__trigger(h,this.move_exit,{type:\"mouseleave\",sx:t,sy:e,shiftKey:!1,ctrlKey:!1},s)}if(null!=a&&(\"mouseenter\"==e.type||h!=a)){const{sx:t,sy:e}=_();this.__trigger(a,this.move_enter,{type:\"mouseenter\",sx:t,sy:e,shiftKey:!1,ctrlKey:!1},s)}if(null!=a&&\"mousemove\"==e.type){const e=_();this.__trigger(a,t,e,s)}this._prev_move={sx:i,sy:r,plot_view:a}}else if(null!=a){const e=_();this.__trigger(a,t,e,s)}}__trigger(t,e,s,n){var i,r;const a=t.model.toolbar.gestures,_=e.name.split(\":\")[0],h=this._hit_test_renderers(t,s.sx,s.sy),o=this._hit_test_canvas(t,s.sx,s.sy);switch(_){case\"move\":{const n=a[_].active;null!=n&&this.trigger(e,s,n.id);const r=t.model.toolbar.inspectors.filter((t=>t.active));let l=\"default\";null!=h?(l=null!==(i=h.cursor(s.sx,s.sy))&&void 0!==i?i:l,(0,p.is_empty)(r)||(e=this.move_exit)):this._hit_test_frame(t,s.sx,s.sy)&&((0,p.is_empty)(r)||(l=\"crosshair\")),this.set_cursor(l),t.set_toolbar_visibility(o),r.map((t=>this.trigger(e,s,t.id)));break}case\"tap\":{const{target:t}=n;if(null!=t&&t!=this.hit_area)return;null!=h&&null!=h.on_hit&&h.on_hit(s.sx,s.sy);const i=a[_].active;null!=i&&this.trigger(e,s,i.id);break}case\"doubletap\":{const t=null!==(r=a.doubletap.active)&&void 0!==r?r:a.tap.active;null!=t&&this.trigger(e,s,t.id);break}case\"scroll\":{const t=a[v.is_mobile?\"pinch\":\"scroll\"].active;null!=t&&(n.preventDefault(),n.stopPropagation(),this.trigger(e,s,t.id));break}case\"pan\":{const t=a[_].active;null!=t&&(n.preventDefault(),this.trigger(e,s,t.id));break}default:{const t=a[_].active;null!=t&&this.trigger(e,s,t.id)}}this._trigger_bokeh_event(t,s)}trigger(t,e,s=null){t.emit({id:s,e})}_trigger_bokeh_event(t,e){const s=(()=>{const{sx:s,sy:n}=e,i=t.frame.x_scale.invert(s),r=t.frame.y_scale.invert(n);switch(e.type){case\"wheel\":return new l.MouseWheel(s,n,i,r,e.delta);case\"mousemove\":return new l.MouseMove(s,n,i,r);case\"mouseenter\":return new l.MouseEnter(s,n,i,r);case\"mouseleave\":return new l.MouseLeave(s,n,i,r);case\"tap\":return new l.Tap(s,n,i,r);case\"doubletap\":return new l.DoubleTap(s,n,i,r);case\"press\":return new l.Press(s,n,i,r);case\"pressup\":return new l.PressUp(s,n,i,r);case\"pan\":return new l.Pan(s,n,i,r,e.deltaX,e.deltaY);case\"panstart\":return new l.PanStart(s,n,i,r);case\"panend\":return new l.PanEnd(s,n,i,r);case\"pinch\":return new l.Pinch(s,n,i,r,e.scale);case\"pinchstart\":return new l.PinchStart(s,n,i,r);case\"pinchend\":return new l.PinchEnd(s,n,i,r);case\"rotate\":return new l.Rotate(s,n,i,r,e.rotation);case\"rotatestart\":return new l.RotateStart(s,n,i,r);case\"rotateend\":return new l.RotateEnd(s,n,i,r);default:return}})();null!=s&&t.model.trigger_event(s)}_get_sxy(t){const{pageX:e,pageY:s}=function(t){return\"undefined\"!=typeof TouchEvent&&t instanceof TouchEvent}(t)?(0!=t.touches.length?t.touches:t.changedTouches)[0]:t,{left:n,top:i}=(0,o.offset)(this.hit_area);return{sx:e-n,sy:s-i}}_pan_event(t){return Object.assign(Object.assign({type:t.type},this._get_sxy(t.srcEvent)),{deltaX:t.deltaX,deltaY:t.deltaY,shiftKey:t.srcEvent.shiftKey,ctrlKey:t.srcEvent.ctrlKey})}_pinch_event(t){return Object.assign(Object.assign({type:t.type},this._get_sxy(t.srcEvent)),{scale:t.scale,shiftKey:t.srcEvent.shiftKey,ctrlKey:t.srcEvent.ctrlKey})}_rotate_event(t){return Object.assign(Object.assign({type:t.type},this._get_sxy(t.srcEvent)),{rotation:t.rotation,shiftKey:t.srcEvent.shiftKey,ctrlKey:t.srcEvent.ctrlKey})}_tap_event(t){return Object.assign(Object.assign({type:t.type},this._get_sxy(t.srcEvent)),{shiftKey:t.srcEvent.shiftKey,ctrlKey:t.srcEvent.ctrlKey})}_move_event(t){return Object.assign(Object.assign({type:t.type},this._get_sxy(t)),{shiftKey:t.shiftKey,ctrlKey:t.ctrlKey})}_scroll_event(t){return Object.assign(Object.assign({type:t.type},this._get_sxy(t)),{delta:(0,c.getDeltaY)(t),shiftKey:t.shiftKey,ctrlKey:t.ctrlKey})}_key_event(t){return{type:t.type,keyCode:t.keyCode}}_pan_start(t){const e=this._pan_event(t);e.sx-=t.deltaX,e.sy-=t.deltaY,this._trigger(this.pan_start,e,t.srcEvent)}_pan(t){this._trigger(this.pan,this._pan_event(t),t.srcEvent)}_pan_end(t){this._trigger(this.pan_end,this._pan_event(t),t.srcEvent)}_pinch_start(t){this._trigger(this.pinch_start,this._pinch_event(t),t.srcEvent)}_pinch(t){this._trigger(this.pinch,this._pinch_event(t),t.srcEvent)}_pinch_end(t){this._trigger(this.pinch_end,this._pinch_event(t),t.srcEvent)}_rotate_start(t){this._trigger(this.rotate_start,this._rotate_event(t),t.srcEvent)}_rotate(t){this._trigger(this.rotate,this._rotate_event(t),t.srcEvent)}_rotate_end(t){this._trigger(this.rotate_end,this._rotate_event(t),t.srcEvent)}_tap(t){this._trigger(this.tap,this._tap_event(t),t.srcEvent)}_doubletap(t){this._trigger(this.doubletap,this._tap_event(t),t.srcEvent)}_press(t){this._trigger(this.press,this._tap_event(t),t.srcEvent)}_pressup(t){this._trigger(this.pressup,this._tap_event(t),t.srcEvent)}_mouse_enter(t){this._trigger(this.move_enter,this._move_event(t),t)}_mouse_move(t){this._trigger(this.move,this._move_event(t),t)}_mouse_exit(t){this._trigger(this.move_exit,this._move_event(t),t)}_mouse_wheel(t){this._trigger(this.scroll,this._scroll_event(t),t)}_context_menu(t){!this.menu.is_open&&this.menu.can_open&&t.preventDefault();const{sx:e,sy:s}=this._get_sxy(t);this.menu.toggle({left:e,top:s})}_key_down(t){this.trigger(this.keydown,this._key_event(t))}_key_up(t){this.trigger(this.keyup,this._key_event(t))}}s.UIEventBus=g,g.__name__=\"UIEventBus\"},\n", + " function _(e,t,i,s,a){var l,r=this&&this.__createBinding||(Object.create?function(e,t,i,s){void 0===s&&(s=i),Object.defineProperty(e,s,{enumerable:!0,get:function(){return t[i]}})}:function(e,t,i,s){void 0===s&&(s=i),e[s]=t[i]}),n=this&&this.__setModuleDefault||(Object.create?function(e,t){Object.defineProperty(e,\"default\",{enumerable:!0,value:t})}:function(e,t){e.default=t}),o=this&&this.__importStar||function(e){if(e&&e.__esModule)return e;var t={};if(null!=e)for(var i in e)\"default\"!==i&&Object.prototype.hasOwnProperty.call(e,i)&&r(t,e,i);return n(t,e),t};s();const h=e(14),c=e(28),u=e(226),_=e(19),d=e(43),p=e(20),b=e(13),v=e(250),g=e(65),w=e(138),y=e(235);const f=(()=>{let t;return async()=>void 0!==t?t:t=await async function(){const t=document.createElement(\"canvas\"),i=t.getContext(\"webgl\",{premultipliedAlpha:!0});if(null!=i){const s=await(0,w.load_module)(Promise.resolve().then((()=>o(e(410)))));if(null!=s){const e=s.get_regl(i);if(e.has_webgl)return{canvas:t,regl_wrapper:e};_.logger.trace(\"WebGL is supported, but not the required extensions\")}else _.logger.trace(\"WebGL is supported, but bokehjs(.min).js bundle is not available\")}else _.logger.trace(\"WebGL is not supported\");return null}()})(),m={position:\"absolute\",top:\"0\",left:\"0\",width:\"100%\",height:\"100%\"};class x extends u.DOMView{constructor(){super(...arguments),this.bbox=new g.BBox,this.webgl=null}initialize(){super.initialize(),this.underlays_el=(0,d.div)({style:m}),this.primary=this.create_layer(),this.overlays=this.create_layer(),this.overlays_el=(0,d.div)({style:m}),this.events_el=(0,d.div)({class:\"bk-canvas-events\",style:m});const e=[this.underlays_el,this.primary.el,this.overlays.el,this.overlays_el,this.events_el];(0,b.extend)(this.el.style,m),(0,d.append)(this.el,...e),this.ui_event_bus=new v.UIEventBus(this)}async lazy_initialize(){if(await super.lazy_initialize(),\"webgl\"==this.model.output_backend&&(this.webgl=await f(),c.settings.force_webgl&&null==this.webgl))throw new Error(\"webgl is not available\")}remove(){this.ui_event_bus.destroy(),super.remove()}add_underlay(e){this.underlays_el.appendChild(e)}add_overlay(e){this.overlays_el.appendChild(e)}add_event(e){this.events_el.appendChild(e)}get pixel_ratio(){return this.primary.pixel_ratio}resize(e,t){this.bbox=new g.BBox({left:0,top:0,width:e,height:t}),this.primary.resize(e,t),this.overlays.resize(e,t)}prepare_webgl(e){const{webgl:t}=this;if(null!=t){const{width:i,height:s}=this.bbox;t.canvas.width=this.pixel_ratio*i,t.canvas.height=this.pixel_ratio*s;const[a,l,r,n]=e,{xview:o,yview:h}=this.bbox,c=o.compute(a),u=h.compute(l+n),_=this.pixel_ratio;t.regl_wrapper.set_scissor(_*c,_*u,_*r,_*n),this._clear_webgl()}}blit_webgl(e){const{webgl:t}=this;if(null!=t){if(_.logger.debug(\"Blitting WebGL canvas\"),e.restore(),e.drawImage(t.canvas,0,0),e.save(),this.model.hidpi){const t=this.pixel_ratio;e.scale(t,t),e.translate(.5,.5)}this._clear_webgl()}}_clear_webgl(){const{webgl:e}=this;if(null!=e){const{regl_wrapper:t,canvas:i}=e;t.clear(i.width,i.height)}}compose(){const e=this.create_layer(),{width:t,height:i}=this.bbox;return e.resize(t,i),e.ctx.drawImage(this.primary.canvas,0,0),e.ctx.drawImage(this.overlays.canvas,0,0),e}create_layer(){const{output_backend:e,hidpi:t}=this.model;return new y.CanvasLayer(e,t)}to_blob(){return this.compose().to_blob()}}i.CanvasView=x,x.__name__=\"CanvasView\";class z extends h.HasProps{constructor(e){super(e)}}i.Canvas=z,l=z,z.__name__=\"Canvas\",l.prototype.default_view=x,l.internal((({Boolean:e})=>({hidpi:[e,!0],output_backend:[p.OutputBackend,\"canvas\"]})))},\n", + " function _(t,e,s,n,i){n();const r=t(1),a=(0,r.__importDefault)(t(225)),_=t(15),h=t(19),o=t(43),l=(0,r.__importStar)(t(251)),c=t(252),p=t(9),u=t(8),v=t(27),d=t(230);class g{constructor(t){this.canvas_view=t,this.pan_start=new _.Signal(this,\"pan:start\"),this.pan=new _.Signal(this,\"pan\"),this.pan_end=new _.Signal(this,\"pan:end\"),this.pinch_start=new _.Signal(this,\"pinch:start\"),this.pinch=new _.Signal(this,\"pinch\"),this.pinch_end=new _.Signal(this,\"pinch:end\"),this.rotate_start=new _.Signal(this,\"rotate:start\"),this.rotate=new _.Signal(this,\"rotate\"),this.rotate_end=new _.Signal(this,\"rotate:end\"),this.tap=new _.Signal(this,\"tap\"),this.doubletap=new _.Signal(this,\"doubletap\"),this.press=new _.Signal(this,\"press\"),this.pressup=new _.Signal(this,\"pressup\"),this.move_enter=new _.Signal(this,\"move:enter\"),this.move=new _.Signal(this,\"move\"),this.move_exit=new _.Signal(this,\"move:exit\"),this.scroll=new _.Signal(this,\"scroll\"),this.keydown=new _.Signal(this,\"keydown\"),this.keyup=new _.Signal(this,\"keyup\"),this.hammer=new a.default(this.hit_area,{touchAction:\"auto\",inputClass:a.default.TouchMouseInput}),this._prev_move=null,this._curr_pan=null,this._curr_pinch=null,this._curr_rotate=null,this._configure_hammerjs(),this.hit_area.addEventListener(\"mousemove\",(t=>this._mouse_move(t))),this.hit_area.addEventListener(\"mouseenter\",(t=>this._mouse_enter(t))),this.hit_area.addEventListener(\"mouseleave\",(t=>this._mouse_exit(t))),this.hit_area.addEventListener(\"contextmenu\",(t=>this._context_menu(t))),this.hit_area.addEventListener(\"wheel\",(t=>this._mouse_wheel(t))),document.addEventListener(\"keydown\",this),document.addEventListener(\"keyup\",this),this.menu=new d.ContextMenu([],{prevent_hide:t=>2==t.button&&t.target==this.hit_area}),this.hit_area.appendChild(this.menu.el)}get hit_area(){return this.canvas_view.events_el}destroy(){this.menu.remove(),this.hammer.destroy(),document.removeEventListener(\"keydown\",this),document.removeEventListener(\"keyup\",this)}handleEvent(t){\"keydown\"==t.type?this._key_down(t):\"keyup\"==t.type&&this._key_up(t)}_configure_hammerjs(){this.hammer.get(\"doubletap\").recognizeWith(\"tap\"),this.hammer.get(\"tap\").requireFailure(\"doubletap\"),this.hammer.get(\"doubletap\").dropRequireFailure(\"tap\"),this.hammer.on(\"doubletap\",(t=>this._doubletap(t))),this.hammer.on(\"tap\",(t=>this._tap(t))),this.hammer.on(\"press\",(t=>this._press(t))),this.hammer.on(\"pressup\",(t=>this._pressup(t))),this.hammer.get(\"pan\").set({direction:a.default.DIRECTION_ALL}),this.hammer.on(\"panstart\",(t=>this._pan_start(t))),this.hammer.on(\"pan\",(t=>this._pan(t))),this.hammer.on(\"panend\",(t=>this._pan_end(t))),this.hammer.get(\"pinch\").set({enable:!0}),this.hammer.on(\"pinchstart\",(t=>this._pinch_start(t))),this.hammer.on(\"pinch\",(t=>this._pinch(t))),this.hammer.on(\"pinchend\",(t=>this._pinch_end(t))),this.hammer.get(\"rotate\").set({enable:!0}),this.hammer.on(\"rotatestart\",(t=>this._rotate_start(t))),this.hammer.on(\"rotate\",(t=>this._rotate(t))),this.hammer.on(\"rotateend\",(t=>this._rotate_end(t)))}register_tool(t){const e=t.model.event_type;null!=e&&((0,u.isString)(e)?this._register_tool(t,e):e.forEach(((e,s)=>this._register_tool(t,e,s<1))))}_register_tool(t,e,s=!0){const n=t,{id:i}=n.model,r=t=>e=>{e.id==i&&t(e.e)},a=t=>e=>{t(e.e)};switch(e){case\"pan\":null!=n._pan_start&&n.connect(this.pan_start,r(n._pan_start.bind(n))),null!=n._pan&&n.connect(this.pan,r(n._pan.bind(n))),null!=n._pan_end&&n.connect(this.pan_end,r(n._pan_end.bind(n)));break;case\"pinch\":null!=n._pinch_start&&n.connect(this.pinch_start,r(n._pinch_start.bind(n))),null!=n._pinch&&n.connect(this.pinch,r(n._pinch.bind(n))),null!=n._pinch_end&&n.connect(this.pinch_end,r(n._pinch_end.bind(n)));break;case\"rotate\":null!=n._rotate_start&&n.connect(this.rotate_start,r(n._rotate_start.bind(n))),null!=n._rotate&&n.connect(this.rotate,r(n._rotate.bind(n))),null!=n._rotate_end&&n.connect(this.rotate_end,r(n._rotate_end.bind(n)));break;case\"move\":null!=n._move_enter&&n.connect(this.move_enter,r(n._move_enter.bind(n))),null!=n._move&&n.connect(this.move,r(n._move.bind(n))),null!=n._move_exit&&n.connect(this.move_exit,r(n._move_exit.bind(n)));break;case\"tap\":null!=n._tap&&n.connect(this.tap,r(n._tap.bind(n))),null!=n._doubletap&&n.connect(this.doubletap,r(n._doubletap.bind(n)));break;case\"press\":null!=n._press&&n.connect(this.press,r(n._press.bind(n))),null!=n._pressup&&n.connect(this.pressup,r(n._pressup.bind(n)));break;case\"scroll\":null!=n._scroll&&n.connect(this.scroll,r(n._scroll.bind(n)));break;default:throw new Error(`unsupported event_type: ${e}`)}s&&(null!=n._keydown&&n.connect(this.keydown,a(n._keydown.bind(n))),null!=n._keyup&&n.connect(this.keyup,a(n._keyup.bind(n))),v.is_mobile&&null!=n._scroll&&\"pinch\"==e&&(h.logger.debug(\"Registering scroll on touch screen\"),n.connect(this.scroll,r(n._scroll.bind(n)))))}_hit_test_renderers(t,e,s){var n;const i=t.get_renderer_views();for(const t of(0,p.reversed)(i))if(null===(n=t.interactive_hit)||void 0===n?void 0:n.call(t,e,s))return t;return null}set_cursor(t=\"default\"){this.hit_area.style.cursor=t}_hit_test_frame(t,e,s){return t.frame.bbox.contains(e,s)}_hit_test_canvas(t,e,s){return t.layout.bbox.contains(e,s)}_hit_test_plot(t,e){for(const s of this.canvas_view.plot_views)if(s.layout.bbox.relative().contains(t,e))return s;return null}_trigger(t,e,s){var n;const{sx:i,sy:r}=e,a=this._hit_test_plot(i,r),_=t=>{const[s,n]=[i,r];return Object.assign(Object.assign({},e),{sx:s,sy:n})};if(\"panstart\"==e.type||\"pan\"==e.type||\"panend\"==e.type){let n;if(\"panstart\"==e.type&&null!=a?(this._curr_pan={plot_view:a},n=a):\"pan\"==e.type&&null!=this._curr_pan?n=this._curr_pan.plot_view:\"panend\"==e.type&&null!=this._curr_pan?(n=this._curr_pan.plot_view,this._curr_pan=null):n=null,null!=n){const e=_();this.__trigger(n,t,e,s)}}else if(\"pinchstart\"==e.type||\"pinch\"==e.type||\"pinchend\"==e.type){let n;if(\"pinchstart\"==e.type&&null!=a?(this._curr_pinch={plot_view:a},n=a):\"pinch\"==e.type&&null!=this._curr_pinch?n=this._curr_pinch.plot_view:\"pinchend\"==e.type&&null!=this._curr_pinch?(n=this._curr_pinch.plot_view,this._curr_pinch=null):n=null,null!=n){const e=_();this.__trigger(n,t,e,s)}}else if(\"rotatestart\"==e.type||\"rotate\"==e.type||\"rotateend\"==e.type){let n;if(\"rotatestart\"==e.type&&null!=a?(this._curr_rotate={plot_view:a},n=a):\"rotate\"==e.type&&null!=this._curr_rotate?n=this._curr_rotate.plot_view:\"rotateend\"==e.type&&null!=this._curr_rotate?(n=this._curr_rotate.plot_view,this._curr_rotate=null):n=null,null!=n){const e=_();this.__trigger(n,t,e,s)}}else if(\"mouseenter\"==e.type||\"mousemove\"==e.type||\"mouseleave\"==e.type){const h=null===(n=this._prev_move)||void 0===n?void 0:n.plot_view;if(null!=h&&(\"mouseleave\"==e.type||h!=a)){const{sx:t,sy:e}=_();this.__trigger(h,this.move_exit,{type:\"mouseleave\",sx:t,sy:e,shiftKey:!1,ctrlKey:!1},s)}if(null!=a&&(\"mouseenter\"==e.type||h!=a)){const{sx:t,sy:e}=_();this.__trigger(a,this.move_enter,{type:\"mouseenter\",sx:t,sy:e,shiftKey:!1,ctrlKey:!1},s)}if(null!=a&&\"mousemove\"==e.type){const e=_();this.__trigger(a,t,e,s)}this._prev_move={sx:i,sy:r,plot_view:a}}else if(null!=a){const e=_();this.__trigger(a,t,e,s)}}__trigger(t,e,s,n){var i,r,a;const _=t.model.toolbar.gestures,h=e.name.split(\":\")[0],o=this._hit_test_renderers(t,s.sx,s.sy),l=this._hit_test_canvas(t,s.sx,s.sy);switch(h){case\"move\":{const n=_.move.active;null!=n&&this.trigger(e,s,n.id);const r=t.model.toolbar.inspectors.filter((t=>t.active));let a=\"default\";null!=o?(a=null!==(i=o.cursor(s.sx,s.sy))&&void 0!==i?i:a,(0,p.is_empty)(r)||(e=this.move_exit)):this._hit_test_frame(t,s.sx,s.sy)&&((0,p.is_empty)(r)||(a=\"crosshair\")),this.set_cursor(a),t.set_toolbar_visibility(l),r.map((t=>this.trigger(e,s,t.id)));break}case\"tap\":{const{target:i}=n;if(null!=i&&i!=this.hit_area)return;if(null===(r=null==o?void 0:o.on_hit)||void 0===r||r.call(o,s.sx,s.sy),this._hit_test_frame(t,s.sx,s.sy)){const t=_.tap.active;null!=t&&this.trigger(e,s,t.id)}break}case\"doubletap\":if(this._hit_test_frame(t,s.sx,s.sy)){const t=null!==(a=_.doubletap.active)&&void 0!==a?a:_.tap.active;null!=t&&this.trigger(e,s,t.id)}break;case\"scroll\":{const t=_[v.is_mobile?\"pinch\":\"scroll\"].active;null!=t&&(n.preventDefault(),n.stopPropagation(),this.trigger(e,s,t.id));break}case\"pan\":{const t=_.pan.active;null!=t&&(n.preventDefault(),this.trigger(e,s,t.id));break}default:{const t=_[h].active;null!=t&&this.trigger(e,s,t.id)}}this._trigger_bokeh_event(t,s)}trigger(t,e,s=null){t.emit({id:s,e})}_trigger_bokeh_event(t,e){const s=(()=>{const{sx:s,sy:n}=e,i=t.frame.x_scale.invert(s),r=t.frame.y_scale.invert(n);switch(e.type){case\"wheel\":return new l.MouseWheel(s,n,i,r,e.delta);case\"mousemove\":return new l.MouseMove(s,n,i,r);case\"mouseenter\":return new l.MouseEnter(s,n,i,r);case\"mouseleave\":return new l.MouseLeave(s,n,i,r);case\"tap\":return new l.Tap(s,n,i,r);case\"doubletap\":return new l.DoubleTap(s,n,i,r);case\"press\":return new l.Press(s,n,i,r);case\"pressup\":return new l.PressUp(s,n,i,r);case\"pan\":return new l.Pan(s,n,i,r,e.deltaX,e.deltaY);case\"panstart\":return new l.PanStart(s,n,i,r);case\"panend\":return new l.PanEnd(s,n,i,r);case\"pinch\":return new l.Pinch(s,n,i,r,e.scale);case\"pinchstart\":return new l.PinchStart(s,n,i,r);case\"pinchend\":return new l.PinchEnd(s,n,i,r);case\"rotate\":return new l.Rotate(s,n,i,r,e.rotation);case\"rotatestart\":return new l.RotateStart(s,n,i,r);case\"rotateend\":return new l.RotateEnd(s,n,i,r);default:return}})();null!=s&&t.model.trigger_event(s)}_get_sxy(t){const{pageX:e,pageY:s}=function(t){return\"undefined\"!=typeof TouchEvent&&t instanceof TouchEvent}(t)?(0!=t.touches.length?t.touches:t.changedTouches)[0]:t,{left:n,top:i}=(0,o.offset)(this.hit_area);return{sx:e-n,sy:s-i}}_pan_event(t){return Object.assign(Object.assign({type:t.type},this._get_sxy(t.srcEvent)),{deltaX:t.deltaX,deltaY:t.deltaY,shiftKey:t.srcEvent.shiftKey,ctrlKey:t.srcEvent.ctrlKey})}_pinch_event(t){return Object.assign(Object.assign({type:t.type},this._get_sxy(t.srcEvent)),{scale:t.scale,shiftKey:t.srcEvent.shiftKey,ctrlKey:t.srcEvent.ctrlKey})}_rotate_event(t){return Object.assign(Object.assign({type:t.type},this._get_sxy(t.srcEvent)),{rotation:t.rotation,shiftKey:t.srcEvent.shiftKey,ctrlKey:t.srcEvent.ctrlKey})}_tap_event(t){return Object.assign(Object.assign({type:t.type},this._get_sxy(t.srcEvent)),{shiftKey:t.srcEvent.shiftKey,ctrlKey:t.srcEvent.ctrlKey})}_move_event(t){return Object.assign(Object.assign({type:t.type},this._get_sxy(t)),{shiftKey:t.shiftKey,ctrlKey:t.ctrlKey})}_scroll_event(t){return Object.assign(Object.assign({type:t.type},this._get_sxy(t)),{delta:(0,c.getDeltaY)(t),shiftKey:t.shiftKey,ctrlKey:t.ctrlKey})}_key_event(t){return{type:t.type,keyCode:t.keyCode}}_pan_start(t){const e=this._pan_event(t);e.sx-=t.deltaX,e.sy-=t.deltaY,this._trigger(this.pan_start,e,t.srcEvent)}_pan(t){this._trigger(this.pan,this._pan_event(t),t.srcEvent)}_pan_end(t){this._trigger(this.pan_end,this._pan_event(t),t.srcEvent)}_pinch_start(t){this._trigger(this.pinch_start,this._pinch_event(t),t.srcEvent)}_pinch(t){this._trigger(this.pinch,this._pinch_event(t),t.srcEvent)}_pinch_end(t){this._trigger(this.pinch_end,this._pinch_event(t),t.srcEvent)}_rotate_start(t){this._trigger(this.rotate_start,this._rotate_event(t),t.srcEvent)}_rotate(t){this._trigger(this.rotate,this._rotate_event(t),t.srcEvent)}_rotate_end(t){this._trigger(this.rotate_end,this._rotate_event(t),t.srcEvent)}_tap(t){this._trigger(this.tap,this._tap_event(t),t.srcEvent)}_doubletap(t){this._trigger(this.doubletap,this._tap_event(t),t.srcEvent)}_press(t){this._trigger(this.press,this._tap_event(t),t.srcEvent)}_pressup(t){this._trigger(this.pressup,this._tap_event(t),t.srcEvent)}_mouse_enter(t){this._trigger(this.move_enter,this._move_event(t),t)}_mouse_move(t){this._trigger(this.move,this._move_event(t),t)}_mouse_exit(t){this._trigger(this.move_exit,this._move_event(t),t)}_mouse_wheel(t){this._trigger(this.scroll,this._scroll_event(t),t)}_context_menu(t){!this.menu.is_open&&this.menu.can_open&&t.preventDefault();const{sx:e,sy:s}=this._get_sxy(t);this.menu.toggle({left:e,top:s})}_key_down(t){this.trigger(this.keydown,this._key_event(t))}_key_up(t){this.trigger(this.keyup,this._key_event(t))}}s.UIEventBus=g,g.__name__=\"UIEventBus\"},\n", " function _(e,t,s,n,_){n();var a=this&&this.__decorate||function(e,t,s,n){var _,a=arguments.length,o=a<3?t:null===n?n=Object.getOwnPropertyDescriptor(t,s):n;if(\"object\"==typeof Reflect&&\"function\"==typeof Reflect.decorate)o=Reflect.decorate(e,t,s,n);else for(var r=e.length-1;r>=0;r--)(_=e[r])&&(o=(a<3?_(o):a>3?_(t,s,o):_(t,s))||o);return a>3&&o&&Object.defineProperty(t,s,o),o};function o(e){return function(t){t.prototype.event_name=e}}class r{to_json(){const{event_name:e}=this;return{event_name:e,event_values:this._to_json()}}}s.BokehEvent=r,r.__name__=\"BokehEvent\";class c extends r{constructor(){super(...arguments),this.origin=null}_to_json(){return{model:this.origin}}}s.ModelEvent=c,c.__name__=\"ModelEvent\";let l=class extends r{_to_json(){return{}}};s.DocumentReady=l,l.__name__=\"DocumentReady\",s.DocumentReady=l=a([o(\"document_ready\")],l);let i=class extends c{};s.ButtonClick=i,i.__name__=\"ButtonClick\",s.ButtonClick=i=a([o(\"button_click\")],i);let u=class extends c{constructor(e){super(),this.item=e}_to_json(){const{item:e}=this;return Object.assign(Object.assign({},super._to_json()),{item:e})}};s.MenuItemClick=u,u.__name__=\"MenuItemClick\",s.MenuItemClick=u=a([o(\"menu_item_click\")],u);class d extends c{}s.UIEvent=d,d.__name__=\"UIEvent\";let m=class extends d{};s.LODStart=m,m.__name__=\"LODStart\",s.LODStart=m=a([o(\"lodstart\")],m);let h=class extends d{};s.LODEnd=h,h.__name__=\"LODEnd\",s.LODEnd=h=a([o(\"lodend\")],h);let p=class extends d{constructor(e,t,s,n){super(),this.x0=e,this.x1=t,this.y0=s,this.y1=n}_to_json(){const{x0:e,x1:t,y0:s,y1:n}=this;return Object.assign(Object.assign({},super._to_json()),{x0:e,x1:t,y0:s,y1:n})}};s.RangesUpdate=p,p.__name__=\"RangesUpdate\",s.RangesUpdate=p=a([o(\"rangesupdate\")],p);let x=class extends d{constructor(e,t){super(),this.geometry=e,this.final=t}_to_json(){const{geometry:e,final:t}=this;return Object.assign(Object.assign({},super._to_json()),{geometry:e,final:t})}};s.SelectionGeometry=x,x.__name__=\"SelectionGeometry\",s.SelectionGeometry=x=a([o(\"selectiongeometry\")],x);let j=class extends d{};s.Reset=j,j.__name__=\"Reset\",s.Reset=j=a([o(\"reset\")],j);class y extends d{constructor(e,t,s,n){super(),this.sx=e,this.sy=t,this.x=s,this.y=n}_to_json(){const{sx:e,sy:t,x:s,y:n}=this;return Object.assign(Object.assign({},super._to_json()),{sx:e,sy:t,x:s,y:n})}}s.PointEvent=y,y.__name__=\"PointEvent\";let g=class extends y{constructor(e,t,s,n,_,a){super(e,t,s,n),this.delta_x=_,this.delta_y=a}_to_json(){const{delta_x:e,delta_y:t}=this;return Object.assign(Object.assign({},super._to_json()),{delta_x:e,delta_y:t})}};s.Pan=g,g.__name__=\"Pan\",s.Pan=g=a([o(\"pan\")],g);let P=class extends y{constructor(e,t,s,n,_){super(e,t,s,n),this.scale=_}_to_json(){const{scale:e}=this;return Object.assign(Object.assign({},super._to_json()),{scale:e})}};s.Pinch=P,P.__name__=\"Pinch\",s.Pinch=P=a([o(\"pinch\")],P);let O=class extends y{constructor(e,t,s,n,_){super(e,t,s,n),this.rotation=_}_to_json(){const{rotation:e}=this;return Object.assign(Object.assign({},super._to_json()),{rotation:e})}};s.Rotate=O,O.__name__=\"Rotate\",s.Rotate=O=a([o(\"rotate\")],O);let b=class extends y{constructor(e,t,s,n,_){super(e,t,s,n),this.delta=_}_to_json(){const{delta:e}=this;return Object.assign(Object.assign({},super._to_json()),{delta:e})}};s.MouseWheel=b,b.__name__=\"MouseWheel\",s.MouseWheel=b=a([o(\"wheel\")],b);let v=class extends y{};s.MouseMove=v,v.__name__=\"MouseMove\",s.MouseMove=v=a([o(\"mousemove\")],v);let E=class extends y{};s.MouseEnter=E,E.__name__=\"MouseEnter\",s.MouseEnter=E=a([o(\"mouseenter\")],E);let R=class extends y{};s.MouseLeave=R,R.__name__=\"MouseLeave\",s.MouseLeave=R=a([o(\"mouseleave\")],R);let M=class extends y{};s.Tap=M,M.__name__=\"Tap\",s.Tap=M=a([o(\"tap\")],M);let f=class extends y{};s.DoubleTap=f,f.__name__=\"DoubleTap\",s.DoubleTap=f=a([o(\"doubletap\")],f);let S=class extends y{};s.Press=S,S.__name__=\"Press\",s.Press=S=a([o(\"press\")],S);let D=class extends y{};s.PressUp=D,D.__name__=\"PressUp\",s.PressUp=D=a([o(\"pressup\")],D);let k=class extends y{};s.PanStart=k,k.__name__=\"PanStart\",s.PanStart=k=a([o(\"panstart\")],k);let L=class extends y{};s.PanEnd=L,L.__name__=\"PanEnd\",s.PanEnd=L=a([o(\"panend\")],L);let U=class extends y{};s.PinchStart=U,U.__name__=\"PinchStart\",s.PinchStart=U=a([o(\"pinchstart\")],U);let C=class extends y{};s.PinchEnd=C,C.__name__=\"PinchEnd\",s.PinchEnd=C=a([o(\"pinchend\")],C);let T=class extends y{};s.RotateStart=T,T.__name__=\"RotateStart\",s.RotateStart=T=a([o(\"rotatestart\")],T);let B=class extends y{};s.RotateEnd=B,B.__name__=\"RotateEnd\",s.RotateEnd=B=a([o(\"rotateend\")],B)},\n", " function _(t,e,n,l,o){\n", " /*!\n", @@ -672,17 +691,17 @@ " function _(n,e,t,o,r){var u;o();const s=n(191),c=n(24),i=n(19);class l extends s.Filter{constructor(n){super(n)}compute_indices(n){const e=n.get_column(this.column_name);if(null==e)return i.logger.warn(`${this}: groupby column '${this.column_name}' not found in the data source`),new c.Indices(n.length,1);{const t=new c.Indices(n.length);for(let n=0;n({column_name:[n],group:[n]})))},\n", " function _(e,n,i,s,t){var l;s();const c=e(191),r=e(24);class d extends c.Filter{constructor(e){super(e)}compute_indices(e){const n=e.length,{indices:i}=this;return null==i?r.Indices.all_set(n):r.Indices.from_indices(n,i)}}i.IndexFilter=d,l=d,d.__name__=\"IndexFilter\",l.define((({Int:e,Array:n,Nullable:i})=>({indices:[i(n(e)),null]})))},\n", " function _(e,a,l,i,t){i(),t(\"AnnularWedge\",e(268).AnnularWedge),t(\"Annulus\",e(269).Annulus),t(\"Arc\",e(270).Arc),t(\"Bezier\",e(271).Bezier),t(\"Circle\",e(272).Circle),t(\"Ellipse\",e(273).Ellipse),t(\"EllipseOval\",e(274).EllipseOval),t(\"Glyph\",e(179).Glyph),t(\"HArea\",e(187).HArea),t(\"HBar\",e(276).HBar),t(\"HexTile\",e(278).HexTile),t(\"Image\",e(279).Image),t(\"ImageRGBA\",e(281).ImageRGBA),t(\"ImageURL\",e(282).ImageURL),t(\"Line\",e(177).Line),t(\"MultiLine\",e(283).MultiLine),t(\"MultiPolygons\",e(284).MultiPolygons),t(\"Oval\",e(285).Oval),t(\"Patch\",e(186).Patch),t(\"Patches\",e(286).Patches),t(\"Quad\",e(287).Quad),t(\"Quadratic\",e(288).Quadratic),t(\"Ray\",e(289).Ray),t(\"Rect\",e(290).Rect),t(\"Scatter\",e(291).Scatter),t(\"Segment\",e(294).Segment),t(\"Spline\",e(295).Spline),t(\"Step\",e(297).Step),t(\"Text\",e(298).Text),t(\"VArea\",e(189).VArea),t(\"VBar\",e(299).VBar),t(\"Wedge\",e(300).Wedge)},\n", - " function _(e,t,s,i,r){i();const n=e(1);var a;const o=e(178),_=e(184),d=e(48),u=e(24),h=e(20),c=(0,n.__importStar)(e(18)),l=e(10),p=e(72);class x extends o.XYGlyphView{_map_data(){\"data\"==this.model.properties.inner_radius.units?this.sinner_radius=this.sdist(this.renderer.xscale,this._x,this.inner_radius):this.sinner_radius=(0,u.to_screen)(this.inner_radius),\"data\"==this.model.properties.outer_radius.units?this.souter_radius=this.sdist(this.renderer.xscale,this._x,this.outer_radius):this.souter_radius=(0,u.to_screen)(this.outer_radius)}_render(e,t,s){const{sx:i,sy:r,start_angle:n,end_angle:a,sinner_radius:o,souter_radius:_}=null!=s?s:this,d=\"anticlock\"==this.model.direction;for(const s of t){const t=i[s],u=r[s],h=o[s],c=_[s],l=n.get(s),p=a.get(s);if(!isFinite(t+u+h+c+l+p))continue;const x=p-l;e.translate(t,u),e.rotate(l),e.beginPath(),e.moveTo(c,0),e.arc(0,0,c,0,x,d),e.rotate(x),e.lineTo(h,0),e.arc(0,0,h,0,-x,!d),e.closePath(),e.rotate(-x-l),e.translate(-t,-u),this.visuals.fill.apply(e,s),this.visuals.hatch.apply(e,s),this.visuals.line.apply(e,s)}}_hit_point(e){const{sx:t,sy:s}=e,i=this.renderer.xscale.invert(t),r=this.renderer.yscale.invert(s);let n,a,o,_;if(\"data\"==this.model.properties.outer_radius.units)n=i-this.max_outer_radius,o=i+this.max_outer_radius,a=r-this.max_outer_radius,_=r+this.max_outer_radius;else{const e=t-this.max_outer_radius,i=t+this.max_outer_radius;[n,o]=this.renderer.xscale.r_invert(e,i);const r=s-this.max_outer_radius,d=s+this.max_outer_radius;[a,_]=this.renderer.yscale.r_invert(r,d)}const d=[];for(const e of this.index.indices({x0:n,x1:o,y0:a,y1:_})){const t=this.souter_radius[e]**2,s=this.sinner_radius[e]**2,[n,a]=this.renderer.xscale.r_compute(i,this._x[e]),[o,_]=this.renderer.yscale.r_compute(r,this._y[e]),u=(n-a)**2+(o-_)**2;u<=t&&u>=s&&d.push(e)}const u=\"anticlock\"==this.model.direction,h=[];for(const e of d){const i=Math.atan2(s-this.sy[e],t-this.sx[e]);(0,l.angle_between)(-i,-this.start_angle.get(e),-this.end_angle.get(e),u)&&h.push(e)}return new p.Selection({indices:h})}draw_legend_for_index(e,t,s){(0,_.generic_area_vector_legend)(this.visuals,e,t,s)}scenterxy(e){const t=(this.sinner_radius[e]+this.souter_radius[e])/2,s=(this.start_angle.get(e)+this.end_angle.get(e))/2;return[this.sx[e]+t*Math.cos(s),this.sy[e]+t*Math.sin(s)]}}s.AnnularWedgeView=x,x.__name__=\"AnnularWedgeView\";class g extends o.XYGlyph{constructor(e){super(e)}}s.AnnularWedge=g,a=g,g.__name__=\"AnnularWedge\",a.prototype.default_view=x,a.mixins([d.LineVector,d.FillVector,d.HatchVector]),a.define((({})=>({direction:[h.Direction,\"anticlock\"],inner_radius:[c.DistanceSpec,{field:\"inner_radius\"}],outer_radius:[c.DistanceSpec,{field:\"outer_radius\"}],start_angle:[c.AngleSpec,{field:\"start_angle\"}],end_angle:[c.AngleSpec,{field:\"end_angle\"}]})))},\n", + " function _(e,s,t,i,r){i();const n=e(1);var a;const _=e(178),o=e(184),d=e(48),u=e(24),h=e(20),c=(0,n.__importStar)(e(18)),l=e(10),g=e(72),p=e(12);class x extends _.XYGlyphView{_map_data(){\"data\"==this.model.properties.inner_radius.units?this.sinner_radius=this.sdist(this.renderer.xscale,this._x,this.inner_radius):this.sinner_radius=(0,u.to_screen)(this.inner_radius),\"data\"==this.model.properties.outer_radius.units?this.souter_radius=this.sdist(this.renderer.xscale,this._x,this.outer_radius):this.souter_radius=(0,u.to_screen)(this.outer_radius),this.max_souter_radius=(0,p.max)(this.souter_radius)}_render(e,s,t){const{sx:i,sy:r,start_angle:n,end_angle:a,sinner_radius:_,souter_radius:o}=null!=t?t:this,d=\"anticlock\"==this.model.direction;for(const t of s){const s=i[t],u=r[t],h=_[t],c=o[t],l=n.get(t),g=a.get(t);if(!isFinite(s+u+h+c+l+g))continue;const p=g-l;e.translate(s,u),e.rotate(l),e.beginPath(),e.moveTo(c,0),e.arc(0,0,c,0,p,d),e.rotate(p),e.lineTo(h,0),e.arc(0,0,h,0,-p,!d),e.closePath(),e.rotate(-p-l),e.translate(-s,-u),this.visuals.fill.apply(e,t),this.visuals.hatch.apply(e,t),this.visuals.line.apply(e,t)}}_hit_point(e){const{sx:s,sy:t}=e,i=this.renderer.xscale.invert(s),r=this.renderer.yscale.invert(t),n=s-this.max_souter_radius,a=s+this.max_souter_radius,[_,o]=this.renderer.xscale.r_invert(n,a),d=t-this.max_souter_radius,u=t+this.max_souter_radius,[h,c]=this.renderer.yscale.r_invert(d,u),p=[];for(const e of this.index.indices({x0:_,x1:o,y0:h,y1:c})){const s=this.souter_radius[e]**2,t=this.sinner_radius[e]**2,[n,a]=this.renderer.xscale.r_compute(i,this._x[e]),[_,o]=this.renderer.yscale.r_compute(r,this._y[e]),d=(n-a)**2+(_-o)**2;d<=s&&d>=t&&p.push(e)}const x=\"anticlock\"==this.model.direction,m=[];for(const e of p){const i=Math.atan2(t-this.sy[e],s-this.sx[e]);(0,l.angle_between)(-i,-this.start_angle.get(e),-this.end_angle.get(e),x)&&m.push(e)}return new g.Selection({indices:m})}draw_legend_for_index(e,s,t){(0,o.generic_area_vector_legend)(this.visuals,e,s,t)}scenterxy(e){const s=(this.sinner_radius[e]+this.souter_radius[e])/2,t=(this.start_angle.get(e)+this.end_angle.get(e))/2;return[this.sx[e]+s*Math.cos(t),this.sy[e]+s*Math.sin(t)]}}t.AnnularWedgeView=x,x.__name__=\"AnnularWedgeView\";class m extends _.XYGlyph{constructor(e){super(e)}}t.AnnularWedge=m,a=m,m.__name__=\"AnnularWedge\",a.prototype.default_view=x,a.mixins([d.LineVector,d.FillVector,d.HatchVector]),a.define((({})=>({direction:[h.Direction,\"anticlock\"],inner_radius:[c.DistanceSpec,{field:\"inner_radius\"}],outer_radius:[c.DistanceSpec,{field:\"outer_radius\"}],start_angle:[c.AngleSpec,{field:\"start_angle\"}],end_angle:[c.AngleSpec,{field:\"end_angle\"}]})))},\n", " function _(s,e,i,r,t){r();const n=s(1);var a;const u=s(178),o=s(24),_=s(48),d=(0,n.__importStar)(s(18)),h=s(27),c=s(72);class l extends u.XYGlyphView{_map_data(){\"data\"==this.model.properties.inner_radius.units?this.sinner_radius=this.sdist(this.renderer.xscale,this._x,this.inner_radius):this.sinner_radius=(0,o.to_screen)(this.inner_radius),\"data\"==this.model.properties.outer_radius.units?this.souter_radius=this.sdist(this.renderer.xscale,this._x,this.outer_radius):this.souter_radius=(0,o.to_screen)(this.outer_radius)}_render(s,e,i){const{sx:r,sy:t,sinner_radius:n,souter_radius:a}=null!=i?i:this;for(const i of e){const e=r[i],u=t[i],o=n[i],_=a[i];if(isFinite(e+u+o+_)){if(s.beginPath(),h.is_ie)for(const i of[!1,!0])s.moveTo(e,u),s.arc(e,u,o,0,Math.PI,i),s.moveTo(e+_,u),s.arc(e,u,_,Math.PI,0,!i);else s.arc(e,u,o,0,2*Math.PI,!0),s.moveTo(e+_,u),s.arc(e,u,_,2*Math.PI,0,!1);this.visuals.fill.apply(s,i),this.visuals.hatch.apply(s,i),this.visuals.line.apply(s,i)}}}_hit_point(s){const{sx:e,sy:i}=s,r=this.renderer.xscale.invert(e),t=this.renderer.yscale.invert(i);let n,a,u,o;if(\"data\"==this.model.properties.outer_radius.units)n=r-this.max_outer_radius,u=r+this.max_outer_radius,a=t-this.max_outer_radius,o=t+this.max_outer_radius;else{const s=e-this.max_outer_radius,r=e+this.max_outer_radius;[n,u]=this.renderer.xscale.r_invert(s,r);const t=i-this.max_outer_radius,_=i+this.max_outer_radius;[a,o]=this.renderer.yscale.r_invert(t,_)}const _=[];for(const s of this.index.indices({x0:n,x1:u,y0:a,y1:o})){const e=this.souter_radius[s]**2,i=this.sinner_radius[s]**2,[n,a]=this.renderer.xscale.r_compute(r,this._x[s]),[u,o]=this.renderer.yscale.r_compute(t,this._y[s]),d=(n-a)**2+(u-o)**2;d<=e&&d>=i&&_.push(s)}return new c.Selection({indices:_})}draw_legend_for_index(s,{x0:e,y0:i,x1:r,y1:t},n){const a=n+1,u=new Array(a);u[n]=(e+r)/2;const o=new Array(a);o[n]=(i+t)/2;const _=.5*Math.min(Math.abs(r-e),Math.abs(t-i)),d=new Array(a);d[n]=.4*_;const h=new Array(a);h[n]=.8*_,this._render(s,[n],{sx:u,sy:o,sinner_radius:d,souter_radius:h})}}i.AnnulusView=l,l.__name__=\"AnnulusView\";class x extends u.XYGlyph{constructor(s){super(s)}}i.Annulus=x,a=x,x.__name__=\"Annulus\",a.prototype.default_view=l,a.mixins([_.LineVector,_.FillVector,_.HatchVector]),a.define((({})=>({inner_radius:[d.DistanceSpec,{field:\"inner_radius\"}],outer_radius:[d.DistanceSpec,{field:\"outer_radius\"}]})))},\n", " function _(e,i,s,t,n){t();const r=e(1);var a;const c=e(178),d=e(184),l=e(48),_=e(24),o=e(20),u=(0,r.__importStar)(e(18));class h extends c.XYGlyphView{_map_data(){\"data\"==this.model.properties.radius.units?this.sradius=this.sdist(this.renderer.xscale,this._x,this.radius):this.sradius=(0,_.to_screen)(this.radius)}_render(e,i,s){if(this.visuals.line.doit){const{sx:t,sy:n,sradius:r,start_angle:a,end_angle:c}=null!=s?s:this,d=\"anticlock\"==this.model.direction;for(const s of i){const i=t[s],l=n[s],_=r[s],o=a.get(s),u=c.get(s);isFinite(i+l+_+o+u)&&(e.beginPath(),e.arc(i,l,_,o,u,d),this.visuals.line.set_vectorize(e,s),e.stroke())}}}draw_legend_for_index(e,i,s){(0,d.generic_line_vector_legend)(this.visuals,e,i,s)}}s.ArcView=h,h.__name__=\"ArcView\";class g extends c.XYGlyph{constructor(e){super(e)}}s.Arc=g,a=g,g.__name__=\"Arc\",a.prototype.default_view=h,a.mixins(l.LineVector),a.define((({})=>({direction:[o.Direction,\"anticlock\"],radius:[u.DistanceSpec,{field:\"radius\"}],start_angle:[u.AngleSpec,{field:\"start_angle\"}],end_angle:[u.AngleSpec,{field:\"end_angle\"}]})))},\n", " function _(e,t,i,n,s){n();const o=e(1);var c;const r=e(48),a=e(179),_=e(184),d=e(78),l=(0,o.__importStar)(e(18));function x(e,t,i,n,s,o,c,r){const a=[],_=[[],[]];for(let _=0;_<=2;_++){let d,l,x;if(0===_?(l=6*e-12*i+6*s,d=-3*e+9*i-9*s+3*c,x=3*i-3*e):(l=6*t-12*n+6*o,d=-3*t+9*n-9*o+3*r,x=3*n-3*t),Math.abs(d)<1e-12){if(Math.abs(l)<1e-12)continue;const e=-x/l;0({x0:[l.XCoordinateSpec,{field:\"x0\"}],y0:[l.YCoordinateSpec,{field:\"y0\"}],x1:[l.XCoordinateSpec,{field:\"x1\"}],y1:[l.YCoordinateSpec,{field:\"y1\"}],cx0:[l.XCoordinateSpec,{field:\"cx0\"}],cy0:[l.YCoordinateSpec,{field:\"cy0\"}],cx1:[l.XCoordinateSpec,{field:\"cx1\"}],cy1:[l.YCoordinateSpec,{field:\"cy1\"}]}))),c.mixins(r.LineVector)},\n", - " function _(s,i,e,t,r){t();const a=s(1);var n;const h=s(178),d=s(48),l=s(24),c=s(20),_=(0,a.__importStar)(s(185)),u=(0,a.__importStar)(s(18)),o=s(9),x=s(12),m=s(72);class p extends h.XYGlyphView{async lazy_initialize(){await super.lazy_initialize();const{webgl:i}=this.renderer.plot_view.canvas_view;if(null==i?void 0:i.regl_wrapper.has_webgl){const{MarkerGL:e}=await Promise.resolve().then((()=>(0,a.__importStar)(s(426))));this.glglyph=new e(i.regl_wrapper,this,\"circle\")}}get use_radius(){return!(this.radius.is_Scalar()&&isNaN(this.radius.value))}_set_data(s){super._set_data(s);const i=(()=>{if(this.use_radius)return 2*this.max_radius;{const{size:s}=this;return s.is_Scalar()?s.value:(0,x.max)(s.array)}})();this._configure(\"max_size\",{value:i})}_map_data(){if(this.use_radius)if(\"data\"==this.model.properties.radius.units)switch(this.model.radius_dimension){case\"x\":this.sradius=this.sdist(this.renderer.xscale,this._x,this.radius);break;case\"y\":this.sradius=this.sdist(this.renderer.yscale,this._y,this.radius);break;case\"max\":{const s=this.sdist(this.renderer.xscale,this._x,this.radius),i=this.sdist(this.renderer.yscale,this._y,this.radius);this.sradius=(0,x.map)(s,((s,e)=>Math.max(s,i[e])));break}case\"min\":{const s=this.sdist(this.renderer.xscale,this._x,this.radius),i=this.sdist(this.renderer.yscale,this._y,this.radius);this.sradius=(0,x.map)(s,((s,e)=>Math.min(s,i[e])));break}}else this.sradius=(0,l.to_screen)(this.radius);else{const s=l.ScreenArray.from(this.size);this.sradius=(0,x.map)(s,(s=>s/2))}}_mask_data(){const{frame:s}=this.renderer.plot_view,i=s.x_target,e=s.y_target;let t,r;return this.use_radius&&\"data\"==this.model.properties.radius.units?(t=i.map((s=>this.renderer.xscale.invert(s))).widen(this.max_radius),r=e.map((s=>this.renderer.yscale.invert(s))).widen(this.max_radius)):(t=i.widen(this.max_size).map((s=>this.renderer.xscale.invert(s))),r=e.widen(this.max_size).map((s=>this.renderer.yscale.invert(s)))),this.index.indices({x0:t.start,x1:t.end,y0:r.start,y1:r.end})}_render(s,i,e){const{sx:t,sy:r,sradius:a}=null!=e?e:this;for(const e of i){const i=t[e],n=r[e],h=a[e];isFinite(i+n+h)&&(s.beginPath(),s.arc(i,n,h,0,2*Math.PI,!1),this.visuals.fill.apply(s,e),this.visuals.hatch.apply(s,e),this.visuals.line.apply(s,e))}}_hit_point(s){const{sx:i,sy:e}=s,t=this.renderer.xscale.invert(i),r=this.renderer.yscale.invert(e),{hit_dilation:a}=this.model;let n,h,d,l;if(this.use_radius&&\"data\"==this.model.properties.radius.units)n=t-this.max_radius*a,h=t+this.max_radius*a,d=r-this.max_radius*a,l=r+this.max_radius*a;else{const s=i-this.max_size*a,t=i+this.max_size*a;[n,h]=this.renderer.xscale.r_invert(s,t);const r=e-this.max_size*a,c=e+this.max_size*a;[d,l]=this.renderer.yscale.r_invert(r,c)}const c=this.index.indices({x0:n,x1:h,y0:d,y1:l}),_=[];if(this.use_radius&&\"data\"==this.model.properties.radius.units)for(const s of c){const i=(this.sradius[s]*a)**2,[e,n]=this.renderer.xscale.r_compute(t,this._x[s]),[h,d]=this.renderer.yscale.r_compute(r,this._y[s]);(e-n)**2+(h-d)**2<=i&&_.push(s)}else for(const s of c){const t=(this.sradius[s]*a)**2;(this.sx[s]-i)**2+(this.sy[s]-e)**2<=t&&_.push(s)}return new m.Selection({indices:_})}_hit_span(s){const{sx:i,sy:e}=s,t=this.bounds();let r,a,n,h;if(\"h\"==s.direction){let s,e;if(n=t.y0,h=t.y1,this.use_radius&&\"data\"==this.model.properties.radius.units)s=i-this.max_radius,e=i+this.max_radius,[r,a]=this.renderer.xscale.r_invert(s,e);else{const t=this.max_size/2;s=i-t,e=i+t,[r,a]=this.renderer.xscale.r_invert(s,e)}}else{let s,i;if(r=t.x0,a=t.x1,this.use_radius&&\"data\"==this.model.properties.radius.units)s=e-this.max_radius,i=e+this.max_radius,[n,h]=this.renderer.yscale.r_invert(s,i);else{const t=this.max_size/2;s=e-t,i=e+t,[n,h]=this.renderer.yscale.r_invert(s,i)}}const d=[...this.index.indices({x0:r,x1:a,y0:n,y1:h})];return new m.Selection({indices:d})}_hit_rect(s){const{sx0:i,sx1:e,sy0:t,sy1:r}=s,[a,n]=this.renderer.xscale.r_invert(i,e),[h,d]=this.renderer.yscale.r_invert(t,r),l=[...this.index.indices({x0:a,x1:n,y0:h,y1:d})];return new m.Selection({indices:l})}_hit_poly(s){const{sx:i,sy:e}=s,t=(0,o.range)(0,this.sx.length),r=[];for(let s=0,a=t.length;s({angle:[u.AngleSpec,0],size:[u.ScreenSizeSpec,{value:4}],radius:[u.NullDistanceSpec,null],radius_dimension:[c.RadiusDimension,\"x\"],hit_dilation:[s,1]})))},\n", + " function _(s,i,e,t,r){t();const a=s(1);var n;const h=s(178),d=s(48),l=s(24),_=s(20),c=(0,a.__importStar)(s(185)),u=(0,a.__importStar)(s(18)),o=s(9),x=s(12),m=s(72);class p extends h.XYGlyphView{async lazy_initialize(){await super.lazy_initialize();const{webgl:i}=this.renderer.plot_view.canvas_view;if(null!=i&&i.regl_wrapper.has_webgl){const{CircleGL:e}=await Promise.resolve().then((()=>(0,a.__importStar)(s(423))));this.glglyph=new e(i.regl_wrapper,this)}}get use_radius(){return!(this.radius.is_Scalar()&&isNaN(this.radius.value))}_set_data(s){super._set_data(s);const i=(()=>{if(this.use_radius)return 2*this.max_radius;{const{size:s}=this;return s.is_Scalar()?s.value:(0,x.max)(s.array)}})();this._configure(\"max_size\",{value:i})}_map_data(){if(this.use_radius)if(\"data\"==this.model.properties.radius.units)switch(this.model.radius_dimension){case\"x\":this.sradius=this.sdist(this.renderer.xscale,this._x,this.radius);break;case\"y\":this.sradius=this.sdist(this.renderer.yscale,this._y,this.radius);break;case\"max\":{const s=this.sdist(this.renderer.xscale,this._x,this.radius),i=this.sdist(this.renderer.yscale,this._y,this.radius);this.sradius=(0,x.map)(s,((s,e)=>Math.max(s,i[e])));break}case\"min\":{const s=this.sdist(this.renderer.xscale,this._x,this.radius),i=this.sdist(this.renderer.yscale,this._y,this.radius);this.sradius=(0,x.map)(s,((s,e)=>Math.min(s,i[e])));break}}else this.sradius=(0,l.to_screen)(this.radius);else{const s=l.ScreenArray.from(this.size);this.sradius=(0,x.map)(s,(s=>s/2))}}_mask_data(){const{frame:s}=this.renderer.plot_view,i=s.x_target,e=s.y_target;let t,r;return this.use_radius&&\"data\"==this.model.properties.radius.units?(t=i.map((s=>this.renderer.xscale.invert(s))).widen(this.max_radius),r=e.map((s=>this.renderer.yscale.invert(s))).widen(this.max_radius)):(t=i.widen(this.max_size).map((s=>this.renderer.xscale.invert(s))),r=e.widen(this.max_size).map((s=>this.renderer.yscale.invert(s)))),this.index.indices({x0:t.start,x1:t.end,y0:r.start,y1:r.end})}_render(s,i,e){const{sx:t,sy:r,sradius:a}=null!=e?e:this;for(const e of i){const i=t[e],n=r[e],h=a[e];isFinite(i+n+h)&&(s.beginPath(),s.arc(i,n,h,0,2*Math.PI,!1),this.visuals.fill.apply(s,e),this.visuals.hatch.apply(s,e),this.visuals.line.apply(s,e))}}_hit_point(s){const{sx:i,sy:e}=s,t=this.renderer.xscale.invert(i),r=this.renderer.yscale.invert(e),{hit_dilation:a}=this.model;let n,h,d,l;if(this.use_radius&&\"data\"==this.model.properties.radius.units)n=t-this.max_radius*a,h=t+this.max_radius*a,d=r-this.max_radius*a,l=r+this.max_radius*a;else{const s=i-this.max_size*a,t=i+this.max_size*a;[n,h]=this.renderer.xscale.r_invert(s,t);const r=e-this.max_size*a,_=e+this.max_size*a;[d,l]=this.renderer.yscale.r_invert(r,_)}const _=this.index.indices({x0:n,x1:h,y0:d,y1:l}),c=[];if(this.use_radius&&\"data\"==this.model.properties.radius.units)for(const s of _){const i=(this.sradius[s]*a)**2,[e,n]=this.renderer.xscale.r_compute(t,this._x[s]),[h,d]=this.renderer.yscale.r_compute(r,this._y[s]);(e-n)**2+(h-d)**2<=i&&c.push(s)}else for(const s of _){const t=(this.sradius[s]*a)**2;(this.sx[s]-i)**2+(this.sy[s]-e)**2<=t&&c.push(s)}return new m.Selection({indices:c})}_hit_span(s){const{sx:i,sy:e}=s,t=this.bounds();let r,a,n,h;if(\"h\"==s.direction){let s,e;if(n=t.y0,h=t.y1,this.use_radius&&\"data\"==this.model.properties.radius.units)s=i-this.max_radius,e=i+this.max_radius,[r,a]=this.renderer.xscale.r_invert(s,e);else{const t=this.max_size/2;s=i-t,e=i+t,[r,a]=this.renderer.xscale.r_invert(s,e)}}else{let s,i;if(r=t.x0,a=t.x1,this.use_radius&&\"data\"==this.model.properties.radius.units)s=e-this.max_radius,i=e+this.max_radius,[n,h]=this.renderer.yscale.r_invert(s,i);else{const t=this.max_size/2;s=e-t,i=e+t,[n,h]=this.renderer.yscale.r_invert(s,i)}}const d=[...this.index.indices({x0:r,x1:a,y0:n,y1:h})];return new m.Selection({indices:d})}_hit_rect(s){const{sx0:i,sx1:e,sy0:t,sy1:r}=s,[a,n]=this.renderer.xscale.r_invert(i,e),[h,d]=this.renderer.yscale.r_invert(t,r),l=[...this.index.indices({x0:a,x1:n,y0:h,y1:d})];return new m.Selection({indices:l})}_hit_poly(s){const{sx:i,sy:e}=s,t=(0,o.range)(0,this.sx.length),r=[];for(let s=0,a=t.length;s({angle:[u.AngleSpec,0],size:[u.ScreenSizeSpec,{value:4}],radius:[u.NullDistanceSpec,null],radius_dimension:[_.RadiusDimension,\"x\"],hit_dilation:[s,1]})))},\n", " function _(e,l,s,i,_){var p;i();const t=e(274);class a extends t.EllipseOvalView{}s.EllipseView=a,a.__name__=\"EllipseView\";class n extends t.EllipseOval{constructor(e){super(e)}}s.Ellipse=n,p=n,n.__name__=\"Ellipse\",p.prototype.default_view=a},\n", " function _(t,s,e,i,h){i();const n=t(1),r=t(275),a=(0,n.__importStar)(t(185)),l=t(24),_=t(72),o=(0,n.__importStar)(t(18));class d extends r.CenterRotatableView{_map_data(){\"data\"==this.model.properties.width.units?this.sw=this.sdist(this.renderer.xscale,this._x,this.width,\"center\"):this.sw=(0,l.to_screen)(this.width),\"data\"==this.model.properties.height.units?this.sh=this.sdist(this.renderer.yscale,this._y,this.height,\"center\"):this.sh=(0,l.to_screen)(this.height)}_render(t,s,e){const{sx:i,sy:h,sw:n,sh:r,angle:a}=null!=e?e:this;for(const e of s){const s=i[e],l=h[e],_=n[e],o=r[e],d=a.get(e);isFinite(s+l+_+o+d)&&(t.beginPath(),t.ellipse(s,l,_/2,o/2,d,0,2*Math.PI),this.visuals.fill.apply(t,e),this.visuals.hatch.apply(t,e),this.visuals.line.apply(t,e))}}_hit_point(t){let s,e,i,h,n,r,l,o,d;const{sx:c,sy:p}=t,w=this.renderer.xscale.invert(c),x=this.renderer.yscale.invert(p);\"data\"==this.model.properties.width.units?(s=w-this.max_width,e=w+this.max_width):(r=c-this.max_width,l=c+this.max_width,[s,e]=this.renderer.xscale.r_invert(r,l)),\"data\"==this.model.properties.height.units?(i=x-this.max_height,h=x+this.max_height):(o=p-this.max_height,d=p+this.max_height,[i,h]=this.renderer.yscale.r_invert(o,d));const m=this.index.indices({x0:s,x1:e,y0:i,y1:h}),y=[];for(const t of m)n=a.point_in_ellipse(c,p,this.angle.get(t),this.sh[t]/2,this.sw[t]/2,this.sx[t],this.sy[t]),n&&y.push(t);return new _.Selection({indices:y})}draw_legend_for_index(t,{x0:s,y0:e,x1:i,y1:h},n){const r=n+1,a=new Array(r);a[n]=(s+i)/2;const l=new Array(r);l[n]=(e+h)/2;const _=this.sw[n]/this.sh[n],d=.8*Math.min(Math.abs(i-s),Math.abs(h-e)),c=new Array(r),p=new Array(r);_>1?(c[n]=d,p[n]=d/_):(c[n]=d*_,p[n]=d);const w=new o.UniformScalar(0,r);this._render(t,[n],{sx:a,sy:l,sw:c,sh:p,angle:w})}}e.EllipseOvalView=d,d.__name__=\"EllipseOvalView\";class c extends r.CenterRotatable{constructor(t){super(t)}}e.EllipseOval=c,c.__name__=\"EllipseOval\"},\n", " function _(e,t,i,a,n){a();const s=e(1);var r;const h=e(178),o=e(48),_=(0,s.__importStar)(e(18));class c extends h.XYGlyphView{get max_w2(){return\"data\"==this.model.properties.width.units?this.max_width/2:0}get max_h2(){return\"data\"==this.model.properties.height.units?this.max_height/2:0}_bounds({x0:e,x1:t,y0:i,y1:a}){const{max_w2:n,max_h2:s}=this;return{x0:e-n,x1:t+n,y0:i-s,y1:a+s}}}i.CenterRotatableView=c,c.__name__=\"CenterRotatableView\";class l extends h.XYGlyph{constructor(e){super(e)}}i.CenterRotatable=l,r=l,l.__name__=\"CenterRotatable\",r.mixins([o.LineVector,o.FillVector,o.HatchVector]),r.define((({})=>({angle:[_.AngleSpec,0],width:[_.DistanceSpec,{field:\"width\"}],height:[_.DistanceSpec,{field:\"height\"}]})))},\n", - " function _(t,e,s,i,h){i();const r=t(1);var a;const n=t(277),o=t(24),_=(0,r.__importStar)(t(18));class c extends n.BoxView{scenterxy(t){return[(this.sleft[t]+this.sright[t])/2,this.sy[t]]}_lrtb(t){const e=this._left[t],s=this._right[t],i=this._y[t],h=this.height.get(t)/2;return[Math.min(e,s),Math.max(e,s),i+h,i-h]}_map_data(){this.sy=this.renderer.yscale.v_compute(this._y),this.sh=this.sdist(this.renderer.yscale,this._y,this.height,\"center\"),this.sleft=this.renderer.xscale.v_compute(this._left),this.sright=this.renderer.xscale.v_compute(this._right);const t=this.sy.length;this.stop=new o.ScreenArray(t),this.sbottom=new o.ScreenArray(t);for(let e=0;e({left:[_.XCoordinateSpec,{value:0}],y:[_.YCoordinateSpec,{field:\"y\"}],height:[_.NumberSpec,{value:1}],right:[_.XCoordinateSpec,{field:\"right\"}]})))},\n", + " function _(t,e,s,i,r){i();const h=t(1);var a;const n=t(277),_=t(24),o=(0,h.__importStar)(t(18));class l extends n.BoxView{async lazy_initialize(){await super.lazy_initialize();const{webgl:e}=this.renderer.plot_view.canvas_view;if(null!=e&&e.regl_wrapper.has_webgl){const{LRTBGL:s}=await Promise.resolve().then((()=>(0,h.__importStar)(t(427))));this.glglyph=new s(e.regl_wrapper,this)}}scenterxy(t){return[(this.sleft[t]+this.sright[t])/2,this.sy[t]]}_lrtb(t){const e=this._left[t],s=this._right[t],i=this._y[t],r=this.height.get(t)/2;return[Math.min(e,s),Math.max(e,s),i+r,i-r]}_map_data(){this.sy=this.renderer.yscale.v_compute(this._y),this.sh=this.sdist(this.renderer.yscale,this._y,this.height,\"center\"),this.sleft=this.renderer.xscale.v_compute(this._left),this.sright=this.renderer.xscale.v_compute(this._right);const t=this.sy.length;this.stop=new _.ScreenArray(t),this.sbottom=new _.ScreenArray(t);for(let e=0;e({left:[o.XCoordinateSpec,{value:0}],y:[o.YCoordinateSpec,{field:\"y\"}],height:[o.NumberSpec,{value:1}],right:[o.XCoordinateSpec,{field:\"right\"}]})))},\n", " function _(t,e,s,r,i){var n;r();const a=t(48),h=t(179),o=t(184),c=t(72);class _ extends h.GlyphView{get_anchor_point(t,e,s){const r=Math.min(this.sleft[e],this.sright[e]),i=Math.max(this.sright[e],this.sleft[e]),n=Math.min(this.stop[e],this.sbottom[e]),a=Math.max(this.sbottom[e],this.stop[e]);switch(t){case\"top_left\":return{x:r,y:n};case\"top\":case\"top_center\":return{x:(r+i)/2,y:n};case\"top_right\":return{x:i,y:n};case\"bottom_left\":return{x:r,y:a};case\"bottom\":case\"bottom_center\":return{x:(r+i)/2,y:a};case\"bottom_right\":return{x:i,y:a};case\"left\":case\"center_left\":return{x:r,y:(n+a)/2};case\"center\":case\"center_center\":return{x:(r+i)/2,y:(n+a)/2};case\"right\":case\"center_right\":return{x:i,y:(n+a)/2}}}_index_data(t){const{min:e,max:s}=Math,{data_size:r}=this;for(let i=0;i({r:[l.NumberSpec,{field:\"r\"}],q:[l.NumberSpec,{field:\"q\"}],scale:[l.NumberSpec,1],size:[e,1],aspect_scale:[e,1],orientation:[_.HexTileOrientation,\"pointytop\"]}))),a.override({line_color:null})},\n", + " function _(e,t,s,i,r){i();const n=e(1);var a;const l=e(179),o=(0,n.__importStar)(e(185)),c=(0,n.__importStar)(e(18)),h=e(48),_=e(20),d=e(78),p=e(184),x=e(72);class y extends l.GlyphView{async lazy_initialize(){await super.lazy_initialize();const{webgl:t}=this.renderer.plot_view.canvas_view;if(null!=t&&t.regl_wrapper.has_webgl){const{HexTileGL:s}=await Promise.resolve().then((()=>(0,n.__importStar)(e(425))));this.glglyph=new s(t.regl_wrapper,this)}}scenterxy(e){return[this.sx[e],this.sy[e]]}_set_data(){const{orientation:e,size:t,aspect_scale:s}=this.model,{q:i,r}=this,n=this.q.length;this._x=new Float64Array(n),this._y=new Float64Array(n);const{_x:a,_y:l}=this,o=Math.sqrt(3);if(\"pointytop\"==e)for(let e=0;e({r:[c.NumberSpec,{field:\"r\"}],q:[c.NumberSpec,{field:\"q\"}],scale:[c.NumberSpec,1],size:[e,1],aspect_scale:[e,1],orientation:[_.HexTileOrientation,\"pointytop\"]}))),a.override({line_color:null})},\n", " function _(e,a,t,_,r){var n;_();const s=e(280),o=e(173),i=e(201);class p extends s.ImageBaseView{connect_signals(){super.connect_signals(),this.connect(this.model.color_mapper.change,(()=>this._update_image()))}_update_image(){null!=this.image_data&&(this._set_data(null),this.renderer.request_render())}_flat_img_to_buf8(e){return this.model.color_mapper.rgba_mapper.v_compute(e)}}t.ImageView=p,p.__name__=\"ImageView\";class m extends s.ImageBase{constructor(e){super(e)}}t.Image=m,n=m,m.__name__=\"Image\",n.prototype.default_view=p,n.define((({Ref:e})=>({color_mapper:[e(o.ColorMapper),()=>new i.LinearColorMapper({palette:[\"#000000\",\"#252525\",\"#525252\",\"#737373\",\"#969696\",\"#bdbdbd\",\"#d9d9d9\",\"#f0f0f0\",\"#ffffff\"]})]})))},\n", " function _(e,t,i,s,a){s();const h=e(1);var n;const r=e(178),_=e(24),d=(0,h.__importStar)(e(18)),l=e(72),g=e(9),o=e(29),c=e(11);class m extends r.XYGlyphView{connect_signals(){super.connect_signals(),this.connect(this.model.properties.global_alpha.change,(()=>this.renderer.request_render()))}_render(e,t,i){const{image_data:s,sx:a,sy:h,sw:n,sh:r,global_alpha:_}=null!=i?i:this,d=e.getImageSmoothingEnabled();e.setImageSmoothingEnabled(!1);const l=_.is_Scalar();l&&(e.globalAlpha=_.value);for(const i of t){const t=s[i],_=a[i],d=h[i],g=n[i],o=r[i],c=this.global_alpha.get(i);if(null==t||!isFinite(_+d+g+o+c))continue;l||(e.globalAlpha=c);const m=d;e.translate(0,m),e.scale(1,-1),e.translate(0,-m),e.drawImage(t,0|_,0|d,g,o),e.translate(0,m),e.scale(1,-1),e.translate(0,-m)}e.setImageSmoothingEnabled(d)}_set_data(e){this._set_width_heigh_data();for(let t=0,i=this.image.length;t({image:[d.NDArraySpec,{field:\"image\"}],dw:[d.DistanceSpec,{field:\"dw\"}],dh:[d.DistanceSpec,{field:\"dh\"}],global_alpha:[d.NumberSpec,{value:1}],dilate:[e,!1]})))},\n", " function _(e,a,t,r,_){var n;r();const s=e(280),m=e(8);class i extends s.ImageBaseView{_flat_img_to_buf8(e){let a;return a=(0,m.isArray)(e)?new Uint32Array(e):e,new Uint8ClampedArray(a.buffer)}}t.ImageRGBAView=i,i.__name__=\"ImageRGBAView\";class g extends s.ImageBase{constructor(e){super(e)}}t.ImageRGBA=g,n=g,g.__name__=\"ImageRGBA\",n.prototype.default_view=i},\n", @@ -691,11 +710,11 @@ " function _(t,e,s,n,i){n();const o=t(1);var r;const l=t(181),h=t(179),a=t(184),_=t(12),c=t(12),d=t(48),x=(0,o.__importStar)(t(185)),y=(0,o.__importStar)(t(18)),f=t(72),g=t(11);class p extends h.GlyphView{_project_data(){}_index_data(t){const{min:e,max:s}=Math,{data_size:n}=this;for(let i=0;i1&&c.length>1)for(let s=1,n=i.length;s1){let r=!1;for(let t=1;t({xs:[y.XCoordinateSeqSeqSeqSpec,{field:\"xs\"}],ys:[y.YCoordinateSeqSeqSeqSpec,{field:\"ys\"}]}))),r.mixins([d.LineVector,d.FillVector,d.HatchVector])},\n", " function _(a,e,l,s,_){var t;s();const i=a(274),n=a(12);class p extends i.EllipseOvalView{_map_data(){super._map_data(),(0,n.mul)(this.sw,.75)}}l.OvalView=p,p.__name__=\"OvalView\";class v extends i.EllipseOval{constructor(a){super(a)}}l.Oval=v,t=v,v.__name__=\"Oval\",t.prototype.default_view=p},\n", " function _(e,t,s,i,n){i();const r=e(1);var a;const o=e(179),c=e(184),_=e(12),h=e(48),l=(0,r.__importStar)(e(185)),d=(0,r.__importStar)(e(18)),y=e(72),p=e(11),x=e(78);class f extends o.GlyphView{_project_data(){x.inplace.project_xy(this._xs.array,this._ys.array)}_index_data(e){const{data_size:t}=this;for(let s=0;s({xs:[d.XCoordinateSeqSpec,{field:\"xs\"}],ys:[d.YCoordinateSeqSpec,{field:\"ys\"}]}))),a.mixins([h.LineVector,h.FillVector,h.HatchVector])},\n", - " function _(t,e,o,i,s){i();const r=t(1);var n;const _=t(277),d=(0,r.__importStar)(t(18));class a extends _.BoxView{scenterxy(t){return[this.sleft[t]/2+this.sright[t]/2,this.stop[t]/2+this.sbottom[t]/2]}_lrtb(t){return[this._left[t],this._right[t],this._top[t],this._bottom[t]]}}o.QuadView=a,a.__name__=\"QuadView\";class c extends _.Box{constructor(t){super(t)}}o.Quad=c,n=c,c.__name__=\"Quad\",n.prototype.default_view=a,n.define((({})=>({right:[d.XCoordinateSpec,{field:\"right\"}],bottom:[d.YCoordinateSpec,{field:\"bottom\"}],left:[d.XCoordinateSpec,{field:\"left\"}],top:[d.YCoordinateSpec,{field:\"top\"}]})))},\n", + " function _(t,e,i,o,r){o();const s=t(1);var a;const n=t(277),l=(0,s.__importStar)(t(18));class _ extends n.BoxView{async lazy_initialize(){await super.lazy_initialize();const{webgl:e}=this.renderer.plot_view.canvas_view;if(null!=e&&e.regl_wrapper.has_webgl){const{LRTBGL:i}=await Promise.resolve().then((()=>(0,s.__importStar)(t(427))));this.glglyph=new i(e.regl_wrapper,this)}}scenterxy(t){return[this.sleft[t]/2+this.sright[t]/2,this.stop[t]/2+this.sbottom[t]/2]}_lrtb(t){return[this._left[t],this._right[t],this._top[t],this._bottom[t]]}}i.QuadView=_,_.__name__=\"QuadView\";class p extends n.Box{constructor(t){super(t)}}i.Quad=p,a=p,p.__name__=\"Quad\",a.prototype.default_view=_,a.define((({})=>({right:[l.XCoordinateSpec,{field:\"right\"}],bottom:[l.YCoordinateSpec,{field:\"bottom\"}],left:[l.XCoordinateSpec,{field:\"left\"}],top:[l.YCoordinateSpec,{field:\"top\"}]})))},\n", " function _(e,t,i,n,s){n();const c=e(1);var o;const r=e(48),a=e(78),_=e(179),d=e(184),l=(0,c.__importStar)(e(18));function x(e,t,i){if(t==(e+i)/2)return[e,i];{const n=(e-t)/(e-2*t+i),s=e*(1-n)**2+2*t*(1-n)*n+i*n**2;return[Math.min(e,i,s),Math.max(e,i,s)]}}class y extends _.GlyphView{_project_data(){a.inplace.project_xy(this._x0,this._y0),a.inplace.project_xy(this._x1,this._y1)}_index_data(e){const{_x0:t,_x1:i,_y0:n,_y1:s,_cx:c,_cy:o,data_size:r}=this;for(let a=0;a({x0:[l.XCoordinateSpec,{field:\"x0\"}],y0:[l.YCoordinateSpec,{field:\"y0\"}],x1:[l.XCoordinateSpec,{field:\"x1\"}],y1:[l.YCoordinateSpec,{field:\"y1\"}],cx:[l.XCoordinateSpec,{field:\"cx\"}],cy:[l.YCoordinateSpec,{field:\"cy\"}]}))),o.mixins(r.LineVector)},\n", " function _(e,t,s,i,n){i();const l=e(1);var a;const r=e(178),o=e(184),h=e(48),_=e(24),c=(0,l.__importStar)(e(18));class g extends r.XYGlyphView{_map_data(){\"data\"==this.model.properties.length.units?this.slength=this.sdist(this.renderer.xscale,this._x,this.length):this.slength=(0,_.to_screen)(this.length);const{width:e,height:t}=this.renderer.plot_view.frame.bbox,s=2*(e+t),{slength:i}=this;for(let e=0,t=i.length;e({length:[c.DistanceSpec,0],angle:[c.AngleSpec,0]})))},\n", - " function _(t,e,s,i,r){var n,h=this&&this.__createBinding||(Object.create?function(t,e,s,i){void 0===i&&(i=s),Object.defineProperty(t,i,{enumerable:!0,get:function(){return e[s]}})}:function(t,e,s,i){void 0===i&&(i=s),t[i]=e[s]}),a=this&&this.__setModuleDefault||(Object.create?function(t,e){Object.defineProperty(t,\"default\",{enumerable:!0,value:e})}:function(t,e){t.default=e}),l=this&&this.__importStar||function(t){if(t&&t.__esModule)return t;var e={};if(null!=t)for(var s in t)\"default\"!==s&&Object.prototype.hasOwnProperty.call(t,s)&&h(e,t,s);return a(e,t),e};i();const o=t(275),c=t(184),_=t(24),d=t(12),f=t(72);class y extends o.CenterRotatableView{async lazy_initialize(){await super.lazy_initialize();const{webgl:e}=this.renderer.plot_view.canvas_view;if(null==e?void 0:e.regl_wrapper.has_webgl){const{RectGL:s}=await Promise.resolve().then((()=>l(t(425))));this.glglyph=new s(e.regl_wrapper,this)}}_map_data(){if(\"data\"==this.model.properties.width.units)[this.sw,this.sx0]=this._map_dist_corner_for_data_side_length(this._x,this.width,this.renderer.xscale);else{this.sw=(0,_.to_screen)(this.width);const t=this.sx.length;this.sx0=new _.ScreenArray(t);for(let e=0;e({dilate:[t,!1]})))},\n", - " function _(e,t,s,r,i){r();const a=e(1);var n;const l=e(292),_=e(293),c=(0,a.__importStar)(e(18));class o extends l.MarkerView{async lazy_initialize(){await super.lazy_initialize();const{webgl:t}=this.renderer.plot_view.canvas_view;if(null==t?void 0:t.regl_wrapper.has_webgl){const{MarkerGL:t}=await Promise.resolve().then((()=>(0,a.__importStar)(e(426))));this.glcls=t}}_init_webgl(){const{webgl:e}=this.renderer.plot_view.canvas_view;if(null!=e){const{regl_wrapper:t}=e;if(t.has_webgl){const e=new Set(null!=this.base?this.base.marker:this.marker);if(1==e.size){const[s]=[...e],r=this.glcls;if(null==r?void 0:r.is_supported(s)){const{glglyph:e}=this;if(null==e||e.marker_type!=s)return void(this.glglyph=new r(t,this,s))}}}}delete this.glglyph}_set_visuals(){this._init_webgl()}_render(e,t,s){const{sx:r,sy:i,size:a,angle:n,marker:l}=null!=s?s:this;for(const s of t){const t=r[s],c=i[s],o=a.get(s),g=n.get(s),h=l.get(s);if(!isFinite(t+c+o+g)||null==h)continue;const w=o/2;e.beginPath(),e.translate(t,c),g&&e.rotate(g),_.marker_funcs[h](e,s,w,this.visuals),g&&e.rotate(-g),e.translate(-t,-c)}}draw_legend_for_index(e,{x0:t,x1:s,y0:r,y1:i},a){const n=a+1,l=this.marker.get(a),_=Object.assign(Object.assign({},this._get_legend_args({x0:t,x1:s,y0:r,y1:i},a)),{marker:new c.UniformScalar(l,n)});this._render(e,[a],_)}}s.ScatterView=o,o.__name__=\"ScatterView\";class g extends l.Marker{constructor(e){super(e)}}s.Scatter=g,n=g,g.__name__=\"Scatter\",n.prototype.default_view=o,n.define((()=>({marker:[c.MarkerSpec,{value:\"circle\"}]})))},\n", + " function _(t,e,s,i,r){var n,h=this&&this.__createBinding||(Object.create?function(t,e,s,i){void 0===i&&(i=s),Object.defineProperty(t,i,{enumerable:!0,get:function(){return e[s]}})}:function(t,e,s,i){void 0===i&&(i=s),t[i]=e[s]}),a=this&&this.__setModuleDefault||(Object.create?function(t,e){Object.defineProperty(t,\"default\",{enumerable:!0,value:e})}:function(t,e){t.default=e}),l=this&&this.__importStar||function(t){if(t&&t.__esModule)return t;var e={};if(null!=t)for(var s in t)\"default\"!==s&&Object.prototype.hasOwnProperty.call(t,s)&&h(e,t,s);return a(e,t),e};i();const o=t(275),c=t(184),_=t(24),d=t(12),f=t(72);class y extends o.CenterRotatableView{async lazy_initialize(){await super.lazy_initialize();const{webgl:e}=this.renderer.plot_view.canvas_view;if(null==e?void 0:e.regl_wrapper.has_webgl){const{RectGL:s}=await Promise.resolve().then((()=>l(t(429))));this.glglyph=new s(e.regl_wrapper,this)}}_map_data(){if(\"data\"==this.model.properties.width.units)[this.sw,this.sx0]=this._map_dist_corner_for_data_side_length(this._x,this.width,this.renderer.xscale);else{this.sw=(0,_.to_screen)(this.width);const t=this.sx.length;this.sx0=new _.ScreenArray(t);for(let e=0;e({dilate:[t,!1]})))},\n", + " function _(e,t,r,a,s){a();const i=e(1);var n;const l=e(292),_=e(293),c=(0,i.__importStar)(e(18));class o extends l.MarkerView{async lazy_initialize(){await super.lazy_initialize();const{webgl:t}=this.renderer.plot_view.canvas_view;if(null!=t&&t.regl_wrapper.has_webgl){const{MultiMarkerGL:r}=await Promise.resolve().then((()=>(0,i.__importStar)(e(428))));this.glglyph=new r(t.regl_wrapper,this)}}_render(e,t,r){const{sx:a,sy:s,size:i,angle:n,marker:l}=null!=r?r:this;for(const r of t){const t=a[r],c=s[r],o=i.get(r),g=n.get(r),w=l.get(r);if(!isFinite(t+c+o+g)||null==w)continue;const p=o/2;e.beginPath(),e.translate(t,c),g&&e.rotate(g),_.marker_funcs[w](e,r,p,this.visuals),g&&e.rotate(-g),e.translate(-t,-c)}}draw_legend_for_index(e,{x0:t,x1:r,y0:a,y1:s},i){const n=i+1,l=this.marker.get(i),_=Object.assign(Object.assign({},this._get_legend_args({x0:t,x1:r,y0:a,y1:s},i)),{marker:new c.UniformScalar(l,n)});this._render(e,[i],_)}}r.ScatterView=o,o.__name__=\"ScatterView\";class g extends l.Marker{constructor(e){super(e)}}r.Scatter=g,n=g,g.__name__=\"Scatter\",n.prototype.default_view=o,n.define((()=>({marker:[c.MarkerSpec,{value:\"circle\"}]})))},\n", " function _(e,t,s,n,i){n();const r=e(1);var a;const c=e(178),o=e(48),_=(0,r.__importStar)(e(185)),h=(0,r.__importStar)(e(18)),l=e(9),x=e(72);class d extends c.XYGlyphView{_render(e,t,s){const{sx:n,sy:i,size:r,angle:a}=null!=s?s:this;for(const s of t){const t=n[s],c=i[s],o=r.get(s),_=a.get(s);if(!isFinite(t+c+o+_))continue;const h=o/2;e.beginPath(),e.translate(t,c),_&&e.rotate(_),this._render_one(e,s,h,this.visuals),_&&e.rotate(-_),e.translate(-t,-c)}}_mask_data(){const{x_target:e,y_target:t}=this.renderer.plot_view.frame,s=e.widen(this.max_size).map((e=>this.renderer.xscale.invert(e))),n=t.widen(this.max_size).map((e=>this.renderer.yscale.invert(e)));return this.index.indices({x0:s.start,x1:s.end,y0:n.start,y1:n.end})}_hit_point(e){const{sx:t,sy:s}=e,{max_size:n}=this,{hit_dilation:i}=this.model,r=t-n*i,a=t+n*i,[c,o]=this.renderer.xscale.r_invert(r,a),_=s-n*i,h=s+n*i,[l,d]=this.renderer.yscale.r_invert(_,h),y=this.index.indices({x0:c,x1:o,y0:l,y1:d}),g=[];for(const e of y){const n=this.size.get(e)/2*i;Math.abs(this.sx[e]-t)<=n&&Math.abs(this.sy[e]-s)<=n&&g.push(e)}return new x.Selection({indices:g})}_hit_span(e){const{sx:t,sy:s}=e,n=this.bounds(),i=this.max_size/2;let r,a,c,o;if(\"h\"==e.direction){c=n.y0,o=n.y1;const e=t-i,s=t+i;[r,a]=this.renderer.xscale.r_invert(e,s)}else{r=n.x0,a=n.x1;const e=s-i,t=s+i;[c,o]=this.renderer.yscale.r_invert(e,t)}const _=[...this.index.indices({x0:r,x1:a,y0:c,y1:o})];return new x.Selection({indices:_})}_hit_rect(e){const{sx0:t,sx1:s,sy0:n,sy1:i}=e,[r,a]=this.renderer.xscale.r_invert(t,s),[c,o]=this.renderer.yscale.r_invert(n,i),_=[...this.index.indices({x0:r,x1:a,y0:c,y1:o})];return new x.Selection({indices:_})}_hit_poly(e){const{sx:t,sy:s}=e,n=(0,l.range)(0,this.sx.length),i=[];for(let e=0,r=n.length;e({size:[h.ScreenSizeSpec,{value:4}],angle:[h.AngleSpec,0],hit_dilation:[e,1]})))},\n", " function _(l,o,n,t,i){t();const e=Math.sqrt(3),a=Math.sqrt(5),c=(a+1)/4,p=Math.sqrt((5-a)/8),r=(a-1)/4,h=Math.sqrt((5+a)/8);function u(l,o){l.rotate(Math.PI/4),s(l,o),l.rotate(-Math.PI/4)}function f(l,o){const n=o*e,t=n/3;l.moveTo(-n/2,-t),l.lineTo(0,0),l.lineTo(n/2,-t),l.lineTo(0,0),l.lineTo(0,o)}function s(l,o){l.moveTo(0,o),l.lineTo(0,-o),l.moveTo(-o,0),l.lineTo(o,0)}function T(l,o){l.moveTo(0,o),l.lineTo(o/1.5,0),l.lineTo(0,-o),l.lineTo(-o/1.5,0),l.closePath()}function y(l,o){const n=o*e,t=n/3;l.moveTo(-o,t),l.lineTo(o,t),l.lineTo(0,t-n),l.closePath()}function v(l,o,n,t){l.arc(0,0,n,0,2*Math.PI,!1),t.fill.apply(l,o),t.hatch.apply(l,o),t.line.apply(l,o)}function d(l,o,n,t){T(l,n),t.fill.apply(l,o),t.hatch.apply(l,o),t.line.apply(l,o)}function _(l,o,n,t){!function(l,o){l.beginPath(),l.arc(0,0,o/4,0,2*Math.PI,!1),l.closePath()}(l,n),t.line.set_vectorize(l,o),l.fillStyle=l.strokeStyle,l.fill()}function P(l,o,n,t){!function(l,o){const n=o/2,t=e*n;l.moveTo(o,0),l.lineTo(n,-t),l.lineTo(-n,-t),l.lineTo(-o,0),l.lineTo(-n,t),l.lineTo(n,t),l.closePath()}(l,n),t.fill.apply(l,o),t.hatch.apply(l,o),t.line.apply(l,o)}function m(l,o,n,t){const i=2*n;l.rect(-n,-n,i,i),t.fill.apply(l,o),t.hatch.apply(l,o),t.line.apply(l,o)}function q(l,o,n,t){!function(l,o){const n=Math.sqrt(5-2*a)*o;l.moveTo(0,-o),l.lineTo(n*r,n*h-o),l.lineTo(n*(1+r),n*h-o),l.lineTo(n*(1+r-c),n*(h+p)-o),l.lineTo(n*(1+2*r-c),n*(2*h+p)-o),l.lineTo(0,2*n*h-o),l.lineTo(-n*(1+2*r-c),n*(2*h+p)-o),l.lineTo(-n*(1+r-c),n*(h+p)-o),l.lineTo(-n*(1+r),n*h-o),l.lineTo(-n*r,n*h-o),l.closePath()}(l,n),t.fill.apply(l,o),t.hatch.apply(l,o),t.line.apply(l,o)}function M(l,o,n,t){y(l,n),t.fill.apply(l,o),t.hatch.apply(l,o),t.line.apply(l,o)}n.marker_funcs={asterisk:function(l,o,n,t){s(l,n),u(l,n),t.line.apply(l,o)},circle:v,circle_cross:function(l,o,n,t){l.arc(0,0,n,0,2*Math.PI,!1),t.fill.apply(l,o),t.hatch.apply(l,o),t.line.doit&&(t.line.set_vectorize(l,o),s(l,n),l.stroke())},circle_dot:function(l,o,n,t){v(l,o,n,t),_(l,o,n,t)},circle_y:function(l,o,n,t){l.arc(0,0,n,0,2*Math.PI,!1),t.fill.apply(l,o),t.hatch.apply(l,o),t.line.doit&&(t.line.set_vectorize(l,o),f(l,n),l.stroke())},circle_x:function(l,o,n,t){l.arc(0,0,n,0,2*Math.PI,!1),t.fill.apply(l,o),t.hatch.apply(l,o),t.line.doit&&(t.line.set_vectorize(l,o),u(l,n),l.stroke())},cross:function(l,o,n,t){s(l,n),t.line.apply(l,o)},diamond:d,diamond_dot:function(l,o,n,t){d(l,o,n,t),_(l,o,n,t)},diamond_cross:function(l,o,n,t){T(l,n),t.fill.apply(l,o),t.hatch.apply(l,o),t.line.doit&&(t.line.set_vectorize(l,o),l.moveTo(0,n),l.lineTo(0,-n),l.moveTo(-n/1.5,0),l.lineTo(n/1.5,0),l.stroke())},dot:_,hex:P,hex_dot:function(l,o,n,t){P(l,o,n,t),_(l,o,n,t)},inverted_triangle:function(l,o,n,t){l.rotate(Math.PI),y(l,n),l.rotate(-Math.PI),t.fill.apply(l,o),t.hatch.apply(l,o),t.line.apply(l,o)},plus:function(l,o,n,t){const i=3*n/8,e=[i,i,n,n,i,i,-i,-i,-n,-n,-i,-i],a=[n,i,i,-i,-i,-n,-n,-i,-i,i,i,n];l.beginPath();for(let o=0;o<12;o++)l.lineTo(e[o],a[o]);l.closePath(),t.fill.apply(l,o),t.hatch.apply(l,o),t.line.apply(l,o)},square:m,square_cross:function(l,o,n,t){const i=2*n;l.rect(-n,-n,i,i),t.fill.apply(l,o),t.hatch.apply(l,o),t.line.doit&&(t.line.set_vectorize(l,o),s(l,n),l.stroke())},square_dot:function(l,o,n,t){m(l,o,n,t),_(l,o,n,t)},square_pin:function(l,o,n,t){const i=3*n/8;l.moveTo(-n,-n),l.quadraticCurveTo(0,-i,n,-n),l.quadraticCurveTo(i,0,n,n),l.quadraticCurveTo(0,i,-n,n),l.quadraticCurveTo(-i,0,-n,-n),l.closePath(),t.fill.apply(l,o),t.hatch.apply(l,o),t.line.apply(l,o)},square_x:function(l,o,n,t){const i=2*n;l.rect(-n,-n,i,i),t.fill.apply(l,o),t.hatch.apply(l,o),t.line.doit&&(t.line.set_vectorize(l,o),l.moveTo(-n,n),l.lineTo(n,-n),l.moveTo(-n,-n),l.lineTo(n,n),l.stroke())},star:q,star_dot:function(l,o,n,t){q(l,o,n,t),_(l,o,n,t)},triangle:M,triangle_dot:function(l,o,n,t){M(l,o,n,t),_(l,o,n,t)},triangle_pin:function(l,o,n,t){const i=n*e,a=i/3,c=3*a/8;l.moveTo(-n,a),l.quadraticCurveTo(0,c,n,a),l.quadraticCurveTo(e*c/2,c/2,0,a-i),l.quadraticCurveTo(-e*c/2,c/2,-n,a),l.closePath(),t.fill.apply(l,o),t.hatch.apply(l,o),t.line.apply(l,o)},dash:function(l,o,n,t){!function(l,o){l.moveTo(-o,0),l.lineTo(o,0)}(l,n),t.line.apply(l,o)},x:function(l,o,n,t){u(l,n),t.line.apply(l,o)},y:function(l,o,n,t){f(l,n),t.line.apply(l,o)}}},\n", " function _(e,t,s,i,n){i();const r=e(1);var o;const _=(0,r.__importStar)(e(185)),h=(0,r.__importStar)(e(18)),c=e(48),a=e(78),d=e(179),x=e(184),l=e(72);class y extends d.GlyphView{_project_data(){a.inplace.project_xy(this._x0,this._y0),a.inplace.project_xy(this._x1,this._y1)}_index_data(e){const{min:t,max:s}=Math,{_x0:i,_x1:n,_y0:r,_y1:o,data_size:_}=this;for(let h=0;h<_;h++){const _=i[h],c=n[h],a=r[h],d=o[h];e.add_rect(t(_,c),t(a,d),s(_,c),s(a,d))}}_render(e,t,s){if(this.visuals.line.doit){const{sx0:i,sy0:n,sx1:r,sy1:o}=null!=s?s:this;for(const s of t){const t=i[s],_=n[s],h=r[s],c=o[s];isFinite(t+_+h+c)&&(e.beginPath(),e.moveTo(t,_),e.lineTo(h,c),this.visuals.line.set_vectorize(e,s),e.stroke())}}}_hit_point(e){const{sx:t,sy:s}=e,i={x:t,y:s},[n,r]=this.renderer.xscale.r_invert(t-2,t+2),[o,h]=this.renderer.yscale.r_invert(s-2,s+2),c=this.index.indices({x0:n,y0:o,x1:r,y1:h}),a=[];for(const e of c){const t=Math.max(2,this.line_width.get(e)/2)**2,s={x:this.sx0[e],y:this.sy0[e]},n={x:this.sx1[e],y:this.sy1[e]};_.dist_to_segment_squared(i,s,n)({x0:[h.XCoordinateSpec,{field:\"x0\"}],y0:[h.YCoordinateSpec,{field:\"y0\"}],x1:[h.XCoordinateSpec,{field:\"x1\"}],y1:[h.YCoordinateSpec,{field:\"y1\"}]}))),o.mixins(c.LineVector)},\n", @@ -703,8 +722,8 @@ " function _(n,t,e,o,s){o();const c=n(24),l=n(11);e.catmullrom_spline=function(n,t,e=10,o=.5,s=!1){(0,l.assert)(n.length==t.length);const r=n.length,f=s?r+1:r,w=(0,c.infer_type)(n,t),i=new w(f+2),u=new w(f+2);i.set(n,1),u.set(t,1),s?(i[0]=n[r-1],u[0]=t[r-1],i[f]=n[0],u[f]=t[0],i[f+1]=n[1],u[f+1]=t[1]):(i[0]=n[0],u[0]=t[0],i[f+1]=n[r-1],u[f+1]=t[r-1]);const g=new w(4*(e+1));for(let n=0,t=0;n<=e;n++){const o=n/e,s=o**2,c=o*s;g[t++]=2*c-3*s+1,g[t++]=-2*c+3*s,g[t++]=c-2*s+o,g[t++]=c-s}const h=new w((f-1)*(e+1)),_=new w((f-1)*(e+1));for(let n=1,t=0;n1&&(e.stroke(),o=!1)}o?(e.lineTo(t,r),e.lineTo(a,c)):(e.beginPath(),e.moveTo(s[n],i[n]),o=!0),l=n}e.lineTo(s[a-1],i[a-1]),e.stroke()}}draw_legend_for_index(e,t,n){(0,r.generic_line_scalar_legend)(this.visuals,e,t)}}n.StepView=f,f.__name__=\"StepView\";class u extends a.XYGlyph{constructor(e){super(e)}}n.Step=u,l=u,u.__name__=\"Step\",l.prototype.default_view=f,l.mixins(c.LineScalar),l.define((()=>({mode:[_.StepMode,\"before\"]})))},\n", " function _(t,e,s,i,n){i();const o=t(1);var _;const h=t(178),l=t(48),r=(0,o.__importStar)(t(185)),a=(0,o.__importStar)(t(18)),c=t(121),x=t(11),u=t(72);class f extends h.XYGlyphView{_rotate_point(t,e,s,i,n){return[(t-s)*Math.cos(n)-(e-i)*Math.sin(n)+s,(t-s)*Math.sin(n)+(e-i)*Math.cos(n)+i]}_text_bounds(t,e,s,i){return[[t,t+s,t+s,t,t],[e,e,e-i,e-i,e]]}_render(t,e,s){const{sx:i,sy:n,x_offset:o,y_offset:_,angle:h,text:l}=null!=s?s:this;this._sys=[],this._sxs=[];for(const s of e){const e=this._sxs[s]=[],r=this._sys[s]=[],a=i[s],x=n[s],u=o.get(s),f=_.get(s),p=h.get(s),g=l.get(s);if(isFinite(a+x+u+f+p)&&null!=g&&this.visuals.text.doit){const i=`${g}`;t.save(),t.translate(a+u,x+f),t.rotate(p),this.visuals.text.set_vectorize(t,s);const n=this.visuals.text.font_value(s),{height:o}=(0,c.font_metrics)(n),_=this.text_line_height.get(s)*o;if(-1==i.indexOf(\"\\n\")){t.fillText(i,0,0);const s=a+u,n=x+f,o=t.measureText(i).width,[h,l]=this._text_bounds(s,n,o,_);e.push(h),r.push(l)}else{const n=i.split(\"\\n\"),o=_*n.length,h=this.text_baseline.get(s);let l;switch(h){case\"top\":l=0;break;case\"middle\":l=-o/2+_/2;break;case\"bottom\":l=-o+_;break;default:l=0,console.warn(`'${h}' baseline not supported with multi line text`)}for(const s of n){t.fillText(s,0,l);const i=a+u,n=l+x+f,o=t.measureText(s).width,[h,c]=this._text_bounds(i,n,o,_);e.push(h),r.push(c),l+=_}}t.restore()}}}_hit_point(t){const{sx:e,sy:s}=t,i=[];for(let t=0;t({text:[a.NullStringSpec,{field:\"text\"}],angle:[a.AngleSpec,0],x_offset:[a.NumberSpec,0],y_offset:[a.NumberSpec,0]})))},\n", - " function _(t,s,e,i,r){i();const h=t(1);var o;const a=t(277),n=t(24),_=(0,h.__importStar)(t(18));class c extends a.BoxView{scenterxy(t){return[this.sx[t],(this.stop[t]+this.sbottom[t])/2]}_lrtb(t){const s=this.width.get(t)/2,e=this._x[t],i=this._top[t],r=this._bottom[t];return[e-s,e+s,Math.max(i,r),Math.min(i,r)]}_map_data(){this.sx=this.renderer.xscale.v_compute(this._x),this.sw=this.sdist(this.renderer.xscale,this._x,this.width,\"center\"),this.stop=this.renderer.yscale.v_compute(this._top),this.sbottom=this.renderer.yscale.v_compute(this._bottom);const t=this.sx.length;this.sleft=new n.ScreenArray(t),this.sright=new n.ScreenArray(t);for(let s=0;s({x:[_.XCoordinateSpec,{field:\"x\"}],bottom:[_.YCoordinateSpec,{value:0}],width:[_.NumberSpec,{value:1}],top:[_.YCoordinateSpec,{field:\"top\"}]})))},\n", - " function _(e,s,t,i,n){i();const r=e(1);var a;const c=e(178),l=e(184),d=e(48),o=e(24),h=e(20),_=(0,r.__importStar)(e(18)),u=e(10),g=e(72);class p extends c.XYGlyphView{_map_data(){\"data\"==this.model.properties.radius.units?this.sradius=this.sdist(this.renderer.xscale,this._x,this.radius):this.sradius=(0,o.to_screen)(this.radius)}_render(e,s,t){const{sx:i,sy:n,sradius:r,start_angle:a,end_angle:c}=null!=t?t:this,l=\"anticlock\"==this.model.direction;for(const t of s){const s=i[t],d=n[t],o=r[t],h=a.get(t),_=c.get(t);isFinite(s+d+o+h+_)&&(e.beginPath(),e.arc(s,d,o,h,_,l),e.lineTo(s,d),e.closePath(),this.visuals.fill.apply(e,t),this.visuals.hatch.apply(e,t),this.visuals.line.apply(e,t))}}_hit_point(e){let s,t,i,n,r,a,c,l,d;const{sx:o,sy:h}=e,_=this.renderer.xscale.invert(o),p=this.renderer.yscale.invert(h),x=2*this.max_radius;\"data\"===this.model.properties.radius.units?(a=_-x,c=_+x,l=p-x,d=p+x):(t=o-x,i=o+x,[a,c]=this.renderer.xscale.r_invert(t,i),n=h-x,r=h+x,[l,d]=this.renderer.yscale.r_invert(n,r));const y=[];for(const e of this.index.indices({x0:a,x1:c,y0:l,y1:d})){const a=this.sradius[e]**2;[t,i]=this.renderer.xscale.r_compute(_,this._x[e]),[n,r]=this.renderer.yscale.r_compute(p,this._y[e]),s=(t-i)**2+(n-r)**2,s<=a&&y.push(e)}const f=\"anticlock\"==this.model.direction,m=[];for(const e of y){const s=Math.atan2(h-this.sy[e],o-this.sx[e]);(0,u.angle_between)(-s,-this.start_angle.get(e),-this.end_angle.get(e),f)&&m.push(e)}return new g.Selection({indices:m})}draw_legend_for_index(e,s,t){(0,l.generic_area_vector_legend)(this.visuals,e,s,t)}scenterxy(e){const s=this.sradius[e]/2,t=(this.start_angle.get(e)+this.end_angle.get(e))/2;return[this.sx[e]+s*Math.cos(t),this.sy[e]+s*Math.sin(t)]}}t.WedgeView=p,p.__name__=\"WedgeView\";class x extends c.XYGlyph{constructor(e){super(e)}}t.Wedge=x,a=x,x.__name__=\"Wedge\",a.prototype.default_view=p,a.mixins([d.LineVector,d.FillVector,d.HatchVector]),a.define((({})=>({direction:[h.Direction,\"anticlock\"],radius:[_.DistanceSpec,{field:\"radius\"}],start_angle:[_.AngleSpec,{field:\"start_angle\"}],end_angle:[_.AngleSpec,{field:\"end_angle\"}]})))},\n", + " function _(t,e,s,i,r){i();const h=t(1);var o;const a=t(277),n=t(24),_=(0,h.__importStar)(t(18));class l extends a.BoxView{async lazy_initialize(){await super.lazy_initialize();const{webgl:e}=this.renderer.plot_view.canvas_view;if(null!=e&&e.regl_wrapper.has_webgl){const{LRTBGL:s}=await Promise.resolve().then((()=>(0,h.__importStar)(t(427))));this.glglyph=new s(e.regl_wrapper,this)}}scenterxy(t){return[this.sx[t],(this.stop[t]+this.sbottom[t])/2]}_lrtb(t){const e=this.width.get(t)/2,s=this._x[t],i=this._top[t],r=this._bottom[t];return[s-e,s+e,Math.max(i,r),Math.min(i,r)]}_map_data(){this.sx=this.renderer.xscale.v_compute(this._x),this.sw=this.sdist(this.renderer.xscale,this._x,this.width,\"center\"),this.stop=this.renderer.yscale.v_compute(this._top),this.sbottom=this.renderer.yscale.v_compute(this._bottom);const t=this.sx.length;this.sleft=new n.ScreenArray(t),this.sright=new n.ScreenArray(t);for(let e=0;e({x:[_.XCoordinateSpec,{field:\"x\"}],bottom:[_.YCoordinateSpec,{value:0}],width:[_.NumberSpec,{value:1}],top:[_.YCoordinateSpec,{field:\"top\"}]})))},\n", + " function _(e,s,t,i,n){i();const r=e(1);var a;const c=e(178),d=e(184),l=e(48),h=e(24),o=e(20),_=(0,r.__importStar)(e(18)),u=e(10),g=e(72),x=e(12);class p extends c.XYGlyphView{_map_data(){\"data\"==this.model.properties.radius.units?this.sradius=this.sdist(this.renderer.xscale,this._x,this.radius):this.sradius=(0,h.to_screen)(this.radius),this.max_sradius=(0,x.max)(this.sradius)}_render(e,s,t){const{sx:i,sy:n,sradius:r,start_angle:a,end_angle:c}=null!=t?t:this,d=\"anticlock\"==this.model.direction;for(const t of s){const s=i[t],l=n[t],h=r[t],o=a.get(t),_=c.get(t);isFinite(s+l+h+o+_)&&(e.beginPath(),e.arc(s,l,h,o,_,d),e.lineTo(s,l),e.closePath(),this.visuals.fill.apply(e,t),this.visuals.hatch.apply(e,t),this.visuals.line.apply(e,t))}}_hit_point(e){let s,t,i,n,r;const{sx:a,sy:c}=e,d=this.renderer.xscale.invert(a),l=this.renderer.yscale.invert(c);t=a-this.max_sradius,i=a+this.max_sradius;const[h,o]=this.renderer.xscale.r_invert(t,i);n=c-this.max_sradius,r=c+this.max_sradius;const[_,x]=this.renderer.yscale.r_invert(n,r),p=[];for(const e of this.index.indices({x0:h,x1:o,y0:_,y1:x})){const a=this.sradius[e]**2;[t,i]=this.renderer.xscale.r_compute(d,this._x[e]),[n,r]=this.renderer.yscale.r_compute(l,this._y[e]),s=(t-i)**2+(n-r)**2,s<=a&&p.push(e)}const y=\"anticlock\"==this.model.direction,m=[];for(const e of p){const s=Math.atan2(c-this.sy[e],a-this.sx[e]);(0,u.angle_between)(-s,-this.start_angle.get(e),-this.end_angle.get(e),y)&&m.push(e)}return new g.Selection({indices:m})}draw_legend_for_index(e,s,t){(0,d.generic_area_vector_legend)(this.visuals,e,s,t)}scenterxy(e){const s=this.sradius[e]/2,t=(this.start_angle.get(e)+this.end_angle.get(e))/2;return[this.sx[e]+s*Math.cos(t),this.sy[e]+s*Math.sin(t)]}}t.WedgeView=p,p.__name__=\"WedgeView\";class y extends c.XYGlyph{constructor(e){super(e)}}t.Wedge=y,a=y,y.__name__=\"Wedge\",a.prototype.default_view=p,a.mixins([l.LineVector,l.FillVector,l.HatchVector]),a.define((({})=>({direction:[o.Direction,\"anticlock\"],radius:[_.DistanceSpec,{field:\"radius\"}],start_angle:[_.AngleSpec,{field:\"start_angle\"}],end_angle:[_.AngleSpec,{field:\"end_angle\"}]})))},\n", " function _(t,_,r,o,a){o();const e=t(1);(0,e.__exportStar)(t(302),r),(0,e.__exportStar)(t(303),r),(0,e.__exportStar)(t(304),r)},\n", " function _(e,t,d,n,s){n();const o=e(53),r=e(12),_=e(9),i=e(72);class c extends o.Model{constructor(e){super(e)}_hit_test(e,t,d){if(!t.model.visible)return null;const n=d.glyph.hit_test(e);return null==n?null:d.model.view.convert_selection_from_subset(n)}}d.GraphHitTestPolicy=c,c.__name__=\"GraphHitTestPolicy\";class a extends c{constructor(e){super(e)}hit_test(e,t){return this._hit_test(e,t,t.edge_view)}do_selection(e,t,d,n){if(null==e)return!1;const s=t.edge_renderer.data_source.selected;return s.update(e,d,n),t.edge_renderer.data_source._select.emit(),!s.is_empty()}do_inspection(e,t,d,n,s){if(null==e)return!1;const{edge_renderer:o}=d.model,r=o.get_selection_manager().get_or_create_inspector(d.edge_view.model);return r.update(e,n,s),d.edge_view.model.data_source.setv({inspected:r},{silent:!0}),d.edge_view.model.data_source.inspect.emit([d.edge_view.model,{geometry:t}]),!r.is_empty()}}d.EdgesOnly=a,a.__name__=\"EdgesOnly\";class l extends c{constructor(e){super(e)}hit_test(e,t){return this._hit_test(e,t,t.node_view)}do_selection(e,t,d,n){if(null==e)return!1;const s=t.node_renderer.data_source.selected;return s.update(e,d,n),t.node_renderer.data_source._select.emit(),!s.is_empty()}do_inspection(e,t,d,n,s){if(null==e)return!1;const{node_renderer:o}=d.model,r=o.get_selection_manager().get_or_create_inspector(d.node_view.model);return r.update(e,n,s),d.node_view.model.data_source.setv({inspected:r},{silent:!0}),d.node_view.model.data_source.inspect.emit([d.node_view.model,{geometry:t}]),!r.is_empty()}}d.NodesOnly=l,l.__name__=\"NodesOnly\";class u extends c{constructor(e){super(e)}hit_test(e,t){return this._hit_test(e,t,t.node_view)}get_linked_edges(e,t,d){let n=[];\"selection\"==d?n=e.selected.indices.map((t=>e.data.index[t])):\"inspection\"==d&&(n=e.inspected.indices.map((t=>e.data.index[t])));const s=[];for(let e=0;e(0,r.indexOf)(e.data.index,t)));return new i.Selection({indices:o})}do_selection(e,t,d,n){if(null==e)return!1;const s=t.edge_renderer.data_source.selected;s.update(e,d,n);const o=t.node_renderer.data_source.selected,r=this.get_linked_nodes(t.node_renderer.data_source,t.edge_renderer.data_source,\"selection\");return o.update(r,d,n),t.edge_renderer.data_source._select.emit(),!s.is_empty()}do_inspection(e,t,d,n,s){if(null==e)return!1;const o=d.edge_view.model.data_source.selection_manager.get_or_create_inspector(d.edge_view.model);o.update(e,n,s),d.edge_view.model.data_source.setv({inspected:o},{silent:!0});const r=d.node_view.model.data_source.selection_manager.get_or_create_inspector(d.node_view.model),_=this.get_linked_nodes(d.node_view.model.data_source,d.edge_view.model.data_source,\"inspection\");return r.update(_,n,s),d.node_view.model.data_source.setv({inspected:r},{silent:!0}),d.edge_view.model.data_source.inspect.emit([d.edge_view.model,{geometry:t}]),!o.is_empty()}}d.EdgesAndLinkedNodes=m,m.__name__=\"EdgesAndLinkedNodes\"},\n", " function _(e,o,t,r,n){var s;r();const a=e(53),d=e(260);class _ extends a.Model{constructor(e){super(e)}get node_coordinates(){return new u({layout:this})}get edge_coordinates(){return new i({layout:this})}}t.LayoutProvider=_,_.__name__=\"LayoutProvider\";class c extends d.CoordinateTransform{constructor(e){super(e)}}t.GraphCoordinates=c,s=c,c.__name__=\"GraphCoordinates\",s.define((({Ref:e})=>({layout:[e(_)]})));class u extends c{constructor(e){super(e)}_v_compute(e){const[o,t]=this.layout.get_node_coordinates(e);return{x:o,y:t}}}t.NodeCoordinates=u,u.__name__=\"NodeCoordinates\";class i extends c{constructor(e){super(e)}_v_compute(e){const[o,t]=this.layout.get_edge_coordinates(e);return{x:o,y:t}}}t.EdgeCoordinates=i,i.__name__=\"EdgeCoordinates\"},\n", @@ -734,16 +753,16 @@ " function _(t,s,_,r,e){r();const i=t(9),o=t(325);class n extends o.Interpolator{constructor(t){super(t)}compute(t){if(this.sort(!1),this.clip){if(tthis._x_sorted[this._x_sorted.length-1])return NaN}else{if(tthis._x_sorted[this._x_sorted.length-1])return this._y_sorted[this._y_sorted.length-1]}if(t==this._x_sorted[0])return this._y_sorted[0];const s=(0,i.find_last_index)(this._x_sorted,(s=>sthis._x_sorted[this._x_sorted.length-1])return NaN}else{if(tthis._x_sorted[this._x_sorted.length-1])return this._y_sorted[this._y_sorted.length-1]}let e;switch(this.mode){case\"after\":e=(0,d.find_last_index)(this._x_sorted,(e=>t>=e));break;case\"before\":e=(0,d.find_index)(this._x_sorted,(e=>t<=e));break;case\"center\":{const s=(0,d.map)(this._x_sorted,(e=>Math.abs(e-t))),r=(0,d.min)(s);e=(0,d.find_index)(s,(t=>r===t));break}default:throw new Error(`unknown mode: ${this.mode}`)}return-1!=e?this._y_sorted[e]:NaN}}s.StepInterpolator=h,_=h,h.__name__=\"StepInterpolator\",_.define((()=>({mode:[n.StepMode,\"after\"]})))},\n", " function _(p,o,t,a,n){a(),n(\"MapOptions\",p(330).MapOptions),n(\"GMapOptions\",p(330).GMapOptions),n(\"GMapPlot\",p(330).GMapPlot),n(\"Plot\",p(331).Plot)},\n", - " function _(e,t,n,o,a){var s,p,_;o();const i=e(331),r=e(53),l=e(58),c=e(336);a(\"GMapPlotView\",c.GMapPlotView);class d extends r.Model{constructor(e){super(e)}}n.MapOptions=d,s=d,d.__name__=\"MapOptions\",s.define((({Int:e,Number:t})=>({lat:[t],lng:[t],zoom:[e,12]})));class u extends d{constructor(e){super(e)}}n.GMapOptions=u,p=u,u.__name__=\"GMapOptions\",p.define((({Boolean:e,Int:t,String:n})=>({map_type:[n,\"roadmap\"],scale_control:[e,!1],styles:[n],tilt:[t,45]})));class M extends i.Plot{constructor(e){super(e),this.use_map=!0}}n.GMapPlot=M,_=M,M.__name__=\"GMapPlot\",_.prototype.default_view=c.GMapPlotView,_.define((({String:e,Ref:t})=>({map_options:[t(u)],api_key:[e],api_version:[e,\"3.43\"]}))),_.override({x_range:()=>new l.Range1d,y_range:()=>new l.Range1d})},\n", + " function _(e,t,n,o,a){var s,p,_;o();const i=e(331),r=e(53),l=e(58),c=e(336);a(\"GMapPlotView\",c.GMapPlotView);class d extends r.Model{constructor(e){super(e)}}n.MapOptions=d,s=d,d.__name__=\"MapOptions\",s.define((({Int:e,Number:t})=>({lat:[t],lng:[t],zoom:[e,12]})));class u extends d{constructor(e){super(e)}}n.GMapOptions=u,p=u,u.__name__=\"GMapOptions\",p.define((({Boolean:e,Int:t,String:n})=>({map_type:[n,\"roadmap\"],scale_control:[e,!1],styles:[n],tilt:[t,45]})));class M extends i.Plot{constructor(e){super(e),this.use_map=!0}}n.GMapPlot=M,_=M,M.__name__=\"GMapPlot\",_.prototype.default_view=c.GMapPlotView,_.define((({String:e,Ref:t})=>({map_options:[t(u)],api_key:[e],api_version:[e,\"weekly\"]}))),_.override({x_range:()=>new l.Range1d,y_range:()=>new l.Range1d})},\n", " function _(e,t,r,n,i){n();const o=e(1);var a;const s=(0,o.__importStar)(e(48)),l=(0,o.__importStar)(e(18)),_=e(15),c=e(20),h=e(9),d=e(13),u=e(8),g=e(309),p=e(128),f=e(306),b=e(40),w=e(118),y=e(59),m=e(221),x=e(57),v=e(55),A=e(75),S=e(41),R=e(176),D=e(175),L=e(63),P=e(332);i(\"PlotView\",P.PlotView);class k extends g.LayoutDOM{constructor(e){super(e),this.use_map=!1}_doc_attached(){super._doc_attached(),this._push_changes([[this.properties.inner_height,null,this.inner_height],[this.properties.inner_width,null,this.inner_width]])}initialize(){super.initialize(),this.reset=new _.Signal0(this,\"reset\");for(const e of(0,d.values)(this.extra_x_ranges).concat(this.x_range)){let t=e.plots;(0,u.isArray)(t)&&(t=t.concat(this),e.setv({plots:t},{silent:!0}))}for(const e of(0,d.values)(this.extra_y_ranges).concat(this.y_range)){let t=e.plots;(0,u.isArray)(t)&&(t=t.concat(this),e.setv({plots:t},{silent:!0}))}}add_layout(e,t=\"center\"){const r=this.properties[t].get_value();this.setv({[t]:[...r,e]})}remove_layout(e){const t=t=>{(0,h.remove_by)(t,(t=>t==e))};t(this.left),t(this.right),t(this.above),t(this.below),t(this.center)}get data_renderers(){return this.renderers.filter((e=>e instanceof R.DataRenderer))}add_renderers(...e){this.renderers=this.renderers.concat(e)}add_glyph(e,t=new A.ColumnDataSource,r={}){const n=new D.GlyphRenderer(Object.assign(Object.assign({},r),{data_source:t,glyph:e}));return this.add_renderers(n),n}add_tools(...e){this.toolbar.tools=this.toolbar.tools.concat(e)}get panels(){return[...this.side_panels,...this.center]}get side_panels(){const{above:e,below:t,left:r,right:n}=this;return(0,h.concat)([e,t,r,n])}}r.Plot=k,a=k,k.__name__=\"Plot\",a.prototype.default_view=P.PlotView,a.mixins([[\"outline_\",s.Line],[\"background_\",s.Fill],[\"border_\",s.Fill]]),a.define((({Boolean:e,Number:t,String:r,Array:n,Dict:i,Or:o,Ref:a,Null:s,Nullable:_})=>({toolbar:[a(m.Toolbar),()=>new m.Toolbar],toolbar_location:[_(c.Location),\"right\"],toolbar_sticky:[e,!0],plot_width:[l.Alias(\"width\")],plot_height:[l.Alias(\"height\")],frame_width:[_(t),null],frame_height:[_(t),null],title:[o(a(w.Title),r,s),\"\",{convert:e=>(0,u.isString)(e)?new w.Title({text:e}):e}],title_location:[_(c.Location),\"above\"],above:[n(o(a(b.Annotation),a(p.Axis))),[]],below:[n(o(a(b.Annotation),a(p.Axis))),[]],left:[n(o(a(b.Annotation),a(p.Axis))),[]],right:[n(o(a(b.Annotation),a(p.Axis))),[]],center:[n(o(a(b.Annotation),a(f.Grid))),[]],renderers:[n(a(S.Renderer)),[]],x_range:[a(x.Range),()=>new L.DataRange1d],y_range:[a(x.Range),()=>new L.DataRange1d],x_scale:[a(v.Scale),()=>new y.LinearScale],y_scale:[a(v.Scale),()=>new y.LinearScale],extra_x_ranges:[i(a(x.Range)),{}],extra_y_ranges:[i(a(x.Range)),{}],extra_x_scales:[i(a(v.Scale)),{}],extra_y_scales:[i(a(v.Scale)),{}],lod_factor:[t,10],lod_interval:[t,300],lod_threshold:[_(t),2e3],lod_timeout:[t,500],hidpi:[e,!0],output_backend:[c.OutputBackend,\"canvas\"],min_border:[_(t),5],min_border_top:[_(t),null],min_border_left:[_(t),null],min_border_bottom:[_(t),null],min_border_right:[_(t),null],inner_width:[t,0],inner_height:[t,0],outer_width:[t,0],outer_height:[t,0],match_aspect:[e,!1],aspect_scale:[t,1],reset_policy:[c.ResetPolicy,\"standard\"]}))),a.override({width:600,height:600,outline_line_color:\"#e5e5e5\",border_fill_color:\"#ffffff\",background_fill_color:\"#ffffff\"})},\n", " function _(e,t,i,s,a){s();const n=e(1),o=e(126),l=e(249),r=e(309),_=e(40),h=e(118),d=e(128),u=e(220),c=e(251),p=e(113),v=e(45),g=e(19),b=e(251),m=e(333),y=e(8),w=e(9),f=e(235),x=e(208),z=e(211),k=e(209),q=e(123),M=e(65),R=e(334),V=e(335),S=e(28);class O extends r.LayoutDOMView{constructor(){super(...arguments),this._outer_bbox=new M.BBox,this._inner_bbox=new M.BBox,this._needs_paint=!0,this._needs_layout=!1,this._invalidated_painters=new Set,this._invalidate_all=!0,this._needs_notify=!1}get canvas(){return this.canvas_view}get state(){return this._state_manager}set invalidate_dataranges(e){this._range_manager.invalidate_dataranges=e}renderer_view(e){const t=this.renderer_views.get(e);if(null==t)for(const[,t]of this.renderer_views){const i=t.renderer_view(e);if(null!=i)return i}return t}get is_paused(){return null!=this._is_paused&&0!==this._is_paused}get child_models(){return[]}pause(){null==this._is_paused?this._is_paused=1:this._is_paused+=1}unpause(e=!1){if(null==this._is_paused)throw new Error(\"wasn't paused\");this._is_paused-=1,0!=this._is_paused||e||this.request_paint(\"everything\")}notify_finished_after_paint(){this._needs_notify=!0}request_render(){this.request_paint(\"everything\")}request_paint(e){this.invalidate_painters(e),this.schedule_paint()}invalidate_painters(e){if(\"everything\"==e)this._invalidate_all=!0;else if((0,y.isArray)(e))for(const t of e)this._invalidated_painters.add(t);else this._invalidated_painters.add(e)}schedule_paint(){if(!this.is_paused){const e=this.throttled_paint();this._ready=this._ready.then((()=>e))}}request_layout(){this._needs_layout=!0,this.request_paint(\"everything\")}reset(){\"standard\"==this.model.reset_policy&&(this.state.clear(),this.reset_range(),this.reset_selection()),this.model.trigger_event(new c.Reset)}remove(){(0,p.remove_views)(this.renderer_views),(0,p.remove_views)(this.tool_views),this.canvas_view.remove(),super.remove()}render(){super.render(),this.el.appendChild(this.canvas_view.el),this.canvas_view.render()}initialize(){this.pause(),super.initialize(),this.lod_started=!1,this.visuals=new v.Visuals(this),this._initial_state={selection:new Map,dimensions:{width:0,height:0}},this.visibility_callbacks=[],this.renderer_views=new Map,this.tool_views=new Map,this.frame=new o.CartesianFrame(this.model.x_scale,this.model.y_scale,this.model.x_range,this.model.y_range,this.model.extra_x_ranges,this.model.extra_y_ranges,this.model.extra_x_scales,this.model.extra_y_scales),this._range_manager=new R.RangeManager(this),this._state_manager=new V.StateManager(this,this._initial_state),this.throttled_paint=(0,m.throttle)((()=>this.repaint()),1e3/60);const{title_location:e,title:t}=this.model;null!=e&&null!=t&&(this._title=t instanceof h.Title?t:new h.Title({text:t}));const{toolbar_location:i,toolbar:s}=this.model;null!=i&&null!=s&&(this._toolbar=new u.ToolbarPanel({toolbar:s}),s.toolbar_location=i)}async lazy_initialize(){await super.lazy_initialize();const{hidpi:e,output_backend:t}=this.model,i=new l.Canvas({hidpi:e,output_backend:t});this.canvas_view=await(0,p.build_view)(i,{parent:this}),this.canvas_view.plot_views=[this],await this.build_renderer_views(),await this.build_tool_views(),this._range_manager.update_dataranges(),this.unpause(!0),g.logger.debug(\"PlotView initialized\")}_width_policy(){return null==this.model.frame_width?super._width_policy():\"min\"}_height_policy(){return null==this.model.frame_height?super._height_policy():\"min\"}_update_layout(){var e,t,i,s,a;this.layout=new z.BorderLayout,this.layout.set_sizing(this.box_sizing());const n=(0,w.copy)(this.model.above),o=(0,w.copy)(this.model.below),l=(0,w.copy)(this.model.left),r=(0,w.copy)(this.model.right),d=e=>{switch(e){case\"above\":return n;case\"below\":return o;case\"left\":return l;case\"right\":return r}},{title_location:c,title:p}=this.model;null!=c&&null!=p&&d(c).push(this._title);const{toolbar_location:v,toolbar:g}=this.model;if(null!=v&&null!=g){const e=d(v);let t=!0;if(this.model.toolbar_sticky)for(let i=0;i{var i;const s=this.renderer_view(t);return s.panel=new q.Panel(e),null===(i=s.update_layout)||void 0===i||i.call(s),s.layout},m=(e,t)=>{const i=\"above\"==e||\"below\"==e,s=[];for(const a of t)if((0,y.isArray)(a)){const t=a.map((t=>{const s=b(e,t);if(t instanceof u.ToolbarPanel){const e=i?\"width_policy\":\"height_policy\";s.set_sizing(Object.assign(Object.assign({},s.sizing),{[e]:\"min\"}))}return s}));let n;i?(n=new k.Row(t),n.set_sizing({width_policy:\"max\",height_policy:\"min\"})):(n=new k.Column(t),n.set_sizing({width_policy:\"min\",height_policy:\"max\"})),n.absolute=!0,s.push(n)}else s.push(b(e,a));return s},f=null!==(e=this.model.min_border)&&void 0!==e?e:0;this.layout.min_border={left:null!==(t=this.model.min_border_left)&&void 0!==t?t:f,top:null!==(i=this.model.min_border_top)&&void 0!==i?i:f,right:null!==(s=this.model.min_border_right)&&void 0!==s?s:f,bottom:null!==(a=this.model.min_border_bottom)&&void 0!==a?a:f};const M=new x.NodeLayout,R=new x.VStack,V=new x.VStack,S=new x.HStack,O=new x.HStack;M.absolute=!0,R.absolute=!0,V.absolute=!0,S.absolute=!0,O.absolute=!0,M.children=this.model.center.filter((e=>e instanceof _.Annotation)).map((e=>{var t;const i=this.renderer_view(e);return null===(t=i.update_layout)||void 0===t||t.call(i),i.layout})).filter((e=>null!=e));const{frame_width:P,frame_height:j}=this.model;M.set_sizing(Object.assign(Object.assign({},null!=P?{width_policy:\"fixed\",width:P}:{width_policy:\"fit\"}),null!=j?{height_policy:\"fixed\",height:j}:{height_policy:\"fit\"})),M.on_resize((e=>this.frame.set_geometry(e))),R.children=(0,w.reversed)(m(\"above\",n)),V.children=m(\"below\",o),S.children=(0,w.reversed)(m(\"left\",l)),O.children=m(\"right\",r),R.set_sizing({width_policy:\"fit\",height_policy:\"min\"}),V.set_sizing({width_policy:\"fit\",height_policy:\"min\"}),S.set_sizing({width_policy:\"min\",height_policy:\"fit\"}),O.set_sizing({width_policy:\"min\",height_policy:\"fit\"}),this.layout.center_panel=M,this.layout.top_panel=R,this.layout.bottom_panel=V,this.layout.left_panel=S,this.layout.right_panel=O}get axis_views(){const e=[];for(const[,t]of this.renderer_views)t instanceof d.AxisView&&e.push(t);return e}set_toolbar_visibility(e){for(const t of this.visibility_callbacks)t(e)}update_range(e,t){this.pause(),this._range_manager.update(e,t),this.unpause()}reset_range(){this.update_range(null),this.trigger_ranges_update_event()}trigger_ranges_update_event(){const{x_range:e,y_range:t}=this.model;this.model.trigger_event(new b.RangesUpdate(e.start,e.end,t.start,t.end))}get_selection(){const e=new Map;for(const t of this.model.data_renderers){const{selected:i}=t.selection_manager.source;e.set(t,i)}return e}update_selection(e){for(const t of this.model.data_renderers){const i=t.selection_manager.source;if(null!=e){const s=e.get(t);null!=s&&i.selected.update(s,!0)}else i.selection_manager.clear()}}reset_selection(){this.update_selection(null)}_invalidate_layout(){(()=>{var e;for(const t of this.model.side_panels){const i=this.renderer_views.get(t);if(null===(e=i.layout)||void 0===e?void 0:e.has_size_changed())return this.invalidate_painters(i),!0}return!1})()&&this.root.compute_layout()}get_renderer_views(){return this.computed_renderers.map((e=>this.renderer_views.get(e)))}*_compute_renderers(){const{above:e,below:t,left:i,right:s,center:a,renderers:n}=this.model;yield*n,yield*e,yield*t,yield*i,yield*s,yield*a,null!=this._title&&(yield this._title),null!=this._toolbar&&(yield this._toolbar);for(const e of this.model.toolbar.tools)null!=e.overlay&&(yield e.overlay),yield*e.synthetic_renderers}async build_renderer_views(){this.computed_renderers=[...this._compute_renderers()],await(0,p.build_views)(this.renderer_views,this.computed_renderers,{parent:this})}async build_tool_views(){const e=this.model.toolbar.tools;(await(0,p.build_views)(this.tool_views,e,{parent:this})).map((e=>this.canvas_view.ui_event_bus.register_tool(e)))}connect_signals(){super.connect_signals();const{x_ranges:e,y_ranges:t}=this.frame;for(const[,t]of e)this.connect(t.change,(()=>{this._needs_layout=!0,this.request_paint(\"everything\")}));for(const[,e]of t)this.connect(e.change,(()=>{this._needs_layout=!0,this.request_paint(\"everything\")}));const{above:i,below:s,left:a,right:n,center:o,renderers:l}=this.model.properties;this.on_change([i,s,a,n,o,l],(async()=>await this.build_renderer_views())),this.connect(this.model.toolbar.properties.tools.change,(async()=>{await this.build_renderer_views(),await this.build_tool_views()})),this.connect(this.model.change,(()=>this.request_paint(\"everything\"))),this.connect(this.model.reset,(()=>this.reset()))}has_finished(){if(!super.has_finished())return!1;if(this.model.visible)for(const[,e]of this.renderer_views)if(!e.has_finished())return!1;return!0}after_layout(){var e;super.after_layout();for(const[,t]of this.renderer_views)t instanceof _.AnnotationView&&(null===(e=t.after_layout)||void 0===e||e.call(t));if(this._needs_layout=!1,this.model.setv({inner_width:Math.round(this.frame.bbox.width),inner_height:Math.round(this.frame.bbox.height),outer_width:Math.round(this.layout.bbox.width),outer_height:Math.round(this.layout.bbox.height)},{no_change:!0}),!1!==this.model.match_aspect&&(this.pause(),this._range_manager.update_dataranges(),this.unpause(!0)),!this._outer_bbox.equals(this.layout.bbox)){const{width:e,height:t}=this.layout.bbox;this.canvas_view.resize(e,t),this._outer_bbox=this.layout.bbox,this._invalidate_all=!0,this._needs_paint=!0}const{inner_bbox:t}=this.layout;this._inner_bbox.equals(t)||(this._inner_bbox=t,this._needs_paint=!0),this._needs_paint&&this.paint()}repaint(){this._needs_layout&&this._invalidate_layout(),this.paint()}paint(){this.is_paused||(this.model.visible&&(g.logger.trace(`${this.toString()}.paint()`),this._actual_paint()),this._needs_notify&&(this._needs_notify=!1,this.notify_finished()))}_actual_paint(){var e;const{document:t}=this.model;if(null!=t){const e=t.interactive_duration();e>=0&&e{t.interactive_duration()>this.model.lod_timeout&&t.interactive_stop(),this.request_paint(\"everything\")}),this.model.lod_timeout):t.interactive_stop()}this._range_manager.invalidate_dataranges&&(this._range_manager.update_dataranges(),this._invalidate_layout());let i=!1,s=!1;if(this._invalidate_all)i=!0,s=!0;else for(const e of this._invalidated_painters){const{level:t}=e.model;if(\"overlay\"!=t?i=!0:s=!0,i&&s)break}this._invalidated_painters.clear(),this._invalidate_all=!1;const a=[this.frame.bbox.left,this.frame.bbox.top,this.frame.bbox.width,this.frame.bbox.height],{primary:n,overlays:o}=this.canvas_view;i&&(n.prepare(),this.canvas_view.prepare_webgl(a),this._map_hook(n.ctx,a),this._paint_empty(n.ctx,a),this._paint_outline(n.ctx,a),this._paint_levels(n.ctx,\"image\",a,!0),this._paint_levels(n.ctx,\"underlay\",a,!0),this._paint_levels(n.ctx,\"glyph\",a,!0),this._paint_levels(n.ctx,\"guide\",a,!1),this._paint_levels(n.ctx,\"annotation\",a,!1),n.finish()),(s||S.settings.wireframe)&&(o.prepare(),this._paint_levels(o.ctx,\"overlay\",a,!1),S.settings.wireframe&&this._paint_layout(o.ctx,this.layout),o.finish()),null==this._initial_state.range&&(this._initial_state.range=null!==(e=this._range_manager.compute_initial())&&void 0!==e?e:void 0),this._needs_paint=!1}_paint_levels(e,t,i,s){for(const a of this.computed_renderers){if(a.level!=t)continue;const n=this.renderer_views.get(a);e.save(),(s||n.needs_clip)&&(e.beginPath(),e.rect(...i),e.clip()),n.render(),e.restore(),n.has_webgl&&n.needs_webgl_blit&&this.canvas_view.blit_webgl(e)}}_paint_layout(e,t){const{x:i,y:s,width:a,height:n}=t.bbox;e.strokeStyle=\"blue\",e.strokeRect(i,s,a,n);for(const a of t)e.save(),t.absolute||e.translate(i,s),this._paint_layout(e,a),e.restore()}_map_hook(e,t){}_paint_empty(e,t){const[i,s,a,n]=[0,0,this.layout.bbox.width,this.layout.bbox.height],[o,l,r,_]=t;this.visuals.border_fill.doit&&(this.visuals.border_fill.set_value(e),e.fillRect(i,s,a,n),e.clearRect(o,l,r,_)),this.visuals.background_fill.doit&&(this.visuals.background_fill.set_value(e),e.fillRect(o,l,r,_))}_paint_outline(e,t){if(this.visuals.outline_line.doit){e.save(),this.visuals.outline_line.set_value(e);let[i,s,a,n]=t;i+a==this.layout.bbox.width&&(a-=1),s+n==this.layout.bbox.height&&(n-=1),e.strokeRect(i,s,a,n),e.restore()}}to_blob(){return this.canvas_view.to_blob()}export(e,t=!0){const i=\"png\"==e?\"canvas\":\"svg\",s=new f.CanvasLayer(i,t),{width:a,height:n}=this.layout.bbox;s.resize(a,n);const{canvas:o}=this.canvas_view.compose();return s.ctx.drawImage(o,0,0),s}serializable_state(){const e=super.serializable_state(),{children:t}=e,i=(0,n.__rest)(e,[\"children\"]),s=this.get_renderer_views().map((e=>e.serializable_state())).filter((e=>null!=e.bbox));return Object.assign(Object.assign({},i),{children:[...null!=t?t:[],...s]})}}i.PlotView=O,O.__name__=\"PlotView\"},\n", " function _(t,n,e,o,u){o(),e.throttle=function(t,n){let e=null,o=0,u=!1;return function(){return new Promise(((r,i)=>{const l=function(){o=Date.now(),e=null,u=!1;try{t(),r()}catch(t){i(t)}},a=Date.now(),c=n-(a-o);c<=0&&!u?(null!=e&&clearTimeout(e),u=!0,requestAnimationFrame(l)):e||u?r():e=setTimeout((()=>requestAnimationFrame(l)),c)}))}}},\n", - " function _(t,n,e,a,s){a();const o=t(63),r=t(19);class l{constructor(t){this.parent=t,this.invalidate_dataranges=!0}get frame(){return this.parent.frame}update(t,n){const{x_ranges:e,y_ranges:a}=this.frame;if(null==t){for(const[,t]of e)t.reset();for(const[,t]of a)t.reset();this.update_dataranges()}else{const s=[];for(const[n,a]of e)s.push([a,t.xrs.get(n)]);for(const[n,e]of a)s.push([e,t.yrs.get(n)]);(null==n?void 0:n.scrolling)&&this._update_ranges_together(s),this._update_ranges_individually(s,n)}}reset(){this.update(null)}_update_dataranges(t){const n=new Map,e=new Map;let a=!1;for(const[,n]of t.x_ranges)n instanceof o.DataRange1d&&\"log\"==n.scale_hint&&(a=!0);for(const[,n]of t.y_ranges)n instanceof o.DataRange1d&&\"log\"==n.scale_hint&&(a=!0);for(const t of this.parent.model.data_renderers){const s=this.parent.renderer_view(t);if(null==s)continue;const o=s.glyph_view.bounds();if(null!=o&&n.set(t,o),a){const n=s.glyph_view.log_bounds();null!=n&&e.set(t,n)}}let s=!1,l=!1;const i=t.x_target.span,d=t.y_target.span;let u;!1!==this.parent.model.match_aspect&&0!=i&&0!=d&&(u=1/this.parent.model.aspect_scale*(i/d));for(const[,a]of t.x_ranges){if(a instanceof o.DataRange1d){const t=\"log\"==a.scale_hint?e:n;a.update(t,0,this.parent.model,u),a.follow&&(s=!0)}null!=a.bounds&&(l=!0)}for(const[,a]of t.y_ranges){if(a instanceof o.DataRange1d){const t=\"log\"==a.scale_hint?e:n;a.update(t,1,this.parent.model,u),a.follow&&(s=!0)}null!=a.bounds&&(l=!0)}if(s&&l){r.logger.warn(\"Follow enabled so bounds are unset.\");for(const[,n]of t.x_ranges)n.bounds=null;for(const[,n]of t.y_ranges)n.bounds=null}}update_dataranges(){this._update_dataranges(this.frame);for(const t of this.parent.model.renderers){const{coordinates:n}=t;null!=n&&this._update_dataranges(n)}this.invalidate_dataranges=!1}compute_initial(){let t=!0;const{x_ranges:n,y_ranges:e}=this.frame,a=new Map,s=new Map;for(const[e,s]of n){const{start:n,end:o}=s;if(null==n||null==o||isNaN(n+o)){t=!1;break}a.set(e,{start:n,end:o})}if(t)for(const[n,a]of e){const{start:e,end:o}=a;if(null==e||null==o||isNaN(e+o)){t=!1;break}s.set(n,{start:e,end:o})}return t?{xrs:a,yrs:s}:(r.logger.warn(\"could not set initial ranges\"),null)}_update_ranges_together(t){let n=1;for(const[e,a]of t)n=Math.min(n,this._get_weight_to_constrain_interval(e,a));if(n<1)for(const[e,a]of t)a.start=n*a.start+(1-n)*e.start,a.end=n*a.end+(1-n)*e.end}_update_ranges_individually(t,n){const e=!!(null==n?void 0:n.panning),a=!!(null==n?void 0:n.scrolling);let s=!1;for(const[n,o]of t){if(!a){const t=this._get_weight_to_constrain_interval(n,o);t<1&&(o.start=t*o.start+(1-t)*n.start,o.end=t*o.end+(1-t)*n.end)}if(null!=n.bounds&&\"auto\"!=n.bounds){const[t,r]=n.bounds,l=Math.abs(o.end-o.start);n.is_reversed?(null!=t&&t>=o.end&&(s=!0,o.end=t,(e||a)&&(o.start=t+l)),null!=r&&r<=o.start&&(s=!0,o.start=r,(e||a)&&(o.end=r-l))):(null!=t&&t>=o.start&&(s=!0,o.start=t,(e||a)&&(o.end=t+l)),null!=r&&r<=o.end&&(s=!0,o.end=r,(e||a)&&(o.start=r-l)))}}if(!(a&&s&&(null==n?void 0:n.maintain_focus)))for(const[n,e]of t)n.have_updated_interactively=!0,n.start==e.start&&n.end==e.end||n.setv(e)}_get_weight_to_constrain_interval(t,n){const{min_interval:e}=t;let{max_interval:a}=t;if(null!=t.bounds&&\"auto\"!=t.bounds){const[n,e]=t.bounds;if(null!=n&&null!=e){const t=Math.abs(e-n);a=null!=a?Math.min(a,t):t}}let s=1;if(null!=e||null!=a){const o=Math.abs(t.end-t.start),r=Math.abs(n.end-n.start);null!=e&&e>0&&r0&&r>a&&(s=(a-o)/(r-o)),s=Math.max(0,Math.min(1,s))}return s}}e.RangeManager=l,l.__name__=\"RangeManager\"},\n", + " function _(t,n,e,a,s){a();const o=t(63),r=t(19);class l{constructor(t){this.parent=t,this.invalidate_dataranges=!0}get frame(){return this.parent.frame}update(t,n){const{x_ranges:e,y_ranges:a}=this.frame;if(null==t){for(const[,t]of e)t.reset();for(const[,t]of a)t.reset();this.update_dataranges()}else{const s=[];for(const[n,a]of e)s.push([a,t.xrs.get(n)]);for(const[n,e]of a)s.push([e,t.yrs.get(n)]);(null==n?void 0:n.scrolling)&&this._update_ranges_together(s),this._update_ranges_individually(s,n)}}reset(){this.update(null)}_update_dataranges(t){const n=new Map,e=new Map;let a=!1;for(const[,n]of t.x_ranges)n instanceof o.DataRange1d&&\"log\"==n.scale_hint&&(a=!0);for(const[,n]of t.y_ranges)n instanceof o.DataRange1d&&\"log\"==n.scale_hint&&(a=!0);for(const t of this.parent.model.data_renderers){const s=this.parent.renderer_view(t);if(null==s)continue;const o=s.glyph_view.bounds();if(null!=o&&n.set(t,o),a){const n=s.glyph_view.log_bounds();null!=n&&e.set(t,n)}}let s=!1,l=!1;const i=t.x_target.span,d=t.y_target.span;let u;!1!==this.parent.model.match_aspect&&0!=i&&0!=d&&(u=1/this.parent.model.aspect_scale*(i/d));for(const[,a]of t.x_ranges){if(a instanceof o.DataRange1d){const t=\"log\"==a.scale_hint?e:n;a.update(t,0,this.parent.model,u),a.follow&&(s=!0)}null!=a.bounds&&(l=!0)}for(const[,a]of t.y_ranges){if(a instanceof o.DataRange1d){const t=\"log\"==a.scale_hint?e:n;a.update(t,1,this.parent.model,u),a.follow&&(s=!0)}null!=a.bounds&&(l=!0)}if(s&&l){r.logger.warn(\"Follow enabled so bounds are unset.\");for(const[,n]of t.x_ranges)n.bounds=null;for(const[,n]of t.y_ranges)n.bounds=null}}update_dataranges(){this._update_dataranges(this.frame);for(const t of this.parent.model.renderers){const{coordinates:n}=t;null!=n&&this._update_dataranges(n)}null!=this.compute_initial()&&(this.invalidate_dataranges=!1)}compute_initial(){let t=!0;const{x_ranges:n,y_ranges:e}=this.frame,a=new Map,s=new Map;for(const[e,s]of n){const{start:n,end:o}=s;if(null==n||null==o||isNaN(n+o)){t=!1;break}a.set(e,{start:n,end:o})}if(t)for(const[n,a]of e){const{start:e,end:o}=a;if(null==e||null==o||isNaN(e+o)){t=!1;break}s.set(n,{start:e,end:o})}return t?{xrs:a,yrs:s}:(r.logger.warn(\"could not set initial ranges\"),null)}_update_ranges_together(t){let n=1;for(const[e,a]of t)n=Math.min(n,this._get_weight_to_constrain_interval(e,a));if(n<1)for(const[e,a]of t)a.start=n*a.start+(1-n)*e.start,a.end=n*a.end+(1-n)*e.end}_update_ranges_individually(t,n){const e=!!(null==n?void 0:n.panning),a=!!(null==n?void 0:n.scrolling);let s=!1;for(const[n,o]of t){if(!a){const t=this._get_weight_to_constrain_interval(n,o);t<1&&(o.start=t*o.start+(1-t)*n.start,o.end=t*o.end+(1-t)*n.end)}if(null!=n.bounds&&\"auto\"!=n.bounds){const[t,r]=n.bounds,l=Math.abs(o.end-o.start);n.is_reversed?(null!=t&&t>o.end&&(s=!0,o.end=t,(e||a)&&(o.start=t+l)),null!=r&&ro.start&&(s=!0,o.start=t,(e||a)&&(o.end=t+l)),null!=r&&r0&&r0&&r>a&&(s=(a-o)/(r-o)),s=Math.max(0,Math.min(1,s))}return s}}e.RangeManager=l,l.__name__=\"RangeManager\"},\n", " function _(t,i,s,e,n){e();const h=t(15);class a{constructor(t,i){this.parent=t,this.initial_state=i,this.changed=new h.Signal0(this.parent,\"state_changed\"),this.history=[],this.index=-1}_do_state_change(t){const i=null!=this.history[t]?this.history[t].state:this.initial_state;return null!=i.range&&this.parent.update_range(i.range),null!=i.selection&&this.parent.update_selection(i.selection),i}push(t,i){const{history:s,index:e}=this,n=null!=s[e]?s[e].state:{},h=Object.assign(Object.assign(Object.assign({},this.initial_state),n),i);this.history=this.history.slice(0,this.index+1),this.history.push({type:t,state:h}),this.index=this.history.length-1,this.changed.emit()}clear(){this.history=[],this.index=-1,this.changed.emit()}undo(){if(this.can_undo){this.index-=1;const t=this._do_state_change(this.index);return this.changed.emit(),t}return null}redo(){if(this.can_redo){this.index+=1;const t=this._do_state_change(this.index);return this.changed.emit(),t}return null}get can_undo(){return this.index>=0}get can_redo(){return this.indexm.emit();const s=encodeURIComponent,o=document.createElement(\"script\");o.type=\"text/javascript\",o.src=`https://maps.googleapis.com/maps/api/js?v=${s(e)}&key=${s(t)}&callback=_bokeh_gmaps_callback`,document.body.appendChild(o)}(t,e)}m.connect((()=>this.request_paint(\"everything\")))}this.unpause()}remove(){(0,p.remove)(this.map_el),super.remove()}update_range(t,e){var s,o;if(null==t)this.map.setCenter({lat:this.initial_lat,lng:this.initial_lng}),this.map.setOptions({zoom:this.initial_zoom}),super.update_range(null,e);else if(null!=t.sdx||null!=t.sdy)this.map.panBy(null!==(s=t.sdx)&&void 0!==s?s:0,null!==(o=t.sdy)&&void 0!==o?o:0),super.update_range(t,e);else if(null!=t.factor){if(10!==this.zoom_count)return void(this.zoom_count+=1);this.zoom_count=0,this.pause(),super.update_range(t,e);const s=t.factor<0?-1:1,o=this.map.getZoom();if(null!=o){const t=o+s;if(t>=2){this.map.setZoom(t);const[e,s]=this._get_projected_bounds();s-e<0&&this.map.setZoom(o)}}this.unpause()}this._set_bokeh_ranges()}_build_map(){const{maps:t}=google;this.map_types={satellite:t.MapTypeId.SATELLITE,terrain:t.MapTypeId.TERRAIN,roadmap:t.MapTypeId.ROADMAP,hybrid:t.MapTypeId.HYBRID};const e=this.model.map_options,s={center:new t.LatLng(e.lat,e.lng),zoom:e.zoom,disableDefaultUI:!0,mapTypeId:this.map_types[e.map_type],scaleControl:e.scale_control,tilt:e.tilt};null!=e.styles&&(s.styles=JSON.parse(e.styles)),this.map_el=(0,p.div)({style:{position:\"absolute\"}}),this.canvas_view.add_underlay(this.map_el),this.map=new t.Map(this.map_el,s),t.event.addListener(this.map,\"idle\",(()=>this._set_bokeh_ranges())),t.event.addListener(this.map,\"bounds_changed\",(()=>this._set_bokeh_ranges())),t.event.addListenerOnce(this.map,\"tilesloaded\",(()=>this._render_finished())),this.connect(this.model.properties.map_options.change,(()=>this._update_options())),this.connect(this.model.map_options.properties.styles.change,(()=>this._update_styles())),this.connect(this.model.map_options.properties.lat.change,(()=>this._update_center(\"lat\"))),this.connect(this.model.map_options.properties.lng.change,(()=>this._update_center(\"lng\"))),this.connect(this.model.map_options.properties.zoom.change,(()=>this._update_zoom())),this.connect(this.model.map_options.properties.map_type.change,(()=>this._update_map_type())),this.connect(this.model.map_options.properties.scale_control.change,(()=>this._update_scale_control())),this.connect(this.model.map_options.properties.tilt.change,(()=>this._update_tilt()))}_render_finished(){this._tiles_loaded=!0,this.notify_finished()}has_finished(){return super.has_finished()&&!0===this._tiles_loaded}_get_latlon_bounds(){const t=this.map.getBounds(),e=t.getNorthEast(),s=t.getSouthWest();return[s.lng(),e.lng(),s.lat(),e.lat()]}_get_projected_bounds(){const[t,e,s,o]=this._get_latlon_bounds(),[i,a]=l.wgs84_mercator.compute(t,s),[n,p]=l.wgs84_mercator.compute(e,o);return[i,n,a,p]}_set_bokeh_ranges(){const[t,e,s,o]=this._get_projected_bounds();this.frame.x_range.setv({start:t,end:e}),this.frame.y_range.setv({start:s,end:o})}_update_center(t){var e;const s=null===(e=this.map.getCenter())||void 0===e?void 0:e.toJSON();null!=s&&(s[t]=this.model.map_options[t],this.map.setCenter(s),this._set_bokeh_ranges())}_update_map_type(){this.map.setOptions({mapTypeId:this.map_types[this.model.map_options.map_type]})}_update_scale_control(){this.map.setOptions({scaleControl:this.model.map_options.scale_control})}_update_tilt(){this.map.setOptions({tilt:this.model.map_options.tilt})}_update_options(){this._update_styles(),this._update_center(\"lat\"),this._update_center(\"lng\"),this._update_zoom(),this._update_map_type()}_update_styles(){this.map.setOptions({styles:JSON.parse(this.model.map_options.styles)})}_update_zoom(){this.map.setOptions({zoom:this.model.map_options.zoom}),this._set_bokeh_ranges()}_map_hook(t,e){if(null==this.map&&\"undefined\"!=typeof google&&null!=google.maps&&this._build_map(),null!=this.map_el){const[t,s,o,i]=e;this.map_el.style.top=`${s}px`,this.map_el.style.left=`${t}px`,this.map_el.style.width=`${o}px`,this.map_el.style.height=`${i}px`}}_paint_empty(t,e){const s=this.layout.bbox.width,o=this.layout.bbox.height,[i,a,n,p]=e;t.clearRect(0,0,s,o),t.beginPath(),t.moveTo(0,0),t.lineTo(0,o),t.lineTo(s,o),t.lineTo(s,0),t.lineTo(0,0),t.moveTo(i,a),t.lineTo(i+n,a),t.lineTo(i+n,a+p),t.lineTo(i,a+p),t.lineTo(i,a),t.closePath(),null!=this.model.border_fill_color&&(t.fillStyle=(0,_.color2css)(this.model.border_fill_color),t.fill())}}s.GMapPlotView=d,d.__name__=\"GMapPlotView\"},\n", " function _(t,_,n,o,r){o();(0,t(1).__exportStar)(t(132),n)},\n", " function _(e,r,d,n,R){n(),R(\"GlyphRenderer\",e(175).GlyphRenderer),R(\"GraphRenderer\",e(339).GraphRenderer),R(\"GuideRenderer\",e(129).GuideRenderer);var G=e(41);R(\"Renderer\",G.Renderer),R(\"RendererGroup\",G.RendererGroup)},\n", - " function _(e,r,i,n,t){var d;n();const o=e(176),s=e(175),a=e(303),l=e(302),p=e(113),_=e(178),h=e(283),y=e(286);class c extends o.DataRendererView{get glyph_view(){return this.node_view.glyph}async lazy_initialize(){await super.lazy_initialize(),this.apply_coordinates();const{parent:e}=this,{edge_renderer:r,node_renderer:i}=this.model;this.edge_view=await(0,p.build_view)(r,{parent:e}),this.node_view=await(0,p.build_view)(i,{parent:e})}connect_signals(){super.connect_signals(),this.connect(this.model.layout_provider.change,(()=>{this.apply_coordinates(),this.edge_view.set_data(),this.node_view.set_data(),this.request_render()}))}apply_coordinates(){const{edge_renderer:e,node_renderer:r}=this.model;if(!(e.glyph instanceof h.MultiLine||e.glyph instanceof y.Patches))throw new Error(`${this}.edge_renderer.glyph must be a MultiLine glyph`);if(!(r.glyph instanceof _.XYGlyph))throw new Error(`${this}.node_renderer.glyph must be a XYGlyph glyph`);const i=this.model.layout_provider.edge_coordinates,n=this.model.layout_provider.node_coordinates;e.glyph.properties.xs.internal=!0,e.glyph.properties.ys.internal=!0,r.glyph.properties.x.internal=!0,r.glyph.properties.y.internal=!0,e.glyph.xs={expr:i.x},e.glyph.ys={expr:i.y},r.glyph.x={expr:n.x},r.glyph.y={expr:n.y},this.model.edge_renderer=e,this.model.node_renderer=r}remove(){this.edge_view.remove(),this.node_view.remove(),super.remove()}_render(){this.edge_view.render(),this.node_view.render()}renderer_view(e){if(e instanceof s.GlyphRenderer){if(e==this.edge_view.model)return this.edge_view;if(e==this.node_view.model)return this.node_view}return super.renderer_view(e)}}i.GraphRendererView=c,c.__name__=\"GraphRendererView\";class g extends o.DataRenderer{constructor(e){super(e)}get_selection_manager(){return this.node_renderer.data_source.selection_manager}}i.GraphRenderer=g,d=g,g.__name__=\"GraphRenderer\",d.prototype.default_view=c,d.define((({Ref:e})=>({layout_provider:[e(a.LayoutProvider)],node_renderer:[e(s.GlyphRenderer)],edge_renderer:[e(s.GlyphRenderer)],selection_policy:[e(l.GraphHitTestPolicy),()=>new l.NodesOnly],inspection_policy:[e(l.GraphHitTestPolicy),()=>new l.NodesOnly]})))},\n", + " function _(e,r,i,n,t){var o;n();const s=e(176),d=e(175),a=e(303),p=e(302),l=e(113),_=e(178),h=e(283),y=e(286);class c extends s.DataRendererView{get glyph_view(){return this.node_view.glyph}async lazy_initialize(){await super.lazy_initialize(),this.apply_coordinates();const{parent:e}=this,{edge_renderer:r,node_renderer:i}=this.model;this.edge_view=await(0,l.build_view)(r,{parent:e}),this.node_view=await(0,l.build_view)(i,{parent:e})}connect_signals(){super.connect_signals(),this.connect(this.model.layout_provider.change,(()=>{this.apply_coordinates(),this.edge_view.set_data(),this.node_view.set_data(),this.request_render()}))}apply_coordinates(){const{edge_renderer:e,node_renderer:r}=this.model;if(!(e.glyph instanceof h.MultiLine||e.glyph instanceof y.Patches))throw new Error(`${this}.edge_renderer.glyph must be a MultiLine glyph`);if(!(r.glyph instanceof _.XYGlyph))throw new Error(`${this}.node_renderer.glyph must be a XYGlyph glyph`);const i=this.model.layout_provider.edge_coordinates,n=this.model.layout_provider.node_coordinates;e.glyph.properties.xs.internal=!0,e.glyph.properties.ys.internal=!0,r.glyph.properties.x.internal=!0,r.glyph.properties.y.internal=!0,e.glyph.xs={expr:i.x},e.glyph.ys={expr:i.y},r.glyph.x={expr:n.x},r.glyph.y={expr:n.y}}remove(){this.edge_view.remove(),this.node_view.remove(),super.remove()}_render(){this.edge_view.render(),this.node_view.render()}renderer_view(e){if(e instanceof d.GlyphRenderer){if(e==this.edge_view.model)return this.edge_view;if(e==this.node_view.model)return this.node_view}return super.renderer_view(e)}}i.GraphRendererView=c,c.__name__=\"GraphRendererView\";class g extends s.DataRenderer{constructor(e){super(e)}get_selection_manager(){return this.node_renderer.data_source.selection_manager}}i.GraphRenderer=g,o=g,g.__name__=\"GraphRenderer\",o.prototype.default_view=c,o.define((({Ref:e})=>({layout_provider:[e(a.LayoutProvider)],node_renderer:[e(d.GlyphRenderer)],edge_renderer:[e(d.GlyphRenderer)],selection_policy:[e(p.GraphHitTestPolicy),()=>new p.NodesOnly],inspection_policy:[e(p.GraphHitTestPolicy),()=>new p.NodesOnly]})))},\n", " function _(e,t,n,o,c){o();(0,e(1).__exportStar)(e(74),n),c(\"Selection\",e(72).Selection)},\n", " function _(a,e,S,o,r){o(),r(\"ServerSentDataSource\",a(342).ServerSentDataSource),r(\"AjaxDataSource\",a(344).AjaxDataSource),r(\"ColumnDataSource\",a(75).ColumnDataSource),r(\"ColumnarDataSource\",a(70).ColumnarDataSource),r(\"CDSView\",a(190).CDSView),r(\"DataSource\",a(71).DataSource),r(\"GeoJSONDataSource\",a(345).GeoJSONDataSource),r(\"WebDataSource\",a(343).WebDataSource)},\n", " function _(e,t,i,a,s){a();const n=e(343);class r extends n.WebDataSource{constructor(e){super(e),this.initialized=!1}setup(){if(!this.initialized){this.initialized=!0;new EventSource(this.data_url).onmessage=e=>{var t;this.load_data(JSON.parse(e.data),this.mode,null!==(t=this.max_size)&&void 0!==t?t:void 0)}}}}i.ServerSentDataSource=r,r.__name__=\"ServerSentDataSource\"},\n", @@ -795,7 +814,7 @@ " function _(e,o,t,s,i){var n;s();const l=e(223),_=e(368),h=e(20),a=e(27),r=e(228);class m extends l.GestureToolView{_pinch(e){const{sx:o,sy:t,scale:s,ctrlKey:i,shiftKey:n}=e;let l;l=s>=1?20*(s-1):-20/s,this._scroll({type:\"wheel\",sx:o,sy:t,delta:l,ctrlKey:i,shiftKey:n})}_scroll(e){var o;const{frame:t}=this.plot_view,s=t.bbox.h_range,i=t.bbox.v_range,{sx:n,sy:l}=e,h=this.model.dimensions,a=(\"width\"==h||\"both\"==h)&&s.startthis.plot_view.trigger_ranges_update_event()))}}t.WheelZoomToolView=m,m.__name__=\"WheelZoomToolView\";class d extends l.GestureTool{constructor(e){super(e),this.tool_name=\"Wheel Zoom\",this.icon=r.tool_icon_wheel_zoom,this.event_type=a.is_mobile?\"pinch\":\"scroll\",this.default_order=10}get tooltip(){return this._get_dim_tooltip(this.dimensions)}}t.WheelZoomTool=d,n=d,d.__name__=\"WheelZoomTool\",n.prototype.default_view=m,n.define((({Boolean:e,Number:o})=>({dimensions:[h.Dimensions,\"both\"],maintain_focus:[e,!0],zoom_on_axis:[e,!0],speed:[o,1/600]}))),n.register_alias(\"wheel_zoom\",(()=>new d({dimensions:\"both\"}))),n.register_alias(\"xwheel_zoom\",(()=>new d({dimensions:\"width\"}))),n.register_alias(\"ywheel_zoom\",(()=>new d({dimensions:\"height\"})))},\n", " function _(i,e,s,t,o){var n;t();const l=i(232),a=i(219),h=i(20),r=i(13),_=i(228);class c extends l.InspectToolView{_move(i){if(!this.model.active)return;const{sx:e,sy:s}=i;this.plot_view.frame.bbox.contains(e,s)?this._update_spans(e,s):this._update_spans(null,null)}_move_exit(i){this._update_spans(null,null)}_update_spans(i,e){const s=this.model.dimensions;\"width\"!=s&&\"both\"!=s||(this.model.spans.width.location=e),\"height\"!=s&&\"both\"!=s||(this.model.spans.height.location=i)}}s.CrosshairToolView=c,c.__name__=\"CrosshairToolView\";class p extends l.InspectTool{constructor(i){super(i),this.tool_name=\"Crosshair\",this.icon=_.tool_icon_crosshair}get tooltip(){return this._get_dim_tooltip(this.dimensions)}get synthetic_renderers(){return(0,r.values)(this.spans)}}s.CrosshairTool=p,n=p,p.__name__=\"CrosshairTool\",(()=>{function i(i,e){return new a.Span({for_hover:!0,dimension:e,location_units:\"screen\",level:\"overlay\",line_color:i.line_color,line_width:i.line_width,line_alpha:i.line_alpha})}n.prototype.default_view=c,n.define((({Alpha:i,Number:e,Color:s})=>({dimensions:[h.Dimensions,\"both\"],line_color:[s,\"black\"],line_width:[e,1],line_alpha:[i,1]}))),n.internal((({Struct:e,Ref:s})=>({spans:[e({width:s(a.Span),height:s(a.Span)}),e=>({width:i(e,\"width\"),height:i(e,\"height\")})]}))),n.register_alias(\"crosshair\",(()=>new p))})()},\n", " function _(e,s,t,r,n){var o;r();const a=e(53),u=e(13),c=e(34);class i extends a.Model{constructor(e){super(e)}get values(){return(0,u.values)(this.args)}_make_code(e,s,t,r){return new Function(...(0,u.keys)(this.args),e,s,t,(0,c.use_strict)(r))}format(e,s,t){return this._make_code(\"value\",\"format\",\"special_vars\",this.code)(...this.values,e,s,t)}}t.CustomJSHover=i,o=i,i.__name__=\"CustomJSHover\",o.define((({Unknown:e,String:s,Dict:t})=>({args:[t(e),{}],code:[s,\"\"]})))},\n", - " function _(e,t,n,s,o){s();const i=e(1);var r;const l=e(232),a=e(390),c=e(241),_=e(175),d=e(339),p=e(176),h=e(177),u=e(283),m=(0,i.__importStar)(e(185)),y=e(152),f=e(43),v=e(22),x=e(13),w=e(234),g=e(8),b=e(113),k=e(20),C=e(228),S=e(15),T=e(66),$=(0,i.__importStar)(e(242)),R=e(392);function M(e,t,n,s,o,i){const r={x:o[e],y:i[e]},l={x:o[e+1],y:i[e+1]};let a,c;if(\"span\"==t.type)\"h\"==t.direction?(a=Math.abs(r.x-n),c=Math.abs(l.x-n)):(a=Math.abs(r.y-s),c=Math.abs(l.y-s));else{const e={x:n,y:s};a=m.dist_2_pts(r,e),c=m.dist_2_pts(l,e)}return adelete this._template_el)),this.on_change([e,t,n],(async()=>await this._update_ttmodels()))}async _update_ttmodels(){const{_ttmodels:e,computed_renderers:t}=this;e.clear();const{tooltips:n}=this.model;if(null!=n)for(const t of this.computed_renderers){const s=new c.Tooltip({custom:(0,g.isString)(n)||(0,g.isFunction)(n),attachment:this.model.attachment,show_arrow:this.model.show_arrow});t instanceof _.GlyphRenderer?e.set(t,s):t instanceof d.GraphRenderer&&(e.set(t.node_renderer,s),e.set(t.edge_renderer,s))}const s=await(0,b.build_views)(this._ttviews,[...e.values()],{parent:this.plot_view});for(const e of s)e.render();const o=[...function*(){for(const e of t)e instanceof _.GlyphRenderer?yield e:e instanceof d.GraphRenderer&&(yield e.node_renderer,yield e.edge_renderer)}()],i=this._slots.get(this._update);if(null!=i){const e=new Set(o.map((e=>e.data_source)));S.Signal.disconnect_receiver(this,i,e)}for(const e of o)this.connect(e.data_source.inspect,this._update)}get computed_renderers(){const{renderers:e,names:t}=this.model,n=this.plot_model.data_renderers;return(0,T.compute_renderers)(e,n,t)}get ttmodels(){return this._ttmodels}_clear(){this._inspect(1/0,1/0);for(const[,e]of this.ttmodels)e.clear()}_move(e){if(!this.model.active)return;const{sx:t,sy:n}=e;this.plot_view.frame.bbox.contains(t,n)?this._inspect(t,n):this._clear()}_move_exit(){this._clear()}_inspect(e,t){let n;if(\"mouse\"==this.model.mode)n={type:\"point\",sx:e,sy:t};else{n={type:\"span\",direction:\"vline\"==this.model.mode?\"h\":\"v\",sx:e,sy:t}}for(const e of this.computed_renderers){const t=e.get_selection_manager(),s=this.plot_view.renderer_view(e);null!=s&&t.inspect(s,n)}this._emit_callback(n)}_update([e,{geometry:t}]){var n,s;if(!this.model.active)return;if(\"point\"!=t.type&&\"span\"!=t.type)return;if(!(e instanceof _.GlyphRenderer))return;if(\"ignore\"==this.model.muted_policy&&e.muted)return;const o=this.ttmodels.get(e);if(null==o)return;const i=e.get_selection_manager(),r=i.inspectors.get(e),l=e.view.convert_selection_to_subset(r);if(r.is_empty())return void o.clear();const a=i.source,c=this.plot_view.renderer_view(e);if(null==c)return;const{sx:d,sy:p}=t,m=c.coordinates.x_scale,y=c.coordinates.y_scale,v=m.invert(d),w=y.invert(p),{glyph:g}=c,b=[];if(g instanceof h.LineView)for(const n of l.line_indices){let s,o,i=g._x[n+1],r=g._y[n+1],c=n;switch(this.model.line_policy){case\"interp\":[i,r]=g.get_interpolation_hit(n,t),s=m.compute(i),o=y.compute(r);break;case\"prev\":[[s,o],c]=G(g.sx,g.sy,n);break;case\"next\":[[s,o],c]=G(g.sx,g.sy,n+1);break;case\"nearest\":[[s,o],c]=M(n,t,d,p,g.sx,g.sy),i=g._x[c],r=g._y[c];break;default:[s,o]=[d,p]}const _={index:c,x:v,y:w,sx:d,sy:p,data_x:i,data_y:r,rx:s,ry:o,indices:l.line_indices,name:e.name};b.push([s,o,this._render_tooltips(a,c,_)])}for(const t of r.image_indices){const n={index:t.index,x:v,y:w,sx:d,sy:p,name:e.name},s=this._render_tooltips(a,t,n);b.push([d,p,s])}for(const o of l.indices)if(g instanceof u.MultiLineView&&!(0,x.isEmpty)(l.multiline_indices))for(const n of l.multiline_indices[o.toString()]){let s,i,r,c=g._xs.get(o)[n],h=g._ys.get(o)[n],u=n;switch(this.model.line_policy){case\"interp\":[c,h]=g.get_interpolation_hit(o,n,t),s=m.compute(c),i=y.compute(h);break;case\"prev\":[[s,i],u]=G(g.sxs.get(o),g.sys.get(o),n);break;case\"next\":[[s,i],u]=G(g.sxs.get(o),g.sys.get(o),n+1);break;case\"nearest\":[[s,i],u]=M(n,t,d,p,g.sxs.get(o),g.sys.get(o)),c=g._xs.get(o)[u],h=g._ys.get(o)[u];break;default:throw new Error(\"shouldn't have happened\")}r=e instanceof _.GlyphRenderer?e.view.convert_indices_from_subset([o])[0]:o;const f={index:r,x:v,y:w,sx:d,sy:p,data_x:c,data_y:h,segment_index:u,indices:l.multiline_indices,name:e.name};b.push([s,i,this._render_tooltips(a,r,f)])}else{const t=null===(n=g._x)||void 0===n?void 0:n[o],i=null===(s=g._y)||void 0===s?void 0:s[o];let r,c,h;if(\"snap_to_data\"==this.model.point_policy){let e=g.get_anchor_point(this.model.anchor,o,[d,p]);if(null==e&&(e=g.get_anchor_point(\"center\",o,[d,p]),null==e))continue;r=e.x,c=e.y}else[r,c]=[d,p];h=e instanceof _.GlyphRenderer?e.view.convert_indices_from_subset([o])[0]:o;const u={index:h,x:v,y:w,sx:d,sy:p,data_x:t,data_y:i,indices:l.indices,name:e.name};b.push([r,c,this._render_tooltips(a,h,u)])}if(0==b.length)o.clear();else{const{content:e}=o;(0,f.empty)(o.content);for(const[,,t]of b)null!=t&&e.appendChild(t);const[t,n]=b[b.length-1];o.setv({position:[t,n]},{check_eq:!1})}}_emit_callback(e){const{callback:t}=this.model;if(null!=t)for(const n of this.computed_renderers){if(!(n instanceof _.GlyphRenderer))continue;const s=this.plot_view.renderer_view(n);if(null==s)continue;const{x_scale:o,y_scale:i}=s.coordinates,r=o.invert(e.sx),l=i.invert(e.sy),a=n.data_source.inspected;t.execute(this.model,{geometry:Object.assign({x:r,y:l},e),renderer:n,index:a})}}_create_template(e){const t=(0,f.div)({style:{display:\"table\",borderSpacing:\"2px\"}});for(const[n]of e){const e=(0,f.div)({style:{display:\"table-row\"}});t.appendChild(e);const s=(0,f.div)({style:{display:\"table-cell\"},class:$.tooltip_row_label},0!=n.length?`${n}: `:\"\");e.appendChild(s);const o=(0,f.span)();o.dataset.value=\"\";const i=(0,f.span)({class:$.tooltip_color_block},\" \");i.dataset.swatch=\"\",(0,f.undisplay)(i);const r=(0,f.div)({style:{display:\"table-cell\"},class:$.tooltip_row_value},o,i);e.appendChild(r)}return t}_render_template(e,t,n,s,o){const i=e.cloneNode(!0),r=i.querySelectorAll(\"[data-value]\"),l=i.querySelectorAll(\"[data-swatch]\"),a=/\\$color(\\[.*\\])?:(\\w*)/,c=/\\$swatch:(\\w*)/;for(const[[,e],i]of(0,w.enumerate)(t)){const t=e.match(c),_=e.match(a);if(null!=t||null!=_){if(null!=t){const[,e]=t,o=n.get_column(e);if(null==o)r[i].textContent=`${e} unknown`;else{const e=(0,g.isNumber)(s)?o[s]:null;null!=e&&(l[i].style.backgroundColor=(0,v.color2css)(e),(0,f.display)(l[i]))}}if(null!=_){const[,e=\"\",t]=_,o=n.get_column(t);if(null==o){r[i].textContent=`${t} unknown`;continue}const a=e.indexOf(\"hex\")>=0,c=e.indexOf(\"swatch\")>=0,d=(0,g.isNumber)(s)?o[s]:null;if(null==d){r[i].textContent=\"(null)\";continue}r[i].textContent=a?(0,v.color2hex)(d):(0,v.color2css)(d),c&&(l[i].style.backgroundColor=(0,v.color2css)(d),(0,f.display)(l[i]))}}else{const t=(0,y.replace_placeholders)(e.replace(\"$~\",\"$data_\"),n,s,this.model.formatters,o);if((0,g.isString)(t))r[i].textContent=t;else for(const e of t)r[i].appendChild(e)}}return i}_render_tooltips(e,t,n){var s;const{tooltips:o}=this.model;if((0,g.isString)(o)){const s=(0,y.replace_placeholders)({html:o},e,t,this.model.formatters,n);return(0,f.div)(s)}if((0,g.isFunction)(o))return o(e,n);if(o instanceof R.Template)return this._template_view.update(e,t,n),this._template_view.el;if(null!=o){const i=null!==(s=this._template_el)&&void 0!==s?s:this._template_el=this._create_template(o);return this._render_template(i,o,e,t,n)}return null}}n.HoverToolView=z,z.__name__=\"HoverToolView\";class A extends l.InspectTool{constructor(e){super(e),this.tool_name=\"Hover\",this.icon=C.tool_icon_hover}}n.HoverTool=A,r=A,A.__name__=\"HoverTool\",r.prototype.default_view=z,r.define((({Any:e,Boolean:t,String:n,Array:s,Tuple:o,Dict:i,Or:r,Ref:l,Function:c,Auto:_,Nullable:d})=>({tooltips:[d(r(l(R.Template),n,s(o(n,n)),c())),[[\"index\",\"$index\"],[\"data (x, y)\",\"($x, $y)\"],[\"screen (x, y)\",\"($sx, $sy)\"]]],formatters:[i(r(l(a.CustomJSHover),y.FormatterType)),{}],renderers:[r(s(l(p.DataRenderer)),_),\"auto\"],names:[s(n),[]],mode:[k.HoverMode,\"mouse\"],muted_policy:[k.MutedPolicy,\"show\"],point_policy:[k.PointPolicy,\"snap_to_data\"],line_policy:[k.LinePolicy,\"nearest\"],show_arrow:[t,!0],anchor:[k.Anchor,\"center\"],attachment:[k.TooltipAttachment,\"horizontal\"],callback:[d(e)]}))),r.register_alias(\"hover\",(()=>new A))},\n", + " function _(e,t,n,s,i){s();const o=e(1);var r;const l=e(232),a=e(390),c=e(241),_=e(175),d=e(339),p=e(176),h=e(177),u=e(283),m=e(186),y=e(187),f=e(189),x=(0,o.__importStar)(e(185)),v=e(152),w=e(43),g=e(22),b=e(13),k=e(234),C=e(8),S=e(113),T=e(20),$=e(228),R=e(15),A=e(66),M=(0,o.__importStar)(e(242)),V=e(392);function G(e,t,n,s,i,o){const r={x:i[e],y:o[e]},l={x:i[e+1],y:o[e+1]};let a,c;if(\"span\"==t.type)\"h\"==t.direction?(a=Math.abs(r.x-n),c=Math.abs(l.x-n)):(a=Math.abs(r.y-s),c=Math.abs(l.y-s));else{const e={x:n,y:s};a=x.dist_2_pts(r,e),c=x.dist_2_pts(l,e)}return adelete this._template_el)),this.on_change([e,t,n],(async()=>await this._update_ttmodels()))}async _update_ttmodels(){const{_ttmodels:e,computed_renderers:t}=this;e.clear();const{tooltips:n}=this.model;if(null!=n)for(const t of this.computed_renderers){const s=new c.Tooltip({custom:(0,C.isString)(n)||(0,C.isFunction)(n),attachment:this.model.attachment,show_arrow:this.model.show_arrow});t instanceof _.GlyphRenderer?e.set(t,s):t instanceof d.GraphRenderer&&(e.set(t.node_renderer,s),e.set(t.edge_renderer,s))}const s=await(0,S.build_views)(this._ttviews,[...e.values()],{parent:this.plot_view});for(const e of s)e.render();const i=[...function*(){for(const e of t)e instanceof _.GlyphRenderer?yield e:e instanceof d.GraphRenderer&&(yield e.node_renderer,yield e.edge_renderer)}()],o=this._slots.get(this._update);if(null!=o){const e=new Set(i.map((e=>e.data_source)));R.Signal.disconnect_receiver(this,o,e)}for(const e of i)this.connect(e.data_source.inspect,this._update)}get computed_renderers(){const{renderers:e,names:t}=this.model,n=this.plot_model.data_renderers;return(0,A.compute_renderers)(e,n,t)}get ttmodels(){return this._ttmodels}_clear(){this._inspect(1/0,1/0);for(const[,e]of this.ttmodels)e.clear()}_move(e){if(!this.model.active)return;const{sx:t,sy:n}=e;this.plot_view.frame.bbox.contains(t,n)?this._inspect(t,n):this._clear()}_move_exit(){this._clear()}_inspect(e,t){let n;if(\"mouse\"==this.model.mode)n={type:\"point\",sx:e,sy:t};else{n={type:\"span\",direction:\"vline\"==this.model.mode?\"h\":\"v\",sx:e,sy:t}}for(const e of this.computed_renderers){const t=e.get_selection_manager(),s=this.plot_view.renderer_view(e);null!=s&&t.inspect(s,n)}this._emit_callback(n)}_update([e,{geometry:t}]){var n,s;if(!this.model.active)return;if(\"point\"!=t.type&&\"span\"!=t.type)return;if(!(e instanceof _.GlyphRenderer))return;if(\"ignore\"==this.model.muted_policy&&e.muted)return;const i=this.ttmodels.get(e);if(null==i)return;const o=e.get_selection_manager(),r=o.inspectors.get(e),l=e.view.convert_selection_to_subset(r);if(r.is_empty()&&null==r.view)return void i.clear();const a=o.source,c=this.plot_view.renderer_view(e);if(null==c)return;const{sx:d,sy:p}=t,x=c.coordinates.x_scale,v=c.coordinates.y_scale,g=x.invert(d),k=v.invert(p),{glyph:C}=c,S=[];if(C instanceof m.PatchView){const[t,n]=[d,p],s={x:g,y:k,sx:d,sy:p,rx:t,ry:n,name:e.name};S.push([t,n,this._render_tooltips(a,-1,s)])}if(C instanceof y.HAreaView)for(const t of l.line_indices){const n=C._x1,s=C._x2,i=C._y,[o,r]=[d,p],c={index:t,x:g,y:k,sx:d,sy:p,data_x1:n,data_x2:s,data_y:i,rx:o,ry:r,indices:l.line_indices,name:e.name};S.push([o,r,this._render_tooltips(a,t,c)])}if(C instanceof f.VAreaView)for(const t of l.line_indices){const n=C._x,s=C._y1,i=C._y2,[o,r]=[d,p],c={index:t,x:g,y:k,sx:d,sy:p,data_x:n,data_y1:s,data_y2:i,rx:o,ry:r,indices:l.line_indices,name:e.name};S.push([o,r,this._render_tooltips(a,t,c)])}if(C instanceof h.LineView)for(const n of l.line_indices){let s,i,o=C._x[n+1],r=C._y[n+1],c=n;switch(this.model.line_policy){case\"interp\":[o,r]=C.get_interpolation_hit(n,t),s=x.compute(o),i=v.compute(r);break;case\"prev\":[[s,i],c]=H(C.sx,C.sy,n);break;case\"next\":[[s,i],c]=H(C.sx,C.sy,n+1);break;case\"nearest\":[[s,i],c]=G(n,t,d,p,C.sx,C.sy),o=C._x[c],r=C._y[c];break;default:[s,i]=[d,p]}const _={index:c,x:g,y:k,sx:d,sy:p,data_x:o,data_y:r,rx:s,ry:i,indices:l.line_indices,name:e.name};S.push([s,i,this._render_tooltips(a,c,_)])}for(const t of r.image_indices){const n={index:t.index,x:g,y:k,sx:d,sy:p,name:e.name},s=this._render_tooltips(a,t,n);S.push([d,p,s])}for(const i of l.indices)if(C instanceof u.MultiLineView&&!(0,b.isEmpty)(l.multiline_indices))for(const n of l.multiline_indices[i.toString()]){let s,o,r,c=C._xs.get(i)[n],h=C._ys.get(i)[n],u=n;switch(this.model.line_policy){case\"interp\":[c,h]=C.get_interpolation_hit(i,n,t),s=x.compute(c),o=v.compute(h);break;case\"prev\":[[s,o],u]=H(C.sxs.get(i),C.sys.get(i),n);break;case\"next\":[[s,o],u]=H(C.sxs.get(i),C.sys.get(i),n+1);break;case\"nearest\":[[s,o],u]=G(n,t,d,p,C.sxs.get(i),C.sys.get(i)),c=C._xs.get(i)[u],h=C._ys.get(i)[u];break;default:throw new Error(\"shouldn't have happened\")}r=e instanceof _.GlyphRenderer?e.view.convert_indices_from_subset([i])[0]:i;const m={index:r,x:g,y:k,sx:d,sy:p,data_x:c,data_y:h,segment_index:u,indices:l.multiline_indices,name:e.name};S.push([s,o,this._render_tooltips(a,r,m)])}else{const t=null===(n=C._x)||void 0===n?void 0:n[i],o=null===(s=C._y)||void 0===s?void 0:s[i];let r,c,h;if(\"snap_to_data\"==this.model.point_policy){let e=C.get_anchor_point(this.model.anchor,i,[d,p]);if(null==e&&(e=C.get_anchor_point(\"center\",i,[d,p]),null==e))continue;r=e.x,c=e.y}else[r,c]=[d,p];h=e instanceof _.GlyphRenderer?e.view.convert_indices_from_subset([i])[0]:i;const u={index:h,x:g,y:k,sx:d,sy:p,data_x:t,data_y:o,indices:l.indices,name:e.name};S.push([r,c,this._render_tooltips(a,h,u)])}if(0==S.length)i.clear();else{const{content:e}=i;(0,w.empty)(i.content);for(const[,,t]of S)null!=t&&e.appendChild(t);const[t,n]=S[S.length-1];i.setv({position:[t,n]},{check_eq:!1})}}_emit_callback(e){const{callback:t}=this.model;if(null!=t)for(const n of this.computed_renderers){if(!(n instanceof _.GlyphRenderer))continue;const s=this.plot_view.renderer_view(n);if(null==s)continue;const{x_scale:i,y_scale:o}=s.coordinates,r=i.invert(e.sx),l=o.invert(e.sy),a=n.data_source.inspected;t.execute(this.model,{geometry:Object.assign({x:r,y:l},e),renderer:n,index:a})}}_create_template(e){const t=(0,w.div)({style:{display:\"table\",borderSpacing:\"2px\"}});for(const[n]of e){const e=(0,w.div)({style:{display:\"table-row\"}});t.appendChild(e);const s=(0,w.div)({style:{display:\"table-cell\"},class:M.tooltip_row_label},0!=n.length?`${n}: `:\"\");e.appendChild(s);const i=(0,w.span)();i.dataset.value=\"\";const o=(0,w.span)({class:M.tooltip_color_block},\" \");o.dataset.swatch=\"\",(0,w.undisplay)(o);const r=(0,w.div)({style:{display:\"table-cell\"},class:M.tooltip_row_value},i,o);e.appendChild(r)}return t}_render_template(e,t,n,s,i){const o=e.cloneNode(!0),r=o.querySelectorAll(\"[data-value]\"),l=o.querySelectorAll(\"[data-swatch]\"),a=/\\$color(\\[.*\\])?:(\\w*)/,c=/\\$swatch:(\\w*)/;for(const[[,e],o]of(0,k.enumerate)(t)){const t=e.match(c),_=e.match(a);if(null!=t||null!=_){if(null!=t){const[,e]=t,i=n.get_column(e);if(null==i)r[o].textContent=`${e} unknown`;else{const e=(0,C.isNumber)(s)?i[s]:null;null!=e&&(l[o].style.backgroundColor=(0,g.color2css)(e),(0,w.display)(l[o]))}}if(null!=_){const[,e=\"\",t]=_,i=n.get_column(t);if(null==i){r[o].textContent=`${t} unknown`;continue}const a=e.indexOf(\"hex\")>=0,c=e.indexOf(\"swatch\")>=0,d=(0,C.isNumber)(s)?i[s]:null;if(null==d){r[o].textContent=\"(null)\";continue}r[o].textContent=a?(0,g.color2hex)(d):(0,g.color2css)(d),c&&(l[o].style.backgroundColor=(0,g.color2css)(d),(0,w.display)(l[o]))}}else{const t=(0,v.replace_placeholders)(e.replace(\"$~\",\"$data_\"),n,s,this.model.formatters,i);if((0,C.isString)(t))r[o].textContent=t;else for(const e of t)r[o].appendChild(e)}}return o}_render_tooltips(e,t,n){var s;const{tooltips:i}=this.model;if((0,C.isString)(i)){const s=(0,v.replace_placeholders)({html:i},e,t,this.model.formatters,n);return(0,w.div)(s)}if((0,C.isFunction)(i))return i(e,n);if(i instanceof V.Template)return this._template_view.update(e,t,n),this._template_view.el;if(null!=i){const o=null!==(s=this._template_el)&&void 0!==s?s:this._template_el=this._create_template(i);return this._render_template(o,i,e,t,n)}return null}}n.HoverToolView=z,z.__name__=\"HoverToolView\";class P extends l.InspectTool{constructor(e){super(e),this.tool_name=\"Hover\",this.icon=$.tool_icon_hover}}n.HoverTool=P,r=P,P.__name__=\"HoverTool\",r.prototype.default_view=z,r.define((({Any:e,Boolean:t,String:n,Array:s,Tuple:i,Dict:o,Or:r,Ref:l,Function:c,Auto:_,Nullable:d})=>({tooltips:[d(r(l(V.Template),n,s(i(n,n)),c())),[[\"index\",\"$index\"],[\"data (x, y)\",\"($x, $y)\"],[\"screen (x, y)\",\"($sx, $sy)\"]]],formatters:[o(r(l(a.CustomJSHover),v.FormatterType)),{}],renderers:[r(s(l(p.DataRenderer)),_),\"auto\"],names:[s(n),[]],mode:[T.HoverMode,\"mouse\"],muted_policy:[T.MutedPolicy,\"show\"],point_policy:[T.PointPolicy,\"snap_to_data\"],line_policy:[T.LinePolicy,\"nearest\"],show_arrow:[t,!0],anchor:[T.Anchor,\"center\"],attachment:[T.TooltipAttachment,\"horizontal\"],callback:[d(e)]}))),r.register_alias(\"hover\",(()=>new P))},\n", " function _(e,t,s,n,a){n();const l=e(1);var i,_,o,r,c,d,p,u,m,w,f,h,x;const v=e(53),y=e(309),V=e(393);a(\"Styles\",V.Styles);const g=e(43),T=e(42),b=e(226),R=e(113),D=e(8),M=e(13),S=(0,l.__importStar)(e(242)),O=e(152);class C extends b.DOMView{}s.DOMNodeView=C,C.__name__=\"DOMNodeView\";class z extends v.Model{constructor(e){super(e)}}s.DOMNode=z,z.__name__=\"DOMNode\",z.__module__=\"bokeh.models.dom\";class P extends C{render(){super.render(),this.el.textContent=this.model.content}_createElement(){return document.createTextNode(\"\")}}s.TextView=P,P.__name__=\"TextView\";class A extends z{constructor(e){super(e)}}s.Text=A,i=A,A.__name__=\"Text\",i.prototype.default_view=P,i.define((({String:e})=>({content:[e,\"\"]})));class N extends C{}s.PlaceholderView=N,N.__name__=\"PlaceholderView\",N.tag_name=\"span\";class E extends z{constructor(e){super(e)}}s.Placeholder=E,_=E,E.__name__=\"Placeholder\",_.define((({})=>({})));class G extends N{update(e,t,s){this.el.textContent=t.toString()}}s.IndexView=G,G.__name__=\"IndexView\";class I extends E{constructor(e){super(e)}}s.Index=I,o=I,I.__name__=\"Index\",o.prototype.default_view=G,o.define((({})=>({})));class k extends N{update(e,t,s){const n=(0,O._get_column_value)(this.model.field,e,t),a=null==n?\"???\":`${n}`;this.el.textContent=a}}s.ValueRefView=k,k.__name__=\"ValueRefView\";class $ extends E{constructor(e){super(e)}}s.ValueRef=$,r=$,$.__name__=\"ValueRef\",r.prototype.default_view=k,r.define((({String:e})=>({field:[e]})));class B extends k{render(){super.render(),this.value_el=(0,g.span)(),this.swatch_el=(0,g.span)({class:S.tooltip_color_block},\" \"),this.el.appendChild(this.value_el),this.el.appendChild(this.swatch_el)}update(e,t,s){const n=(0,O._get_column_value)(this.model.field,e,t),a=null==n?\"???\":`${n}`;this.el.textContent=a}}s.ColorRefView=B,B.__name__=\"ColorRefView\";class L extends ${constructor(e){super(e)}}s.ColorRef=L,c=L,L.__name__=\"ColorRef\",c.prototype.default_view=B,c.define((({Boolean:e})=>({hex:[e,!0],swatch:[e,!0]})));class j extends C{constructor(){super(...arguments),this.child_views=new Map}async lazy_initialize(){await super.lazy_initialize();const e=this.model.children.filter((e=>e instanceof v.Model));await(0,R.build_views)(this.child_views,e,{parent:this})}render(){super.render();const{style:e}=this.model;if(null!=e)if(e instanceof V.Styles)for(const t of e){const e=t.get_value();if((0,D.isString)(e)){const s=t.attr.replace(/_/g,\"-\");this.el.style.hasOwnProperty(s)&&this.el.style.setProperty(s,e)}}else for(const[t,s]of(0,M.entries)(e)){const e=t.replace(/_/g,\"-\");this.el.style.hasOwnProperty(e)&&this.el.style.setProperty(e,s)}for(const e of this.model.children)if((0,D.isString)(e)){const t=document.createTextNode(e);this.el.appendChild(t)}else{this.child_views.get(e).renderTo(this.el)}}}s.DOMElementView=j,j.__name__=\"DOMElementView\";class q extends z{constructor(e){super(e)}}s.DOMElement=q,d=q,q.__name__=\"DOMElement\",d.define((({String:e,Array:t,Dict:s,Or:n,Nullable:a,Ref:l})=>({style:[a(n(l(V.Styles),s(e))),null],children:[t(n(e,l(z),l(y.LayoutDOM))),[]]})));class F extends T.View{}s.ActionView=F,F.__name__=\"ActionView\";class H extends v.Model{constructor(e){super(e)}}s.Action=H,p=H,H.__name__=\"Action\",H.__module__=\"bokeh.models.dom\",p.define((({})=>({})));class J extends j{constructor(){super(...arguments),this.action_views=new Map}async lazy_initialize(){await super.lazy_initialize(),await(0,R.build_views)(this.action_views,this.model.actions,{parent:this})}remove(){(0,R.remove_views)(this.action_views),super.remove()}update(e,t,s={}){!function n(a){for(const l of a.child_views.values())l instanceof N?l.update(e,t,s):l instanceof j&&n(l)}(this);for(const n of this.action_views.values())n.update(e,t,s)}}s.TemplateView=J,J.__name__=\"TemplateView\",J.tag_name=\"div\";class K extends q{}s.Template=K,u=K,K.__name__=\"Template\",u.prototype.default_view=J,u.define((({Array:e,Ref:t})=>({actions:[e(t(H)),[]]})));class Q extends j{}s.SpanView=Q,Q.__name__=\"SpanView\",Q.tag_name=\"span\";class U extends q{}s.Span=U,m=U,U.__name__=\"Span\",m.prototype.default_view=Q;class W extends j{}s.DivView=W,W.__name__=\"DivView\",W.tag_name=\"div\";class X extends q{}s.Div=X,w=X,X.__name__=\"Div\",w.prototype.default_view=W;class Y extends j{}s.TableView=Y,Y.__name__=\"TableView\",Y.tag_name=\"table\";class Z extends q{}s.Table=Z,f=Z,Z.__name__=\"Table\",f.prototype.default_view=Y;class ee extends j{}s.TableRowView=ee,ee.__name__=\"TableRowView\",ee.tag_name=\"tr\";class te extends q{}s.TableRow=te,h=te,te.__name__=\"TableRow\",h.prototype.default_view=ee;const se=e(41),ne=e(234);class ae extends F{update(e,t,s){for(const[e,s]of(0,ne.enumerate)(this.model.groups))e.visible=t==s}}s.ToggleGroupView=ae,ae.__name__=\"ToggleGroupView\";class le extends H{constructor(e){super(e)}}s.ToggleGroup=le,x=le,le.__name__=\"ToggleGroup\",x.prototype.default_view=ae,x.define((({Array:e,Ref:t})=>({groups:[e(t(se.RendererGroup)),[]]})))},\n", " function _(l,n,u,_,e){var t;_();const o=l(53);class r extends o.Model{constructor(l){super(l)}}u.Styles=r,t=r,r.__name__=\"Styles\",r.__module__=\"bokeh.models.css\",t.define((({String:l,Nullable:n})=>({align_content:[n(l),null],align_items:[n(l),null],align_self:[n(l),null],alignment_baseline:[n(l),null],all:[n(l),null],animation:[n(l),null],animation_delay:[n(l),null],animation_direction:[n(l),null],animation_duration:[n(l),null],animation_fill_mode:[n(l),null],animation_iteration_count:[n(l),null],animation_name:[n(l),null],animation_play_state:[n(l),null],animation_timing_function:[n(l),null],backface_visibility:[n(l),null],background:[n(l),null],background_attachment:[n(l),null],background_clip:[n(l),null],background_color:[n(l),null],background_image:[n(l),null],background_origin:[n(l),null],background_position:[n(l),null],background_position_x:[n(l),null],background_position_y:[n(l),null],background_repeat:[n(l),null],background_size:[n(l),null],baseline_shift:[n(l),null],block_size:[n(l),null],border:[n(l),null],border_block_end:[n(l),null],border_block_end_color:[n(l),null],border_block_end_style:[n(l),null],border_block_end_width:[n(l),null],border_block_start:[n(l),null],border_block_start_color:[n(l),null],border_block_start_style:[n(l),null],border_block_start_width:[n(l),null],border_bottom:[n(l),null],border_bottom_color:[n(l),null],border_bottom_left_radius:[n(l),null],border_bottom_right_radius:[n(l),null],border_bottom_style:[n(l),null],border_bottom_width:[n(l),null],border_collapse:[n(l),null],border_color:[n(l),null],border_image:[n(l),null],border_image_outset:[n(l),null],border_image_repeat:[n(l),null],border_image_slice:[n(l),null],border_image_source:[n(l),null],border_image_width:[n(l),null],border_inline_end:[n(l),null],border_inline_end_color:[n(l),null],border_inline_end_style:[n(l),null],border_inline_end_width:[n(l),null],border_inline_start:[n(l),null],border_inline_start_color:[n(l),null],border_inline_start_style:[n(l),null],border_inline_start_width:[n(l),null],border_left:[n(l),null],border_left_color:[n(l),null],border_left_style:[n(l),null],border_left_width:[n(l),null],border_radius:[n(l),null],border_right:[n(l),null],border_right_color:[n(l),null],border_right_style:[n(l),null],border_right_width:[n(l),null],border_spacing:[n(l),null],border_style:[n(l),null],border_top:[n(l),null],border_top_color:[n(l),null],border_top_left_radius:[n(l),null],border_top_right_radius:[n(l),null],border_top_style:[n(l),null],border_top_width:[n(l),null],border_width:[n(l),null],bottom:[n(l),null],box_shadow:[n(l),null],box_sizing:[n(l),null],break_after:[n(l),null],break_before:[n(l),null],break_inside:[n(l),null],caption_side:[n(l),null],caret_color:[n(l),null],clear:[n(l),null],clip:[n(l),null],clip_path:[n(l),null],clip_rule:[n(l),null],color:[n(l),null],color_interpolation:[n(l),null],color_interpolation_filters:[n(l),null],column_count:[n(l),null],column_fill:[n(l),null],column_gap:[n(l),null],column_rule:[n(l),null],column_rule_color:[n(l),null],column_rule_style:[n(l),null],column_rule_width:[n(l),null],column_span:[n(l),null],column_width:[n(l),null],columns:[n(l),null],content:[n(l),null],counter_increment:[n(l),null],counter_reset:[n(l),null],css_float:[n(l),null],css_text:[n(l),null],cursor:[n(l),null],direction:[n(l),null],display:[n(l),null],dominant_baseline:[n(l),null],empty_cells:[n(l),null],fill:[n(l),null],fill_opacity:[n(l),null],fill_rule:[n(l),null],filter:[n(l),null],flex:[n(l),null],flex_basis:[n(l),null],flex_direction:[n(l),null],flex_flow:[n(l),null],flex_grow:[n(l),null],flex_shrink:[n(l),null],flex_wrap:[n(l),null],float:[n(l),null],flood_color:[n(l),null],flood_opacity:[n(l),null],font:[n(l),null],font_family:[n(l),null],font_feature_settings:[n(l),null],font_kerning:[n(l),null],font_size:[n(l),null],font_size_adjust:[n(l),null],font_stretch:[n(l),null],font_style:[n(l),null],font_synthesis:[n(l),null],font_variant:[n(l),null],font_variant_caps:[n(l),null],font_variant_east_asian:[n(l),null],font_variant_ligatures:[n(l),null],font_variant_numeric:[n(l),null],font_variant_position:[n(l),null],font_weight:[n(l),null],gap:[n(l),null],glyph_orientation_vertical:[n(l),null],grid:[n(l),null],grid_area:[n(l),null],grid_auto_columns:[n(l),null],grid_auto_flow:[n(l),null],grid_auto_rows:[n(l),null],grid_column:[n(l),null],grid_column_end:[n(l),null],grid_column_gap:[n(l),null],grid_column_start:[n(l),null],grid_gap:[n(l),null],grid_row:[n(l),null],grid_row_end:[n(l),null],grid_row_gap:[n(l),null],grid_row_start:[n(l),null],grid_template:[n(l),null],grid_template_areas:[n(l),null],grid_template_columns:[n(l),null],grid_template_rows:[n(l),null],height:[n(l),null],hyphens:[n(l),null],image_orientation:[n(l),null],image_rendering:[n(l),null],inline_size:[n(l),null],justify_content:[n(l),null],justify_items:[n(l),null],justify_self:[n(l),null],left:[n(l),null],letter_spacing:[n(l),null],lighting_color:[n(l),null],line_break:[n(l),null],line_height:[n(l),null],list_style:[n(l),null],list_style_image:[n(l),null],list_style_position:[n(l),null],list_style_type:[n(l),null],margin:[n(l),null],margin_block_end:[n(l),null],margin_block_start:[n(l),null],margin_bottom:[n(l),null],margin_inline_end:[n(l),null],margin_inline_start:[n(l),null],margin_left:[n(l),null],margin_right:[n(l),null],margin_top:[n(l),null],marker:[n(l),null],marker_end:[n(l),null],marker_mid:[n(l),null],marker_start:[n(l),null],mask:[n(l),null],mask_composite:[n(l),null],mask_image:[n(l),null],mask_position:[n(l),null],mask_repeat:[n(l),null],mask_size:[n(l),null],mask_type:[n(l),null],max_block_size:[n(l),null],max_height:[n(l),null],max_inline_size:[n(l),null],max_width:[n(l),null],min_block_size:[n(l),null],min_height:[n(l),null],min_inline_size:[n(l),null],min_width:[n(l),null],object_fit:[n(l),null],object_position:[n(l),null],opacity:[n(l),null],order:[n(l),null],orphans:[n(l),null],outline:[n(l),null],outline_color:[n(l),null],outline_offset:[n(l),null],outline_style:[n(l),null],outline_width:[n(l),null],overflow:[n(l),null],overflow_anchor:[n(l),null],overflow_wrap:[n(l),null],overflow_x:[n(l),null],overflow_y:[n(l),null],overscroll_behavior:[n(l),null],overscroll_behavior_block:[n(l),null],overscroll_behavior_inline:[n(l),null],overscroll_behavior_x:[n(l),null],overscroll_behavior_y:[n(l),null],padding:[n(l),null],padding_block_end:[n(l),null],padding_block_start:[n(l),null],padding_bottom:[n(l),null],padding_inline_end:[n(l),null],padding_inline_start:[n(l),null],padding_left:[n(l),null],padding_right:[n(l),null],padding_top:[n(l),null],page_break_after:[n(l),null],page_break_before:[n(l),null],page_break_inside:[n(l),null],paint_order:[n(l),null],perspective:[n(l),null],perspective_origin:[n(l),null],place_content:[n(l),null],place_items:[n(l),null],place_self:[n(l),null],pointer_events:[n(l),null],position:[n(l),null],quotes:[n(l),null],resize:[n(l),null],right:[n(l),null],rotate:[n(l),null],row_gap:[n(l),null],ruby_align:[n(l),null],ruby_position:[n(l),null],scale:[n(l),null],scroll_behavior:[n(l),null],shape_rendering:[n(l),null],stop_color:[n(l),null],stop_opacity:[n(l),null],stroke:[n(l),null],stroke_dasharray:[n(l),null],stroke_dashoffset:[n(l),null],stroke_linecap:[n(l),null],stroke_linejoin:[n(l),null],stroke_miterlimit:[n(l),null],stroke_opacity:[n(l),null],stroke_width:[n(l),null],tab_size:[n(l),null],table_layout:[n(l),null],text_align:[n(l),null],text_align_last:[n(l),null],text_anchor:[n(l),null],text_combine_upright:[n(l),null],text_decoration:[n(l),null],text_decoration_color:[n(l),null],text_decoration_line:[n(l),null],text_decoration_style:[n(l),null],text_emphasis:[n(l),null],text_emphasis_color:[n(l),null],text_emphasis_position:[n(l),null],text_emphasis_style:[n(l),null],text_indent:[n(l),null],text_justify:[n(l),null],text_orientation:[n(l),null],text_overflow:[n(l),null],text_rendering:[n(l),null],text_shadow:[n(l),null],text_transform:[n(l),null],text_underline_position:[n(l),null],top:[n(l),null],touch_action:[n(l),null],transform:[n(l),null],transform_box:[n(l),null],transform_origin:[n(l),null],transform_style:[n(l),null],transition:[n(l),null],transition_delay:[n(l),null],transition_duration:[n(l),null],transition_property:[n(l),null],transition_timing_function:[n(l),null],translate:[n(l),null],unicode_bidi:[n(l),null],user_select:[n(l),null],vertical_align:[n(l),null],visibility:[n(l),null],white_space:[n(l),null],widows:[n(l),null],width:[n(l),null],will_change:[n(l),null],word_break:[n(l),null],word_spacing:[n(l),null],word_wrap:[n(l),null],writing_mode:[n(l),null],z_index:[n(l),null]})))},\n", " function _(t,o,e,n,s){var i;n();const l=t(15),c=t(53),r=t(224),a=t(232),u=t(234);class h extends c.Model{constructor(t){super(t)}get button_view(){return this.tools[0].button_view}get event_type(){return this.tools[0].event_type}get tooltip(){return this.tools[0].tooltip}get tool_name(){return this.tools[0].tool_name}get icon(){return this.tools[0].computed_icon}get computed_icon(){return this.icon}get toggleable(){const t=this.tools[0];return t instanceof a.InspectTool&&t.toggleable}initialize(){super.initialize(),this.do=new l.Signal0(this,\"do\")}connect_signals(){super.connect_signals(),this.connect(this.do,(()=>this.doit())),this.connect(this.properties.active.change,(()=>this.set_active()));for(const t of this.tools)this.connect(t.properties.active.change,(()=>{this.active=t.active}))}doit(){for(const t of this.tools)t.do.emit()}set_active(){for(const t of this.tools)t.active=this.active}get menu(){const{menu:t}=this.tools[0];if(null==t)return null;const o=[];for(const[e,n]of(0,u.enumerate)(t))if(null==e)o.push(null);else{const t=()=>{var t,o,e;for(const s of this.tools)null===(e=null===(o=null===(t=s.menu)||void 0===t?void 0:t[n])||void 0===o?void 0:o.handler)||void 0===e||e.call(o)};o.push(Object.assign(Object.assign({},e),{handler:t}))}return o}}e.ToolProxy=h,i=h,h.__name__=\"ToolProxy\",i.define((({Boolean:t,Array:o,Ref:e})=>({tools:[o(e(r.ButtonTool)),[]],active:[t,!1],disabled:[t,!1]})))},\n", @@ -817,11 +836,10 @@ "\n", " /* END bokeh.min.js */\n", " },\n", - " \n", " function(Bokeh) {\n", " /* BEGIN bokeh-gl.min.js */\n", " /*!\n", - " * Copyright (c) 2012 - 2021, Anaconda, Inc., and Bokeh Contributors\n", + " * Copyright (c) 2012 - 2022, Anaconda, Inc., and Bokeh Contributors\n", " * All rights reserved.\n", " * \n", " * Redistribution and use in source and binary forms, with or without modification,\n", @@ -851,7 +869,7 @@ " * THE POSSIBILITY OF SUCH DAMAGE.\n", " */\n", " (function(root, factory) {\n", - " factory(root[\"Bokeh\"], \"2.4.1\");\n", + " factory(root[\"Bokeh\"], \"2.4.3\");\n", " })(this, function(Bokeh, version) {\n", " let define;\n", " return (function(modules, entry, aliases, externals) {\n", @@ -864,44 +882,34 @@ " })\n", " ({\n", " 409: function _(n,c,f,i,o){i(),n(410)},\n", - " 410: function _(t,_,r,e,o){e();const g=t(1);\n", - " /*\n", - " Copyright notice: many of the awesome techniques and GLSL code contained in\n", - " this module are based on work by Nicolas Rougier as part of the Glumpy and\n", - " Vispy projects. The algorithms are published in\n", - " http://jcgt.org/published/0003/04/01/ and http://jcgt.org/published/0002/02/08/\n", - " \n", - " Other locations where we work with GL, or prepare for GL-rendering:\n", - " - canvas.ts\n", - " - plot.ts\n", - " - glyph.ts\n", - " - glyph_renderer.ts\n", - " */o(\"get_regl\",t(411).get_regl),(0,g.__exportStar)(t(421),r),(0,g.__exportStar)(t(425),r),(0,g.__exportStar)(t(426),r)},\n", - " 411: function _(t,i,e,_,a){_();const r=t(1),o=(0,r.__importDefault)(t(412)),n=t(413),s=(0,r.__importDefault)(t(415)),l=(0,r.__importDefault)(t(416)),p=(0,r.__importDefault)(t(417)),c=(0,r.__importDefault)(t(418)),h=(0,r.__importDefault)(t(419)),u=(0,r.__importDefault)(t(420));let f;e.get_regl=function(t){return null==f&&(f=new g(t)),f};class g{constructor(t){try{this._regl=(0,o.default)({gl:t,extensions:[\"ANGLE_instanced_arrays\",\"EXT_blend_minmax\"]}),this._regl_available=!0,this._line_geometry=this._regl.buffer({usage:\"static\",type:\"float\",data:[[-2,0],[-1,-1],[1,-1],[2,0],[1,1],[-1,1]]}),this._line_triangles=this._regl.elements({usage:\"static\",primitive:\"triangles\",data:[[0,1,5],[1,2,5],[5,2,4],[2,3,4]]})}catch(t){this._regl_available=!1}}buffer(t){return this._regl.buffer(t)}clear(t,i){this._viewport={x:0,y:0,width:t,height:i},this._regl.clear({color:[0,0,0,0]})}get has_webgl(){return this._regl_available}get scissor(){return this._scissor}set_scissor(t,i,e,_){this._scissor={x:t,y:i,width:e,height:_}}get viewport(){return this._viewport}dashed_line(){return null==this._dashed_line&&(this._dashed_line=function(t,i,e){const _={vert:`#define DASHED\\n\\n${s.default}`,frag:`#define DASHED\\n\\n${l.default}`,attributes:{a_position:{buffer:i,divisor:0},a_point_prev:(t,i)=>i.points.to_attribute_config(),a_point_start:(t,i)=>i.points.to_attribute_config(2*Float32Array.BYTES_PER_ELEMENT),a_point_end:(t,i)=>i.points.to_attribute_config(4*Float32Array.BYTES_PER_ELEMENT),a_point_next:(t,i)=>i.points.to_attribute_config(6*Float32Array.BYTES_PER_ELEMENT),a_length_so_far:(t,i)=>i.length_so_far.to_attribute_config()},uniforms:{u_canvas_size:t.prop(\"canvas_size\"),u_pixel_ratio:t.prop(\"pixel_ratio\"),u_antialias:t.prop(\"antialias\"),u_line_color:t.prop(\"line_color\"),u_linewidth:t.prop(\"linewidth\"),u_miter_limit:t.prop(\"miter_limit\"),u_line_join:t.prop(\"line_join\"),u_line_cap:t.prop(\"line_cap\"),u_dash_tex:t.prop(\"dash_tex\"),u_dash_tex_info:t.prop(\"dash_tex_info\"),u_dash_scale:t.prop(\"dash_scale\"),u_dash_offset:t.prop(\"dash_offset\")},elements:e,instances:t.prop(\"nsegments\"),blend:{enable:!0,equation:\"max\",func:{srcRGB:1,srcAlpha:1,dstRGB:1,dstAlpha:1}},depth:{enable:!1},scissor:{enable:!0,box:t.prop(\"scissor\")},viewport:t.prop(\"viewport\")};return t(_)}(this._regl,this._line_geometry,this._line_triangles)),this._dashed_line}get_dash(t){return null==this._dash_cache&&(this._dash_cache=new n.DashCache(this._regl)),this._dash_cache.get(t)}marker(t){null==this._marker_map&&(this._marker_map=new Map);let i=this._marker_map.get(t);return null==i&&(i=function(t,i){const e={vert:p.default,frag:`#define USE_${i.toUpperCase()}\\n\\n${c.default}`,attributes:{a_position:{buffer:t.buffer([[-.5,-.5],[-.5,.5],[.5,.5],[.5,-.5]]),divisor:0},a_center:(t,i)=>i.center.to_attribute_config(),a_size:(t,i)=>i.size.to_attribute_config(),a_angle:(t,i)=>i.angle.to_attribute_config(),a_linewidth:(t,i)=>i.linewidth.to_attribute_config(),a_line_color:(t,i)=>i.line_color.to_attribute_config(),a_fill_color:(t,i)=>i.fill_color.to_attribute_config(),a_show:(t,i)=>i.show.to_attribute_config()},uniforms:{u_canvas_size:t.prop(\"canvas_size\"),u_pixel_ratio:t.prop(\"pixel_ratio\"),u_antialias:t.prop(\"antialias\")},count:4,primitive:\"triangle fan\",instances:t.prop(\"nmarkers\"),blend:{enable:!0,func:{srcRGB:\"one\",srcAlpha:\"one\",dstRGB:\"one minus src alpha\",dstAlpha:\"one minus src alpha\"}},depth:{enable:!1},scissor:{enable:!0,box:t.prop(\"scissor\")},viewport:t.prop(\"viewport\")};return t(e)}(this._regl,t),this._marker_map.set(t,i)),i}rect_no_hatch(){return null==this._rect_no_hatch&&(this._rect_no_hatch=function(t){const i={vert:h.default,frag:u.default,attributes:{a_position:{buffer:t.buffer([[-.5,-.5],[-.5,.5],[.5,.5],[.5,-.5]]),divisor:0},a_center:(t,i)=>i.center.to_attribute_config(),a_width:(t,i)=>i.width.to_attribute_config(),a_height:(t,i)=>i.height.to_attribute_config(),a_angle:(t,i)=>i.angle.to_attribute_config(),a_linewidth:(t,i)=>i.linewidth.to_attribute_config(),a_line_color:(t,i)=>i.line_color.to_attribute_config(),a_fill_color:(t,i)=>i.fill_color.to_attribute_config(),a_line_join:(t,i)=>i.line_join.to_attribute_config(),a_show:(t,i)=>i.show.to_attribute_config()},uniforms:{u_canvas_size:t.prop(\"canvas_size\"),u_pixel_ratio:t.prop(\"pixel_ratio\"),u_antialias:t.prop(\"antialias\")},count:4,primitive:\"triangle fan\",instances:t.prop(\"nmarkers\"),blend:{enable:!0,func:{srcRGB:\"one\",srcAlpha:\"one\",dstRGB:\"one minus src alpha\",dstAlpha:\"one minus src alpha\"}},depth:{enable:!1},scissor:{enable:!0,box:t.prop(\"scissor\")},viewport:t.prop(\"viewport\")};return t(i)}(this._regl)),this._rect_no_hatch}rect_hatch(){return null==this._rect_hatch&&(this._rect_hatch=function(t){const i={vert:`#define HATCH\\n\\n${h.default}`,frag:`#define HATCH\\n\\n${u.default}`,attributes:{a_position:{buffer:t.buffer([[-.5,-.5],[-.5,.5],[.5,.5],[.5,-.5]]),divisor:0},a_center:(t,i)=>i.center.to_attribute_config(),a_width:(t,i)=>i.width.to_attribute_config(),a_height:(t,i)=>i.height.to_attribute_config(),a_angle:(t,i)=>i.angle.to_attribute_config(),a_linewidth:(t,i)=>i.linewidth.to_attribute_config(),a_line_color:(t,i)=>i.line_color.to_attribute_config(),a_fill_color:(t,i)=>i.fill_color.to_attribute_config(),a_line_join:(t,i)=>i.line_join.to_attribute_config(),a_show:(t,i)=>i.show.to_attribute_config(),a_hatch_pattern:(t,i)=>i.hatch_pattern.to_attribute_config(),a_hatch_scale:(t,i)=>i.hatch_scale.to_attribute_config(),a_hatch_weight:(t,i)=>i.hatch_weight.to_attribute_config(),a_hatch_color:(t,i)=>i.hatch_color.to_attribute_config()},uniforms:{u_canvas_size:t.prop(\"canvas_size\"),u_pixel_ratio:t.prop(\"pixel_ratio\"),u_antialias:t.prop(\"antialias\")},count:4,primitive:\"triangle fan\",instances:t.prop(\"nmarkers\"),blend:{enable:!0,func:{srcRGB:\"one\",srcAlpha:\"one\",dstRGB:\"one minus src alpha\",dstAlpha:\"one minus src alpha\"}},depth:{enable:!1},scissor:{enable:!0,box:t.prop(\"scissor\")},viewport:t.prop(\"viewport\")};return t(i)}(this._regl)),this._rect_hatch}solid_line(){return null==this._solid_line&&(this._solid_line=function(t,i,e){const _={vert:s.default,frag:l.default,attributes:{a_position:{buffer:i,divisor:0},a_point_prev:(t,i)=>i.points.to_attribute_config(),a_point_start:(t,i)=>i.points.to_attribute_config(2*Float32Array.BYTES_PER_ELEMENT),a_point_end:(t,i)=>i.points.to_attribute_config(4*Float32Array.BYTES_PER_ELEMENT),a_point_next:(t,i)=>i.points.to_attribute_config(6*Float32Array.BYTES_PER_ELEMENT)},uniforms:{u_canvas_size:t.prop(\"canvas_size\"),u_pixel_ratio:t.prop(\"pixel_ratio\"),u_antialias:t.prop(\"antialias\"),u_line_color:t.prop(\"line_color\"),u_linewidth:t.prop(\"linewidth\"),u_miter_limit:t.prop(\"miter_limit\"),u_line_join:t.prop(\"line_join\"),u_line_cap:t.prop(\"line_cap\")},elements:e,instances:t.prop(\"nsegments\"),blend:{enable:!0,equation:\"max\",func:{srcRGB:1,srcAlpha:1,dstRGB:1,dstAlpha:1}},depth:{enable:!1},scissor:{enable:!0,box:t.prop(\"scissor\")},viewport:t.prop(\"viewport\")};return t(_)}(this._regl,this._line_geometry,this._line_triangles)),this._solid_line}}e.ReglWrapper=g,g.__name__=\"ReglWrapper\"},\n", + " 410: function _(t,_,r,e,o){e();const a=t(1);o(\"get_regl\",t(411).get_regl),(0,a.__exportStar)(t(419),r),(0,a.__exportStar)(t(423),r),(0,a.__exportStar)(t(425),r),(0,a.__exportStar)(t(426),r),(0,a.__exportStar)(t(427),r),(0,a.__exportStar)(t(428),r),(0,a.__exportStar)(t(429),r),(0,a.__exportStar)(t(424),r)},\n", + " 411: function _(t,i,e,_,a){_();const r=t(1),o=(0,r.__importDefault)(t(412)),n=t(413),s=(0,r.__importDefault)(t(415)),l=(0,r.__importDefault)(t(416)),p=(0,r.__importDefault)(t(417)),h=(0,r.__importDefault)(t(418));let c;e.get_regl=function(t){return null==c&&(c=new u(t)),c};class u{constructor(t){try{this._regl=(0,o.default)({gl:t,extensions:[\"ANGLE_instanced_arrays\",\"EXT_blend_minmax\"]}),this._regl_available=!0,this._line_geometry=this._regl.buffer({usage:\"static\",type:\"float\",data:[[-2,0],[-1,-1],[1,-1],[2,0],[1,1],[-1,1]]}),this._line_triangles=this._regl.elements({usage:\"static\",primitive:\"triangles\",data:[[0,1,5],[1,2,5],[5,2,4],[2,3,4]]})}catch(t){this._regl_available=!1}}buffer(t){return this._regl.buffer(t)}clear(t,i){this._viewport={x:0,y:0,width:t,height:i},this._regl.clear({color:[0,0,0,0]})}get has_webgl(){return this._regl_available}get scissor(){return this._scissor}set_scissor(t,i,e,_){this._scissor={x:t,y:i,width:e,height:_}}get viewport(){return this._viewport}dashed_line(){return null==this._dashed_line&&(this._dashed_line=function(t,i,e){const _={vert:`#define DASHED\\n\\n${s.default}`,frag:`#define DASHED\\n\\n${l.default}`,attributes:{a_position:{buffer:i,divisor:0},a_point_prev:(t,i)=>i.points.to_attribute_config(),a_point_start:(t,i)=>i.points.to_attribute_config(2*Float32Array.BYTES_PER_ELEMENT),a_point_end:(t,i)=>i.points.to_attribute_config(4*Float32Array.BYTES_PER_ELEMENT),a_point_next:(t,i)=>i.points.to_attribute_config(6*Float32Array.BYTES_PER_ELEMENT),a_show_prev:(t,i)=>i.show.to_attribute_config(),a_show_curr:(t,i)=>i.show.to_attribute_config(Uint8Array.BYTES_PER_ELEMENT),a_show_next:(t,i)=>i.show.to_attribute_config(2*Uint8Array.BYTES_PER_ELEMENT),a_length_so_far:(t,i)=>i.length_so_far.to_attribute_config()},uniforms:{u_canvas_size:t.prop(\"canvas_size\"),u_pixel_ratio:t.prop(\"pixel_ratio\"),u_antialias:t.prop(\"antialias\"),u_line_color:t.prop(\"line_color\"),u_linewidth:t.prop(\"linewidth\"),u_miter_limit:t.prop(\"miter_limit\"),u_line_join:t.prop(\"line_join\"),u_line_cap:t.prop(\"line_cap\"),u_dash_tex:t.prop(\"dash_tex\"),u_dash_tex_info:t.prop(\"dash_tex_info\"),u_dash_scale:t.prop(\"dash_scale\"),u_dash_offset:t.prop(\"dash_offset\")},elements:e,instances:t.prop(\"nsegments\"),blend:{enable:!0,equation:\"max\",func:{srcRGB:1,srcAlpha:1,dstRGB:1,dstAlpha:1}},depth:{enable:!1},scissor:{enable:!0,box:t.prop(\"scissor\")},viewport:t.prop(\"viewport\")};return t(_)}(this._regl,this._line_geometry,this._line_triangles)),this._dashed_line}get_dash(t){return null==this._dash_cache&&(this._dash_cache=new n.DashCache(this._regl)),this._dash_cache.get(t)}marker_no_hatch(t){null==this._marker_no_hatch_map&&(this._marker_no_hatch_map=new Map);let i=this._marker_no_hatch_map.get(t);return null==i&&(i=function(t,i){const e={vert:p.default,frag:`#define USE_${i.toUpperCase()}\\n${h.default}`,attributes:{a_position:{buffer:t.buffer([[-.5,-.5],[-.5,.5],[.5,.5],[.5,-.5]]),divisor:0},a_center:(t,i)=>i.center.to_attribute_config(),a_width:(t,i)=>i.width.to_attribute_config(),a_height:(t,i)=>i.height.to_attribute_config(),a_angle:(t,i)=>i.angle.to_attribute_config(),a_linewidth:(t,i)=>i.linewidth.to_attribute_config(),a_line_color:(t,i)=>i.line_color.to_attribute_config(),a_fill_color:(t,i)=>i.fill_color.to_attribute_config(),a_line_cap:(t,i)=>i.line_cap.to_attribute_config(),a_line_join:(t,i)=>i.line_join.to_attribute_config(),a_show:(t,i)=>i.show.to_attribute_config()},uniforms:{u_canvas_size:t.prop(\"canvas_size\"),u_pixel_ratio:t.prop(\"pixel_ratio\"),u_antialias:t.prop(\"antialias\"),u_size_hint:t.prop(\"size_hint\")},count:4,primitive:\"triangle fan\",instances:t.prop(\"nmarkers\"),blend:{enable:!0,func:{srcRGB:\"one\",srcAlpha:\"one\",dstRGB:\"one minus src alpha\",dstAlpha:\"one minus src alpha\"}},depth:{enable:!1},scissor:{enable:!0,box:t.prop(\"scissor\")},viewport:t.prop(\"viewport\")};return t(e)}(this._regl,t),this._marker_no_hatch_map.set(t,i)),i}marker_hatch(t){null==this._marker_hatch_map&&(this._marker_hatch_map=new Map);let i=this._marker_hatch_map.get(t);return null==i&&(i=function(t,i){const e={vert:`#define HATCH\\n${p.default}`,frag:`#define USE_${i.toUpperCase()}\\n#define HATCH\\n${h.default}`,attributes:{a_position:{buffer:t.buffer([[-.5,-.5],[-.5,.5],[.5,.5],[.5,-.5]]),divisor:0},a_center:(t,i)=>i.center.to_attribute_config(),a_width:(t,i)=>i.width.to_attribute_config(),a_height:(t,i)=>i.height.to_attribute_config(),a_angle:(t,i)=>i.angle.to_attribute_config(),a_linewidth:(t,i)=>i.linewidth.to_attribute_config(),a_line_color:(t,i)=>i.line_color.to_attribute_config(),a_fill_color:(t,i)=>i.fill_color.to_attribute_config(),a_line_cap:(t,i)=>i.line_cap.to_attribute_config(),a_line_join:(t,i)=>i.line_join.to_attribute_config(),a_show:(t,i)=>i.show.to_attribute_config(),a_hatch_pattern:(t,i)=>i.hatch_pattern.to_attribute_config(),a_hatch_scale:(t,i)=>i.hatch_scale.to_attribute_config(),a_hatch_weight:(t,i)=>i.hatch_weight.to_attribute_config(),a_hatch_color:(t,i)=>i.hatch_color.to_attribute_config()},uniforms:{u_canvas_size:t.prop(\"canvas_size\"),u_pixel_ratio:t.prop(\"pixel_ratio\"),u_antialias:t.prop(\"antialias\"),u_size_hint:t.prop(\"size_hint\")},count:4,primitive:\"triangle fan\",instances:t.prop(\"nmarkers\"),blend:{enable:!0,func:{srcRGB:\"one\",srcAlpha:\"one\",dstRGB:\"one minus src alpha\",dstAlpha:\"one minus src alpha\"}},depth:{enable:!1},scissor:{enable:!0,box:t.prop(\"scissor\")},viewport:t.prop(\"viewport\")};return t(e)}(this._regl,t),this._marker_hatch_map.set(t,i)),i}solid_line(){return null==this._solid_line&&(this._solid_line=function(t,i,e){const _={vert:s.default,frag:l.default,attributes:{a_position:{buffer:i,divisor:0},a_point_prev:(t,i)=>i.points.to_attribute_config(),a_point_start:(t,i)=>i.points.to_attribute_config(2*Float32Array.BYTES_PER_ELEMENT),a_point_end:(t,i)=>i.points.to_attribute_config(4*Float32Array.BYTES_PER_ELEMENT),a_point_next:(t,i)=>i.points.to_attribute_config(6*Float32Array.BYTES_PER_ELEMENT),a_show_prev:(t,i)=>i.show.to_attribute_config(),a_show_curr:(t,i)=>i.show.to_attribute_config(Uint8Array.BYTES_PER_ELEMENT),a_show_next:(t,i)=>i.show.to_attribute_config(2*Uint8Array.BYTES_PER_ELEMENT)},uniforms:{u_canvas_size:t.prop(\"canvas_size\"),u_pixel_ratio:t.prop(\"pixel_ratio\"),u_antialias:t.prop(\"antialias\"),u_line_color:t.prop(\"line_color\"),u_linewidth:t.prop(\"linewidth\"),u_miter_limit:t.prop(\"miter_limit\"),u_line_join:t.prop(\"line_join\"),u_line_cap:t.prop(\"line_cap\")},elements:e,instances:t.prop(\"nsegments\"),blend:{enable:!0,equation:\"max\",func:{srcRGB:1,srcAlpha:1,dstRGB:1,dstAlpha:1}},depth:{enable:!1},scissor:{enable:!0,box:t.prop(\"scissor\")},viewport:t.prop(\"viewport\")};return t(_)}(this._regl,this._line_geometry,this._line_triangles)),this._solid_line}}e.ReglWrapper=u,u.__name__=\"ReglWrapper\"},\n", " 412: function _(e,t,r,n,a){var i,o;i=this,o=function(){\"use strict\";var e=function(e){return e instanceof Uint8Array||e instanceof Uint16Array||e instanceof Uint32Array||e instanceof Int8Array||e instanceof Int16Array||e instanceof Int32Array||e instanceof Float32Array||e instanceof Float64Array||e instanceof Uint8ClampedArray},t=function(e,t){for(var r=Object.keys(t),n=0;n=0&&(0|e)===e||n(\"invalid parameter type, (\"+e+\")\"+i(t)+\". must be a nonnegative integer\")},oneOf:f,shaderError:function(e,t,n,i,o){if(!e.getShaderParameter(t,e.COMPILE_STATUS)){var f=e.getShaderInfoLog(t),u=i===e.FRAGMENT_SHADER?\"fragment\":\"vertex\";g(n,\"string\",u+\" shader source must be a string\",o);var c=h(n,o),l=function(e){var t=[];return e.split(\"\\n\").forEach((function(e){if(!(e.length<5)){var r=/^ERROR:\\s+(\\d+):(\\d+):\\s*(.*)$/.exec(e);r?t.push(new d(0|r[1],0|r[2],r[3].trim())):e.length>0&&t.push(new d(\"unknown\",0,e))}})),t}(f);!function(e,t){t.forEach((function(t){var r=e[t.file];if(r){var n=r.index[t.line];if(n)return n.errors.push(t),void(r.hasErrors=!0)}e.unknown.hasErrors=!0,e.unknown.lines[0].errors.push(t)}))}(c,l),Object.keys(c).forEach((function(e){var t=c[e];if(t.hasErrors){var n=[\"\"],a=[\"\"];i(\"file number \"+e+\": \"+t.name+\"\\n\",\"color:red;text-decoration:underline;font-weight:bold\"),t.lines.forEach((function(e){if(e.errors.length>0){i(s(e.number,4)+\"| \",\"background-color:yellow; font-weight:bold\"),i(e.line+r,\"color:red; background-color:yellow; font-weight:bold\");var t=0;e.errors.forEach((function(n){var a=n.message,o=/^\\s*'(.*)'\\s*:\\s*(.*)$/.exec(a);if(o){var f=o[1];a=o[2],\"assign\"===f&&(f=\"=\"),t=Math.max(e.line.indexOf(f,t),0)}else t=0;i(s(\"| \",6)),i(s(\"^^^\",t+3)+r,\"font-weight:bold\"),i(s(\"| \",6)),i(a+r,\"font-weight:bold\")})),i(s(\"| \",6)+r)}else i(s(e.number,4)+\"| \"),i(e.line+r,\"color:red\")})),\"undefined\"==typeof document||window.chrome?console.log(n.join(\"\")):(a[0]=n.join(\"%c\"),console.log.apply(console,a))}function i(e,t){n.push(e),a.push(t||\"\")}})),a.raise(\"Error compiling \"+u+\" shader, \"+c[0].name)}},linkError:function(e,t,n,i,o){if(!e.getProgramParameter(t,e.LINK_STATUS)){var f=e.getProgramInfoLog(t),u=h(n,o),s='Error linking program with vertex shader, \"'+h(i,o)[0].name+'\", and fragment shader \"'+u[0].name+'\"';\"undefined\"!=typeof document?console.log(\"%c\"+s+\"\\n%c\"+f,\"color:red;text-decoration:underline;font-weight:bold\",\"color:red\"):console.log(s+r+f),a.raise(s)}},callSite:p,saveCommandRef:b,saveDrawInfo:function(e,t,r,n){function a(e){return e?n.id(e):0}function i(e,t){Object.keys(t).forEach((function(t){e[n.id(t)]=!0}))}b(e),e._fragId=a(e.static.frag),e._vertId=a(e.static.vert);var o=e._uniformSet={};i(o,t.static),i(o,t.dynamic);var f=e._attributeSet={};i(f,r.static),i(f,r.dynamic),e._hasCount=\"count\"in e.static||\"count\"in e.dynamic||\"elements\"in e.static||\"elements\"in e.dynamic},framebufferFormat:function(e,t,r){e.texture?f(e.texture._texture.internalformat,t,\"unsupported texture format for attachment\"):f(e.renderbuffer._renderbuffer.format,r,\"unsupported renderbuffer format for attachment\")},guessCommand:m,texture2D:function(e,t,r){var n,i=t.width,o=t.height,f=t.channels;a(i>0&&i<=r.maxTextureSize&&o>0&&o<=r.maxTextureSize,\"invalid texture shape\"),e.wrapS===y&&e.wrapT===y||a(A(i)&&A(o),\"incompatible wrap mode for texture, both width and height must be power of 2\"),1===t.mipmask?1!==i&&1!==o&&a(9984!==e.minFilter&&9986!==e.minFilter&&9985!==e.minFilter&&9987!==e.minFilter,\"min filter requires mipmap\"):(a(A(i)&&A(o),\"texture must be a square power of 2 to support mipmapping\"),a(t.mipmask===(i<<1)-1,\"missing or incomplete mipmap data\")),5126===t.type&&(r.extensions.indexOf(\"oes_texture_float_linear\")<0&&a(9728===e.minFilter&&9728===e.magFilter,\"filter not supported, must enable oes_texture_float_linear\"),a(!e.genMipmaps,\"mipmap generation not supported with float textures\"));var u=t.images;for(n=0;n<16;++n)if(u[n]){var s=i>>n,c=o>>n;a(t.mipmask&1<0&&i<=n.maxTextureSize&&o>0&&o<=n.maxTextureSize,\"invalid texture shape\"),a(i===o,\"cube map must be square\"),a(t.wrapS===y&&t.wrapT===y,\"wrap mode not supported by cube map\");for(var u=0;u>l,p=o>>l;a(s.mipmask&1<1&&t===r&&('\"'===t||\"'\"===t))return['\"'+O(e.substr(1,e.length-2))+'\"'];var n=/\\[(false|true|null|\\d+|'[^']*'|\"[^\"]*\")\\]/.exec(e);if(n)return E(e.substr(0,n.index)).concat(E(n[1])).concat(E(e.substr(n.index+n[0].length)));var a=e.split(\".\");if(1===a.length)return['\"'+O(e)+'\"'];for(var i=[],o=0;o0,\"invalid pixel ratio\"))):_.raise(\"invalid arguments to regl\"),r&&(\"canvas\"===r.nodeName.toLowerCase()?a=r:n=r),!i){if(!a){_(\"undefined\"!=typeof document,\"must manually specify webgl context outside of DOM environments\");var h=function(e,r,n){var a,i=document.createElement(\"canvas\");function o(){var t=window.innerWidth,r=window.innerHeight;if(e!==document.body){var a=i.getBoundingClientRect();t=a.right-a.left,r=a.bottom-a.top}i.width=n*t,i.height=n*r}return t(i.style,{border:0,margin:0,padding:0,top:0,left:0,width:\"100%\",height:\"100%\"}),e.appendChild(i),e===document.body&&(i.style.position=\"absolute\",t(e.style,{margin:0,padding:0})),e!==document.body&&\"function\"==typeof ResizeObserver?(a=new ResizeObserver((function(){setTimeout(o)}))).observe(e):window.addEventListener(\"resize\",o,!1),o(),{canvas:i,onDestroy:function(){a?a.disconnect():window.removeEventListener(\"resize\",o),e.removeChild(i)}}}(n||document.body,0,l);if(!h)return null;a=h.canvas,p=h.onDestroy}void 0===u.premultipliedAlpha&&(u.premultipliedAlpha=!0),i=function(e,t){function r(r){try{return e.getContext(r,t)}catch(e){return null}}return r(\"webgl\")||r(\"experimental-webgl\")||r(\"webgl-experimental\")}(a,u)}return i?{gl:i,canvas:a,container:n,extensions:s,optionalExtensions:c,pixelRatio:l,profile:d,onDone:m,onDestroy:p}:(p(),m(\"webgl not supported, try upgrading your browser or graphics drivers http://get.webgl.org\"),null)}function V(e,t){for(var r=Array(e),n=0;n65535)<<4,t|=r=((e>>>=t)>255)<<3,t|=r=((e>>>=r)>15)<<2,(t|=r=((e>>>=r)>3)<<1)|(e>>>=r)>>1}function P(){var e=V(8,(function(){return[]}));function t(t){var r=function(e){for(var t=16;t<=1<<28;t*=16)if(e<=t)return t;return 0}(t),n=e[I(r)>>2];return n.length>0?n.pop():new ArrayBuffer(r)}function r(t){e[I(t.byteLength)>>2].push(t)}return{alloc:t,free:r,allocType:function(e,r){var n=null;switch(e){case 5120:n=new Int8Array(t(r),0,r);break;case 5121:n=new Uint8Array(t(r),0,r);break;case 5122:n=new Int16Array(t(2*r),0,r);break;case 5123:n=new Uint16Array(t(2*r),0,r);break;case 5124:n=new Int32Array(t(4*r),0,r);break;case 5125:n=new Uint32Array(t(4*r),0,r);break;case 5126:n=new Float32Array(t(4*r),0,r);break;default:return null}return n.length!==r?n.subarray(0,r):n},freeType:function(e){r(e.buffer)}}}var L=P();L.zero=P();var R=3553,M=6408,W=5126,U=36160;function G(t){return!!t&&\"object\"==typeof t&&Array.isArray(t.shape)&&Array.isArray(t.stride)&&\"number\"==typeof t.offset&&t.shape.length===t.stride.length&&(Array.isArray(t.data)||e(t.data))}var H=function(e){return Object.keys(e).map((function(t){return e[t]}))},N={shape:function(e){for(var t=[],r=e;r.length;r=r[0])t.push(r.length);return t},flatten:function(e,t,r,n){var a=1;if(t.length)for(var i=0;i>>31<<15,i=(n<<1>>>24)-127,o=n>>13&1023;if(i<-24)t[r]=a;else if(i<-14){var f=-14-i;t[r]=a+(o+1024>>f)}else t[r]=i>15?a+31744:a+(i+15<<10)+o}return t}function me(t){return Array.isArray(t)||e(t)}var pe=function(e){return!(e&e-1||!e)},he=3553,be=34067,ve=34069,ge=6408,ye=6406,xe=6407,we=6409,Ae=6410,_e=32855,ke=6402,Se=34041,Oe=35904,Ee=35906,Te=36193,De=33776,je=33777,Ce=33778,ze=33779,Fe=5121,Be=5123,Ve=5125,Ie=5126,Pe=33071,Le=9728,Re=9984,Me=9987,We=4352,Ue=33984,Ge=[Re,9986,9985,Me],He=[0,we,Ae,xe,ge],Ne={};function qe(e){return\"[object \"+e+\"]\"}Ne[6409]=Ne[6406]=Ne[6402]=1,Ne[34041]=Ne[6410]=2,Ne[6407]=Ne[35904]=3,Ne[6408]=Ne[35906]=4;var Qe=qe(\"HTMLCanvasElement\"),Ye=qe(\"OffscreenCanvas\"),Xe=qe(\"CanvasRenderingContext2D\"),$e=qe(\"ImageBitmap\"),Ke=qe(\"HTMLImageElement\"),Je=qe(\"HTMLVideoElement\"),Ze=Object.keys(Y).concat([Qe,Ye,Xe,$e,Ke,Je]),et=[];et[5121]=1,et[5126]=4,et[36193]=2,et[5123]=2,et[5125]=4;var tt=[];function rt(e){return Array.isArray(e)&&(0===e.length||\"number\"==typeof e[0])}function nt(e){return!!Array.isArray(e)&&!(0===e.length||!me(e[0]))}function at(e){return Object.prototype.toString.call(e)}function it(e){return at(e)===Qe}function ot(e){return at(e)===Ye}function ft(e){if(!e)return!1;var t=at(e);return Ze.indexOf(t)>=0||rt(e)||nt(e)||G(e)}function ut(e){return 0|Y[Object.prototype.toString.call(e)]}function st(e,t){return L.allocType(e.type===Te?Ie:e.type,t)}function ct(e,t){e.type===Te?(e.data=de(t),L.freeType(t)):e.data=t}function lt(e,t,r,n,a,i){var o;if(o=void 0!==tt[e]?tt[e]:Ne[e]*et[t],i&&(o*=6),a){for(var f=0,u=r;u>=1;)f+=o*u*u,u/=2;return f}return o*r*n}function dt(r,n,a,i,o,f,u){var s={\"don't care\":We,\"dont care\":We,nice:4354,fast:4353},c={repeat:10497,clamp:Pe,mirror:33648},l={nearest:Le,linear:9729},d=t({mipmap:Me,\"nearest mipmap nearest\":Re,\"linear mipmap nearest\":9985,\"nearest mipmap linear\":9986,\"linear mipmap linear\":Me},l),m={none:0,browser:37444},p={uint8:Fe,rgba4:32819,rgb565:33635,\"rgb5 a1\":32820},h={alpha:ye,luminance:we,\"luminance alpha\":Ae,rgb:xe,rgba:ge,rgba4:32854,\"rgb5 a1\":_e,rgb565:36194},b={};n.ext_srgb&&(h.srgb=Oe,h.srgba=Ee),n.oes_texture_float&&(p.float32=p.float=Ie),n.oes_texture_half_float&&(p.float16=p[\"half float\"]=Te),n.webgl_depth_texture&&(t(h,{depth:ke,\"depth stencil\":Se}),t(p,{uint16:Be,uint32:Ve,\"depth stencil\":34042})),n.webgl_compressed_texture_s3tc&&t(b,{\"rgb s3tc dxt1\":De,\"rgba s3tc dxt1\":je,\"rgba s3tc dxt3\":Ce,\"rgba s3tc dxt5\":ze}),n.webgl_compressed_texture_atc&&t(b,{\"rgb atc\":35986,\"rgba atc explicit alpha\":35987,\"rgba atc interpolated alpha\":34798}),n.webgl_compressed_texture_pvrtc&&t(b,{\"rgb pvrtc 4bppv1\":35840,\"rgb pvrtc 2bppv1\":35841,\"rgba pvrtc 4bppv1\":35842,\"rgba pvrtc 2bppv1\":35843}),n.webgl_compressed_texture_etc1&&(b[\"rgb etc1\"]=36196);var v=Array.prototype.slice.call(r.getParameter(34467));Object.keys(b).forEach((function(e){var t=b[e];v.indexOf(t)>=0&&(h[e]=t)}));var g=Object.keys(h);a.textureFormats=g;var y=[];Object.keys(h).forEach((function(e){var t=h[e];y[t]=e}));var x=[];Object.keys(p).forEach((function(e){var t=p[e];x[t]=e}));var w=[];Object.keys(l).forEach((function(e){w[l[e]]=e}));var A=[];Object.keys(d).forEach((function(e){var t=d[e];A[t]=e}));var k=[];Object.keys(c).forEach((function(e){k[c[e]]=e}));var S=g.reduce((function(e,t){var r=h[t];return r===we||r===ye||r===we||r===Ae||r===ke||r===Se||n.ext_srgb&&(r===Oe||r===Ee)?e[r]=r:r===_e||t.indexOf(\"rgba\")>=0?e[r]=ge:e[r]=xe,e}),{});function O(){this.internalformat=ge,this.format=ge,this.type=Fe,this.compressed=!1,this.premultiplyAlpha=!1,this.flipY=!1,this.unpackAlignment=1,this.colorSpace=37444,this.width=0,this.height=0,this.channels=0}function E(e,t){e.internalformat=t.internalformat,e.format=t.format,e.type=t.type,e.compressed=t.compressed,e.premultiplyAlpha=t.premultiplyAlpha,e.flipY=t.flipY,e.unpackAlignment=t.unpackAlignment,e.colorSpace=t.colorSpace,e.width=t.width,e.height=t.height,e.channels=t.channels}function T(e,t){if(\"object\"==typeof t&&t){if(\"premultiplyAlpha\"in t&&(_.type(t.premultiplyAlpha,\"boolean\",\"invalid premultiplyAlpha\"),e.premultiplyAlpha=t.premultiplyAlpha),\"flipY\"in t&&(_.type(t.flipY,\"boolean\",\"invalid texture flip\"),e.flipY=t.flipY),\"alignment\"in t&&(_.oneOf(t.alignment,[1,2,4,8],\"invalid texture unpack alignment\"),e.unpackAlignment=t.alignment),\"colorSpace\"in t&&(_.parameter(t.colorSpace,m,\"invalid colorSpace\"),e.colorSpace=m[t.colorSpace]),\"type\"in t){var r=t.type;_(n.oes_texture_float||!(\"float\"===r||\"float32\"===r),\"you must enable the OES_texture_float extension in order to use floating point textures.\"),_(n.oes_texture_half_float||!(\"half float\"===r||\"float16\"===r),\"you must enable the OES_texture_half_float extension in order to use 16-bit floating point textures.\"),_(n.webgl_depth_texture||!(\"uint16\"===r||\"uint32\"===r||\"depth stencil\"===r),\"you must enable the WEBGL_depth_texture extension in order to use depth/stencil textures.\"),_.parameter(r,p,\"invalid texture type\"),e.type=p[r]}var i=e.width,o=e.height,f=e.channels,u=!1;\"shape\"in t?(_(Array.isArray(t.shape)&&t.shape.length>=2,\"shape must be an array\"),i=t.shape[0],o=t.shape[1],3===t.shape.length&&(f=t.shape[2],_(f>0&&f<=4,\"invalid number of channels\"),u=!0),_(i>=0&&i<=a.maxTextureSize,\"invalid width\"),_(o>=0&&o<=a.maxTextureSize,\"invalid height\")):(\"radius\"in t&&(i=o=t.radius,_(i>=0&&i<=a.maxTextureSize,\"invalid radius\")),\"width\"in t&&(i=t.width,_(i>=0&&i<=a.maxTextureSize,\"invalid width\")),\"height\"in t&&(o=t.height,_(o>=0&&o<=a.maxTextureSize,\"invalid height\")),\"channels\"in t&&(f=t.channels,_(f>0&&f<=4,\"invalid number of channels\"),u=!0)),e.width=0|i,e.height=0|o,e.channels=0|f;var s=!1;if(\"format\"in t){var c=t.format;_(n.webgl_depth_texture||!(\"depth\"===c||\"depth stencil\"===c),\"you must enable the WEBGL_depth_texture extension in order to use depth/stencil textures.\"),_.parameter(c,h,\"invalid texture format\");var l=e.internalformat=h[c];e.format=S[l],c in p&&(\"type\"in t||(e.type=p[c])),c in b&&(e.compressed=!0),s=!0}!u&&s?e.channels=Ne[e.format]:u&&!s?e.channels!==He[e.format]&&(e.format=e.internalformat=He[e.channels]):s&&u&&_(e.channels===Ne[e.format],\"number of channels inconsistent with specified format\")}}function D(e){r.pixelStorei(37440,e.flipY),r.pixelStorei(37441,e.premultiplyAlpha),r.pixelStorei(37443,e.colorSpace),r.pixelStorei(3317,e.unpackAlignment)}function j(){O.call(this),this.xOffset=0,this.yOffset=0,this.data=null,this.needsFree=!1,this.element=null,this.needsCopy=!1}function C(t,r){var n=null;if(ft(r)?n=r:r&&(_.type(r,\"object\",\"invalid pixel data type\"),T(t,r),\"x\"in r&&(t.xOffset=0|r.x),\"y\"in r&&(t.yOffset=0|r.y),ft(r.data)&&(n=r.data)),_(!t.compressed||n instanceof Uint8Array,\"compressed texture data must be stored in a uint8array\"),r.copy){_(!n,\"can not specify copy and data field for the same texture\");var i=o.viewportWidth,f=o.viewportHeight;t.width=t.width||i-t.xOffset,t.height=t.height||f-t.yOffset,t.needsCopy=!0,_(t.xOffset>=0&&t.xOffset=0&&t.yOffset0&&t.width<=i&&t.height>0&&t.height<=f,\"copy texture read out of bounds\")}else if(n){if(e(n))t.channels=t.channels||4,t.data=n,\"type\"in r||t.type!==Fe||(t.type=ut(n));else if(rt(n))t.channels=t.channels||4,function(e,t){var r=t.length;switch(e.type){case Fe:case Be:case Ve:case Ie:var n=L.allocType(e.type,r);n.set(t),e.data=n;break;case Te:e.data=de(t);break;default:_.raise(\"unsupported texture type, must specify a typed array\")}}(t,n),t.alignment=1,t.needsFree=!0;else if(G(n)){var u=n.data;Array.isArray(u)||t.type!==Fe||(t.type=ut(u));var s,c,l,d,m,p,h=n.shape,b=n.stride;3===h.length?(l=h[2],p=b[2]):(_(2===h.length,\"invalid ndarray pixel data, must be 2 or 3D\"),l=1,p=1),s=h[0],c=h[1],d=b[0],m=b[1],t.alignment=1,t.width=s,t.height=c,t.channels=l,t.format=t.internalformat=He[l],t.needsFree=!0,function(e,t,r,n,a,i){for(var o=e.width,f=e.height,u=e.channels,s=st(e,o*f*u),c=0,l=0;l=0,\"oes_texture_float extension not enabled\"):t.type===Te&&_(a.extensions.indexOf(\"oes_texture_half_float\")>=0,\"oes_texture_half_float extension not enabled\")}function z(e,t,n){var a=e.element,o=e.data,f=e.internalformat,u=e.format,s=e.type,c=e.width,l=e.height;D(e),a?r.texImage2D(t,n,u,u,s,a):e.compressed?r.compressedTexImage2D(t,n,f,c,l,0,o):e.needsCopy?(i(),r.copyTexImage2D(t,n,u,e.xOffset,e.yOffset,c,l,0)):r.texImage2D(t,n,u,c,l,0,u,s,o||null)}function F(e,t,n,a,o){var f=e.element,u=e.data,s=e.internalformat,c=e.format,l=e.type,d=e.width,m=e.height;D(e),f?r.texSubImage2D(t,o,n,a,c,l,f):e.compressed?r.compressedTexSubImage2D(t,o,n,a,s,d,m,u):e.needsCopy?(i(),r.copyTexSubImage2D(t,o,n,a,e.xOffset,e.yOffset,d,m)):r.texSubImage2D(t,o,n,a,d,m,c,l,u)}var B=[];function V(){return B.pop()||new j}function I(e){e.needsFree&&L.freeType(e.data),j.call(e),B.push(e)}function P(){O.call(this),this.genMipmaps=!1,this.mipmapHint=We,this.mipmask=0,this.images=Array(16)}function R(e,t,r){var n=e.images[0]=V();e.mipmask=1,n.width=e.width=t,n.height=e.height=r,n.channels=e.channels=4}function M(e,t){var r=null;if(ft(t))E(r=e.images[0]=V(),e),C(r,t),e.mipmask=1;else if(T(e,t),Array.isArray(t.mipmap))for(var n=t.mipmap,a=0;a>=a,r.height>>=a,C(r,n[a]),e.mipmask|=1<=0&&!(\"faces\"in t)&&(e.genMipmaps=!0)}if(\"mag\"in t){var n=t.mag;_.parameter(n,l),e.magFilter=l[n]}var i=e.wrapS,o=e.wrapT;if(\"wrap\"in t){var f=t.wrap;\"string\"==typeof f?(_.parameter(f,c),i=o=c[f]):Array.isArray(f)&&(_.parameter(f[0],c),_.parameter(f[1],c),i=c[f[0]],o=c[f[1]])}else{if(\"wrapS\"in t){var u=t.wrapS;_.parameter(u,c),i=c[u]}if(\"wrapT\"in t){var m=t.wrapT;_.parameter(m,c),o=c[m]}}if(e.wrapS=i,e.wrapT=o,\"anisotropic\"in t){var p=t.anisotropic;_(\"number\"==typeof p&&p>=1&&p<=a.maxAnisotropic,\"aniso samples must be between 1 and \"),e.anisotropic=t.anisotropic}if(\"mipmap\"in t){var h=!1;switch(typeof t.mipmap){case\"string\":_.parameter(t.mipmap,s,\"invalid mipmap hint\"),e.mipmapHint=s[t.mipmap],e.genMipmaps=!0,h=!0;break;case\"boolean\":h=e.genMipmaps=t.mipmap;break;case\"object\":_(Array.isArray(t.mipmap),\"invalid mipmap type\"),e.genMipmaps=!1,h=!0;break;default:_.raise(\"invalid mipmap type\")}h&&!(\"min\"in t)&&(e.minFilter=Re)}}function $(e,t){r.texParameteri(t,10241,e.minFilter),r.texParameteri(t,10240,e.magFilter),r.texParameteri(t,10242,e.wrapS),r.texParameteri(t,10243,e.wrapT),n.ext_texture_filter_anisotropic&&r.texParameteri(t,34046,e.anisotropic),e.genMipmaps&&(r.hint(33170,e.mipmapHint),r.generateMipmap(t))}var K=0,J={},Z=a.maxTextureUnits,ee=Array(Z).map((function(){return null}));function te(e){O.call(this),this.mipmask=0,this.internalformat=ge,this.id=K++,this.refCount=1,this.target=e,this.texture=r.createTexture(),this.unit=-1,this.bindCount=0,this.texInfo=new Y,u.profile&&(this.stats={size:0})}function re(e){r.activeTexture(Ue),r.bindTexture(e.target,e.texture)}function ne(){var e=ee[0];e?r.bindTexture(e.target,e.texture):r.bindTexture(he,null)}function ae(e){var t=e.texture;_(t,\"must not double destroy texture\");var n=e.unit,a=e.target;n>=0&&(r.activeTexture(Ue+n),r.bindTexture(a,null),ee[n]=null),r.deleteTexture(t),e.texture=null,e.params=null,e.pixels=null,e.refCount=0,delete J[e.id],f.textureCount--}return t(te.prototype,{bind:function(){var e=this;e.bindCount+=1;var t=e.unit;if(t<0){for(var n=0;n0)continue;a.unit=-1}ee[n]=e,t=n;break}t>=Z&&_.raise(\"insufficient number of texture units\"),u.profile&&f.maxTextureUnits>u)-o,s.height=s.height||(n.height>>u)-f,_(n.type===s.type&&n.format===s.format&&n.internalformat===s.internalformat,\"incompatible format for texture.subimage\"),_(o>=0&&f>=0&&o+s.width<=n.width&&f+s.height<=n.height,\"texture.subimage write out of bounds\"),_(n.mipmask&1<>f;++f){var s=a>>f,c=o>>f;if(!s||!c)break;r.texImage2D(he,f,n.format,s,c,0,n.format,n.type,null)}return ne(),u.profile&&(n.stats.size=lt(n.internalformat,n.type,a,o,!1,!1)),i},i._reglType=\"texture2d\",i._texture=n,u.profile&&(i.stats=n.stats),i.destroy=function(){n.decRef()},i},createCube:function(e,t,n,i,o,s){var c=new te(be);J[c.id]=c,f.cubeCount++;var l=new Array(6);function d(e,t,r,n,i,o){var f,s=c.texInfo;for(Y.call(s),f=0;f<6;++f)l[f]=q();if(\"number\"!=typeof e&&e)if(\"object\"==typeof e)if(t)M(l[0],e),M(l[1],t),M(l[2],r),M(l[3],n),M(l[4],i),M(l[5],o);else if(X(s,e),T(c,e),\"faces\"in e){var m=e.faces;for(_(Array.isArray(m)&&6===m.length,\"cube faces must be a length 6 array\"),f=0;f<6;++f)_(\"object\"==typeof m[f]&&!!m[f],\"invalid input for cube map face\"),E(l[f],c),M(l[f],m[f])}else for(f=0;f<6;++f)M(l[f],e);else _.raise(\"invalid arguments to cube map\");else{var p=0|e||1;for(f=0;f<6;++f)R(l[f],p,p)}for(E(c,l[0]),_.optional((function(){a.npotTextureCube||_(pe(c.width)&&pe(c.height),\"your browser does not support non power or two texture dimensions\")})),s.genMipmaps?c.mipmask=(l[0].width<<1)-1:c.mipmask=l[0].mipmask,_.textureCube(c,s,l,a),c.internalformat=l[0].internalformat,d.width=l[0].width,d.height=l[0].height,re(c),f=0;f<6;++f)W(l[f],ve+f);for($(s,be),ne(),u.profile&&(c.stats.size=lt(c.internalformat,c.type,d.width,d.height,s.genMipmaps,!0)),d.format=y[c.internalformat],d.type=x[c.type],d.mag=w[s.magFilter],d.min=A[s.minFilter],d.wrapS=k[s.wrapS],d.wrapT=k[s.wrapT],f=0;f<6;++f)Q(l[f]);return d}return d(e,t,n,i,o,s),d.subimage=function(e,t,r,n,a){_(!!t,\"must specify image data\"),_(\"number\"==typeof e&&e===(0|e)&&e>=0&&e<6,\"invalid face\");var i=0|r,o=0|n,f=0|a,u=V();return E(u,c),u.width=0,u.height=0,C(u,t),u.width=u.width||(c.width>>f)-i,u.height=u.height||(c.height>>f)-o,_(c.type===u.type&&c.format===u.format&&c.internalformat===u.internalformat,\"incompatible format for texture.subimage\"),_(i>=0&&o>=0&&i+u.width<=c.width&&o+u.height<=c.height,\"texture.subimage write out of bounds\"),_(c.mipmask&1<>a;++a)r.texImage2D(ve+n,a,c.format,t>>a,t>>a,0,c.format,c.type,null);return ne(),u.profile&&(c.stats.size=lt(c.internalformat,c.type,d.width,d.height,!1,!0)),d}},d._reglType=\"textureCube\",d._texture=c,u.profile&&(d.stats=c.stats),d.destroy=function(){c.decRef()},d},clear:function(){for(var e=0;e>t,e.height>>t,0,e.internalformat,e.type,null);else for(var n=0;n<6;++n)r.texImage2D(ve+n,t,e.internalformat,e.width>>t,e.height>>t,0,e.internalformat,e.type,null);$(e.texInfo,e.target)}))},refresh:function(){for(var e=0;e=0&&c=0&&l0&&d+c<=a.framebufferWidth,\"invalid width for read pixels\"),_(m>0&&m+l<=a.framebufferHeight,\"invalid height for read pixels\"),n();var h=d*m*4;return p||(s===Dt?p=new Uint8Array(h):s===jt&&(p=p||new Float32Array(h))),_.isTypedArray(p,\"data buffer for regl.read() must be a typedarray\"),_(p.byteLength>=h,\"data buffer for regl.read() too small\"),t.pixelStorei(3333,4),t.readPixels(c,l,d,m,6408,s,p),p}return function(e){return e&&\"framebuffer\"in e?function(e){var t;return r.setFBO({framebuffer:e.framebuffer},(function(){t=u(e)})),t}(e):u(e)}}function zt(e){return Array.prototype.slice.call(e)}function Ft(e){return zt(e).join(\"\")}var Bt=\"xyzw\".split(\"\"),Vt=\"dither\",It=\"blend.enable\",Pt=\"blend.color\",Lt=\"blend.equation\",Rt=\"blend.func\",Mt=\"depth.enable\",Wt=\"depth.func\",Ut=\"depth.range\",Gt=\"depth.mask\",Ht=\"colorMask\",Nt=\"cull.enable\",qt=\"cull.face\",Qt=\"frontFace\",Yt=\"lineWidth\",Xt=\"polygonOffset.enable\",$t=\"polygonOffset.offset\",Kt=\"sample.alpha\",Jt=\"sample.enable\",Zt=\"sample.coverage\",er=\"stencil.enable\",tr=\"stencil.mask\",rr=\"stencil.func\",nr=\"stencil.opFront\",ar=\"stencil.opBack\",ir=\"scissor.enable\",or=\"scissor.box\",fr=\"viewport\",ur=\"profile\",sr=\"framebuffer\",cr=\"vert\",lr=\"frag\",dr=\"elements\",mr=\"primitive\",pr=\"count\",hr=\"offset\",br=\"instances\",vr=\"vao\",gr=\"Width\",yr=\"Height\",xr=sr+gr,wr=sr+yr,Ar=\"drawingBufferWidth\",_r=\"drawingBufferHeight\",kr=[Rt,Lt,rr,nr,ar,Zt,fr,or,$t],Sr=34962,Or=34963,Er=5126,Tr=35664,Dr=35665,jr=35666,Cr=5124,zr=35667,Fr=35668,Br=35669,Vr=35670,Ir=35671,Pr=35672,Lr=35673,Rr=35674,Mr=35675,Wr=35676,Ur=35678,Gr=35680,Hr=1028,Nr=1029,qr=2305,Qr=7680,Yr={0:0,1:1,zero:0,one:1,\"src color\":768,\"one minus src color\":769,\"src alpha\":770,\"one minus src alpha\":771,\"dst color\":774,\"one minus dst color\":775,\"dst alpha\":772,\"one minus dst alpha\":773,\"constant color\":32769,\"one minus constant color\":32770,\"constant alpha\":32771,\"one minus constant alpha\":32772,\"src alpha saturate\":776},Xr=[\"constant color, constant alpha\",\"one minus constant color, constant alpha\",\"constant color, one minus constant alpha\",\"one minus constant color, one minus constant alpha\",\"constant alpha, constant color\",\"constant alpha, one minus constant color\",\"one minus constant alpha, constant color\",\"one minus constant alpha, one minus constant color\"],$r={never:512,less:513,\"<\":513,equal:514,\"=\":514,\"==\":514,\"===\":514,lequal:515,\"<=\":515,greater:516,\">\":516,notequal:517,\"!=\":517,\"!==\":517,gequal:518,\">=\":518,always:519},Kr={0:0,zero:0,keep:7680,replace:7681,increment:7682,decrement:7683,\"increment wrap\":34055,\"decrement wrap\":34056,invert:5386},Jr={frag:35632,vert:35633},Zr={cw:2304,ccw:qr};function en(t){return Array.isArray(t)||e(t)||G(t)}function tn(e){return e.sort((function(e,t){return e===fr?-1:t===fr?1:e=1,n>=2,t)}if(4===r){var a=e.data;return new rn(a.thisDep,a.contextDep,a.propDep,t)}if(5===r)return new rn(!1,!1,!1,t);if(6===r){for(var i=!1,o=!1,f=!1,u=0;u=1&&(o=!0),c>=2&&(f=!0)}else 4===s.type&&(i=i||s.data.thisDep,o=o||s.data.contextDep,f=f||s.data.propDep)}return new rn(i,o,f,t)}return new rn(3===r,2===r,1===r,t)}var fn=new rn(!1,!1,!1,(function(){}));function un(e,r,n,a,i,o,f,u,s,c,l,d,m,p,h){var b=c.Record,v={add:32774,subtract:32778,\"reverse subtract\":32779};n.ext_blend_minmax&&(v.min=32775,v.max=32776);var g=n.angle_instanced_arrays,y=n.webgl_draw_buffers,x=n.oes_vertex_array_object,w={dirty:!0,profile:h.profile},A={},k=[],S={},O={};function E(e){return e.replace(\".\",\"_\")}function T(e,t,r){var n=E(e);k.push(e),A[n]=w[n]=!!r,S[n]=t}function j(e,t,r){var n=E(e);k.push(e),Array.isArray(r)?(w[n]=r.slice(),A[n]=r.slice()):w[n]=A[n]=r,O[n]=t}T(Vt,3024),T(It,3042),j(Pt,\"blendColor\",[0,0,0,0]),j(Lt,\"blendEquationSeparate\",[32774,32774]),j(Rt,\"blendFuncSeparate\",[1,0,1,0]),T(Mt,2929,!0),j(Wt,\"depthFunc\",513),j(Ut,\"depthRange\",[0,1]),j(Gt,\"depthMask\",!0),j(Ht,Ht,[!0,!0,!0,!0]),T(Nt,2884),j(qt,\"cullFace\",Nr),j(Qt,Qt,qr),j(Yt,Yt,1),T(Xt,32823),j($t,\"polygonOffset\",[0,0]),T(Kt,32926),T(Jt,32928),j(Zt,\"sampleCoverage\",[1,!1]),T(er,2960),j(tr,\"stencilMask\",-1),j(rr,\"stencilFunc\",[519,0,-1]),j(nr,\"stencilOpSeparate\",[Hr,Qr,Qr,Qr]),j(ar,\"stencilOpSeparate\",[Nr,Qr,Qr,Qr]),T(ir,3089),j(or,\"scissor\",[0,0,e.drawingBufferWidth,e.drawingBufferHeight]),j(fr,fr,[0,0,e.drawingBufferWidth,e.drawingBufferHeight]);var C={gl:e,context:m,strings:r,next:A,current:w,draw:d,elements:o,buffer:i,shader:l,attributes:c.state,vao:c,uniforms:s,framebuffer:u,extensions:n,timer:p,isBufferArgs:en},z={primTypes:ie,compareFuncs:$r,blendFuncs:Yr,blendEquations:v,stencilOps:Kr,glTypes:X,orientationType:Zr};_.optional((function(){C.isArrayLike=me})),y&&(z.backBuffer=[Nr],z.drawBuffer=V(a.maxDrawbuffers,(function(e){return 0===e?[0]:V(e,(function(e){return 36064+e}))})));var F=0;function B(){var e=function(){var e=0,r=[],n=[];function a(){var r=[],n=[];return t((function(){r.push.apply(r,zt(arguments))}),{def:function(){var t=\"v\"+e++;return n.push(t),arguments.length>0&&(r.push(t,\"=\"),r.push.apply(r,zt(arguments)),r.push(\";\")),t},toString:function(){return Ft([n.length>0?\"var \"+n.join(\",\")+\";\":\"\",Ft(r)])}})}function i(){var e=a(),r=a(),n=e.toString,i=r.toString;function o(t,n){r(t,n,\"=\",e.def(t,n),\";\")}return t((function(){e.apply(e,zt(arguments))}),{def:e.def,entry:e,exit:r,save:o,set:function(t,r,n){o(t,r),e(t,r,\"=\",n,\";\")},toString:function(){return n()+i()}})}var o=a(),f={};return{global:o,link:function(t){for(var a=0;a=0,'unknown parameter \"'+t+'\"',d.commandStr)}))}t(m),t(p)}));var h=function(e,t){var r=e.static;if(\"string\"==typeof r[lr]&&\"string\"==typeof r[cr]){if(Object.keys(t.dynamic).length>0)return null;var n=t.static,a=Object.keys(n);if(a.length>0&&\"number\"==typeof n[a[0]]){for(var i=[],o=0;o=0,\"invalid \"+e,r.commandStr)):u=!1,\"height\"in i?(f=0|i.height,_.command(f>=0,\"invalid \"+e,r.commandStr)):u=!1,new rn(!u&&t&&t.thisDep,!u&&t&&t.contextDep,!u&&t&&t.propDep,(function(e,t){var r=e.shared.context,n=o;\"width\"in i||(n=t.def(r,\".\",xr,\"-\",s));var a=f;return\"height\"in i||(a=t.def(r,\".\",wr,\"-\",c)),[s,c,n,a]}))}if(e in a){var l=a[e],d=on(l,(function(t,r){var n=t.invoke(r,l);_.optional((function(){t.assert(r,n+\"&&typeof \"+n+'===\"object\"',\"invalid \"+e)}));var a=t.shared.context,i=r.def(n,\".x|0\"),o=r.def(n,\".y|0\"),f=r.def('\"width\" in ',n,\"?\",n,\".width|0:\",\"(\",a,\".\",xr,\"-\",i,\")\"),u=r.def('\"height\" in ',n,\"?\",n,\".height|0:\",\"(\",a,\".\",wr,\"-\",o,\")\");return _.optional((function(){t.assert(r,f+\">=0&&\"+u+\">=0\",\"invalid \"+e)})),[i,o,f,u]}));return t&&(d.thisDep=d.thisDep||t.thisDep,d.contextDep=d.contextDep||t.contextDep,d.propDep=d.propDep||t.propDep),d}return t?new rn(t.thisDep,t.contextDep,t.propDep,(function(e,t){var r=e.shared.context;return[0,0,t.def(r,\".\",xr),t.def(r,\".\",wr)]})):null}var o=i(fr);if(o){var f=o;o=new rn(o.thisDep,o.contextDep,o.propDep,(function(e,t){var r=f.append(e,t),n=e.shared.context;return t.set(n,\".viewportWidth\",r[2]),t.set(n,\".viewportHeight\",r[3]),r}))}return{viewport:o,scissor_box:i(or)}}(e,y,d),w=function(e,t){var r=e.static,n=e.dynamic,a={},i=!1,f=function(){if(vr in r){var e=r[vr];return null!==e&&null===c.getVAO(e)&&(e=c.createVAO(e)),i=!0,a.vao=e,an((function(t){var r=c.getVAO(e);return r?t.link(r):\"null\"}))}if(vr in n){i=!0;var t=n[vr];return on(t,(function(e,r){var n=e.invoke(r,t);return r.def(e.shared.vao+\".getVAO(\"+n+\")\")}))}return null}(),u=!1,s=function(){if(dr in r){var e=r[dr];if(a.elements=e,en(e)){var s=a.elements=o.create(e,!0);e=o.getElements(s),u=!0}else e&&(e=o.getElements(e),u=!0,_.command(e,\"invalid elements\",t.commandStr));var c=an((function(t,r){if(e){var n=t.link(e);return t.ELEMENTS=n,n}return t.ELEMENTS=null,null}));return c.value=e,c}if(dr in n){u=!0;var l=n[dr];return on(l,(function(e,t){var r=e.shared,n=r.isBufferArgs,a=r.elements,i=e.invoke(t,l),o=t.def(\"null\"),f=t.def(n,\"(\",i,\")\"),u=e.cond(f).then(o,\"=\",a,\".createStream(\",i,\");\").else(o,\"=\",a,\".getElements(\",i,\");\");return _.optional((function(){e.assert(u.else,\"!\"+i+\"||\"+o,\"invalid elements\")})),t.entry(u),t.exit(e.cond(f).then(a,\".destroyStream(\",o,\");\")),e.ELEMENTS=o,o}))}return i?new rn(f.thisDep,f.contextDep,f.propDep,(function(e,t){return t.def(e.shared.vao+\".currentVAO?\"+e.shared.elements+\".getElements(\"+e.shared.vao+\".currentVAO.elements):null\")})):null}();function l(e,o){if(e in r){var s=0|r[e];return o?a.offset=s:a.instances=s,_.command(!o||s>=0,\"invalid \"+e,t.commandStr),an((function(e,t){return o&&(e.OFFSET=s),s}))}if(e in n){var c=n[e];return on(c,(function(t,r){var n=t.invoke(r,c);return o&&(t.OFFSET=n,_.optional((function(){t.assert(r,n+\">=0\",\"invalid \"+e)}))),n}))}if(o){if(u)return an((function(e,t){return e.OFFSET=0,0}));if(i)return new rn(f.thisDep,f.contextDep,f.propDep,(function(e,t){return t.def(e.shared.vao+\".currentVAO?\"+e.shared.vao+\".currentVAO.offset:0\")}))}else if(i)return new rn(f.thisDep,f.contextDep,f.propDep,(function(e,t){return t.def(e.shared.vao+\".currentVAO?\"+e.shared.vao+\".currentVAO.instances:-1\")}));return null}var d=l(hr,!0),m=function(){if(mr in r){var e=r[mr];return a.primitive=e,_.commandParameter(e,ie,\"invalid primitve\",t.commandStr),an((function(t,r){return ie[e]}))}if(mr in n){var o=n[mr];return on(o,(function(e,t){var r=e.constants.primTypes,n=e.invoke(t,o);return _.optional((function(){e.assert(t,n+\" in \"+r,\"invalid primitive, must be one of \"+Object.keys(ie))})),t.def(r,\"[\",n,\"]\")}))}return u?nn(s)?s.value?an((function(e,t){return t.def(e.ELEMENTS,\".primType\")})):an((function(){return 4})):new rn(s.thisDep,s.contextDep,s.propDep,(function(e,t){var r=e.ELEMENTS;return t.def(r,\"?\",r,\".primType:\",4)})):i?new rn(f.thisDep,f.contextDep,f.propDep,(function(e,t){return t.def(e.shared.vao+\".currentVAO?\"+e.shared.vao+\".currentVAO.primitive:4\")})):null}(),p=function(){if(pr in r){var e=0|r[pr];return a.count=e,_.command(\"number\"==typeof e&&e>=0,\"invalid vertex count\",t.commandStr),an((function(){return e}))}if(pr in n){var o=n[pr];return on(o,(function(e,t){var r=e.invoke(t,o);return _.optional((function(){e.assert(t,\"typeof \"+r+'===\"number\"&&'+r+\">=0&&\"+r+\"===(\"+r+\"|0)\",\"invalid vertex count\")})),r}))}if(u){if(nn(s)){if(s)return d?new rn(d.thisDep,d.contextDep,d.propDep,(function(e,t){var r=t.def(e.ELEMENTS,\".vertCount-\",e.OFFSET);return _.optional((function(){e.assert(t,r+\">=0\",\"invalid vertex offset/element buffer too small\")})),r})):an((function(e,t){return t.def(e.ELEMENTS,\".vertCount\")}));var c=an((function(){return-1}));return _.optional((function(){c.MISSING=!0})),c}var l=new rn(s.thisDep||d.thisDep,s.contextDep||d.contextDep,s.propDep||d.propDep,(function(e,t){var r=e.ELEMENTS;return e.OFFSET?t.def(r,\"?\",r,\".vertCount-\",e.OFFSET,\":-1\"):t.def(r,\"?\",r,\".vertCount:-1\")}));return _.optional((function(){l.DYNAMIC=!0})),l}if(i){var m=new rn(f.thisDep,f.contextDep,f.propDep,(function(e,t){return t.def(e.shared.vao,\".currentVAO?\",e.shared.vao,\".currentVAO.count:-1\")}));return m}return null}(),h=l(br,!1);return{elements:s,primitive:m,count:p,instances:h,offset:d,vao:f,vaoActive:i,elementsActive:u,static:a}}(e,d),A=function(e,t){var r=e.static,n=e.dynamic,i={};return k.forEach((function(e){var o=E(e);function f(t,a){if(e in r){var f=t(r[e]);i[o]=an((function(){return f}))}else if(e in n){var u=n[e];i[o]=on(u,(function(e,t){return a(e,t,e.invoke(t,u))}))}}switch(e){case Nt:case It:case Vt:case er:case Mt:case ir:case Xt:case Kt:case Jt:case Gt:return f((function(r){return _.commandType(r,\"boolean\",e,t.commandStr),r}),(function(t,r,n){return _.optional((function(){t.assert(r,\"typeof \"+n+'===\"boolean\"',\"invalid flag \"+e,t.commandStr)})),n}));case Wt:return f((function(r){return _.commandParameter(r,$r,\"invalid \"+e,t.commandStr),$r[r]}),(function(t,r,n){var a=t.constants.compareFuncs;return _.optional((function(){t.assert(r,n+\" in \"+a,\"invalid \"+e+\", must be one of \"+Object.keys($r))})),r.def(a,\"[\",n,\"]\")}));case Ut:return f((function(e){return _.command(me(e)&&2===e.length&&\"number\"==typeof e[0]&&\"number\"==typeof e[1]&&e[0]<=e[1],\"depth range is 2d array\",t.commandStr),e}),(function(e,t,r){return _.optional((function(){e.assert(t,e.shared.isArrayLike+\"(\"+r+\")&&\"+r+\".length===2&&typeof \"+r+'[0]===\"number\"&&typeof '+r+'[1]===\"number\"&&'+r+\"[0]<=\"+r+\"[1]\",\"depth range must be a 2d array\")})),[t.def(\"+\",r,\"[0]\"),t.def(\"+\",r,\"[1]\")]}));case Rt:return f((function(e){_.commandType(e,\"object\",\"blend.func\",t.commandStr);var r=\"srcRGB\"in e?e.srcRGB:e.src,n=\"srcAlpha\"in e?e.srcAlpha:e.src,a=\"dstRGB\"in e?e.dstRGB:e.dst,i=\"dstAlpha\"in e?e.dstAlpha:e.dst;return _.commandParameter(r,Yr,o+\".srcRGB\",t.commandStr),_.commandParameter(n,Yr,o+\".srcAlpha\",t.commandStr),_.commandParameter(a,Yr,o+\".dstRGB\",t.commandStr),_.commandParameter(i,Yr,o+\".dstAlpha\",t.commandStr),_.command(-1===Xr.indexOf(r+\", \"+a),\"unallowed blending combination (srcRGB, dstRGB) = (\"+r+\", \"+a+\")\",t.commandStr),[Yr[r],Yr[a],Yr[n],Yr[i]]}),(function(t,r,n){var a=t.constants.blendFuncs;function i(i,o){var f=r.def('\"',i,o,'\" in ',n,\"?\",n,\".\",i,o,\":\",n,\".\",i);return _.optional((function(){t.assert(r,f+\" in \"+a,\"invalid \"+e+\".\"+i+o+\", must be one of \"+Object.keys(Yr))})),f}_.optional((function(){t.assert(r,n+\"&&typeof \"+n+'===\"object\"',\"invalid blend func, must be an object\")}));var o=i(\"src\",\"RGB\"),f=i(\"dst\",\"RGB\");_.optional((function(){var e=t.constants.invalidBlendCombinations;t.assert(r,e+\".indexOf(\"+o+'+\", \"+'+f+\") === -1 \",\"unallowed blending combination for (srcRGB, dstRGB)\")}));var u=r.def(a,\"[\",o,\"]\"),s=r.def(a,\"[\",i(\"src\",\"Alpha\"),\"]\");return[u,r.def(a,\"[\",f,\"]\"),s,r.def(a,\"[\",i(\"dst\",\"Alpha\"),\"]\")]}));case Lt:return f((function(r){return\"string\"==typeof r?(_.commandParameter(r,v,\"invalid \"+e,t.commandStr),[v[r],v[r]]):\"object\"==typeof r?(_.commandParameter(r.rgb,v,e+\".rgb\",t.commandStr),_.commandParameter(r.alpha,v,e+\".alpha\",t.commandStr),[v[r.rgb],v[r.alpha]]):void _.commandRaise(\"invalid blend.equation\",t.commandStr)}),(function(t,r,n){var a=t.constants.blendEquations,i=r.def(),o=r.def(),f=t.cond(\"typeof \",n,'===\"string\"');return _.optional((function(){function r(e,r,n){t.assert(e,n+\" in \"+a,\"invalid \"+r+\", must be one of \"+Object.keys(v))}r(f.then,e,n),t.assert(f.else,n+\"&&typeof \"+n+'===\"object\"',\"invalid \"+e),r(f.else,e+\".rgb\",n+\".rgb\"),r(f.else,e+\".alpha\",n+\".alpha\")})),f.then(i,\"=\",o,\"=\",a,\"[\",n,\"];\"),f.else(i,\"=\",a,\"[\",n,\".rgb];\",o,\"=\",a,\"[\",n,\".alpha];\"),r(f),[i,o]}));case Pt:return f((function(e){return _.command(me(e)&&4===e.length,\"blend.color must be a 4d array\",t.commandStr),V(4,(function(t){return+e[t]}))}),(function(e,t,r){return _.optional((function(){e.assert(t,e.shared.isArrayLike+\"(\"+r+\")&&\"+r+\".length===4\",\"blend.color must be a 4d array\")})),V(4,(function(e){return t.def(\"+\",r,\"[\",e,\"]\")}))}));case tr:return f((function(e){return _.commandType(e,\"number\",o,t.commandStr),0|e}),(function(e,t,r){return _.optional((function(){e.assert(t,\"typeof \"+r+'===\"number\"',\"invalid stencil.mask\")})),t.def(r,\"|0\")}));case rr:return f((function(r){_.commandType(r,\"object\",o,t.commandStr);var n=r.cmp||\"keep\",a=r.ref||0,i=\"mask\"in r?r.mask:-1;return _.commandParameter(n,$r,e+\".cmp\",t.commandStr),_.commandType(a,\"number\",e+\".ref\",t.commandStr),_.commandType(i,\"number\",e+\".mask\",t.commandStr),[$r[n],a,i]}),(function(e,t,r){var n=e.constants.compareFuncs;return _.optional((function(){function a(){e.assert(t,Array.prototype.join.call(arguments,\"\"),\"invalid stencil.func\")}a(r+\"&&typeof \",r,'===\"object\"'),a('!(\"cmp\" in ',r,\")||(\",r,\".cmp in \",n,\")\")})),[t.def('\"cmp\" in ',r,\"?\",n,\"[\",r,\".cmp]\",\":\",Qr),t.def(r,\".ref|0\"),t.def('\"mask\" in ',r,\"?\",r,\".mask|0:-1\")]}));case nr:case ar:return f((function(r){_.commandType(r,\"object\",o,t.commandStr);var n=r.fail||\"keep\",a=r.zfail||\"keep\",i=r.zpass||\"keep\";return _.commandParameter(n,Kr,e+\".fail\",t.commandStr),_.commandParameter(a,Kr,e+\".zfail\",t.commandStr),_.commandParameter(i,Kr,e+\".zpass\",t.commandStr),[e===ar?Nr:Hr,Kr[n],Kr[a],Kr[i]]}),(function(t,r,n){var a=t.constants.stencilOps;function i(i){return _.optional((function(){t.assert(r,'!(\"'+i+'\" in '+n+\")||(\"+n+\".\"+i+\" in \"+a+\")\",\"invalid \"+e+\".\"+i+\", must be one of \"+Object.keys(Kr))})),r.def('\"',i,'\" in ',n,\"?\",a,\"[\",n,\".\",i,\"]:\",Qr)}return _.optional((function(){t.assert(r,n+\"&&typeof \"+n+'===\"object\"',\"invalid \"+e)})),[e===ar?Nr:Hr,i(\"fail\"),i(\"zfail\"),i(\"zpass\")]}));case $t:return f((function(e){_.commandType(e,\"object\",o,t.commandStr);var r=0|e.factor,n=0|e.units;return _.commandType(r,\"number\",o+\".factor\",t.commandStr),_.commandType(n,\"number\",o+\".units\",t.commandStr),[r,n]}),(function(t,r,n){return _.optional((function(){t.assert(r,n+\"&&typeof \"+n+'===\"object\"',\"invalid \"+e)})),[r.def(n,\".factor|0\"),r.def(n,\".units|0\")]}));case qt:return f((function(e){var r=0;return\"front\"===e?r=Hr:\"back\"===e&&(r=Nr),_.command(!!r,o,t.commandStr),r}),(function(e,t,r){return _.optional((function(){e.assert(t,r+'===\"front\"||'+r+'===\"back\"',\"invalid cull.face\")})),t.def(r,'===\"front\"?',Hr,\":\",Nr)}));case Yt:return f((function(e){return _.command(\"number\"==typeof e&&e>=a.lineWidthDims[0]&&e<=a.lineWidthDims[1],\"invalid line width, must be a positive number between \"+a.lineWidthDims[0]+\" and \"+a.lineWidthDims[1],t.commandStr),e}),(function(e,t,r){return _.optional((function(){e.assert(t,\"typeof \"+r+'===\"number\"&&'+r+\">=\"+a.lineWidthDims[0]+\"&&\"+r+\"<=\"+a.lineWidthDims[1],\"invalid line width\")})),r}));case Qt:return f((function(e){return _.commandParameter(e,Zr,o,t.commandStr),Zr[e]}),(function(e,t,r){return _.optional((function(){e.assert(t,r+'===\"cw\"||'+r+'===\"ccw\"',\"invalid frontFace, must be one of cw,ccw\")})),t.def(r+'===\"cw\"?2304:'+qr)}));case Ht:return f((function(e){return _.command(me(e)&&4===e.length,\"color.mask must be length 4 array\",t.commandStr),e.map((function(e){return!!e}))}),(function(e,t,r){return _.optional((function(){e.assert(t,e.shared.isArrayLike+\"(\"+r+\")&&\"+r+\".length===4\",\"invalid color.mask\")})),V(4,(function(e){return\"!!\"+r+\"[\"+e+\"]\"}))}));case Zt:return f((function(e){_.command(\"object\"==typeof e&&e,o,t.commandStr);var r=\"value\"in e?e.value:1,n=!!e.invert;return _.command(\"number\"==typeof r&&r>=0&&r<=1,\"sample.coverage.value must be a number between 0 and 1\",t.commandStr),[r,n]}),(function(e,t,r){return _.optional((function(){e.assert(t,r+\"&&typeof \"+r+'===\"object\"',\"invalid sample.coverage\")})),[t.def('\"value\" in ',r,\"?+\",r,\".value:1\"),t.def(\"!!\",r,\".invert\")]}))}})),i}(e,d),S=function(e,t,n){var a=e.static,i=e.dynamic;function o(e){if(e in a){var t=r.id(a[e]);_.optional((function(){l.shader(Jr[e],t,_.guessCommand())}));var n=an((function(){return t}));return n.id=t,n}if(e in i){var o=i[e];return on(o,(function(t,r){var n=t.invoke(r,o),a=r.def(t.shared.strings,\".id(\",n,\")\");return _.optional((function(){r(t.shared.shader,\".shader(\",Jr[e],\",\",a,\",\",t.command,\");\")})),a}))}return null}var f,u=o(lr),s=o(cr),c=null;return nn(u)&&nn(s)?(c=l.program(s.id,u.id,null,n),f=an((function(e,t){return e.link(c)}))):f=new rn(u&&u.thisDep||s&&s.thisDep,u&&u.contextDep||s&&s.contextDep,u&&u.propDep||s&&s.propDep,(function(e,t){var r,n=e.shared.shader;r=u?u.append(e,t):t.def(n,\".\",lr);var a=n+\".program(\"+(s?s.append(e,t):t.def(n,\".\",cr))+\",\"+r;return _.optional((function(){a+=\",\"+e.command})),t.def(a+\")\")})),{frag:u,vert:s,progVar:f,program:c}}(e,0,h);function O(e){var t=x[e];t&&(A[e]=t)}O(fr),O(E(or));var T=Object.keys(A).length>0,D={framebuffer:y,draw:w,shader:S,state:A,dirty:T,scopeVAO:null,drawVAO:null,useVAO:!1,attributes:{}};if(D.profile=function(e){var t,r=e.static,n=e.dynamic;if(ur in r){var a=!!r[ur];(t=an((function(e,t){return a}))).enable=a}else if(ur in n){var i=n[ur];t=on(i,(function(e,t){return e.invoke(t,i)}))}return t}(e),D.uniforms=function(e,t){var r=e.static,n=e.dynamic,a={};return Object.keys(r).forEach((function(e){var n,i=r[e];if(\"number\"==typeof i||\"boolean\"==typeof i)n=an((function(){return i}));else if(\"function\"==typeof i){var o=i._reglType;\"texture2d\"===o||\"textureCube\"===o?n=an((function(e){return e.link(i)})):\"framebuffer\"===o||\"framebufferCube\"===o?(_.command(i.color.length>0,'missing color attachment for framebuffer sent to uniform \"'+e+'\"',t.commandStr),n=an((function(e){return e.link(i.color[0])}))):_.commandRaise('invalid data for uniform \"'+e+'\"',t.commandStr)}else me(i)?n=an((function(t){return t.global.def(\"[\",V(i.length,(function(r){return _.command(\"number\"==typeof i[r]||\"boolean\"==typeof i[r],\"invalid uniform \"+e,t.commandStr),i[r]})),\"]\")})):_.commandRaise('invalid or missing data for uniform \"'+e+'\"',t.commandStr);n.value=i,a[e]=n})),Object.keys(n).forEach((function(e){var t=n[e];a[e]=on(t,(function(e,r){return e.invoke(r,t)}))})),a}(f,d),D.drawVAO=D.scopeVAO=w.vao,!D.drawVAO&&S.program&&!h&&n.angle_instanced_arrays&&w.static.elements){var j=!0,C=S.program.attributes.map((function(e){var r=t.static[e];return j=j&&!!r,r}));if(j&&C.length>0){var z=c.getVAO(c.createVAO({attributes:C,elements:w.static.elements}));D.drawVAO=new rn(null,null,null,(function(e,t){return e.link(z)})),D.useVAO=!0}}return h?D.useVAO=!0:D.attributes=function(e,t){var n=e.static,a=e.dynamic,o={};return Object.keys(n).forEach((function(e){var a=n[e],f=r.id(e),u=new b;if(en(a))u.state=1,u.buffer=i.getBuffer(i.create(a,Sr,!1,!0)),u.type=0;else{var s=i.getBuffer(a);if(s)u.state=1,u.buffer=s,u.type=0;else if(_.command(\"object\"==typeof a&&a,\"invalid data for attribute \"+e,t.commandStr),\"constant\"in a){var c=a.constant;u.buffer=\"null\",u.state=2,\"number\"==typeof c?u.x=c:(_.command(me(c)&&c.length>0&&c.length<=4,\"invalid constant for attribute \"+e,t.commandStr),Bt.forEach((function(e,t){t=0,'invalid offset for attribute \"'+e+'\"',t.commandStr);var d=0|a.stride;_.command(d>=0&&d<256,'invalid stride for attribute \"'+e+'\", must be integer betweeen [0, 255]',t.commandStr);var m=0|a.size;_.command(!(\"size\"in a)||m>0&&m<=4,'invalid size for attribute \"'+e+'\", must be 1,2,3,4',t.commandStr);var p=!!a.normalized,h=0;\"type\"in a&&(_.commandParameter(a.type,X,\"invalid type for attribute \"+e,t.commandStr),h=X[a.type]);var v=0|a.divisor;_.optional((function(){\"divisor\"in a&&(_.command(0===v||g,'cannot specify divisor for attribute \"'+e+'\", instancing not supported',t.commandStr),_.command(v>=0,'invalid divisor for attribute \"'+e+'\"',t.commandStr));var r=t.commandStr,n=[\"buffer\",\"offset\",\"divisor\",\"normalized\",\"type\",\"size\",\"stride\"];Object.keys(a).forEach((function(t){_.command(n.indexOf(t)>=0,'unknown parameter \"'+t+'\" for attribute pointer \"'+e+'\" (valid parameters are '+n+\")\",r)}))})),u.buffer=s,u.state=1,u.size=m,u.normalized=p,u.type=h||s.dtype,u.offset=l,u.stride=d,u.divisor=v}}o[e]=an((function(e,t){var r=e.attribCache;if(f in r)return r[f];var n={isStream:!1};return Object.keys(u).forEach((function(e){n[e]=u[e]})),u.buffer&&(n.buffer=e.link(u.buffer),n.type=n.type||n.buffer+\".dtype\"),r[f]=n,n}))})),Object.keys(a).forEach((function(e){var t=a[e];o[e]=on(t,(function(r,n){var a=r.invoke(n,t),i=r.shared,o=r.constants,f=i.isBufferArgs,u=i.buffer;_.optional((function(){r.assert(n,a+\"&&(typeof \"+a+'===\"object\"||typeof '+a+'===\"function\")&&('+f+\"(\"+a+\")||\"+u+\".getBuffer(\"+a+\")||\"+u+\".getBuffer(\"+a+\".buffer)||\"+f+\"(\"+a+'.buffer)||(\"constant\" in '+a+\"&&(typeof \"+a+'.constant===\"number\"||'+i.isArrayLike+\"(\"+a+\".constant))))\",'invalid dynamic attribute \"'+e+'\"')}));var s={isStream:n.def(!1)},c=new b;c.state=1,Object.keys(c).forEach((function(e){s[e]=n.def(\"\"+c[e])}));var l=s.buffer,d=s.type;function m(e){n(s[e],\"=\",a,\".\",e,\"|0;\")}return n(\"if(\",f,\"(\",a,\")){\",s.isStream,\"=true;\",l,\"=\",u,\".createStream(\",Sr,\",\",a,\");\",d,\"=\",l,\".dtype;\",\"}else{\",l,\"=\",u,\".getBuffer(\",a,\");\",\"if(\",l,\"){\",d,\"=\",l,\".dtype;\",'}else if(\"constant\" in ',a,\"){\",s.state,\"=\",2,\";\",\"if(typeof \"+a+'.constant === \"number\"){',s[Bt[0]],\"=\",a,\".constant;\",Bt.slice(1).map((function(e){return s[e]})).join(\"=\"),\"=0;\",\"}else{\",Bt.map((function(e,t){return s[e]+\"=\"+a+\".constant.length>\"+t+\"?\"+a+\".constant[\"+t+\"]:0;\"})).join(\"\"),\"}}else{\",\"if(\",f,\"(\",a,\".buffer)){\",l,\"=\",u,\".createStream(\",Sr,\",\",a,\".buffer);\",\"}else{\",l,\"=\",u,\".getBuffer(\",a,\".buffer);\",\"}\",d,'=\"type\" in ',a,\"?\",o.glTypes,\"[\",a,\".type]:\",l,\".dtype;\",s.normalized,\"=!!\",a,\".normalized;\"),m(\"size\"),m(\"offset\"),m(\"stride\"),m(\"divisor\"),n(\"}}\"),n.exit(\"if(\",s.isStream,\"){\",u,\".destroyStream(\",l,\");\",\"}\"),s}))})),o}(t,d),D.context=function(e){var t=e.static,r=e.dynamic,n={};return Object.keys(t).forEach((function(e){var r=t[e];n[e]=an((function(e,t){return\"number\"==typeof r||\"boolean\"==typeof r?\"\"+r:e.link(r)}))})),Object.keys(r).forEach((function(e){var t=r[e];n[e]=on(t,(function(e,r){return e.invoke(r,t)}))})),n}(s),D}function P(e,t,r){var n=e.shared.context,a=e.scope();Object.keys(r).forEach((function(i){t.save(n,\".\"+i);var o=r[i].append(e,t);Array.isArray(o)?a(n,\".\",i,\"=[\",o.join(),\"];\"):a(n,\".\",i,\"=\",o,\";\")})),t(a)}function L(e,t,r,n){var a,i=e.shared,o=i.gl,f=i.framebuffer;y&&(a=t.def(i.extensions,\".webgl_draw_buffers\"));var u,s=e.constants,c=s.drawBuffer,l=s.backBuffer;u=r?r.append(e,t):t.def(f,\".next\"),n||t(\"if(\",u,\"!==\",f,\".cur){\"),t(\"if(\",u,\"){\",o,\".bindFramebuffer(\",36160,\",\",u,\".framebuffer);\"),y&&t(a,\".drawBuffersWEBGL(\",c,\"[\",u,\".colorAttachments.length]);\"),t(\"}else{\",o,\".bindFramebuffer(\",36160,\",null);\"),y&&t(a,\".drawBuffersWEBGL(\",l,\");\"),t(\"}\",f,\".cur=\",u,\";\"),n||t(\"}\")}function R(e,t,r){var n=e.shared,a=n.gl,i=e.current,o=e.next,f=n.current,u=n.next,s=e.cond(f,\".dirty\");k.forEach((function(t){var n,c,l=E(t);if(!(l in r.state))if(l in o){n=o[l],c=i[l];var d=V(w[l].length,(function(e){return s.def(n,\"[\",e,\"]\")}));s(e.cond(d.map((function(e,t){return e+\"!==\"+c+\"[\"+t+\"]\"})).join(\"||\")).then(a,\".\",O[l],\"(\",d,\");\",d.map((function(e,t){return c+\"[\"+t+\"]=\"+e})).join(\";\"),\";\"))}else{n=s.def(u,\".\",l);var m=e.cond(n,\"!==\",f,\".\",l);s(m),l in S?m(e.cond(n).then(a,\".enable(\",S[l],\");\").else(a,\".disable(\",S[l],\");\"),f,\".\",l,\"=\",n,\";\"):m(a,\".\",O[l],\"(\",n,\");\",f,\".\",l,\"=\",n,\";\")}})),0===Object.keys(r.state).length&&s(f,\".dirty=false;\"),t(s)}function M(e,t,r,n){var a=e.shared,i=e.current,o=a.current,f=a.gl;tn(Object.keys(r)).forEach((function(a){var u=r[a];if(!n||n(u)){var s=u.append(e,t);if(S[a]){var c=S[a];nn(u)?t(f,s?\".enable(\":\".disable(\",c,\");\"):t(e.cond(s).then(f,\".enable(\",c,\");\").else(f,\".disable(\",c,\");\")),t(o,\".\",a,\"=\",s,\";\")}else if(me(s)){var l=i[a];t(f,\".\",O[a],\"(\",s,\");\",s.map((function(e,t){return l+\"[\"+t+\"]=\"+e})).join(\";\"),\";\")}else t(f,\".\",O[a],\"(\",s,\");\",o,\".\",a,\"=\",s,\";\")}}))}function W(e,t){g&&(e.instancing=t.def(e.shared.extensions,\".angle_instanced_arrays\"))}function U(e,t,r,n,a){var i,o,f,u=e.shared,s=e.stats,c=u.current,l=u.timer,d=r.profile;function m(){return\"undefined\"==typeof performance?\"Date.now()\":\"performance.now()\"}function h(e){e(i=t.def(),\"=\",m(),\";\"),\"string\"==typeof a?e(s,\".count+=\",a,\";\"):e(s,\".count++;\"),p&&(n?e(o=t.def(),\"=\",l,\".getNumPendingQueries();\"):e(l,\".beginQuery(\",s,\");\"))}function b(e){e(s,\".cpuTime+=\",m(),\"-\",i,\";\"),p&&(n?e(l,\".pushScopeStats(\",o,\",\",l,\".getNumPendingQueries(),\",s,\");\"):e(l,\".endQuery();\"))}function v(e){var r=t.def(c,\".profile\");t(c,\".profile=\",e,\";\"),t.exit(c,\".profile=\",r,\";\")}if(d){if(nn(d))return void(d.enable?(h(t),b(t.exit),v(\"true\")):v(\"false\"));v(f=d.append(e,t))}else f=t.def(c,\".profile\");var g=e.block();h(g),t(\"if(\",f,\"){\",g,\"}\");var y=e.block();b(y),t.exit(\"if(\",f,\"){\",y,\"}\")}function G(e,t,r,n,a){var i=e.shared;n.forEach((function(n){var o,f=n.name,u=r.attributes[f];if(u){if(!a(u))return;o=u.append(e,t)}else{if(!a(fn))return;var s=e.scopeAttrib(f);_.optional((function(){e.assert(t,s+\".state\",\"missing attribute \"+f)})),o={},Object.keys(new b).forEach((function(e){o[e]=t.def(s,\".\",e)}))}!function(r,n,a){var o=i.gl,f=t.def(r,\".location\"),u=t.def(i.attributes,\"[\",f,\"]\"),s=a.state,c=a.buffer,l=[a.x,a.y,a.z,a.w],d=[\"buffer\",\"normalized\",\"offset\",\"stride\"];function m(){t(\"if(!\",u,\".buffer){\",o,\".enableVertexAttribArray(\",f,\");}\");var r,i=a.type;if(r=a.size?t.def(a.size,\"||\",n):n,t(\"if(\",u,\".type!==\",i,\"||\",u,\".size!==\",r,\"||\",d.map((function(e){return u+\".\"+e+\"!==\"+a[e]})).join(\"||\"),\"){\",o,\".bindBuffer(\",Sr,\",\",c,\".buffer);\",o,\".vertexAttribPointer(\",[f,r,i,a.normalized,a.stride,a.offset],\");\",u,\".type=\",i,\";\",u,\".size=\",r,\";\",d.map((function(e){return u+\".\"+e+\"=\"+a[e]+\";\"})).join(\"\"),\"}\"),g){var s=a.divisor;t(\"if(\",u,\".divisor!==\",s,\"){\",e.instancing,\".vertexAttribDivisorANGLE(\",[f,s],\");\",u,\".divisor=\",s,\";}\")}}function p(){t(\"if(\",u,\".buffer){\",o,\".disableVertexAttribArray(\",f,\");\",u,\".buffer=null;\",\"}if(\",Bt.map((function(e,t){return u+\".\"+e+\"!==\"+l[t]})).join(\"||\"),\"){\",o,\".vertexAttrib4f(\",f,\",\",l,\");\",Bt.map((function(e,t){return u+\".\"+e+\"=\"+l[t]+\";\"})).join(\"\"),\"}\")}1===s?m():2===s?p():(t(\"if(\",s,\"===\",1,\"){\"),m(),t(\"}else{\"),p(),t(\"}\"))}(e.link(n),function(e){switch(e){case Tr:case zr:case Ir:return 2;case Dr:case Fr:case Pr:return 3;case jr:case Br:case Lr:return 4;default:return 1}}(n.info.type),o)}))}function H(e,t,n,a,i,o){for(var f,u=e.shared,s=u.gl,c={},l=0;l1){if(!b)continue;var v=m.replace(\"[0]\",\"\");if(c[v])continue;c[v]=1}var g,y=e.link(d)+\".location\";if(b){if(!i(b))continue;if(nn(b)){var x=b.value;if(_.command(null!=x,'missing uniform \"'+m+'\"',e.commandStr),p===Ur||p===Gr){_.command(\"function\"==typeof x&&(p===Ur&&(\"texture2d\"===x._reglType||\"framebuffer\"===x._reglType)||p===Gr&&(\"textureCube\"===x._reglType||\"framebufferCube\"===x._reglType)),\"invalid texture for uniform \"+m,e.commandStr);var w=e.link(x._texture||x.color[0]._texture);t(s,\".uniform1i(\",y,\",\",w+\".bind());\"),t.exit(w,\".unbind();\")}else if(p===Rr||p===Mr||p===Wr){_.optional((function(){_.command(me(x),\"invalid matrix for uniform \"+m,e.commandStr),_.command(p===Rr&&4===x.length||p===Mr&&9===x.length||p===Wr&&16===x.length,\"invalid length for matrix uniform \"+m,e.commandStr)}));var A=e.global.def(\"new Float32Array([\"+Array.prototype.slice.call(x)+\"])\"),k=2;p===Mr?k=3:p===Wr&&(k=4),t(s,\".uniformMatrix\",k,\"fv(\",y,\",false,\",A,\");\")}else{switch(p){case Er:1===h?_.commandType(x,\"number\",\"uniform \"+m,e.commandStr):_.command(me(x)&&x.length===h,\"uniform \"+m,e.commandStr),f=\"1f\";break;case Tr:_.command(me(x)&&x.length&&x.length%2==0&&x.length<=2*h,\"uniform \"+m,e.commandStr),f=\"2f\";break;case Dr:_.command(me(x)&&x.length&&x.length%3==0&&x.length<=3*h,\"uniform \"+m,e.commandStr),f=\"3f\";break;case jr:_.command(me(x)&&x.length&&x.length%4==0&&x.length<=4*h,\"uniform \"+m,e.commandStr),f=\"4f\";break;case Vr:1===h?_.commandType(x,\"boolean\",\"uniform \"+m,e.commandStr):_.command(me(x)&&x.length===h,\"uniform \"+m,e.commandStr),f=\"1i\";break;case Cr:1===h?_.commandType(x,\"number\",\"uniform \"+m,e.commandStr):_.command(me(x)&&x.length===h,\"uniform \"+m,e.commandStr),f=\"1i\";break;case Ir:case zr:_.command(me(x)&&x.length&&x.length%2==0&&x.length<=2*h,\"uniform \"+m,e.commandStr),f=\"2i\";break;case Pr:case Fr:_.command(me(x)&&x.length&&x.length%3==0&&x.length<=3*h,\"uniform \"+m,e.commandStr),f=\"3i\";break;case Lr:case Br:_.command(me(x)&&x.length&&x.length%4==0&&x.length<=4*h,\"uniform \"+m,e.commandStr),f=\"4i\"}h>1?(f+=\"v\",x=e.global.def(\"[\"+Array.prototype.slice.call(x)+\"]\")):x=me(x)?Array.prototype.slice.call(x):x,t(s,\".uniform\",f,\"(\",y,\",\",x,\");\")}continue}g=b.append(e,t)}else{if(!i(fn))continue;g=t.def(u.uniforms,\"[\",r.id(m),\"]\")}p===Ur?(_(!Array.isArray(g),\"must specify a scalar prop for textures\"),t(\"if(\",g,\"&&\",g,'._reglType===\"framebuffer\"){',g,\"=\",g,\".color[0];\",\"}\")):p===Gr&&(_(!Array.isArray(g),\"must specify a scalar prop for cube maps\"),t(\"if(\",g,\"&&\",g,'._reglType===\"framebufferCube\"){',g,\"=\",g,\".color[0];\",\"}\")),_.optional((function(){function r(r,n){e.assert(t,r,'bad data or missing for uniform \"'+m+'\". '+n)}function n(e,t){1===t&&_(!Array.isArray(g),\"must not specify an array type for uniform\"),r(\"Array.isArray(\"+g+\") && typeof \"+g+'[0]===\" '+e+'\" || typeof '+g+'===\"'+e+'\"',\"invalid type, expected \"+e)}function a(t,n,a){Array.isArray(g)?_(g.length&&g.length%t==0&&g.length<=t*a,\"must have length of \"+(1===a?\"\":\"n * \")+t):r(u.isArrayLike+\"(\"+g+\")&&\"+g+\".length && \"+g+\".length % \"+t+\" === 0 && \"+g+\".length<=\"+t*a,\"invalid vector, should have length of \"+(1===a?\"\":\"n * \")+t,e.commandStr)}function i(t){_(!Array.isArray(g),\"must not specify a value type\"),r(\"typeof \"+g+'===\"function\"&&'+g+'._reglType===\"texture'+(3553===t?\"2d\":\"Cube\")+'\"',\"invalid texture type\",e.commandStr)}switch(p){case Cr:n(\"number\",h);break;case zr:a(2,0,h);break;case Fr:a(3,0,h);break;case Br:a(4,0,h);break;case Er:n(\"number\",h);break;case Tr:a(2,0,h);break;case Dr:a(3,0,h);break;case jr:a(4,0,h);break;case Vr:n(\"boolean\",h);break;case Ir:a(2,0,h);break;case Pr:a(3,0,h);break;case Lr:case Rr:a(4,0,h);break;case Mr:a(9,0,h);break;case Wr:a(16,0,h);break;case Ur:i(3553);break;case Gr:i(34067)}}));var S=1;switch(p){case Ur:case Gr:var O=t.def(g,\"._texture\");t(s,\".uniform1i(\",y,\",\",O,\".bind());\"),t.exit(O,\".unbind();\");continue;case Cr:case Vr:f=\"1i\";break;case zr:case Ir:f=\"2i\",S=2;break;case Fr:case Pr:f=\"3i\",S=3;break;case Br:case Lr:f=\"4i\",S=4;break;case Er:f=\"1f\";break;case Tr:f=\"2f\",S=2;break;case Dr:f=\"3f\",S=3;break;case jr:f=\"4f\",S=4;break;case Rr:f=\"Matrix2fv\";break;case Mr:f=\"Matrix3fv\";break;case Wr:f=\"Matrix4fv\"}if(-1===f.indexOf(\"Matrix\")&&h>1&&(f+=\"v\",S=1),\"M\"===f.charAt(0)){t(s,\".uniform\",f,\"(\",y,\",\");var E=Math.pow(p-Rr+2,2),T=e.global.def(\"new Float32Array(\",E,\")\");Array.isArray(g)?t(\"false,(\",V(E,(function(e){return T+\"[\"+e+\"]=\"+g[e]})),\",\",T,\")\"):t(\"false,(Array.isArray(\",g,\")||\",g,\" instanceof Float32Array)?\",g,\":(\",V(E,(function(e){return T+\"[\"+e+\"]=\"+g+\"[\"+e+\"]\"})),\",\",T,\")\"),t(\");\")}else if(S>1){for(var D=[],j=[],C=0;C=0\",\"missing vertex count\")}))):(a=u.def(o,\".\",pr),_.optional((function(){e.assert(u,a+\">=0\",\"missing vertex count\")}))),a}();if(\"number\"==typeof p){if(0===p)return}else r(\"if(\",p,\"){\"),r.exit(\"}\");g&&(c=s(br),l=e.instancing);var h=u+\".type\",b=f.elements&&nn(f.elements)&&!f.vaoActive;function v(){function e(){r(l,\".drawElementsInstancedANGLE(\",[d,p,h,m+\"<<((\"+h+\"-5121)>>1)\",c],\");\")}function t(){r(l,\".drawArraysInstancedANGLE(\",[d,m,p,c],\");\")}u&&\"null\"!==u?b?e():(r(\"if(\",u,\"){\"),e(),r(\"}else{\"),t(),r(\"}\")):t()}function y(){function e(){r(i+\".drawElements(\"+[d,p,h,m+\"<<((\"+h+\"-5121)>>1)\"]+\");\")}function t(){r(i+\".drawArrays(\"+[d,m,p]+\");\")}u&&\"null\"!==u?b?e():(r(\"if(\",u,\"){\"),e(),r(\"}else{\"),t(),r(\"}\")):t()}g&&(\"number\"!=typeof c||c>=0)?\"string\"==typeof c?(r(\"if(\",c,\">0){\"),v(),r(\"}else if(\",c,\"<0){\"),y(),r(\"}\")):v():y()}function q(e,t,r,n,a){var i=B(),o=i.proc(\"body\",a);return _.optional((function(){i.commandStr=t.commandStr,i.command=i.link(t.commandStr)})),g&&(i.instancing=o.def(i.shared.extensions,\".angle_instanced_arrays\")),e(i,o,r,n),i.compile().body}function Q(e,t,r,n){W(e,t),r.useVAO?r.drawVAO?t(e.shared.vao,\".setVAO(\",r.drawVAO.append(e,t),\");\"):t(e.shared.vao,\".setVAO(\",e.shared.vao,\".targetVAO);\"):(t(e.shared.vao,\".setVAO(null);\"),G(e,t,r,n.attributes,(function(){return!0}))),H(e,t,r,n.uniforms,(function(){return!0}),!1),N(e,t,t,r)}function Y(e,t,r,n){function a(){return!0}e.batchId=\"a1\",W(e,t),G(e,t,r,n.attributes,a),H(e,t,r,n.uniforms,a,!1),N(e,t,t,r)}function $(e,t,r,n){W(e,t);var a=r.contextDep,i=t.def(),o=t.def();e.shared.props=o,e.batchId=i;var f=e.scope(),u=e.scope();function s(e){return e.contextDep&&a||e.propDep}function c(e){return!s(e)}if(t(f.entry,\"for(\",i,\"=0;\",i,\"<\",\"a1\",\";++\",i,\"){\",o,\"=\",\"a0\",\"[\",i,\"];\",u,\"}\",f.exit),r.needsContext&&P(e,u,r.context),r.needsFramebuffer&&L(e,u,r.framebuffer),M(e,u,r.state,s),r.profile&&s(r.profile)&&U(e,u,r,!1,!0),n)r.useVAO?r.drawVAO?s(r.drawVAO)?u(e.shared.vao,\".setVAO(\",r.drawVAO.append(e,u),\");\"):f(e.shared.vao,\".setVAO(\",r.drawVAO.append(e,f),\");\"):f(e.shared.vao,\".setVAO(\",e.shared.vao,\".targetVAO);\"):(f(e.shared.vao,\".setVAO(null);\"),G(e,f,r,n.attributes,c),G(e,u,r,n.attributes,s)),H(e,f,r,n.uniforms,c,!1),H(e,u,r,n.uniforms,s,!0),N(e,f,u,r);else{var l=e.global.def(\"{}\"),d=r.shader.progVar.append(e,u),m=u.def(d,\".id\"),p=u.def(l,\"[\",m,\"]\");u(e.shared.gl,\".useProgram(\",d,\".program);\",\"if(!\",p,\"){\",p,\"=\",l,\"[\",m,\"]=\",e.link((function(t){return q(Y,e,r,t,2)})),\"(\",d,\");}\",p,\".call(this,a0[\",i,\"],\",i,\");\")}}function K(e,t,r){var n=t.static[r];if(n&&function(e){if(\"object\"==typeof e&&!me(e)){for(var t=Object.keys(e),r=0;r0&&r(e.shared.current,\".dirty=true;\"),e.shared.vao&&r(e.shared.vao,\".setVAO(null);\")}(f,u),function(e,t){var n=e.proc(\"scope\",3);e.batchId=\"a2\";var a=e.shared,i=a.current;function o(r){var i=t.shader[r];i&&n.set(a.shader,\".\"+r,i.append(e,n))}P(e,n,t.context),t.framebuffer&&t.framebuffer.append(e,n),tn(Object.keys(t.state)).forEach((function(r){var i=t.state[r].append(e,n);me(i)?i.forEach((function(t,a){n.set(e.next[r],\"[\"+a+\"]\",t)})):n.set(a.next,\".\"+r,i)})),U(e,n,t,!0,!0),[dr,hr,pr,br,mr].forEach((function(r){var i=t.draw[r];i&&n.set(a.draw,\".\"+r,\"\"+i.append(e,n))})),Object.keys(t.uniforms).forEach((function(i){var o=t.uniforms[i].append(e,n);Array.isArray(o)&&(o=\"[\"+o.join()+\"]\"),n.set(a.uniforms,\"[\"+r.id(i)+\"]\",o)})),Object.keys(t.attributes).forEach((function(r){var a=t.attributes[r].append(e,n),i=e.scopeAttrib(r);Object.keys(new b).forEach((function(e){n.set(i,\".\"+e,a[e])}))})),t.scopeVAO&&n.set(a.vao,\".targetVAO\",t.scopeVAO.append(e,n)),o(cr),o(lr),Object.keys(t.state).length>0&&(n(i,\".dirty=true;\"),n.exit(i,\".dirty=true;\")),n(\"a1(\",e.shared.context,\",a0,\",e.batchId,\");\")}(f,u),function(e,t){var r=e.proc(\"batch\",2);e.batchId=\"0\",W(e,r);var n=!1,a=!0;Object.keys(t.context).forEach((function(e){n=n||t.context[e].propDep})),n||(P(e,r,t.context),a=!1);var i=t.framebuffer,o=!1;function f(e){return e.contextDep&&n||e.propDep}i?(i.propDep?n=o=!0:i.contextDep&&n&&(o=!0),o||L(e,r,i)):L(e,r,null),t.state.viewport&&t.state.viewport.propDep&&(n=!0),R(e,r,t),M(e,r,t.state,(function(e){return!f(e)})),t.profile&&f(t.profile)||U(e,r,t,!1,\"a1\"),t.contextDep=n,t.needsContext=a,t.needsFramebuffer=o;var u=t.shader.progVar;if(u.contextDep&&n||u.propDep)$(e,r,t,null);else{var s=u.append(e,r);if(r(e.shared.gl,\".useProgram(\",s,\".program);\"),t.shader.program)$(e,r,t,t.shader.program);else{r(e.shared.vao,\".setVAO(null);\");var c=e.global.def(\"{}\"),l=r.def(s,\".id\"),d=r.def(c,\"[\",l,\"]\");r(e.cond(d).then(d,\".call(this,a0,a1);\").else(d,\"=\",c,\"[\",l,\"]=\",e.link((function(r){return q($,e,t,r,2)})),\"(\",s,\");\",d,\".call(this,a0,a1);\"))}}Object.keys(t.state).length>0&&r(e.shared.current,\".dirty=true;\"),e.shared.vao&&r(e.shared.vao,\".setVAO(null);\")}(f,u),t(f.compile(),{destroy:function(){u.shader.program.destroy()}})}}}var sn=function(e,t){if(!t.ext_disjoint_timer_query)return null;var r=[];function n(e){r.push(e)}var a=[];function i(){this.startQueryIndex=-1,this.endQueryIndex=-1,this.sum=0,this.stats=null}var o=[];function f(e){o.push(e)}var u=[];function s(e,t,r){var n=o.pop()||new i;n.startQueryIndex=e,n.endQueryIndex=t,n.sum=0,n.stats=r,u.push(n)}var c=[],l=[];return{beginQuery:function(e){var n=r.pop()||t.ext_disjoint_timer_query.createQueryEXT();t.ext_disjoint_timer_query.beginQueryEXT(35007,n),a.push(n),s(a.length-1,a.length,e)},endQuery:function(){t.ext_disjoint_timer_query.endQueryEXT(35007)},pushScopeStats:s,update:function(){var e,r,i=a.length;if(0!==i){l.length=Math.max(l.length,i+1),c.length=Math.max(c.length,i+1),c[0]=0,l[0]=0;var o=0;for(e=0,r=0;r0)if(Array.isArray(r[0])){f=J(r);for(var c=1,l=1;l0)if(\"number\"==typeof t[0]){var i=L.allocType(d.dtype,t.length);ne(i,t),p(i,a),L.freeType(i)}else if(Array.isArray(t[0])||e(t[0])){n=J(t);var o=K(t,n,d.dtype);p(o,a),L.freeType(o)}else _.raise(\"invalid buffer data\")}else if(G(t)){n=t.shape;var f=t.stride,u=0,s=0,c=0,l=0;1===n.length?(u=n[0],s=1,c=f[0],l=0):2===n.length?(u=n[0],s=n[1],c=f[0],l=f[1]):_.raise(\"invalid shape\");var h=Array.isArray(t.data)?d.dtype:re(t.data),b=L.allocType(h,u*s);ae(b,t.data,u,s,c,l,t.offset),p(b,a),L.freeType(b)}else _.raise(\"invalid data for buffer subdata\");return m},n.profile&&(m.stats=d.stats),m.destroy=function(){l(d)},m},createStream:function(e,t){var r=u.pop();return r||(r=new f(e)),r.bind(),c(r,t,35040,0,1,!1),r},destroyStream:function(e){u.push(e)},clear:function(){H(o).forEach(l),u.forEach(l)},getBuffer:function(e){return e&&e._buffer instanceof f?e._buffer:null},restore:function(){H(o).forEach((function(e){e.buffer=t.createBuffer(),t.bindBuffer(e.type,e.buffer),t.bufferData(e.type,e.persistentData||e.byteLength,e.usage)}))},_initBuffer:c}}(a,l,n,(function(e){return A.destroyBuffer(e)})),w=function(t,r,n,a){var i={},o=0,f={uint8:oe,uint16:fe};function u(e){this.id=o++,i[this.id]=this,this.buffer=e,this.primType=4,this.vertCount=0,this.type=0}r.oes_element_index_uint&&(f.uint32=ue),u.prototype.bind=function(){this.buffer.bind()};var s=[];function c(a,i,o,f,u,s,c){var l;if(a.buffer.bind(),i){var d=c;c||e(i)&&(!G(i)||e(i.data))||(d=r.oes_element_index_uint?ue:fe),n._initBuffer(a.buffer,i,o,d,3)}else t.bufferData(se,s,o),a.buffer.dtype=l||oe,a.buffer.usage=o,a.buffer.dimension=3,a.buffer.byteLength=s;if(l=c,!c){switch(a.buffer.dtype){case oe:case 5120:l=oe;break;case fe:case 5122:l=fe;break;case ue:case 5124:l=ue;break;default:_.raise(\"unsupported type for element array\")}a.buffer.dtype=l}a.type=l,_(l!==ue||!!r.oes_element_index_uint,\"32 bit element buffers not supported, enable oes_element_index_uint first\");var m=u;m<0&&(m=a.buffer.byteLength,l===fe?m>>=1:l===ue&&(m>>=2)),a.vertCount=m;var p=f;if(f<0){p=4;var h=a.buffer.dimension;1===h&&(p=0),2===h&&(p=1),3===h&&(p=4)}a.primType=p}function l(e){a.elementsCount--,_(null!==e.buffer,\"must not double destroy elements\"),delete i[e.id],e.buffer.destroy(),e.buffer=null}return{create:function(t,r){var i=n.create(null,se,!0),o=new u(i._buffer);function s(t){if(t)if(\"number\"==typeof t)i(t),o.primType=4,o.vertCount=0|t,o.type=oe;else{var r=null,n=35044,a=-1,u=-1,l=0,d=0;Array.isArray(t)||e(t)||G(t)?r=t:(_.type(t,\"object\",\"invalid arguments for elements\"),\"data\"in t&&(r=t.data,_(Array.isArray(r)||e(r)||G(r),\"invalid data for element buffer\")),\"usage\"in t&&(_.parameter(t.usage,$,\"invalid element buffer usage\"),n=$[t.usage]),\"primitive\"in t&&(_.parameter(t.primitive,ie,\"invalid element buffer primitive\"),a=ie[t.primitive]),\"count\"in t&&(_(\"number\"==typeof t.count&&t.count>=0,\"invalid vertex count for elements\"),u=0|t.count),\"type\"in t&&(_.parameter(t.type,f,\"invalid buffer type\"),d=f[t.type]),\"length\"in t?l=0|t.length:(l=u,d===fe||5122===d?l*=2:d!==ue&&5124!==d||(l*=4))),c(o,r,n,a,u,l,d)}else i(),o.primType=4,o.vertCount=0,o.type=oe;return s}return a.elementsCount++,s(t),s._reglType=\"elements\",s._elements=o,s.subdata=function(e,t){return i.subdata(e,t),s},s.destroy=function(){l(o)},s},createStream:function(e){var t=s.pop();return t||(t=new u(n.create(null,se,!0,!1)._buffer)),c(t,e,35040,-1,-1,0,0),t},destroyStream:function(e){s.push(e)},getElements:function(e){return\"function\"==typeof e&&e._elements instanceof u?e._elements:null},clear:function(){H(i).forEach(l)}}}(a,d,x,l),A=function(t,r,n,a,i,o,f){for(var u=n.maxAttributes,s=new Array(u),c=0;c{for(var e=Object.keys(t),r=0;r=0,'invalid option for vao: \"'+e[r]+'\" valid options are '+Et)})),_(Array.isArray(a),\"attributes must be an array\")}_(a.length0,\"must specify at least one attribute\");var c={},l=n.attributes;l.length=a.length;for(var d=0;d=b.byteLength?m.subdata(b):(m.destroy(),n.buffers[d]=null)),n.buffers[d]||(m=n.buffers[d]=i.create(p,34962,!1,!0)),h.buffer=i.getBuffer(m),h.size=0|h.buffer.dimension,h.normalized=!1,h.type=h.buffer.dtype,h.offset=0,h.stride=0,h.divisor=0,h.state=1,c[d]=1):i.getBuffer(p)?(h.buffer=i.getBuffer(p),h.size=0|h.buffer.dimension,h.normalized=!1,h.type=h.buffer.dtype,h.offset=0,h.stride=0,h.divisor=0,h.state=1):i.getBuffer(p.buffer)?(h.buffer=i.getBuffer(p.buffer),h.size=0|(+p.size||h.buffer.dimension),h.normalized=!!p.normalized||!1,\"type\"in p?(_.parameter(p.type,X,\"invalid buffer type\"),h.type=X[p.type]):h.type=h.buffer.dtype,h.offset=0|(p.offset||0),h.stride=0|(p.stride||0),h.divisor=0|(p.divisor||0),h.state=1,_(h.size>=1&&h.size<=4,\"size must be between 1 and 4\"),_(h.offset>=0,\"invalid offset\"),_(h.stride>=0&&h.stride<=255,\"stride must be between 0 and 255\"),_(h.divisor>=0,\"divisor must be positive\"),_(!h.divisor||!!r.angle_instanced_arrays,\"ANGLE_instanced_arrays must be enabled to use divisor\")):\"x\"in p?(_(d>0,\"first attribute must not be a constant\"),h.x=+p.x||0,h.y=+p.y||0,h.z=+p.z||0,h.w=+p.w||0,h.state=2):_(!1,\"invalid attribute spec for location \"+d)}for(var v=0;v1)for(var v=0;v1&&(y=y.replace(\"[0]\",\"\")),u(b,new f(y,r.id(y),e.getUniformLocation(m,y),c))}var x=e.getProgramParameter(m,35721);a.profile&&(t.stats.attributesCount=x);var w=t.attributes;for(o=0;oe&&(e=t.stats.uniformsCount)})),e},n.getMaxAttributesCount=function(){var e=0;return l.forEach((function(t){t.stats.attributesCount>e&&(e=t.stats.attributesCount)})),e}),{clear:function(){var t=e.deleteShader.bind(e);H(i).forEach(t),i={},H(o).forEach(t),o={},l.forEach((function(t){e.deleteProgram(t.program)})),l.length=0,c={},n.shaderCount=0},program:function(r,a,f,u){_.command(r>=0,\"missing vertex shader\",f),_.command(a>=0,\"missing fragment shader\",f);var s=c[a];s||(s=c[a]={});var d=s[r];if(d&&(d.refCount++,!u))return d;var h=new m(a,r);return n.shaderCount++,p(h,f,u),d||(s[r]=h),l.push(h),t(h,{destroy:function(){if(h.refCount--,h.refCount<=0){e.deleteProgram(h.program);var t=l.indexOf(h);l.splice(t,1),n.shaderCount--}s[h.vertId].refCount<=0&&(e.deleteShader(o[h.vertId]),delete o[h.vertId],delete c[h.fragId][h.vertId]),Object.keys(c[h.fragId]).length||(e.deleteShader(i[h.fragId]),delete i[h.fragId],delete c[h.fragId])}})},restore:function(){i={},o={};for(var e=0;e=2,\"invalid renderbuffer shape\"),f=0|m[0],u=0|m[1]}else\"radius\"in d&&(f=u=0|d.radius),\"width\"in d&&(f=0|d.width),\"height\"in d&&(u=0|d.height);\"format\"in d&&(_.parameter(d.format,i,\"invalid renderbuffer format\"),s=i[d.format])}else\"number\"==typeof t?(f=0|t,u=\"number\"==typeof n?0|n:f):t?_.raise(\"invalid arguments to renderbuffer constructor\"):f=u=1;if(_(f>0&&u>0&&f<=r.maxRenderbufferSize&&u<=r.maxRenderbufferSize,\"invalid renderbuffer size\"),f!==c.width||u!==c.height||s!==c.format)return l.width=c.width=f,l.height=c.height=u,c.format=s,e.bindRenderbuffer(mt,c.renderbuffer),e.renderbufferStorage(mt,s,f,u),_(0===e.getError(),\"invalid render buffer format\"),a.profile&&(c.stats.size=bt(c.format,c.width,c.height)),l.format=o[c.format],l}return u[c.id]=c,n.renderbufferCount++,l(t,f),l.resize=function(t,n){var i=0|t,o=0|n||i;return i===c.width&&o===c.height||(_(i>0&&o>0&&i<=r.maxRenderbufferSize&&o<=r.maxRenderbufferSize,\"invalid renderbuffer size\"),l.width=c.width=i,l.height=c.height=o,e.bindRenderbuffer(mt,c.renderbuffer),e.renderbufferStorage(mt,c.format,i,o),_(0===e.getError(),\"invalid render buffer format\"),a.profile&&(c.stats.size=bt(c.format,c.width,c.height))),l},l._reglType=\"renderbuffer\",l._renderbuffer=c,a.profile&&(l.stats=c.stats),l.destroy=function(){c.decRef()},l},clear:function(){H(u).forEach(c)},restore:function(){H(u).forEach((function(t){t.renderbuffer=e.createRenderbuffer(),e.bindRenderbuffer(mt,t.renderbuffer),e.renderbufferStorage(mt,t.format,t.width,t.height)})),e.bindRenderbuffer(mt,null)}}}(a,d,y,l,n),E=function(e,r,n,a,i,o){var f={cur:null,next:null,dirty:!1,setFBO:null},u=[\"rgba\"],s=[\"rgba4\",\"rgb565\",\"rgb5 a1\"];r.ext_srgb&&s.push(\"srgba\"),r.ext_color_buffer_half_float&&s.push(\"rgba16f\",\"rgb16f\"),r.webgl_color_buffer_float&&s.push(\"rgba32f\");var c=[\"uint8\"];function l(e,t,r){this.target=e,this.texture=t,this.renderbuffer=r;var n=0,a=0;t?(n=t.width,a=t.height):r&&(n=r.width,a=r.height),this.width=n,this.height=a}function d(e){e&&(e.texture&&e.texture._texture.decRef(),e.renderbuffer&&e.renderbuffer._renderbuffer.decRef())}function m(e,t,r){if(e)if(e.texture){var n=e.texture._texture,a=Math.max(1,n.width),i=Math.max(1,n.height);_(a===t&&i===r,\"inconsistent width/height for supplied texture\"),n.refCount+=1}else{var o=e.renderbuffer._renderbuffer;_(o.width===t&&o.height===r,\"inconsistent width/height for renderbuffer\"),o.refCount+=1}}function p(t,r){r&&(r.texture?e.framebufferTexture2D(vt,t,r.target,r.texture._texture.texture,0):e.framebufferRenderbuffer(vt,t,gt,r.renderbuffer._renderbuffer.renderbuffer))}function h(e){var t=yt,r=null,n=null,a=e;\"object\"==typeof e&&(a=e.data,\"target\"in e&&(t=0|e.target)),_.type(a,\"function\",\"invalid attachment data\");var i=a._reglType;return\"texture2d\"===i?(r=a,_(t===yt)):\"textureCube\"===i?(r=a,_(t>=xt&&t<34075,\"invalid cube map target\")):\"renderbuffer\"===i?(n=a,t=gt):_.raise(\"invalid regl object for attachment\"),new l(t,r,n)}function b(e,t,r,n,o){if(r){var f=a.create2D({width:e,height:t,format:n,type:o});return f._texture.refCount=0,new l(yt,f,null)}var u=i.create({width:e,height:t,format:n});return u._renderbuffer.refCount=0,new l(gt,null,u)}function v(e){return e&&(e.texture||e.renderbuffer)}function g(e,t,r){e&&(e.texture?e.texture.resize(t,r):e.renderbuffer&&e.renderbuffer.resize(t,r),e.width=t,e.height=r)}r.oes_texture_half_float&&c.push(\"half float\",\"float16\"),r.oes_texture_float&&c.push(\"float\",\"float32\");var y=0,x={};function w(){this.id=y++,x[this.id]=this,this.framebuffer=e.createFramebuffer(),this.width=0,this.height=0,this.colorAttachments=[],this.depthAttachment=null,this.stencilAttachment=null,this.depthStencilAttachment=null}function A(e){e.colorAttachments.forEach(d),d(e.depthAttachment),d(e.stencilAttachment),d(e.depthStencilAttachment)}function k(t){var r=t.framebuffer;_(r,\"must not double destroy framebuffer\"),e.deleteFramebuffer(r),t.framebuffer=null,o.framebufferCount--,delete x[t.id]}function S(t){var r;e.bindFramebuffer(vt,t.framebuffer);var a=t.colorAttachments;for(r=0;r=2,\"invalid shape for framebuffer\"),o=z[0],d=z[1]}else\"radius\"in C&&(o=d=C.radius),\"width\"in C&&(o=C.width),\"height\"in C&&(d=C.height);(\"color\"in C||\"colors\"in C)&&(y=C.color||C.colors,Array.isArray(y)&&_(1===y.length||r.webgl_draw_buffers,\"multiple render targets not supported\")),y||(\"colorCount\"in C&&(O=0|C.colorCount,_(O>0,\"invalid color buffer count\")),\"colorTexture\"in C&&(x=!!C.colorTexture,w=\"rgba4\"),\"colorType\"in C&&(k=C.colorType,x?(_(r.oes_texture_float||!(\"float\"===k||\"float32\"===k),\"you must enable OES_texture_float in order to use floating point framebuffer objects\"),_(r.oes_texture_half_float||!(\"half float\"===k||\"float16\"===k),\"you must enable OES_texture_half_float in order to use 16-bit floating point framebuffer objects\")):\"half float\"===k||\"float16\"===k?(_(r.ext_color_buffer_half_float,\"you must enable EXT_color_buffer_half_float to use 16-bit render buffers\"),w=\"rgba16f\"):\"float\"!==k&&\"float32\"!==k||(_(r.webgl_color_buffer_float,\"you must enable WEBGL_color_buffer_float in order to use 32-bit floating point renderbuffers\"),w=\"rgba32f\"),_.oneOf(k,c,\"invalid color type\")),\"colorFormat\"in C&&(w=C.colorFormat,u.indexOf(w)>=0?x=!0:s.indexOf(w)>=0?x=!1:_.optional((function(){x?_.oneOf(C.colorFormat,u,\"invalid color format for texture\"):_.oneOf(C.colorFormat,s,\"invalid color format for renderbuffer\")})))),(\"depthTexture\"in C||\"depthStencilTexture\"in C)&&(j=!(!C.depthTexture&&!C.depthStencilTexture),_(!j||r.webgl_depth_texture,\"webgl_depth_texture extension not supported\")),\"depth\"in C&&(\"boolean\"==typeof C.depth?p=C.depth:(E=C.depth,g=!1)),\"stencil\"in C&&(\"boolean\"==typeof C.stencil?g=C.stencil:(T=C.stencil,p=!1)),\"depthStencil\"in C&&(\"boolean\"==typeof C.depthStencil?p=g=C.depthStencil:(D=C.depthStencil,p=!1,g=!1))}else o=d=1;var F=null,B=null,V=null,I=null;if(Array.isArray(y))F=y.map(h);else if(y)F=[h(y)];else for(F=new Array(O),a=0;a=0||F[a].renderbuffer&&kt.indexOf(F[a].renderbuffer._renderbuffer.format)>=0,\"framebuffer color attachment \"+a+\" is invalid\"),F[a]&&F[a].texture){var L=At[F[a].texture._texture.format]*_t[F[a].texture._texture.type];null===P?P=L:_(P===L,\"all color attachments much have the same number of bits per pixel.\")}return m(B,o,d),_(!B||B.texture&&6402===B.texture._texture.format||B.renderbuffer&&33189===B.renderbuffer._renderbuffer.format,\"invalid depth attachment for framebuffer object\"),m(V,o,d),_(!V||V.renderbuffer&&36168===V.renderbuffer._renderbuffer.format,\"invalid stencil attachment for framebuffer object\"),m(I,o,d),_(!I||I.texture&&34041===I.texture._texture.format||I.renderbuffer&&34041===I.renderbuffer._renderbuffer.format,\"invalid depth-stencil attachment for framebuffer object\"),A(i),i.width=o,i.height=d,i.colorAttachments=F,i.depthAttachment=B,i.stencilAttachment=V,i.depthStencilAttachment=I,l.color=F.map(v),l.depth=v(B),l.stencil=v(V),l.depthStencil=v(I),l.width=i.width,l.height=i.height,S(i),l}return o.framebufferCount++,l(e,a),t(l,{resize:function(e,t){_(f.next!==i,\"can not resize a framebuffer which is currently in use\");var r=Math.max(0|e,1),n=Math.max(0|t||r,1);if(r===i.width&&n===i.height)return l;for(var a=i.colorAttachments,o=0;o=2,\"invalid shape for framebuffer\"),_(g[0]===g[1],\"cube framebuffer must be square\"),d=g[0]}else\"radius\"in v&&(d=0|v.radius),\"width\"in v?(d=0|v.width,\"height\"in v&&_(v.height===d,\"must be square\")):\"height\"in v&&(d=0|v.height);(\"color\"in v||\"colors\"in v)&&(m=v.color||v.colors,Array.isArray(m)&&_(1===m.length||r.webgl_draw_buffers,\"multiple render targets not supported\")),m||(\"colorCount\"in v&&(b=0|v.colorCount,_(b>0,\"invalid color buffer count\")),\"colorType\"in v&&(_.oneOf(v.colorType,c,\"invalid color type\"),h=v.colorType),\"colorFormat\"in v&&(p=v.colorFormat,_.oneOf(v.colorFormat,u,\"invalid color format for texture\"))),\"depth\"in v&&(l.depth=v.depth),\"stencil\"in v&&(l.stencil=v.stencil),\"depthStencil\"in v&&(l.depthStencil=v.depthStencil)}else d=1;if(m)if(Array.isArray(m))for(s=[],n=0;n0&&(l.depth=i[0].depth,l.stencil=i[0].stencil,l.depthStencil=i[0].depthStencil),i[n]?i[n](l):i[n]=O(l)}return t(o,{width:d,height:d,color:s})}return o(e),t(o,{faces:i,resize:function(e){var t,r=0|e;if(_(r>0&&r<=n.maxCubeMapSize,\"invalid radius for cube fbo\"),r===o.width)return o;var a=o.color;for(t=0;t=0;--e){var t=I[e];t&&t(v,null,0)}a.flush(),m&&m.update()}function ce(){!Q&&I.length>0&&(Q=j.next(Y))}function le(){Q&&(j.cancel(Y),Q=null)}function de(e){e.preventDefault(),o=!0,le(),P.forEach((function(e){e()}))}function me(e){a.getError(),o=!1,f.restore(),k.restore(),x.restore(),S.restore(),O.restore(),E.restore(),A.restore(),m&&m.restore(),T.procs.refresh(),ce(),N.forEach((function(e){e()}))}function pe(e){function r(e,t){var r={},n={};return Object.keys(e).forEach((function(a){var i=e[a];if(D.isDynamic(i))n[a]=D.unbox(i,a);else{if(t&&Array.isArray(i))for(var o=0;o0)return l.call(this,function(e){for(;m.length=0,\"cannot cancel a frame twice\"),I[t]=function e(){var t=dn(I,e);I[t]=I[I.length-1],I.length-=1,I.length<=0&&le()}}}}function ge(){var e=F.viewport,t=F.scissor_box;e[0]=e[1]=t[0]=t[1]=0,v.viewportWidth=v.framebufferWidth=v.drawingBufferWidth=e[2]=t[2]=a.drawingBufferWidth,v.viewportHeight=v.framebufferHeight=v.drawingBufferHeight=e[3]=t[3]=a.drawingBufferHeight}function ye(){v.tick+=1,v.time=we(),ge(),T.procs.poll()}function xe(){S.refresh(),ge(),T.procs.refresh(),m&&m.update()}function we(){return(C()-p)/1e3}xe();var Ae=t(pe,{clear:function(e){if(_(\"object\"==typeof e&&e,\"regl.clear() takes an object as input\"),\"framebuffer\"in e)if(e.framebuffer&&\"framebufferCube\"===e.framebuffer_reglType)for(var r=0;r<6;++r)he(t({framebuffer:e.framebuffer.faces[r]},e),be);else he(e,be);else be(0,e)},prop:D.define.bind(null,1),context:D.define.bind(null,2),this:D.define.bind(null,3),draw:pe({}),buffer:function(e){return x.create(e,34962,!1,!1)},elements:function(e){return w.create(e,!1)},texture:S.create2D,cube:S.createCube,renderbuffer:O.create,framebuffer:E.create,framebufferCube:E.createCube,vao:A.createVAO,attributes:i,frame:ve,on:function(e,t){var r;switch(_.type(t,\"function\",\"listener callback must be a function\"),e){case\"frame\":return ve(t);case\"lost\":r=P;break;case\"restore\":r=N;break;case\"destroy\":r=q;break;default:_.raise(\"invalid event, must be one of frame,lost,restore,destroy\")}return r.push(t),{cancel:function(){for(var e=0;e=0},read:z,destroy:function(){I.length=0,le(),V&&(V.removeEventListener(cn,de),V.removeEventListener(ln,me)),k.clear(),E.clear(),O.clear(),A.clear(),S.clear(),w.clear(),x.clear(),m&&m.clear(),q.forEach((function(e){e()}))},_gl:a,_refresh:xe,poll:function(){ye(),m&&m.update()},now:we,stats:l});return n.onDone(null,Ae),Ae}},\"object\"==typeof r&&void 0!==t?t.exports=o():\"function\"==typeof define&&define.amd?define(o):i.createREGL=o()},\n", - " 413: function _(t,e,s,a,r){a();const n=t(414),_=t(12);class o{constructor(t){this._regl=t,this._map=new Map}_create_texture(t){const e=t.length;let s=0;const a=[];let r=0,_=0;for(let n=0;nc[f+1]&&f++;const a=t[f],n=c[f]+.5*a;let o=.5*a-Math.abs(s-n);f%2==1&&(o=-o),m[e]=Math.round(255*(o-r)/(_-r))}return[[s,u,r,_],this._regl.texture({shape:[l,1,1],data:m,wrapS:\"repeat\",format:\"alpha\",type:\"uint8\",mag:\"linear\",min:\"linear\"})]}_get_key(t){return t.join(\",\")}_get_or_create(t){const e=this._get_key(t);let s=this._map.get(e);if(null==s){const a=(0,n.gcd)(t);if(a>1){t=(0,_.map)(t,(t=>t/a)),s=this._get_or_create(t);const[r,n,o]=s;s=[r,n,a],this._map.set(e,s)}else{const[r,n]=this._create_texture(t);s=[r,n,a],this._map.set(e,s)}}return s}get(t){return t.length%2==1&&(t=t.slice(0,-1)),this._get_or_create(t)}}s.DashCache=o,o.__name__=\"DashCache\"},\n", + " 413: function _(t,e,a,s,r){s();const n=t(414),_=t(9),o=t(12);class c{constructor(t){this._regl=t,this._map=new Map}_create_texture(t){const e=t.length;let a=0;const s=[];let r=0,_=0;for(let n=0;nc[f+1]&&f++;const s=t[f],n=c[f]+.5*s;let o=.5*s-Math.abs(a-n);f%2==1&&(o=-o),m[e]=Math.round(255*(o-r)/(_-r))}return[[a,u,r,_],this._regl.texture({shape:[l,1,1],data:m,wrapS:\"repeat\",format:\"alpha\",type:\"uint8\",mag:\"linear\",min:\"linear\"})]}_get_key(t){return t.join(\",\")}_get_or_create(t){const e=this._get_key(t);let a=this._map.get(e);if(null==a){const s=(0,n.gcd)(t);if(s>1){t=(0,o.map)(t,(t=>t/s)),a=this._get_or_create(t);const[r,n,_]=a;a=[r,n,s],this._map.set(e,a)}else{const[r,n]=this._create_texture(t);a=[r,n,s],this._map.set(e,a)}}return a}get(t){return t.length%2==1&&(t=(0,_.concat)([t,t])),this._get_or_create(t)}}a.DashCache=c,c.__name__=\"DashCache\"},\n", " 414: function _(n,t,e,r,o){function u(n,t){let e,r;n>t?(e=n,r=t):(e=t,r=n);let o=e%r;for(;0!=o;)e=r,r=o,o=e%r;return r}r(),e.gcd=function(n){let t=n[0];for(let e=1;e u_miter_limit);\\n miter_too_large_end = (miter_factor_end > u_miter_limit);\\n }\\n\\n float sign_at_start = -sign(a_position.x); // +ve at segment start, -ve end.\\n vec2 point = sign_at_start > 0.0 ? a_point_start : a_point_end;\\n vec2 adjacent_point =\\n sign_at_start > 0.0 ? (has_start_cap ? a_point_start : a_point_prev)\\n : (has_end_cap ? a_point_end : a_point_next);\\n\\n if ( (has_start_cap && sign_at_start > 0.0) ||\\n (has_end_cap && sign_at_start < 0.0) ) {\\n // Cap.\\n xy = point - segment_right*(halfwidth*a_position.y);\\n if (cap_type == butt_cap)\\n xy -= sign_at_start*0.5*u_antialias*segment_along;\\n else\\n xy -= sign_at_start*halfwidth*segment_along;\\n }\\n else { // Join.\\n // +ve if turning to right, -ve if to left.\\n float turn_sign = sign_at_start > 0.0 ? turn_right_start : turn_right_end;\\n\\n vec2 adjacent_right = sign_at_start*normalize(right_vector(point - adjacent_point));\\n vec2 point_right = normalize(segment_right + adjacent_right);\\n float miter_factor = sign_at_start > 0.0 ? miter_factor_start : miter_factor_end;\\n bool miter_too_large = sign_at_start > 0.0 ? miter_too_large_start : miter_too_large_end;\\n\\n if (abs(a_position.x) > 1.5) {\\n // Outer point, meets prev/next segment.\\n float factor; // multiplied by halfwidth...\\n\\n if (join_type == bevel_join || (join_type == miter_join && miter_too_large))\\n factor = 1.0 / miter_factor; // cos_theta.\\n else if (join_type == round_join &&\\n miter_factor > min_miter_factor_round_join_mesh)\\n factor = 1.0;\\n else // miter, or round (small angle only).\\n factor = miter_factor;\\n\\n xy = point - point_right*(halfwidth*turn_sign*factor);\\n v_coords.y = turn_sign*halfwidth*factor / miter_factor;\\n }\\n else if (turn_sign*a_position.y < 0.0) {\\n // Inner point, meets prev/next segment.\\n float len = halfwidth*miter_factor;\\n float segment_len = v_segment_length;\\n float adjacent_len = distance(point, adjacent_point);\\n\\n if (len <= min(segment_len, adjacent_len))\\n // Normal behaviour.\\n xy = point - point_right*(len*a_position.y);\\n else\\n // For short wide line segments the inner point using the above\\n // calculation can be outside of the line. Here clipping it.\\n xy = point + segment_right*(halfwidth*turn_sign);\\n }\\n else {\\n // Point along outside edge.\\n xy = point - segment_right*(halfwidth*a_position.y);\\n if (join_type == round_join &&\\n miter_factor > min_miter_factor_round_join_mesh) {\\n xy = line_intersection(xy, segment_along,\\n point - turn_sign*point_right*halfwidth,\\n right_vector(point_right));\\n }\\n }\\n }\\n\\n vec2 pos = xy + 0.5; // Bokeh's offset.\\n pos /= u_canvas_size / u_pixel_ratio; // in 0..1\\n gl_Position = vec4(2.0*pos.x - 1.0, 1.0 - 2.0*pos.y, 0.0, 1.0);\\n\\n v_coords.x = dot(xy - a_point_start, segment_along);\\n v_flags = float(int(has_start_cap) +\\n 2*int(has_end_cap) +\\n 4*int(miter_too_large_start) +\\n 8*int(miter_too_large_end));\\n v_cos_theta_turn_right_start = cos_theta_start*turn_right_start;\\n v_cos_theta_turn_right_end = cos_theta_end*turn_right_end;\\n\\n#ifdef DASHED\\n v_length_so_far = a_length_so_far;\\n#endif\\n}\\n\"},\n", - " 416: function _(n,t,a,i,e){i();a.default=\"\\nprecision mediump float;\\n\\nconst int butt_cap = 0;\\nconst int round_cap = 1;\\nconst int square_cap = 2;\\n\\nconst int miter_join = 0;\\nconst int round_join = 1;\\nconst int bevel_join = 2;\\n\\nuniform float u_linewidth;\\nuniform float u_antialias;\\nuniform float u_line_join;\\nuniform float u_line_cap;\\nuniform vec4 u_line_color;\\n#ifdef DASHED\\nuniform sampler2D u_dash_tex;\\nuniform vec4 u_dash_tex_info;\\nuniform float u_dash_scale;\\nuniform float u_dash_offset;\\n#endif\\n\\nvarying float v_segment_length;\\nvarying vec2 v_coords;\\nvarying float v_flags;\\nvarying float v_cos_theta_turn_right_start;\\nvarying float v_cos_theta_turn_right_end;\\n#ifdef DASHED\\nvarying float v_length_so_far;\\n#endif\\n\\nfloat cross_z(in vec2 v0, in vec2 v1)\\n{\\n return v0.x*v1.y - v0.y*v1.x;\\n}\\n\\nfloat point_line_side(in vec2 point, in vec2 start, in vec2 end)\\n{\\n // +ve if point to right of line.\\n // Alternatively could do dot product with right_vector.\\n return cross_z(point - start, end - start);\\n}\\n\\nfloat point_line_distance(in vec2 point, in vec2 start, in vec2 end)\\n{\\n return point_line_side(point, start, end) / distance(start, end);\\n}\\n\\nvec2 right_vector(in vec2 v)\\n{\\n return vec2(v.y, -v.x);\\n}\\n\\nfloat bevel_join_distance(in float sign_start, in float halfwidth)\\n{\\n float cos_theta_turn_right = sign_start > 0.0 ? v_cos_theta_turn_right_start\\n : v_cos_theta_turn_right_end;\\n float cos_theta = abs(cos_theta_turn_right);\\n float turn_right = sign(cos_theta_turn_right);\\n float distance_along = sign_start > 0.0 ? 0.0 : v_segment_length;\\n\\n // In v_coords reference frame (x is along segment, y across).\\n vec2 line_start = vec2(distance_along, halfwidth*turn_right);\\n float sin_alpha = cos_theta;\\n float cos_alpha = sqrt(1.0 - sin_alpha*sin_alpha);\\n vec2 line_along = vec2(-sign_start*turn_right*sin_alpha, -cos_alpha);\\n\\n return halfwidth + sign_start*point_line_distance(\\n v_coords, line_start, line_start+line_along);\\n}\\n\\nfloat cap(in int cap_type, in float x, in float y)\\n{\\n // x is distance along segment in direction away from end of segment,\\n // y is distance across segment.\\n if (cap_type == butt_cap)\\n return max(0.5*u_linewidth - x, abs(y));\\n else if (cap_type == square_cap)\\n return max(-x, abs(y));\\n else // cap_type == round_cap\\n return distance(vec2(min(x, 0.0), y), vec2(0.0, 0.0));\\n}\\n\\nfloat distance_to_alpha(in float dist)\\n{\\n return 1.0 - smoothstep(0.5*(u_linewidth - u_antialias),\\n 0.5*(u_linewidth + u_antialias), dist);\\n}\\n\\n#ifdef DASHED\\nfloat dash_distance(in float x)\\n{\\n // x is in direction of v_coords.x, i.e. along segment.\\n float tex_length = u_dash_tex_info.x;\\n float tex_offset = u_dash_tex_info.y;\\n float tex_dist_min = u_dash_tex_info.z;\\n float tex_dist_max = u_dash_tex_info.w;\\n\\n // Apply offset.\\n x += v_length_so_far - u_dash_scale*tex_offset + u_dash_offset;\\n\\n // Interpolate within texture to obtain distance to dash.\\n float dist = texture2D(u_dash_tex,\\n vec2(x / (tex_length*u_dash_scale), 0.0)).a;\\n\\n // Scale distance within min and max limits.\\n dist = tex_dist_min + dist*(tex_dist_max - tex_dist_min);\\n\\n return u_dash_scale*dist;\\n}\\n\\nmat2 rotation_matrix(in float sign_start)\\n{\\n // Rotation matrix for v_coords from this segment to prev or next segment.\\n float cos_theta_turn_right = sign_start > 0.0 ? v_cos_theta_turn_right_start\\n : v_cos_theta_turn_right_end;\\n float cos_theta = abs(cos_theta_turn_right);\\n float turn_right = sign(cos_theta_turn_right);\\n\\n float sin_theta = sqrt(1.0 - cos_theta*cos_theta)*sign_start*turn_right;\\n float cos_2theta = 2.0*cos_theta*cos_theta - 1.0;\\n float sin_2theta = 2.0*sin_theta*cos_theta;\\n return mat2(cos_2theta, -sin_2theta, sin_2theta, cos_2theta);\\n}\\n#endif\\n\\nvoid main()\\n{\\n int join_type = int(u_line_join + 0.5);\\n int cap_type = int(u_line_cap + 0.5);\\n float halfwidth = 0.5*(u_linewidth + u_antialias);\\n\\n // Extract flags.\\n int flags = int(v_flags + 0.5);\\n bool miter_too_large_end = (flags / 8 > 0);\\n flags -= 8*int(miter_too_large_end);\\n bool miter_too_large_start = (flags / 4 > 0);\\n flags -= 4*int(miter_too_large_start);\\n bool has_end_cap = (flags / 2 > 0);\\n flags -= 2*int(has_end_cap);\\n bool has_start_cap = flags > 0;\\n\\n float dist = v_coords.y; // For straight segment, and miter join.\\n\\n if (v_coords.x <= 0.5*u_antialias) {\\n // At start of segment, either cap or join.\\n if (has_start_cap)\\n dist = cap(cap_type, v_coords.x, v_coords.y);\\n else if (join_type == round_join)\\n dist = distance(v_coords, vec2(0.0, 0.0));\\n else if (join_type == bevel_join ||\\n (join_type == miter_join && miter_too_large_start))\\n dist = max(abs(dist), bevel_join_distance(1.0, halfwidth));\\n // else a miter join which uses the default dist calculation.\\n }\\n else if (v_coords.x >= v_segment_length - 0.5*u_antialias) {\\n // At end of segment, either cap or join.\\n if (has_end_cap)\\n dist = cap(cap_type, v_segment_length - v_coords.x, v_coords.y);\\n else if (join_type == round_join)\\n dist = distance(v_coords, vec2(v_segment_length, 0));\\n else if ((join_type == bevel_join ||\\n (join_type == miter_join && miter_too_large_end)))\\n dist = max(abs(dist), bevel_join_distance(-1.0, halfwidth));\\n // else a miter join which uses the default dist calculation.\\n }\\n\\n float alpha = distance_to_alpha(abs(dist));\\n\\n#ifdef DASHED\\n if (u_dash_tex_info.x >= 0.0) {\\n // Dashes in straight segments (outside of joins) are easily calculated.\\n dist = dash_distance(v_coords.x);\\n\\n if (!has_start_cap && cap_type == butt_cap) {\\n if (v_coords.x < 0.5*u_antialias) {\\n // Outer of start join rendered solid color or not at all\\n // depending on whether corner point is in dash or gap, with\\n // antialiased ends.\\n dist = (dash_distance(0.0) > 0.0 ? 0.5*u_antialias - v_coords.x\\n : -0.5*u_linewidth);\\n\\n // Also consider antialiased end of dash just outside corner.\\n float end_dist = dash_distance(0.5*u_antialias) + v_coords.x -\\n 0.5*u_antialias;\\n dist = max(dist, end_dist);\\n }\\n\\n vec2 prev_coords = rotation_matrix(1.0)*v_coords;\\n\\n if (abs(prev_coords.y) < halfwidth &&\\n prev_coords.x < 0.5*u_antialias) {\\n // Extend dashes across from previous segment, with antialiased\\n // end.\\n float new_dist = dash_distance(min(prev_coords.x,\\n -0.5*u_antialias));\\n\\n if (prev_coords.x > -0.5*u_antialias)\\n new_dist -= prev_coords.x + 0.5*u_antialias;\\n\\n new_dist = min(new_dist, 0.5*u_linewidth - abs(prev_coords.y));\\n dist = max(dist, new_dist);\\n }\\n }\\n\\n if (!has_end_cap && cap_type == butt_cap) {\\n if (v_coords.x > v_segment_length - 0.5*u_antialias) {\\n // Similar for end join.\\n dist = (dash_distance(v_segment_length) > 0.0\\n ? v_coords.x - v_segment_length + 0.5*u_antialias\\n : -0.5*u_linewidth);\\n\\n float end_dist =\\n dash_distance(v_segment_length - 0.5*u_antialias) -\\n v_coords.x + v_segment_length - 0.5*u_antialias;\\n dist = max(dist, end_dist);\\n }\\n\\n vec2 next_coords =\\n rotation_matrix(-1.0)*(v_coords - vec2(v_segment_length, 0.0));\\n\\n if (abs(next_coords.y) < halfwidth &&\\n next_coords.x > -0.5*u_antialias) {\\n // Extend dashes across from next segment, with antialiased end.\\n float new_dist = dash_distance(v_segment_length +\\n max(next_coords.x, 0.5*u_antialias));\\n\\n if (next_coords.x < 0.5*u_antialias)\\n new_dist += next_coords.x - 0.5*u_antialias;\\n\\n new_dist = min(new_dist, 0.5*u_linewidth - abs(next_coords.y));\\n dist = max(dist, new_dist);\\n }\\n }\\n\\n dist = cap(cap_type, dist, v_coords.y);\\n\\n float dash_alpha = distance_to_alpha(dist);\\n alpha = min(alpha, dash_alpha);\\n }\\n#endif\\n\\n alpha = u_line_color.a*alpha;\\n gl_FragColor = vec4(u_line_color.rgb*alpha, alpha); // Premultiplied alpha.\\n}\\n\"},\n", - " 417: function _(n,i,o,a,t){a();o.default=\"\\nprecision mediump float;\\n\\nattribute vec2 a_position;\\nattribute vec2 a_center;\\nattribute float a_size;\\nattribute float a_angle; // in radians\\nattribute float a_linewidth;\\nattribute vec4 a_line_color;\\nattribute vec4 a_fill_color;\\nattribute float a_show;\\n\\nuniform float u_pixel_ratio;\\nuniform vec2 u_canvas_size;\\nuniform float u_antialias;\\n\\nvarying float v_linewidth;\\nvarying float v_size;\\nvarying vec4 v_line_color;\\nvarying vec4 v_fill_color;\\nvarying vec2 v_coords;\\n\\nvoid main()\\n{\\n v_size = a_size;\\n v_linewidth = a_linewidth;\\n v_line_color = a_line_color;\\n v_fill_color = a_fill_color;\\n\\n if (a_show < 0.5) {\\n // Do not show this marker.\\n gl_Position = vec4(-2.0, -2.0, 0.0, 1.0);\\n return;\\n }\\n\\n float enclosing_size = v_size + 2.0*v_linewidth + 3.0*u_antialias;\\n\\n // Coordinates in rotated frame with respect to center of marker, used in\\n // distance functions in fragment shader.\\n v_coords = a_position*enclosing_size;\\n\\n float c = cos(-a_angle);\\n float s = sin(-a_angle);\\n mat2 rotation = mat2(c, -s, s, c);\\n\\n vec2 pos = a_center + rotation*v_coords;\\n pos += 0.5; // make up for Bokeh's offset\\n pos /= u_canvas_size / u_pixel_ratio; // in 0..1\\n gl_Position = vec4(2.0*pos.x - 1.0, 1.0 - 2.0*pos.y, 0.0, 1.0);\\n}\\n\"},\n", - " 418: function _(n,a,e,t,s){t();e.default=\"\\nprecision mediump float;\\n\\nconst float SQRT_2 = 1.4142135623730951;\\nconst float SQRT_3 = sqrt(3.0);\\nconst float PI = 3.14159265358979323846264;\\n\\nconst float IN_ANGLE = 0.6283185307179586; // PI/5. = 36 degrees (star of 5 pikes)\\n//const float OUT_ANGLE = PI/2. - IN_ANGLE; // External angle for regular stars\\nconst float COS_A = 0.8090169943749475; // cos(IN_ANGLE)\\nconst float SIN_A = 0.5877852522924731; // sin(IN_ANGLE)\\nconst float COS_B = 0.5877852522924731; // cos(OUT_ANGLE)\\nconst float SIN_B = 0.8090169943749475; // sin(OUT_ANGLE)\\n\\nuniform float u_antialias;\\n\\nvarying vec4 v_line_color;\\nvarying vec4 v_fill_color;\\nvarying float v_linewidth;\\nvarying float v_size;\\nvarying vec2 v_coords;\\n\\n#ifdef USE_ASTERISK\\n// asterisk\\nfloat marker(vec2 P, float size)\\n{\\n // Masks\\n float diamond = max(abs(SQRT_2 / 2.0 * (P.x - P.y)), abs(SQRT_2 / 2.0 * (P.x + P.y))) - size / 2.0;\\n float square = max(abs(P.x), abs(P.y)) - size / 2.0;\\n // Shapes\\n float X = min(abs(P.x - P.y), abs(P.x + P.y));\\n float cross = min(abs(P.x), abs(P.y));\\n // Result is union of masked shapes\\n float result = min(max(X, diamond), max(cross, square));\\n return max(result - v_linewidth/2.0 + u_antialias/2.0, 0.0);\\n}\\n#endif\\n\\n#ifdef USE_CIRCLE\\n// circle\\nfloat marker(vec2 P, float size)\\n{\\n return length(P) - size/2.0;\\n}\\n#endif\\n\\n#ifdef USE_DOT\\nfloat marker(vec2 P, float size)\\n{\\n return max(length(P) - size/8.0 - v_linewidth/15.0 + u_antialias, 0.0);\\n}\\n#endif\\n\\n#ifdef USE_CIRCLE_DOT\\nfloat marker(vec2 P, float size)\\n{\\n float circle = length(P) - size/2.0;\\n float dot_ = min(size/8.0 + v_linewidth/15.0 - u_antialias - length(P), 0.0);\\n return max(circle, dot_);\\n}\\n#endif\\n\\n#ifdef USE_SQUARE\\n// square\\nfloat marker(vec2 P, float size)\\n{\\n return max(abs(P.x), abs(P.y)) - size/2.0;\\n}\\n#endif\\n\\n#ifdef USE_SQUARE_DOT\\nfloat marker(vec2 P, float size)\\n{\\n float square = max(abs(P.x), abs(P.y)) - size/2.0;\\n float dot_ = min(size/8.0 + v_linewidth/15.0 - u_antialias - length(P), 0.0);\\n return max(square, dot_);\\n}\\n#endif\\n\\n#ifdef USE_DIAMOND\\n// diamond\\nfloat marker(vec2 P, float size)\\n{\\n float x = SQRT_2 / 2.0 * (P.x * 1.5 - P.y);\\n float y = SQRT_2 / 2.0 * (P.x * 1.5 + P.y);\\n float r1 = max(abs(x), abs(y)) - size / (2.0 * SQRT_2);\\n return r1 / SQRT_2;\\n}\\n#endif\\n\\n#ifdef USE_DIAMOND_DOT\\nfloat marker(vec2 P, float size)\\n{\\n float x = SQRT_2 / 2.0 * (P.x * 1.5 - P.y);\\n float y = SQRT_2 / 2.0 * (P.x * 1.5 + P.y);\\n float r1 = max(abs(x), abs(y)) - size / (2.0 * SQRT_2);\\n float diamond = r1 / SQRT_2;\\n float dot_ = min(size/8.0 + v_linewidth/15.0 - u_antialias - length(P), 0.0);\\n return max(diamond, dot_);\\n}\\n#endif\\n\\n#ifdef USE_HEX\\n// hex\\nfloat marker(vec2 P, float size)\\n{\\n vec2 q = abs(P);\\n return max(q.y * 0.57735 + q.x - 1.0 * size/2.0, q.y - 0.866 * size/2.0);\\n}\\n#endif\\n\\n#ifdef USE_HEX_DOT\\nfloat marker(vec2 P, float size)\\n{\\n vec2 q = abs(P);\\n float hex = max(q.y * 0.57735 + q.x - 1.0 * size/2.0, q.y - 0.866 * size/2.0);\\n float dot_ = min(size/8.0 + v_linewidth/15.0 - u_antialias - length(P), 0.0);\\n return max(hex, dot_);\\n}\\n#endif\\n\\n#ifdef USE_STAR\\n// star\\n// https://iquilezles.org/www/articles/distfunctions2d/distfunctions2d.htm\\nfloat marker(vec2 P, float size)\\n{\\n float bn = mod(atan(P.x, -P.y), 2.0*IN_ANGLE) - IN_ANGLE;\\n P = length(P)*vec2(cos(bn), abs(sin(bn)));\\n P -= size*vec2(COS_A, SIN_A)/2.;\\n P += vec2(COS_B, SIN_B)*clamp(-(P.x*COS_B + P.y*SIN_B), 0.0, size*SIN_A/SIN_B/2.);\\n return length(P)*sign(P.x);\\n}\\n#endif\\n\\n#ifdef USE_STAR_DOT\\nfloat marker(vec2 P, float size)\\n{\\n float dot_ = min(size/8.0 + v_linewidth/15.0 - u_antialias - length(P), 0.0);\\n float bn = mod(atan(P.x, -P.y), 2.0*IN_ANGLE) - IN_ANGLE;\\n P = length(P)*vec2(cos(bn), abs(sin(bn)));\\n P -= size*vec2(COS_A, SIN_A)/2.;\\n P += vec2(COS_B, SIN_B)*clamp(-(P.x*COS_B + P.y*SIN_B), 0.0, size*SIN_A/SIN_B/2.);\\n float star = length(P)*sign(P.x);\\n return max(star, dot_);\\n}\\n#endif\\n\\n#ifdef USE_TRIANGLE\\n// triangle\\nfloat marker(vec2 P, float size)\\n{\\n P.y -= size * 0.3;\\n float x = SQRT_2 / 2.0 * (P.x * 1.7 - P.y);\\n float y = SQRT_2 / 2.0 * (P.x * 1.7 + P.y);\\n float r1 = max(abs(x), abs(y)) - size / 1.6;\\n float r2 = P.y;\\n return max(r1 / SQRT_2, r2); // Intersect diamond with rectangle\\n}\\n#endif\\n\\n#ifdef USE_TRIANGLE_DOT\\nfloat marker(vec2 P, float size)\\n{\\n float dot_ = min(size/8.0 + v_linewidth/15.0 - u_antialias - length(P), 0.0);\\n P.y -= size * 0.3;\\n float x = SQRT_2 / 2.0 * (P.x * 1.7 - P.y);\\n float y = SQRT_2 / 2.0 * (P.x * 1.7 + P.y);\\n float r1 = max(abs(x), abs(y)) - size / 1.6;\\n float r2 = P.y;\\n float triangle = max(r1 / SQRT_2, r2); // Intersect diamond with rectangle\\n return max(triangle, dot_);\\n}\\n#endif\\n\\n#ifdef USE_INVERTED_TRIANGLE\\n// inverted_triangle\\nfloat marker(vec2 P, float size)\\n{\\n P.y += size * 0.3;\\n float x = SQRT_2 / 2.0 * (P.x * 1.7 - P.y);\\n float y = SQRT_2 / 2.0 * (P.x * 1.7 + P.y);\\n float r1 = max(abs(x), abs(y)) - size / 1.6;\\n float r2 = - P.y;\\n return max(r1 / SQRT_2, r2); // Intersect diamond with rectangle\\n}\\n#endif\\n\\n#ifdef USE_CROSS\\n// cross\\nfloat marker(vec2 P, float size)\\n{\\n float square = max(abs(P.x), abs(P.y)) - size / 2.0;\\n float cross = min(abs(P.x), abs(P.y));\\n cross = max(cross - v_linewidth/2.0 + u_antialias/2.0, 0.0);\\n return max(square, cross);\\n}\\n#endif\\n\\n#ifdef USE_DASH\\nfloat marker(vec2 P, float size)\\n{\\n float square = max(abs(P.x), abs(P.y)) - size / 2.0;\\n float cross = abs(P.y);\\n cross = max(cross - v_linewidth/2.0 + u_antialias/2.0, 0.0);\\n return max(square, cross);\\n}\\n#endif\\n\\n#ifdef USE_CIRCLE_CROSS\\n// circle_cross\\nfloat marker(vec2 P, float size)\\n{\\n // Define quadrants\\n float qs = size / 2.0; // quadrant size\\n float s1 = max(abs(P.x - qs), abs(P.y - qs)) - qs;\\n float s2 = max(abs(P.x + qs), abs(P.y - qs)) - qs;\\n float s3 = max(abs(P.x - qs), abs(P.y + qs)) - qs;\\n float s4 = max(abs(P.x + qs), abs(P.y + qs)) - qs;\\n // Intersect main shape with quadrants (to form cross)\\n float circle = length(P) - size/2.0;\\n float c1 = max(circle, s1);\\n float c2 = max(circle, s2);\\n float c3 = max(circle, s3);\\n float c4 = max(circle, s4);\\n // Union\\n return min(min(min(c1, c2), c3), c4);\\n}\\n#endif\\n\\n#ifdef USE_SQUARE_CROSS\\n// square_cross\\nfloat marker(vec2 P, float size)\\n{\\n // Define quadrants\\n float qs = size / 2.0; // quadrant size\\n float s1 = max(abs(P.x - qs), abs(P.y - qs)) - qs;\\n float s2 = max(abs(P.x + qs), abs(P.y - qs)) - qs;\\n float s3 = max(abs(P.x - qs), abs(P.y + qs)) - qs;\\n float s4 = max(abs(P.x + qs), abs(P.y + qs)) - qs;\\n // Intersect main shape with quadrants (to form cross)\\n float square = max(abs(P.x), abs(P.y)) - size/2.0;\\n float c1 = max(square, s1);\\n float c2 = max(square, s2);\\n float c3 = max(square, s3);\\n float c4 = max(square, s4);\\n // Union\\n return min(min(min(c1, c2), c3), c4);\\n}\\n#endif\\n\\n#ifdef USE_DIAMOND_CROSS\\n// diamond_cross\\nfloat marker(vec2 P, float size)\\n{\\n // Define quadrants\\n float qs = size / 2.0; // quadrant size\\n float s1 = max(abs(P.x - qs), abs(P.y - qs)) - qs;\\n float s2 = max(abs(P.x + qs), abs(P.y - qs)) - qs;\\n float s3 = max(abs(P.x - qs), abs(P.y + qs)) - qs;\\n float s4 = max(abs(P.x + qs), abs(P.y + qs)) - qs;\\n // Intersect main shape with quadrants (to form cross)\\n float x = SQRT_2 / 2.0 * (P.x * 1.5 - P.y);\\n float y = SQRT_2 / 2.0 * (P.x * 1.5 + P.y);\\n float diamond = max(abs(x), abs(y)) - size / (2.0 * SQRT_2);\\n diamond /= SQRT_2;\\n float c1 = max(diamond, s1);\\n float c2 = max(diamond, s2);\\n float c3 = max(diamond, s3);\\n float c4 = max(diamond, s4);\\n // Union\\n return min(min(min(c1, c2), c3), c4);\\n}\\n#endif\\n\\n#ifdef USE_X\\n// x\\nfloat marker(vec2 P, float size)\\n{\\n float circle = length(P) - size / 2.0;\\n float X = min(abs(P.x - P.y), abs(P.x + P.y));\\n X = max(X - v_linewidth/2.0, 0.0);\\n return max(circle, X);\\n}\\n#endif\\n\\n#ifdef USE_Y\\nfloat marker(vec2 P, float size)\\n{\\n float circle = length(P) - size / 2.0;\\n\\n float dx = 1.0 / SQRT_3;\\n float dy = SQRT_2 / SQRT_3;\\n\\n // Sideways distance from the three spokes.\\n float d0 = abs(P.x);\\n float d1 = abs(dot(P, vec2(dx, dy)));\\n float d2 = abs(dot(P, vec2(dx, -dy)));\\n\\n // Clip each spoke to semicircle.\\n d0 = max(d0, -P.y);\\n d1 = max(d1, dot(P, vec2(-dy, dx)));\\n d2 = max(d2, dot(P, vec2(dy, dx)));\\n\\n float Y = min(min(d0, d1), d2);\\n Y = max(Y - v_linewidth/2.0 + u_antialias/2.0, 0.0);\\n return max(circle, Y);\\n}\\n#endif\\n\\n#ifdef USE_CIRCLE_X\\n// circle_x\\nfloat marker(vec2 P, float size)\\n{\\n float x = P.x - P.y;\\n float y = P.x + P.y;\\n // Define quadrants\\n float qs = size / 2.0; // quadrant size\\n float s1 = max(abs(x - qs), abs(y - qs)) - qs;\\n float s2 = max(abs(x + qs), abs(y - qs)) - qs;\\n float s3 = max(abs(x - qs), abs(y + qs)) - qs;\\n float s4 = max(abs(x + qs), abs(y + qs)) - qs;\\n // Intersect main shape with quadrants (to form cross)\\n float circle = length(P) - size/2.0;\\n float c1 = max(circle, s1);\\n float c2 = max(circle, s2);\\n float c3 = max(circle, s3);\\n float c4 = max(circle, s4);\\n // Union\\n return min(min(min(c1, c2), c3), c4);\\n}\\n#endif\\n\\n#ifdef USE_CIRCLE_Y\\nfloat marker(vec2 P, float size)\\n{\\n float circle = length(P) - size/2.0;\\n\\n float dx = 1.0 / SQRT_3;\\n float dy = SQRT_2 / SQRT_3;\\n\\n // Sideways distance from the three spokes.\\n float d0 = abs(P.x);\\n float d1 = abs(dot(P, vec2(dx, dy)));\\n float d2 = abs(dot(P, vec2(dx, -dy)));\\n\\n // Clip each spoke to semicircle.\\n d0 = max(d0, -P.y);\\n d1 = max(d1, dot(P, vec2(-dy, dx)));\\n d2 = max(d2, dot(P, vec2(dy, dx)));\\n\\n float Y = min(min(d0, d1), d2);\\n Y = min(v_linewidth/2.0 - u_antialias/2.0 - Y, 0.0);\\n\\n return max(circle, Y);\\n}\\n#endif\\n\\n#ifdef USE_SQUARE_X\\n// square_x\\nfloat marker(vec2 P, float size)\\n{\\n float x = P.x - P.y;\\n float y = P.x + P.y;\\n // Define quadrants\\n float qs = size / 2.0; // quadrant size\\n float s1 = max(abs(x - qs), abs(y - qs)) - qs;\\n float s2 = max(abs(x + qs), abs(y - qs)) - qs;\\n float s3 = max(abs(x - qs), abs(y + qs)) - qs;\\n float s4 = max(abs(x + qs), abs(y + qs)) - qs;\\n // Intersect main shape with quadrants (to form cross)\\n float square = max(abs(P.x), abs(P.y)) - size/2.0;\\n float c1 = max(square, s1);\\n float c2 = max(square, s2);\\n float c3 = max(square, s3);\\n float c4 = max(square, s4);\\n // Union\\n return min(min(min(c1, c2), c3), c4);\\n}\\n#endif\\n\\n#ifdef USE_PLUS\\nfloat marker(vec2 P, float size)\\n{\\n vec2 size2 = vec2(size*0.5, size*0.2);\\n P = abs(P);\\n P = (P.y > P.x) ? P.yx : P.xy;\\n vec2 q = P - size2;\\n float k = max(q.y, q.x);\\n vec2 w = (k > 0.0) ? q : vec2(size2.y - P.x, -k);\\n return sign(k)*length(max(w, 0.0));\\n}\\n#endif\\n\\n#ifdef USE_SQUARE_PIN\\nfloat marker(vec2 P, float size)\\n{\\n float actual_size = size*1.2;\\n float radius = 0.75*actual_size; // Radius of curvature of edges.\\n float offset = actual_size/2.0 + sqrt(radius*radius - actual_size*actual_size/4.0);\\n vec2 centerx = vec2(offset, 0.0);\\n vec2 centery = vec2(0.0, offset);\\n\\n float right = length(P - centerx);\\n float left = length(P + centerx);\\n float up = length(P - centery);\\n float down = length(P + centery);\\n float pin = radius - min(min(right, left), min(up, down));\\n\\n float circle = length(P) - actual_size*0.6;\\n return max(circle, pin);\\n}\\n#endif\\n\\n#ifdef USE_TRIANGLE_PIN\\nfloat marker(vec2 P, float size)\\n{\\n float actual_size = size*1.2;\\n float radius = 1.2*actual_size; // Radius of curvature of edges.\\n\\n float angle = 2.0*PI / 3.0;\\n float c = cos(angle);\\n float s = sin(angle);\\n mat2 rotation = mat2(c, -s, s, c);\\n\\n // Half the length of straight triangle edge.\\n float half_edge = actual_size*SQRT_3/4.0;\\n // Distance from center of triangle to middle of straight edge.\\n float centre_middle_edge = 0.25*actual_size;\\n float offset = centre_middle_edge + sqrt(radius*radius - half_edge*half_edge);\\n // Centre of curvature.\\n vec2 center = vec2(0.0, offset);\\n\\n float dist0 = length(P - center);\\n P = rotation*P;\\n float dist1 = length(P - center);\\n P = rotation*P;\\n float dist2 = length(P - center);\\n float pin = radius - min(min(dist0, dist1), dist2);\\n\\n float circle = length(P) - actual_size / 2.0;\\n return max(circle, pin);\\n}\\n#endif\\n\\nvec4 outline(float distance, float linewidth, float antialias, vec4 line_color,\\n vec4 fill_color)\\n{\\n vec4 frag_color;\\n float t = min(linewidth/2.0 - antialias, 0.0); // Line half-width.\\n float signed_distance = distance;\\n float border_distance = abs(signed_distance) - t;\\n float alpha = border_distance/antialias;\\n alpha = exp(-alpha*alpha);\\n\\n // If line alpha is zero, it probably means no outline. To avoid a dark\\n // outline shining through due to antialiasing, we set the line color to the\\n // fill color.\\n float select = float(bool(line_color.a));\\n line_color.rgb = select*line_color.rgb + (1.0 - select)*fill_color.rgb;\\n // Similarly, if we want a transparent fill.\\n select = float(bool(fill_color.a));\\n fill_color.rgb = select*fill_color.rgb + (1.0 - select)*line_color.rgb;\\n\\n if (border_distance < 0.0)\\n frag_color = line_color;\\n else if (signed_distance < 0.0)\\n frag_color = mix(fill_color, line_color, sqrt(alpha));\\n else {\\n if (abs(signed_distance) < linewidth/2.0 + antialias)\\n frag_color = vec4(line_color.rgb, line_color.a*alpha);\\n else\\n discard;\\n }\\n return frag_color;\\n}\\n\\nvoid main()\\n{\\n float distance = marker(v_coords, v_size);\\n gl_FragColor = outline(\\n distance, v_linewidth, u_antialias, v_line_color, v_fill_color);\\n gl_FragColor.rgb *= gl_FragColor.a; // Premultiplied alpha.\\n}\\n\"},\n", - " 419: function _(n,t,a,i,e){i();a.default=\"\\nprecision mediump float;\\n\\nattribute vec2 a_position;\\nattribute vec2 a_center;\\nattribute float a_width;\\nattribute float a_height;\\nattribute float a_angle; // In radians\\nattribute float a_linewidth;\\nattribute vec4 a_line_color;\\nattribute vec4 a_fill_color;\\nattribute float a_line_join;\\nattribute float a_show;\\n#ifdef HATCH\\nattribute float a_hatch_pattern;\\nattribute float a_hatch_scale;\\nattribute float a_hatch_weight;\\nattribute vec4 a_hatch_color;\\n#endif\\n\\nuniform float u_pixel_ratio;\\nuniform vec2 u_canvas_size;\\nuniform float u_antialias;\\n\\nvarying float v_linewidth;\\nvarying vec2 v_size; // 2D size for rects compared to 1D for markers.\\nvarying vec4 v_line_color;\\nvarying vec4 v_fill_color;\\nvarying float v_line_join;\\nvarying vec2 v_coords;\\n#ifdef HATCH\\nvarying float v_hatch_pattern;\\nvarying float v_hatch_scale;\\nvarying float v_hatch_weight;\\nvarying vec4 v_hatch_color;\\nvarying vec2 v_hatch_coords;\\n#endif\\n\\nvoid main()\\n{\\n if (a_show < 0.5) {\\n // Do not show this rect.\\n gl_Position = vec4(-2.0, -2.0, 0.0, 1.0);\\n return;\\n }\\n\\n v_size = vec2(a_width, a_height);\\n v_linewidth = a_linewidth;\\n v_line_color = a_line_color;\\n v_fill_color = a_fill_color;\\n v_line_join = a_line_join;\\n\\n if (v_linewidth < 1.0) {\\n // Linewidth less than 1 is implemented as 1 but with reduced alpha.\\n v_line_color.a *= v_linewidth;\\n v_linewidth = 1.0;\\n }\\n\\n#ifdef HATCH\\n v_hatch_pattern = a_hatch_pattern;\\n v_hatch_scale = a_hatch_scale;\\n v_hatch_weight = a_hatch_weight;\\n v_hatch_color = a_hatch_color;\\n#endif\\n\\n vec2 enclosing_size = v_size + v_linewidth + u_antialias;\\n\\n // Coordinates in rotated frame with respect to center of marker, used for\\n // distance functions in fragment shader.\\n v_coords = a_position*enclosing_size;\\n\\n float c = cos(-a_angle);\\n float s = sin(-a_angle);\\n mat2 rotation = mat2(c, -s, s, c);\\n\\n vec2 pos = a_center + rotation*v_coords;\\n#ifdef HATCH\\n // Coordinates for hatching in unrotated frame of reference.\\n v_hatch_coords = pos - 0.5;\\n#endif\\n pos += 0.5; // Make up for Bokeh's offset.\\n pos /= u_canvas_size / u_pixel_ratio; // 0 to 1.\\n gl_Position = vec4(2.0*pos.x - 1.0, 1.0 - 2.0*pos.y, 0.0, 1.0);\\n}\\n\"},\n", - " 420: function _(n,a,t,o,r){o();t.default=\"\\nprecision mediump float;\\n\\nconst float SQRT2 = sqrt(2.0);\\nconst float INVSQRT2 = 1.0/SQRT2;\\nconst float PI = 3.14159265358979323846;\\n\\nconst int miter_join = 0;\\nconst int round_join = 1;\\nconst int bevel_join = 2;\\n#ifdef HATCH\\nconst int hatch_dot = 1;\\nconst int hatch_ring = 2;\\nconst int hatch_horizontal_line = 3;\\nconst int hatch_vertical_line = 4;\\nconst int hatch_cross = 5;\\nconst int hatch_horizontal_dash = 6;\\nconst int hatch_vertical_dash = 7;\\nconst int hatch_spiral = 8;\\nconst int hatch_right_diagonal_line = 9;\\nconst int hatch_left_diagonal_line = 10;\\nconst int hatch_diagonal_cross = 11;\\nconst int hatch_right_diagonal_dash = 12;\\nconst int hatch_left_diagonal_dash = 13;\\nconst int hatch_horizontal_wave = 14;\\nconst int hatch_vertical_wave = 15;\\nconst int hatch_criss_cross = 16;\\n#endif\\n\\nuniform float u_antialias;\\n\\nvarying float v_linewidth;\\nvarying vec2 v_size;\\nvarying vec4 v_line_color;\\nvarying vec4 v_fill_color;\\nvarying float v_line_join;\\nvarying vec2 v_coords;\\n#ifdef HATCH\\nvarying float v_hatch_pattern;\\nvarying float v_hatch_scale;\\nvarying float v_hatch_weight;\\nvarying vec4 v_hatch_color;\\nvarying vec2 v_hatch_coords;\\n#endif\\n\\n// Distance is zero on edge of marker, +ve outside and -ve inside.\\nfloat marker_distance(vec2 p, int line_join)\\n{\\n vec2 dist2 = abs(p) - v_size/2.0;\\n float dist = max(dist2.x, dist2.y);\\n\\n if (dist2.x > 0.0 && dist2.y > 0.0) {\\n // Outside of corner needs correct join, default is miter.\\n if (line_join == round_join)\\n dist = length(dist2);\\n else if (line_join == bevel_join) {\\n vec2 normal = vec2(INVSQRT2, INVSQRT2);\\n dist = dot(dist2, normal) + 0.5*v_linewidth*(1.0 - INVSQRT2);\\n }\\n }\\n\\n return dist;\\n}\\n\\n// Convert distance from edge of marker to fraction in range 0 to 1, depending\\n// on antialiasing width.\\nfloat distance_to_fraction(float dist)\\n{\\n return 1.0 - smoothstep(-0.5*u_antialias, 0.5*u_antialias, dist);\\n}\\n\\n// Return fraction from 0 (no fill color) to 1 (full fill color).\\nfloat fill_fraction(float dist)\\n{\\n return distance_to_fraction(dist);\\n}\\n\\n// Return fraction in range 0 (no line color) to 1 (full line color).\\nfloat line_fraction(float dist)\\n{\\n return distance_to_fraction(abs(dist) - 0.5*v_linewidth);\\n}\\n\\n// Return fraction (in range 0 to 1) of a color, with premultiplied alpha.\\nvec4 fractional_color(vec4 color, float fraction)\\n{\\n color.a *= fraction;\\n color.rgb *= color.a;\\n return color;\\n}\\n\\n// Blend colors that have premultiplied alpha.\\nvec4 blend_colors(vec4 src, vec4 dest)\\n{\\n return (1.0 - src.a)*dest + src;\\n}\\n\\n#ifdef HATCH\\n// Wrap coordinate(s) by removing integer part to give distance from center of\\n// repeat, in the range -0.5 to +0.5.\\nfloat wrap(float x)\\n{\\n return fract(x) - 0.5;\\n}\\n\\nvec2 wrap(vec2 xy)\\n{\\n return fract(xy) - 0.5;\\n}\\n\\n// Return fraction from 0 (no hatch color) to 1 (full hatch color).\\nfloat hatch_fraction(vec2 coords, int hatch_pattern)\\n{\\n float scale = v_hatch_scale; // Hatch repeat distance.\\n\\n // Coordinates and linewidth/halfwidth are scaled to hatch repeat distance.\\n coords = coords / scale;\\n float halfwidth = 0.5*v_hatch_weight / scale; // Half the hatch linewidth.\\n\\n // Default is to return fraction of zero, i.e. no pattern.\\n float dist = u_antialias;\\n\\n if (hatch_pattern == hatch_dot) {\\n const float dot_radius = 0.25;\\n dist = length(wrap(coords)) - dot_radius;\\n }\\n else if (hatch_pattern == hatch_ring) {\\n const float ring_radius = 0.25;\\n dist = abs(length(wrap(coords)) - ring_radius) - halfwidth;\\n }\\n else if (hatch_pattern == hatch_horizontal_line) {\\n dist = abs(wrap(coords.y)) - halfwidth;\\n }\\n else if (hatch_pattern == hatch_vertical_line) {\\n dist = abs(wrap(coords.x)) - halfwidth;\\n }\\n else if (hatch_pattern == hatch_cross) {\\n dist = min(abs(wrap(coords.x)), abs(wrap(coords.y))) - halfwidth;\\n }\\n else if (hatch_pattern == hatch_horizontal_dash) {\\n // Dashes have square caps.\\n const float halflength = 0.25;\\n dist = max(abs(wrap(coords.y)),\\n abs(wrap(coords.x) + 0.25) - halflength) - halfwidth;\\n }\\n else if (hatch_pattern == hatch_vertical_dash) {\\n const float halflength = 0.25;\\n dist = max(abs(wrap(coords.x)),\\n abs(wrap(coords.y) + 0.25) - halflength) - halfwidth;\\n }\\n else if (hatch_pattern == hatch_spiral) {\\n vec2 wrap2 = wrap(coords);\\n float angle = wrap(atan(wrap2.y, wrap2.x) / (2.0*PI));\\n // Canvas spiral radius increases by scale*pi/15 each rotation.\\n const float dr = PI/15.0;\\n float radius = length(wrap2);\\n // At any angle, spiral lines are equally spaced dr apart.\\n // Find distance to nearest of these lines.\\n float frac = fract((radius - dr*angle) / dr); // 0 to 1.\\n dist = dr*(abs(frac - 0.5));\\n dist = min(dist, radius) - halfwidth; // Consider center point also.\\n }\\n else if (hatch_pattern == hatch_right_diagonal_line) {\\n dist = abs(wrap(2.0*coords.x + coords.y))/sqrt(5.0) - halfwidth;\\n }\\n else if (hatch_pattern == hatch_left_diagonal_line) {\\n dist = abs(wrap(2.0*coords.x - coords.y))/sqrt(5.0) - halfwidth;\\n }\\n else if (hatch_pattern == hatch_diagonal_cross) {\\n coords = vec2(coords.x + coords.y + 0.5, coords.x - coords.y + 0.5);\\n dist = min(abs(wrap(coords.x)), abs(wrap(coords.y))) / SQRT2 - halfwidth;\\n }\\n else if (hatch_pattern == hatch_right_diagonal_dash) {\\n float across = coords.x + coords.y + 0.5;\\n dist = abs(wrap(across)) / SQRT2; // Distance to nearest solid line.\\n\\n across = floor(across); // Offset for dash.\\n float along = wrap(0.5*(coords.x - coords.y + across));\\n const float halflength = 0.25;\\n along = abs(along) - halflength; // Distance along line.\\n\\n dist = max(dist, along) - halfwidth;\\n }\\n else if (hatch_pattern == hatch_left_diagonal_dash) {\\n float across = coords.x - coords.y + 0.5;\\n dist = abs(wrap(across)) / SQRT2; // Distance to nearest solid line.\\n\\n across = floor(across); // Offset for dash.\\n float along = wrap(0.5*(coords.x + coords.y + across));\\n const float halflength = 0.25;\\n along = abs(along) - halflength; // Distance along line.\\n\\n dist = max(dist, along) - halfwidth;\\n }\\n else if (hatch_pattern == hatch_horizontal_wave) {\\n float wrapx = wrap(coords.x);\\n float wrapy = wrap(coords.y - 0.25 + abs(wrapx));\\n dist = abs(wrapy) / SQRT2 - halfwidth;\\n }\\n else if (hatch_pattern == hatch_vertical_wave) {\\n float wrapy = wrap(coords.y);\\n float wrapx = wrap(coords.x - 0.25 + abs(wrapy));\\n dist = abs(wrapx) / SQRT2 - halfwidth;\\n }\\n else if (hatch_pattern == hatch_criss_cross) {\\n float plus = min(abs(wrap(coords.x)), abs(wrap(coords.y)));\\n\\n coords = vec2(coords.x + coords.y + 0.5, coords.x - coords.y + 0.5);\\n float X = min(abs(wrap(coords.x)), abs(wrap(coords.y))) / SQRT2;\\n\\n dist = min(plus, X) - halfwidth;\\n }\\n\\n return distance_to_fraction(dist*scale);\\n}\\n#endif\\n\\nvoid main()\\n{\\n int line_join = int(v_line_join + 0.5);\\n#ifdef HATCH\\n int hatch_pattern = int(v_hatch_pattern + 0.5);\\n#endif\\n\\n float dist = marker_distance(v_coords, line_join);\\n\\n float fill_frac = fill_fraction(dist);\\n vec4 color = fractional_color(v_fill_color, fill_frac);\\n\\n#ifdef HATCH\\n if (hatch_pattern > 0 && fill_frac > 0.0) {\\n float hatch_frac = hatch_fraction(v_hatch_coords, hatch_pattern);\\n vec4 hatch_color = fractional_color(v_hatch_color, hatch_frac*fill_frac);\\n color = blend_colors(hatch_color, color);\\n }\\n#endif\\n\\n float line_frac = line_fraction(dist);\\n if (line_frac > 0.0) {\\n vec4 line_color = fractional_color(v_line_color, line_frac);\\n color = blend_colors(line_color, color);\\n }\\n\\n gl_FragColor = color;\\n}\\n\"},\n", - " 421: function _(s,i,t,e,_){e();const h=s(422),l=s(22),a=s(46),n=s(423),o=s(424),r=-1e4;class p extends h.BaseGLGlyph{constructor(s,i){super(s,i),this.glyph=i,this._antialias=1.5,this._miter_limit=5}draw(s,i,t){const e=i.glglyph;this.visuals_changed&&(this._set_visuals(),this.visuals_changed=!1),e.data_changed&&(e._set_data(),e.data_changed=!1);const _=this.glyph.visuals.line,h=n.cap_lookup[_.line_cap.value],l=n.join_lookup[_.line_join.value];if(this._is_dashed()){const s={scissor:this.regl_wrapper.scissor,viewport:this.regl_wrapper.viewport,canvas_size:[t.width,t.height],pixel_ratio:t.pixel_ratio,line_color:this._color,linewidth:this._linewidth,antialias:this._antialias,miter_limit:this._miter_limit,points:e._points,nsegments:e._nsegments,line_join:l,line_cap:h,length_so_far:e._length_so_far,dash_tex:this._dash_tex,dash_tex_info:this._dash_tex_info,dash_scale:this._dash_scale,dash_offset:this._dash_offset};this.regl_wrapper.dashed_line()(s)}else{const s={scissor:this.regl_wrapper.scissor,viewport:this.regl_wrapper.viewport,canvas_size:[t.width,t.height],pixel_ratio:t.pixel_ratio,line_color:this._color,linewidth:this._linewidth,antialias:this._antialias,miter_limit:this._miter_limit,points:e._points,nsegments:e._nsegments,line_join:l,line_cap:h};this.regl_wrapper.solid_line()(s)}}_is_dashed(){return this._line_dash.length>0}_set_data(){const s=this.glyph.sx.length;this._nsegments=s-1,null==this._is_closed&&(this._is_closed=this.glyph.sx[0]==this.glyph.sx[s-1]&&this.glyph.sy[0]==this.glyph.sy[s-1]&&isFinite(this.glyph.sx[0])&&isFinite(this.glyph.sy[0])),null==this._points&&(this._points=new o.Float32Buffer(this.regl_wrapper));const i=this._points.get_sized_array(2*(s+2));for(let t=1;t-9e3&&i[2*e+4]>-9e3&&(t+=Math.sqrt((i[2*e+4]-i[2*e+2])**2+(i[2*e+5]-i[2*e+3])**2));this._length_so_far.update()}}_set_visuals(){const s=this.glyph.visuals.line,i=(0,l.color2rgba)(s.line_color.value,s.line_alpha.value);this._color=i.map((s=>s/255)),this._linewidth=s.line_width.value,this._linewidth<1&&(this._color[3]*=this._linewidth,this._linewidth=1),this._line_dash=(0,a.resolve_line_dash)(s.line_dash.value),1==this._line_dash.length&&this._line_dash.push(this._line_dash[0]),this._is_dashed()&&([this._dash_tex_info,this._dash_tex,this._dash_scale]=this.regl_wrapper.get_dash(this._line_dash),this._dash_offset=s.line_dash_offset.value)}}t.LineGL=p,p.__name__=\"LineGL\"},\n", - " 422: function _(e,t,s,i,h){i();class a{constructor(e,t){this.glyph=t,this.nvertices=0,this.size_changed=!1,this.data_changed=!1,this.visuals_changed=!1,this.regl_wrapper=e}set_data_changed(){const{data_size:e}=this.glyph;e!=this.nvertices&&(this.nvertices=e,this.size_changed=!0),this.data_changed=!0}set_visuals_changed(){this.visuals_changed=!0}render(e,t,s){if(0==t.length)return!0;const{width:i,height:h}=this.glyph.renderer.plot_view.canvas_view.webgl.canvas,a={pixel_ratio:this.glyph.renderer.plot_view.canvas_view.pixel_ratio,width:i,height:h};return this.draw(t,s,a),!0}}s.BaseGLGlyph=a,a.__name__=\"BaseGLGlyph\"},\n", - " 423: function _(a,o,i,n,l){n();const t=a(52);i.cap_lookup={butt:0,round:1,square:2},i.join_lookup={miter:0,round:1,bevel:2};const _={blank:0,dot:1,ring:2,horizontal_line:3,vertical_line:4,cross:5,horizontal_dash:6,vertical_dash:7,spiral:8,right_diagonal_line:9,left_diagonal_line:10,diagonal_cross:11,right_diagonal_dash:12,left_diagonal_dash:13,horizontal_wave:14,vertical_wave:15,criss_cross:16};i.hatch_pattern_to_index=function(a){var o,i;return null!==(i=_[null!==(o=t.hatch_aliases[a])&&void 0!==o?o:a])&&void 0!==i?i:0}},\n", - " 424: function _(r,t,a,e,s){e();const i=r(423),_=r(22);class n{constructor(r){this.regl_wrapper=r,this.is_scalar=!0}get_sized_array(r){return null!=this.array&&this.array.length==r||(this.array=this.new_array(r)),this.array}is_normalized(){return!1}get length(){return null!=this.array?this.array.length:0}set_from_array(r){const t=r.length,a=this.get_sized_array(t);for(let e=0;e= 0.0 ? 1.0 : -1.0;\\n}\\n\\nvoid main()\\n{\\n if (a_show_curr < 0.5) {\\n // Line segment has non-finite value at one or both ends, do not render.\\n gl_Position = vec4(-2.0, -2.0, 0.0, 1.0);\\n return;\\n }\\n\\n const float min_miter_factor_round_join_mesh = sqrt(2.0);\\n\\n int join_type = int(u_line_join + 0.5);\\n int cap_type = int(u_line_cap + 0.5);\\n float halfwidth = 0.5*(u_linewidth + u_antialias);\\n vec2 segment_along = normalize(a_point_end - a_point_start); // unit vector.\\n v_segment_length = length(a_point_end - a_point_start);\\n vec2 segment_right = right_vector(segment_along); // unit vector.\\n vec2 xy;\\n\\n bool miter_too_large_start = false;\\n bool miter_too_large_end = false;\\n\\n v_coords.y = a_position.y*halfwidth; // Overwritten later for end points.\\n\\n bool has_start_cap = a_show_prev < 0.5;\\n bool has_end_cap = a_show_next < 0.5;\\n\\n vec2 point_normal_start;\\n float cos_theta_start;\\n float turn_right_start;\\n if (has_start_cap)\\n point_normal_start = segment_right;\\n else {\\n vec2 prev_right = right_vector(normalize(a_point_start - a_point_prev));\\n point_normal_start = normalize(segment_right + prev_right);\\n cos_theta_start = dot(segment_right, point_normal_start); // Always +ve\\n turn_right_start = sign_no_zero(dot(segment_right, a_point_prev - a_point_start));\\n }\\n\\n vec2 point_normal_end;\\n float cos_theta_end;\\n float turn_right_end;\\n if (has_end_cap)\\n point_normal_end = segment_right;\\n else {\\n vec2 next_right = right_vector(normalize(a_point_next - a_point_end));\\n point_normal_end = normalize(segment_right + next_right);\\n cos_theta_end = dot(segment_right, point_normal_end); // Always +ve\\n turn_right_end = sign_no_zero(dot(segment_right, a_point_next - a_point_end));\\n }\\n\\n float miter_factor_start = 1.0 / dot(segment_right, point_normal_start);\\n float miter_factor_end = 1.0 / dot(segment_right, point_normal_end);\\n if (join_type == miter_join) {\\n // If miter too large, use bevel join instead.\\n miter_too_large_start = (miter_factor_start > u_miter_limit);\\n miter_too_large_end = (miter_factor_end > u_miter_limit);\\n }\\n\\n float sign_at_start = -sign(a_position.x); // +ve at segment start, -ve end.\\n vec2 point = sign_at_start > 0.0 ? a_point_start : a_point_end;\\n vec2 adjacent_point =\\n sign_at_start > 0.0 ? (has_start_cap ? a_point_start : a_point_prev)\\n : (has_end_cap ? a_point_end : a_point_next);\\n\\n if ( (has_start_cap && sign_at_start > 0.0) ||\\n (has_end_cap && sign_at_start < 0.0) ) {\\n // Cap.\\n xy = point - segment_right*(halfwidth*a_position.y);\\n if (cap_type == butt_cap)\\n xy -= sign_at_start*0.5*u_antialias*segment_along;\\n else\\n xy -= sign_at_start*halfwidth*segment_along;\\n }\\n else { // Join.\\n // +ve if turning to right, -ve if to left.\\n float turn_sign = sign_at_start > 0.0 ? turn_right_start : turn_right_end;\\n\\n vec2 adjacent_right = sign_at_start*normalize(right_vector(point - adjacent_point));\\n vec2 point_right = normalize(segment_right + adjacent_right);\\n float miter_factor = sign_at_start > 0.0 ? miter_factor_start : miter_factor_end;\\n bool miter_too_large = sign_at_start > 0.0 ? miter_too_large_start : miter_too_large_end;\\n\\n if (abs(a_position.x) > 1.5) {\\n // Outer point, meets prev/next segment.\\n float factor; // multiplied by halfwidth...\\n\\n if (join_type == bevel_join || (join_type == miter_join && miter_too_large))\\n factor = 1.0 / miter_factor; // cos_theta.\\n else if (join_type == round_join &&\\n miter_factor > min_miter_factor_round_join_mesh)\\n factor = 1.0;\\n else // miter, or round (small angle only).\\n factor = miter_factor;\\n\\n xy = point - point_right*(halfwidth*turn_sign*factor);\\n v_coords.y = turn_sign*halfwidth*factor / miter_factor;\\n }\\n else if (turn_sign*a_position.y < 0.0) {\\n // Inner point, meets prev/next segment.\\n float len = halfwidth*miter_factor;\\n float segment_len = v_segment_length;\\n float adjacent_len = distance(point, adjacent_point);\\n\\n if (len <= min(segment_len, adjacent_len))\\n // Normal behaviour.\\n xy = point - point_right*(len*a_position.y);\\n else\\n // For short wide line segments the inner point using the above\\n // calculation can be outside of the line. Here clipping it.\\n xy = point + segment_right*(halfwidth*turn_sign);\\n }\\n else {\\n // Point along outside edge.\\n xy = point - segment_right*(halfwidth*a_position.y);\\n if (join_type == round_join &&\\n miter_factor > min_miter_factor_round_join_mesh) {\\n xy = line_intersection(xy, segment_along,\\n point - turn_sign*point_right*halfwidth,\\n right_vector(point_right));\\n }\\n }\\n }\\n\\n vec2 pos = xy + 0.5; // Bokeh's offset.\\n pos /= u_canvas_size / u_pixel_ratio; // in 0..1\\n gl_Position = vec4(2.0*pos.x - 1.0, 1.0 - 2.0*pos.y, 0.0, 1.0);\\n\\n v_coords.x = dot(xy - a_point_start, segment_along);\\n v_flags = float(int(has_start_cap) +\\n 2*int(has_end_cap) +\\n 4*int(miter_too_large_start) +\\n 8*int(miter_too_large_end));\\n v_cos_theta_turn_right_start = cos_theta_start*turn_right_start;\\n v_cos_theta_turn_right_end = cos_theta_end*turn_right_end;\\n\\n#ifdef DASHED\\n v_length_so_far = a_length_so_far;\\n#endif\\n}\\n\"},\n", + " 416: function _(n,t,a,i,e){i();a.default=\"\\nprecision mediump float;\\n\\nconst int butt_cap = 0;\\nconst int round_cap = 1;\\nconst int square_cap = 2;\\n\\nconst int miter_join = 0;\\nconst int round_join = 1;\\nconst int bevel_join = 2;\\n\\nuniform float u_linewidth;\\nuniform float u_antialias;\\nuniform float u_line_join;\\nuniform float u_line_cap;\\nuniform vec4 u_line_color;\\n#ifdef DASHED\\nuniform sampler2D u_dash_tex;\\nuniform vec4 u_dash_tex_info;\\nuniform float u_dash_scale;\\nuniform float u_dash_offset;\\n#endif\\n\\nvarying float v_segment_length;\\nvarying vec2 v_coords;\\nvarying float v_flags;\\nvarying float v_cos_theta_turn_right_start;\\nvarying float v_cos_theta_turn_right_end;\\n#ifdef DASHED\\nvarying float v_length_so_far;\\n#endif\\n\\nfloat cross_z(in vec2 v0, in vec2 v1)\\n{\\n return v0.x*v1.y - v0.y*v1.x;\\n}\\n\\nfloat point_line_side(in vec2 point, in vec2 start, in vec2 end)\\n{\\n // +ve if point to right of line.\\n // Alternatively could do dot product with right_vector.\\n return cross_z(point - start, end - start);\\n}\\n\\nfloat point_line_distance(in vec2 point, in vec2 start, in vec2 end)\\n{\\n return point_line_side(point, start, end) / distance(start, end);\\n}\\n\\nvec2 right_vector(in vec2 v)\\n{\\n return vec2(v.y, -v.x);\\n}\\n\\nfloat bevel_join_distance(in float sign_start, in float halfwidth)\\n{\\n float cos_theta_turn_right = sign_start > 0.0 ? v_cos_theta_turn_right_start\\n : v_cos_theta_turn_right_end;\\n float cos_theta = abs(cos_theta_turn_right);\\n float turn_right = sign(cos_theta_turn_right);\\n float distance_along = sign_start > 0.0 ? 0.0 : v_segment_length;\\n\\n // In v_coords reference frame (x is along segment, y across).\\n vec2 line_start = vec2(distance_along, halfwidth*turn_right);\\n float sin_alpha = cos_theta;\\n float cos_alpha = sqrt(1.0 - sin_alpha*sin_alpha);\\n vec2 line_along = vec2(-sign_start*turn_right*sin_alpha, -cos_alpha);\\n\\n return halfwidth + sign_start*point_line_distance(\\n v_coords, line_start, line_start+line_along);\\n}\\n\\nfloat cap(in int cap_type, in float x, in float y)\\n{\\n // x is distance along segment in direction away from end of segment,\\n // y is distance across segment.\\n if (cap_type == butt_cap)\\n return max(0.5*u_linewidth - x, abs(y));\\n else if (cap_type == square_cap)\\n return max(-x, abs(y));\\n else // cap_type == round_cap\\n return distance(vec2(min(x, 0.0), y), vec2(0.0, 0.0));\\n}\\n\\nfloat distance_to_alpha(in float dist)\\n{\\n return 1.0 - smoothstep(0.5*(u_linewidth - u_antialias),\\n 0.5*(u_linewidth + u_antialias), dist);\\n}\\n\\n#ifdef DASHED\\nfloat dash_distance(in float x)\\n{\\n // x is in direction of v_coords.x, i.e. along segment.\\n float tex_length = u_dash_tex_info.x;\\n float tex_offset = u_dash_tex_info.y;\\n float tex_dist_min = u_dash_tex_info.z;\\n float tex_dist_max = u_dash_tex_info.w;\\n\\n // Apply offset.\\n x += v_length_so_far - u_dash_scale*tex_offset + u_dash_offset;\\n\\n // Interpolate within texture to obtain distance to dash.\\n float dist = texture2D(u_dash_tex,\\n vec2(x / (tex_length*u_dash_scale), 0.0)).a;\\n\\n // Scale distance within min and max limits.\\n dist = tex_dist_min + dist*(tex_dist_max - tex_dist_min);\\n\\n return u_dash_scale*dist;\\n}\\n\\nfloat clip_dash_distance(in float x, in float offset, in float sign_along)\\n{\\n // Return clipped dash distance, sign_along is +1.0 if looking forward\\n // into next segment and -1.0 if looking backward into previous segment.\\n float half_antialias = 0.5*u_antialias;\\n\\n if (sign_along*x > half_antialias) {\\n // Outside antialias region, use usual dash distance.\\n return dash_distance(offset + x);\\n }\\n else {\\n // Inside antialias region.\\n // Dash distance at edge of antialias region clipped to half_antialias.\\n float edge_dist = min(dash_distance(offset + sign_along*half_antialias), half_antialias);\\n\\n // Physical distance from dash distance at edge of antialias region.\\n return edge_dist + sign_along*x - half_antialias;\\n }\\n}\\n\\nmat2 rotation_matrix(in float sign_start)\\n{\\n // Rotation matrix for v_coords from this segment to prev or next segment.\\n float cos_theta_turn_right = sign_start > 0.0 ? v_cos_theta_turn_right_start\\n : v_cos_theta_turn_right_end;\\n float cos_theta = abs(cos_theta_turn_right);\\n float turn_right = sign(cos_theta_turn_right);\\n\\n float sin_theta = sqrt(1.0 - cos_theta*cos_theta)*sign_start*turn_right;\\n float cos_2theta = 2.0*cos_theta*cos_theta - 1.0;\\n float sin_2theta = 2.0*sin_theta*cos_theta;\\n return mat2(cos_2theta, -sin_2theta, sin_2theta, cos_2theta);\\n}\\n#endif\\n\\nvoid main()\\n{\\n int join_type = int(u_line_join + 0.5);\\n int cap_type = int(u_line_cap + 0.5);\\n float halfwidth = 0.5*(u_linewidth + u_antialias);\\n float half_antialias = 0.5*u_antialias;\\n\\n // Extract flags.\\n int flags = int(v_flags + 0.5);\\n bool miter_too_large_end = (flags / 8 > 0);\\n flags -= 8*int(miter_too_large_end);\\n bool miter_too_large_start = (flags / 4 > 0);\\n flags -= 4*int(miter_too_large_start);\\n bool has_end_cap = (flags / 2 > 0);\\n flags -= 2*int(has_end_cap);\\n bool has_start_cap = flags > 0;\\n\\n float dist = v_coords.y; // For straight segment, and miter join.\\n\\n // Along-segment coords with respect to end of segment, +ve inside segment\\n // so equivalent to v_coords.x at start of segment.\\n float end_coords_x = v_segment_length - v_coords.x;\\n\\n if (v_coords.x <= half_antialias) {\\n // At start of segment, either cap or join.\\n if (has_start_cap)\\n dist = cap(cap_type, v_coords.x, v_coords.y);\\n else if (join_type == round_join)\\n dist = distance(v_coords, vec2(0.0, 0.0));\\n else if (join_type == bevel_join ||\\n (join_type == miter_join && miter_too_large_start))\\n dist = max(abs(dist), bevel_join_distance(1.0, halfwidth));\\n // else a miter join which uses the default dist calculation.\\n }\\n else if (end_coords_x <= half_antialias) {\\n // At end of segment, either cap or join.\\n if (has_end_cap)\\n dist = cap(cap_type, end_coords_x, v_coords.y);\\n else if (join_type == round_join)\\n dist = distance(v_coords, vec2(v_segment_length, 0));\\n else if ((join_type == bevel_join ||\\n (join_type == miter_join && miter_too_large_end)))\\n dist = max(abs(dist), bevel_join_distance(-1.0, halfwidth));\\n // else a miter join which uses the default dist calculation.\\n }\\n\\n float alpha = distance_to_alpha(abs(dist));\\n\\n#ifdef DASHED\\n if (u_dash_tex_info.x >= 0.0) {\\n // Dashes in straight segments (outside of joins) are easily calculated.\\n dist = dash_distance(v_coords.x);\\n\\n if (!has_start_cap && cap_type == butt_cap) {\\n if (v_coords.x < half_antialias) {\\n // Outer of start join rendered solid color or not at all\\n // depending on whether corner point is in dash or gap, with\\n // antialiased ends.\\n if (dash_distance(0.0) > 0.0) {\\n // Corner is solid color.\\n dist = max(dist, min(half_antialias, -v_coords.x));\\n // Avoid visible antialiasing band between corner and dash.\\n dist = max(dist, dash_distance(half_antialias));\\n }\\n else {\\n // Use large negative value so corner not colored.\\n dist = -halfwidth;\\n\\n if (v_coords.x > -half_antialias) {\\n // Consider antialias region of dash after start region.\\n float edge_dist = min(dash_distance(half_antialias), half_antialias);\\n dist = max(dist, edge_dist + v_coords.x - half_antialias);\\n }\\n }\\n }\\n\\n vec2 prev_coords = rotation_matrix(1.0)*v_coords;\\n\\n if (abs(prev_coords.y) < halfwidth && prev_coords.x < half_antialias) {\\n // Extend dashes across from end of previous segment, with antialiased end.\\n float new_dist = clip_dash_distance(prev_coords.x, 0.0, -1.0);\\n new_dist = min(new_dist, 0.5*u_linewidth - abs(prev_coords.y));\\n dist = max(dist, new_dist);\\n }\\n }\\n\\n if (!has_end_cap && cap_type == butt_cap) {\\n if (end_coords_x < half_antialias) {\\n // Similar for end join.\\n if (dash_distance(v_segment_length) > 0.0) {\\n // Corner is solid color.\\n dist = max(dist, min(half_antialias, -end_coords_x));\\n // Avoid visible antialiasing band between corner and dash.\\n dist = max(dist, dash_distance(v_segment_length - half_antialias));\\n }\\n else {\\n // Use large negative value so corner not colored.\\n dist = -halfwidth;\\n\\n if (end_coords_x > -half_antialias) {\\n // Consider antialias region of dash before end region.\\n float edge_dist = min(dash_distance(v_segment_length - half_antialias),\\n half_antialias);\\n dist = max(dist, edge_dist + end_coords_x - half_antialias);\\n }\\n }\\n }\\n\\n vec2 next_coords = rotation_matrix(-1.0)*(v_coords - vec2(v_segment_length, 0.0));\\n\\n if (abs(next_coords.y) < halfwidth && next_coords.x > -half_antialias) {\\n // Extend dashes across from next segment, with antialiased end.\\n float new_dist = clip_dash_distance(next_coords.x, v_segment_length, 1.0);\\n new_dist = min(new_dist, 0.5*u_linewidth - abs(next_coords.y));\\n dist = max(dist, new_dist);\\n }\\n }\\n\\n dist = cap(cap_type, dist, v_coords.y);\\n\\n float dash_alpha = distance_to_alpha(dist);\\n alpha = min(alpha, dash_alpha);\\n }\\n#endif\\n\\n alpha = u_line_color.a*alpha;\\n gl_FragColor = vec4(u_line_color.rgb*alpha, alpha); // Premultiplied alpha.\\n}\\n\"},\n", + " 417: function _(n,i,e,t,a){t();e.default=\"\\nprecision mediump float;\\n\\nattribute vec2 a_position;\\nattribute vec2 a_center;\\nattribute float a_width;\\nattribute float a_height;\\nattribute float a_angle; // In radians\\nattribute float a_linewidth;\\nattribute vec4 a_line_color;\\nattribute vec4 a_fill_color;\\nattribute float a_line_cap;\\nattribute float a_line_join;\\nattribute float a_show;\\n#ifdef HATCH\\nattribute float a_hatch_pattern;\\nattribute float a_hatch_scale;\\nattribute float a_hatch_weight;\\nattribute vec4 a_hatch_color;\\n#endif\\n\\nuniform float u_pixel_ratio;\\nuniform vec2 u_canvas_size;\\nuniform float u_antialias;\\nuniform float u_size_hint;\\n\\nvarying float v_linewidth;\\nvarying vec2 v_size; // 2D size for rects compared to 1D for markers.\\nvarying vec4 v_line_color;\\nvarying vec4 v_fill_color;\\nvarying float v_line_cap;\\nvarying float v_line_join;\\nvarying vec2 v_coords;\\n#ifdef HATCH\\nvarying float v_hatch_pattern;\\nvarying float v_hatch_scale;\\nvarying float v_hatch_weight;\\nvarying vec4 v_hatch_color;\\nvarying vec2 v_hatch_coords;\\n#endif\\n\\nvoid main()\\n{\\n if (a_show < 0.5) {\\n // Do not show this rect.\\n gl_Position = vec4(-2.0, -2.0, 0.0, 1.0);\\n return;\\n }\\n\\n v_size = vec2(a_width, a_height);\\n v_linewidth = a_linewidth;\\n v_line_color = a_line_color;\\n v_fill_color = a_fill_color;\\n v_line_cap = a_line_cap;\\n v_line_join = a_line_join;\\n\\n if (v_linewidth < 1.0) {\\n // Linewidth less than 1 is implemented as 1 but with reduced alpha.\\n v_line_color.a *= v_linewidth;\\n v_linewidth = 1.0;\\n }\\n\\n#ifdef HATCH\\n v_hatch_pattern = a_hatch_pattern;\\n v_hatch_scale = a_hatch_scale;\\n v_hatch_weight = a_hatch_weight;\\n v_hatch_color = a_hatch_color;\\n#endif\\n\\n vec2 enclosing_size;\\n // Need extra size of (v_linewidth+u_antialias) if edge of marker parallel to\\n // edge of bounding box. If symmetric spike towards edge then multiply by\\n // 1/cos(theta) where theta is angle between spike and bbox edges.\\n int size_hint = int(u_size_hint + 0.5);\\n if (size_hint == 1) // Dash\\n enclosing_size = vec2(v_size.x + v_linewidth + u_antialias,\\n v_linewidth + u_antialias);\\n else if (size_hint == 2) // Dot\\n enclosing_size = 0.25*v_size + u_antialias;\\n else if (size_hint == 3) // Diamond\\n enclosing_size = vec2(v_size.x*(2.0/3.0) + (v_linewidth + u_antialias)*1.20185,\\n v_size.y + (v_linewidth + u_antialias)*1.80278);\\n else if (size_hint == 4) // Hex\\n enclosing_size = v_size + (v_linewidth + u_antialias)*vec2(2.0/sqrt(3.0), 1.0);\\n else if (size_hint == 5) // Square pin\\n enclosing_size = v_size + (v_linewidth + u_antialias)*3.1;\\n else if (size_hint == 6) // Triangle\\n enclosing_size = vec2(v_size.x + (v_linewidth + u_antialias)*sqrt(3.0),\\n v_size.y*(2.0/sqrt(3.0)) + (v_linewidth + u_antialias)*2.0);\\n else if (size_hint == 7) // Triangle pin\\n enclosing_size = v_size + (v_linewidth + u_antialias)*vec2(4.8, 6.0);\\n else if (size_hint == 8) // Star\\n enclosing_size = vec2(v_size.x*0.95106 + (v_linewidth + u_antialias)*3.0,\\n v_size.y + (v_linewidth + u_antialias)*3.2);\\n else\\n enclosing_size = v_size + v_linewidth + u_antialias;\\n\\n // Coordinates in rotated frame with respect to center of marker, used for\\n // distance functions in fragment shader.\\n v_coords = a_position*enclosing_size;\\n\\n float c = cos(-a_angle);\\n float s = sin(-a_angle);\\n mat2 rotation = mat2(c, -s, s, c);\\n\\n vec2 pos = a_center + rotation*v_coords;\\n#ifdef HATCH\\n // Coordinates for hatching in unrotated frame of reference.\\n v_hatch_coords = pos - 0.5;\\n#endif\\n pos += 0.5; // Make up for Bokeh's offset.\\n pos /= u_canvas_size / u_pixel_ratio; // 0 to 1.\\n gl_Position = vec4(2.0*pos.x - 1.0, 1.0 - 2.0*pos.y, 0.0, 1.0);\\n}\\n\"},\n", + " 418: function _(n,i,e,t,a){t();e.default=\"\\nprecision mediump float;\\n\\nconst float SQRT2 = sqrt(2.0);\\nconst float SQRT3 = sqrt(3.0);\\nconst float PI = 3.14159265358979323846;\\n\\nconst int butt_cap = 0;\\nconst int round_cap = 1;\\nconst int square_cap = 2;\\n\\nconst int miter_join = 0;\\nconst int round_join = 1;\\nconst int bevel_join = 2;\\n\\n#ifdef HATCH\\nconst int hatch_dot = 1;\\nconst int hatch_ring = 2;\\nconst int hatch_horizontal_line = 3;\\nconst int hatch_vertical_line = 4;\\nconst int hatch_cross = 5;\\nconst int hatch_horizontal_dash = 6;\\nconst int hatch_vertical_dash = 7;\\nconst int hatch_spiral = 8;\\nconst int hatch_right_diagonal_line = 9;\\nconst int hatch_left_diagonal_line = 10;\\nconst int hatch_diagonal_cross = 11;\\nconst int hatch_right_diagonal_dash = 12;\\nconst int hatch_left_diagonal_dash = 13;\\nconst int hatch_horizontal_wave = 14;\\nconst int hatch_vertical_wave = 15;\\nconst int hatch_criss_cross = 16;\\n#endif\\n\\nuniform float u_antialias;\\n\\nvarying float v_linewidth;\\nvarying vec2 v_size;\\nvarying vec4 v_line_color;\\nvarying vec4 v_fill_color;\\nvarying float v_line_cap;\\nvarying float v_line_join;\\nvarying vec2 v_coords;\\n#ifdef HATCH\\nvarying float v_hatch_pattern;\\nvarying float v_hatch_scale;\\nvarying float v_hatch_weight;\\nvarying vec4 v_hatch_color;\\nvarying vec2 v_hatch_coords;\\n#endif\\n\\n// Lines within the marker (dot, cross, x and y) are added at the end as they are\\n// on top of the fill rather than astride it.\\n#if defined(USE_CIRCLE_DOT) || defined(USE_DIAMOND_DOT) || defined(USE_DOT) || defined(USE_HEX_DOT) || defined(USE_SQUARE_DOT) || defined(USE_STAR_DOT) || defined(USE_TRIANGLE_DOT)\\n #define APPEND_DOT\\n#endif\\n\\n#if defined(USE_CIRCLE_CROSS) || defined(USE_SQUARE_CROSS)\\n #define APPEND_CROSS\\n#endif\\n\\n#ifdef USE_DIAMOND_CROSS\\n #define APPEND_CROSS_2\\n#endif\\n\\n#ifdef USE_CIRCLE_X\\n #define APPEND_X\\n #define APPEND_X_LEN (0.5*v_size.x)\\n#endif\\n\\n#ifdef USE_SQUARE_X\\n #define APPEND_X\\n #define APPEND_X_LEN (v_size.x/SQRT2)\\n#endif\\n\\n#ifdef USE_CIRCLE_Y\\n #define APPEND_Y\\n#endif\\n\\n#if defined(USE_ASTERISK) || defined(USE_CROSS) || defined(USE_DASH) || defined(USE_DOT) || defined(USE_X) || defined(USE_Y)\\n // No fill.\\n #define LINE_ONLY\\n#endif\\n\\n#if defined(LINE_ONLY) || defined(APPEND_CROSS) || defined(APPEND_CROSS_2) || defined(APPEND_X) || defined(APPEND_Y)\\nfloat end_cap_distance(in vec2 p, in vec2 end_point, in vec2 unit_direction, in int line_cap)\\n{\\n vec2 offset = p - end_point;\\n if (line_cap == butt_cap)\\n return dot(offset, unit_direction) + 0.5*v_linewidth;\\n else if (line_cap == square_cap)\\n return dot(offset, unit_direction);\\n else if (line_cap == round_cap && dot(offset, unit_direction) > 0.0)\\n return length(offset);\\n else\\n // Default is outside of line and should be -0.5*(v_linewidth+u_antialias) or less,\\n // so here avoid the multiplication.\\n return -v_linewidth-u_antialias;\\n}\\n#endif\\n\\n#if !(defined(LINE_ONLY) || defined(USE_SQUARE_PIN) || defined(USE_TRIANGLE_PIN))\\n// For line join at a vec2 corner where 2 line segments meet, consider bevel points which are the 2\\n// points obtained by moving half a linewidth away from the corner point in the directions normal to\\n// the line segments. The line through these points is the bevel line, characterised by a vec2\\n// unit_normal and offset distance from the corner point. Edge of bevel join straddles this line,\\n// round join occurs outside of this line centred on the corner point. In general\\n// offset = (linewidth/2)*sin(alpha/2)\\n// where alpha is the angle between the 2 line segments at the corner.\\nfloat line_join_distance_no_miter(\\n in vec2 p, in vec2 corner, in vec2 unit_normal, in float offset, in int line_join)\\n{\\n // Simplified version of line_join_distance ignoring miter which most markers do implicitly\\n // as they are composed of straight line segments.\\n float dist_outside = dot((p - corner), unit_normal) - offset;\\n\\n if (line_join == bevel_join && dist_outside > -0.5*u_antialias)\\n return dist_outside + 0.5*v_linewidth;\\n else if (dist_outside > 0.0) // round_join\\n return distance(p, corner);\\n else\\n // Default is outside of line and should be -0.5*(v_linewidth+u_antialias) or less,\\n // so here avoid the multiplication.\\n return -v_linewidth-u_antialias;\\n}\\n#endif\\n\\n#if defined(USE_SQUARE_PIN) || defined(USE_TRIANGLE_PIN)\\n// Line join distance including miter but only one-sided check as assuming use of symmetry in\\n// calling function.\\nfloat line_join_distance_incl_miter(\\n in vec2 p, in vec2 corner, in vec2 unit_normal, in float offset, in int line_join,\\n vec2 miter_unit_normal)\\n{\\n float dist_outside = dot((p - corner), unit_normal) - offset;\\n\\n if (line_join == miter_join && dist_outside > 0.0)\\n return dot((p - corner), miter_unit_normal);\\n else if (line_join == bevel_join && dist_outside > -0.5*u_antialias)\\n return dist_outside + 0.5*v_linewidth;\\n else if (dist_outside > 0.0) // round_join\\n return distance(p, corner);\\n else\\n return -v_linewidth-u_antialias;\\n}\\n#endif\\n\\n#if defined(APPEND_CROSS) || defined(APPEND_X) || defined(USE_ASTERISK) || defined(USE_CROSS) || defined(USE_X)\\nfloat one_cross(in vec2 p, in int line_cap, in float len)\\n{\\n p = abs(p);\\n p = (p.y > p.x) ? p.yx : p.xy;\\n float dist = p.y;\\n float end_dist = end_cap_distance(p, vec2(len, 0.0), vec2(1.0, 0.0), line_cap);\\n return max(dist, end_dist);\\n}\\n#endif\\n\\n#ifdef APPEND_CROSS_2\\nfloat one_cross_2(in vec2 p, in int line_cap, in vec2 lengths)\\n{\\n // Cross with different length in x and y directions.\\n p = abs(p);\\n bool switch_xy = (p.y > p.x);\\n p = switch_xy ? p.yx : p.xy;\\n float len = switch_xy ? lengths.y : lengths.x;\\n float dist = p.y;\\n float end_dist = end_cap_distance(p, vec2(len, 0.0), vec2(1.0, 0.0), line_cap);\\n return max(dist, end_dist);\\n}\\n#endif\\n\\n#if defined(APPEND_Y) || defined(USE_Y)\\nfloat one_y(in vec2 p, in int line_cap, in float len)\\n{\\n p = vec2(abs(p.x), -p.y);\\n\\n // End point of line to right is (1/2, 1/3)*len*SQRT3.\\n // Unit vector along line is (1/2, 1/3)*k where k = 6/SQRT13.\\n const float k = 6.0/sqrt(13.0);\\n vec2 unit_along = vec2(0.5*k, k/3.0);\\n vec2 end_point = vec2(0.5*len*SQRT3, len*SQRT3/3.0);\\n float dist = max(abs(dot(p, vec2(-unit_along.y, unit_along.x))),\\n end_cap_distance(p, end_point, unit_along, line_cap));\\n\\n if (p.y < 0.0) {\\n // Vertical line.\\n float vert_dist = max(p.x,\\n end_cap_distance(p, vec2(0.0, -len), vec2(0.0, -1.0), line_cap));\\n dist = min(dist, vert_dist);\\n }\\n return dist;\\n}\\n#endif\\n\\n// One marker_distance function per marker type.\\n// Distance is zero on edge of marker, +ve outside and -ve inside.\\n\\n#ifdef USE_ASTERISK\\nfloat marker_distance(in vec2 p, in int line_cap, in int line_join)\\n{\\n // Assuming v_size.x == v.size_y\\n vec2 p_diag = vec2((p.x + p.y)/SQRT2, (p.x - p.y)/SQRT2);\\n float len = 0.5*v_size.x;\\n return min(one_cross(p, line_cap, len), // cross\\n one_cross(p_diag, line_cap, len)); // x\\n}\\n#endif\\n\\n#if defined(USE_CIRCLE) || defined(USE_CIRCLE_CROSS) || defined(USE_CIRCLE_DOT) || defined(USE_CIRCLE_X) || defined(USE_CIRCLE_Y)\\nfloat marker_distance(in vec2 p, in int line_cap, in int line_join)\\n{\\n // Assuming v_size.x == v.size_y\\n return length(p) - 0.5*v_size.x;\\n}\\n#endif\\n\\n#ifdef USE_CROSS\\nfloat marker_distance(in vec2 p, in int line_cap, in int line_join)\\n{\\n // Assuming v_size.x == v.size_y\\n return one_cross(p, line_cap, 0.5*v_size.x);\\n}\\n#endif\\n\\n#ifdef USE_DASH\\nfloat marker_distance(in vec2 p, in int line_cap, in int line_join)\\n{\\n p = abs(p);\\n float dist = p.y;\\n float end_dist = end_cap_distance(p, vec2(0.5*v_size.x, 0.0), vec2(1.0, 0.0), line_cap);\\n return max(dist, end_dist);\\n}\\n#endif\\n\\n#if defined(USE_DIAMOND) || defined(USE_DIAMOND_CROSS) || defined(USE_DIAMOND_DOT)\\nfloat marker_distance(in vec2 p, in int line_cap, in int line_join)\\n{\\n // Assuming v_size.x == v.size_y\\n // Only need to consider +ve quadrant, the 2 end points are (2r/3, 0) and (0, r)\\n // where r = radius = v_size.x/2.\\n // Line has outward-facing unit normal vec2(1, 2/3)/k where k = SQRT13/3\\n // hence vec2(3, 2)/SQRT13, and distance from origin of 2r/(3k) = 2r/SQRT13.\\n p = abs(p);\\n float r = 0.5*v_size.x;\\n const float SQRT13 = sqrt(13.0);\\n float dist = dot(p, vec2(3.0, 2.0))/SQRT13 - 2.0*r/SQRT13;\\n\\n if (line_join != miter_join) {\\n dist = max(dist, line_join_distance_no_miter(\\n p, vec2(0.0, r), vec2(0.0, 1.0), v_linewidth/SQRT13, line_join));\\n\\n dist = max(dist, line_join_distance_no_miter(\\n p, vec2(r*2.0/3.0, 0.0), vec2(1.0, 0.0), v_linewidth*(1.5/SQRT13), line_join));\\n }\\n\\n return dist;\\n}\\n#endif\\n\\n#ifdef USE_DOT\\nfloat marker_distance(in vec2 p, in int line_cap, in int line_join)\\n{\\n // Dot is always appended.\\n return v_linewidth+u_antialias;\\n}\\n#endif\\n\\n#if defined(USE_HEX) || defined(USE_HEX_DOT)\\nfloat marker_distance(in vec2 p, in int line_cap, in int line_join)\\n{\\n // A regular hexagon has v_size.x == v.size_y = r where r is the length of\\n // each of the 3 sides of the 6 equilateral triangles that comprise the hex.\\n // Only consider +ve quadrant, the 3 corners are at (0, h), (rx/2, h), (rx, 0)\\n // where rx = 0.5*v_size.x, ry = 0.5*v_size.y and h = ry*SQRT3/2.\\n // Sloping line has outward normal vec2(h, rx/2). Length of this is\\n // len = sqrt(h**2 + rx**2/4) to give unit normal (h, rx/2)/len and distance\\n // from origin of this line is rx*h/len.\\n p = abs(p);\\n float rx = v_size.x/2.0;\\n float h = v_size.y*(SQRT3/4.0);\\n float len_normal = sqrt(h*h + 0.25*rx*rx);\\n vec2 unit_normal = vec2(h, 0.5*rx) / len_normal;\\n float dist = max(dot(p, unit_normal) - rx*h/len_normal, // Distance from sloping line.\\n p.y - h); // Distance from horizontal line.\\n\\n if (line_join != miter_join) {\\n dist = max(dist, line_join_distance_no_miter(\\n p, vec2(rx, 0.0), vec2(1.0, 0.0), 0.5*v_linewidth*unit_normal.x, line_join));\\n\\n unit_normal = normalize(unit_normal + vec2(0.0, 1.0)); // At (rx/2, h) corner.\\n dist = max(dist, line_join_distance_no_miter(\\n p, vec2(0.5*rx, h), unit_normal, 0.5*v_linewidth*unit_normal.y, line_join));\\n }\\n return dist;\\n}\\n#endif\\n\\n#ifdef USE_PLUS\\nfloat marker_distance(in vec2 p, in int line_cap, in int line_join)\\n{\\n // Assuming v_size.x == v.size_y\\n // Only need to consider one octant, the +ve quadrant with x >= y.\\n p = abs(p);\\n p = (p.y > p.x) ? p.yx : p.xy;\\n\\n // 3 corners are (r, 0), (r, 3r/8) and (3r/8, 3r/8).\\n float r = 0.5*v_size.x;\\n p = p - vec2(r, 0.375*r); // Distance with respect to outside corner\\n float dist = max(p.x, p.y);\\n\\n if (line_join != miter_join) {\\n // Outside corner\\n dist = max(dist, line_join_distance_no_miter(\\n p, vec2(0.0, 0.0), vec2(1.0/SQRT2, 1.0/SQRT2), v_linewidth/(2.0*SQRT2), line_join));\\n\\n // Inside corner\\n dist = min(dist, -line_join_distance_no_miter(\\n p, vec2(-5.0*r/8.0, 0.0), vec2(-1.0/SQRT2, -1.0/SQRT2), v_linewidth/(2.0*SQRT2), line_join));\\n }\\n\\n return dist;\\n}\\n#endif\\n\\n#if defined(USE_SQUARE) || defined(USE_SQUARE_CROSS) || defined(USE_SQUARE_DOT) || defined(USE_SQUARE_X)\\nfloat marker_distance(in vec2 p, in int line_cap, in int line_join)\\n{\\n vec2 p2 = abs(p) - v_size/2.0; // Offset from corner\\n float dist = max(p2.x, p2.y);\\n\\n if (line_join != miter_join)\\n dist = max(dist, line_join_distance_no_miter(\\n p2, vec2(0.0, 0.0), vec2(1.0/SQRT2, 1.0/SQRT2), v_linewidth/(2.0*SQRT2), line_join));\\n\\n return dist;\\n}\\n#endif\\n\\n#ifdef USE_SQUARE_PIN\\nfloat marker_distance(in vec2 p, in int line_cap, in int line_join)\\n{\\n // Assuming v_size.x == v.size_y\\n p = abs(p);\\n p = (p.y > p.x) ? p.yx : p.xy;\\n // p is in octant between y=0 and y=x.\\n // Quadratic bezier curve passes through (r, r), (11r/16, 0) and (r, -r).\\n // Circular arc that passes through the same points has center at\\n // x = r + 231r/160 = 2.44275r and y = 0 and hence radius is\\n // x - 11r/16 = 1.75626 precisely.\\n float r = 0.5*v_size.x;\\n float center_x = r*2.44375;\\n float radius = r*1.75626;\\n float dist = radius - distance(p, vec2(center_x, 0.0));\\n\\n // Magic number is 0.5*sin(atan(8/5) - pi/4)\\n dist = max(dist, line_join_distance_incl_miter(\\n p, vec2(r, r), vec2(1.0/SQRT2, 1.0/SQRT2), v_linewidth*0.1124297533493792, line_join,\\n vec2(8.0/sqrt(89.0), -5.0/sqrt(89.0))));\\n\\n return dist;\\n}\\n#endif\\n\\n#if defined(USE_STAR) || defined(USE_STAR_DOT)\\nfloat marker_distance(in vec2 p, in int line_cap, in int line_join)\\n{\\n // Assuming v_size.x == v.size_y\\n const float SQRT5 = sqrt(5.0);\\n const float COS72 = 0.25*(SQRT5 - 1.0);\\n const float SIN72 = sqrt((5.0+SQRT5) / 8.0);\\n\\n float angle = atan(p.x, p.y); // In range -pi to +pi clockwise from +y direction.\\n angle = mod(angle, 0.4*PI) - 0.2*PI; // In range -pi/5 to +pi/5 clockwise from +y direction.\\n p = length(p)*vec2(cos(angle), abs(sin(angle))); // (x,y) in pi/10 (36 degree) sector.\\n\\n // 2 corners are at (r, 0) and (r-a*SIN72, a*COS72) where a = r sqrt(5-2*sqrt(5)).\\n // Line has outward-facing unit normal vec2(COS72, SIN72) and distance from\\n // origin of dot(vec2(r, 0), vec2(COS72, SIN72)) = r*COS72\\n float r = 0.5*v_size.x;\\n float a = r*sqrt(5.0 - 2.0*SQRT5);\\n float dist = dot(p, vec2(COS72, SIN72)) - r*COS72;\\n\\n if (line_join != miter_join) {\\n // Outside corner\\n dist = max(dist, line_join_distance_no_miter(\\n p, vec2(r, 0.0), vec2(1.0, 0.0), v_linewidth*(0.5*COS72), line_join));\\n\\n // Inside corner\\n const float COS36 = sqrt(0.5 + COS72/2.0);\\n const float SIN36 = sqrt(0.5 - COS72/2.0);\\n dist = min(dist, -line_join_distance_no_miter(\\n p, vec2(r-a*SIN72, a*COS72), vec2(-COS36, -SIN36), v_linewidth*(0.5*COS36), line_join));\\n }\\n\\n return dist;\\n}\\n#endif\\n\\n#if defined(USE_TRIANGLE) || defined(USE_TRIANGLE_DOT) || defined(USE_INVERTED_TRIANGLE)\\nfloat marker_distance(in vec2 p, in int line_cap, in int line_join)\\n{\\n // Assuming v_size.x == v.size_y\\n // For normal triangle 3 corners are at (-r, a), (r, a), (0, a-h)=(0, -2h/3)\\n // given r = radius = v_size.x/2, h = SQRT3*r, a = h/3.\\n // Sloping line has outward-facing unit normal vec2(h, -r)/2r = vec2(SQRT3, -1)/2\\n // and distance from origin of a. Horizontal line has outward-facing unit normal\\n // vec2(0, 1) and distance from origin of a.\\n float r = 0.5*v_size.x;\\n float a = r*SQRT3/3.0;\\n\\n // Only need to consider +ve x.\\n#ifdef USE_INVERTED_TRIANGLE\\n p = vec2(abs(p.x), -p.y);\\n#else\\n p = vec2(abs(p.x), p.y);\\n#endif\\n\\n float dist = max(0.5*dot(p, vec2(SQRT3, -1.0)) - a, // Distance from sloping line.\\n p.y - a); // Distance from horizontal line.\\n\\n if (line_join != miter_join) {\\n dist = max(dist, line_join_distance_no_miter(\\n p, vec2(0.0, -(2.0/SQRT3)*r), vec2(0.0, -1.0), v_linewidth*0.25, line_join));\\n\\n dist = max(dist, line_join_distance_no_miter(\\n p, vec2(r, a), vec2(SQRT3/2.0, 0.5), v_linewidth*0.25, line_join));\\n }\\n\\n return dist;\\n}\\n#endif\\n\\n#ifdef USE_TRIANGLE_PIN\\nfloat marker_distance(in vec2 p, in int line_cap, in int line_join)\\n{\\n // Assuming v_size.x == v.size_y\\n float angle = atan(p.x, -p.y); // In range -pi to +pi.\\n angle = mod(angle, PI*2.0/3.0) - PI/3.0; // In range -pi/3 to pi/3.\\n p = length(p)*vec2(cos(angle), abs(sin(angle))); // (x,y) in range 0 to pi/3.\\n // Quadratic bezier curve passes through (a, r), ((a+b)/2, 0) and (a, -r) where\\n // a = r/SQRT3, b = 3a/8 = r SQRT3/8. Circular arc that passes through the same points has\\n // center at (a+x, 0) and radius x+c where c = (a-b)/2 and x = (r**2 - c**2) / (2c).\\n // Ignore r factor until the end so can use const.\\n const float a = 1.0/SQRT3;\\n const float b = SQRT3/8.0;\\n const float c = (a-b)/2.0;\\n const float x = (1.0 - c*c) / (2.0*c);\\n const float center_x = x + a;\\n const float radius = x + c;\\n float r = 0.5*v_size.x;\\n float dist = r*radius - distance(p, vec2(r*center_x, 0.0));\\n\\n // Magic number is 0.5*sin(atan(8*sqrt(3)/5) - pi/3)\\n dist = max(dist, line_join_distance_incl_miter(\\n p, vec2(a*r, r), vec2(0.5, 0.5*SQRT3), v_linewidth*0.0881844526878324, line_join,\\n vec2(8.0*SQRT3, -5.0)/sqrt(217.0)));\\n\\n return dist;\\n}\\n#endif\\n\\n#ifdef USE_X\\nfloat marker_distance(in vec2 p, in int line_cap, in int line_join)\\n{\\n // Assuming v_size.x == v.size_y\\n p = vec2((p.x + p.y)/SQRT2, (p.x - p.y)/SQRT2);\\n return one_cross(p, line_cap, 0.5*v_size.x);\\n}\\n#endif\\n\\n#ifdef USE_Y\\nfloat marker_distance(in vec2 p, in int line_cap, in int line_join)\\n{\\n // Assuming v_size.x == v.size_y\\n return one_y(p, line_cap, 0.5*v_size.x);\\n}\\n#endif\\n\\n// Convert distance from edge of marker to fraction in range 0 to 1, depending\\n// on antialiasing width.\\nfloat distance_to_fraction(in float dist)\\n{\\n return 1.0 - smoothstep(-0.5*u_antialias, 0.5*u_antialias, dist);\\n}\\n\\n// Return fraction from 0 (no fill color) to 1 (full fill color).\\nfloat fill_fraction(in float dist)\\n{\\n return distance_to_fraction(dist);\\n}\\n\\n// Return fraction in range 0 (no line color) to 1 (full line color).\\nfloat line_fraction(in float dist)\\n{\\n return distance_to_fraction(abs(dist) - 0.5*v_linewidth);\\n}\\n\\n// Return fraction (in range 0 to 1) of a color, with premultiplied alpha.\\nvec4 fractional_color(in vec4 color, in float fraction)\\n{\\n color.a *= fraction;\\n color.rgb *= color.a;\\n return color;\\n}\\n\\n// Blend colors that have premultiplied alpha.\\nvec4 blend_colors(in vec4 src, in vec4 dest)\\n{\\n return (1.0 - src.a)*dest + src;\\n}\\n\\n#ifdef APPEND_DOT\\nfloat dot_fraction(in vec2 p)\\n{\\n // Assuming v_size.x == v_size.y\\n float radius = 0.125*v_size.x;\\n float dot_distance = max(length(p) - radius, -0.5*u_antialias);\\n return fill_fraction(dot_distance);\\n}\\n#endif\\n\\n#ifdef HATCH\\n// Wrap coordinate(s) by removing integer part to give distance from center of\\n// repeat, in the range -0.5 to +0.5.\\nfloat wrap(in float x)\\n{\\n return fract(x) - 0.5;\\n}\\n\\nvec2 wrap(in vec2 xy)\\n{\\n return fract(xy) - 0.5;\\n}\\n\\n// Return fraction from 0 (no hatch color) to 1 (full hatch color).\\nfloat hatch_fraction(in vec2 coords, in int hatch_pattern)\\n{\\n float scale = v_hatch_scale; // Hatch repeat distance.\\n\\n // Coordinates and linewidth/halfwidth are scaled to hatch repeat distance.\\n coords = coords / scale;\\n float halfwidth = 0.5*v_hatch_weight / scale; // Half the hatch linewidth.\\n\\n // Default is to return fraction of zero, i.e. no pattern.\\n float dist = u_antialias;\\n\\n if (hatch_pattern == hatch_dot) {\\n const float dot_radius = 0.25;\\n dist = length(wrap(coords)) - dot_radius;\\n }\\n else if (hatch_pattern == hatch_ring) {\\n const float ring_radius = 0.25;\\n dist = abs(length(wrap(coords)) - ring_radius) - halfwidth;\\n }\\n else if (hatch_pattern == hatch_horizontal_line) {\\n dist = abs(wrap(coords.y)) - halfwidth;\\n }\\n else if (hatch_pattern == hatch_vertical_line) {\\n dist = abs(wrap(coords.x)) - halfwidth;\\n }\\n else if (hatch_pattern == hatch_cross) {\\n dist = min(abs(wrap(coords.x)), abs(wrap(coords.y))) - halfwidth;\\n }\\n else if (hatch_pattern == hatch_horizontal_dash) {\\n // Dashes have square caps.\\n const float halflength = 0.25;\\n dist = max(abs(wrap(coords.y)),\\n abs(wrap(coords.x) + 0.25) - halflength) - halfwidth;\\n }\\n else if (hatch_pattern == hatch_vertical_dash) {\\n const float halflength = 0.25;\\n dist = max(abs(wrap(coords.x)),\\n abs(wrap(coords.y) + 0.25) - halflength) - halfwidth;\\n }\\n else if (hatch_pattern == hatch_spiral) {\\n vec2 wrap2 = wrap(coords);\\n float angle = wrap(atan(wrap2.y, wrap2.x) / (2.0*PI));\\n // Canvas spiral radius increases by scale*pi/15 each rotation.\\n const float dr = PI/15.0;\\n float radius = length(wrap2);\\n // At any angle, spiral lines are equally spaced dr apart.\\n // Find distance to nearest of these lines.\\n float frac = fract((radius - dr*angle) / dr); // 0 to 1.\\n dist = dr*(abs(frac - 0.5));\\n dist = min(dist, radius) - halfwidth; // Consider center point also.\\n }\\n else if (hatch_pattern == hatch_right_diagonal_line) {\\n dist = abs(wrap(2.0*coords.x + coords.y))/sqrt(5.0) - halfwidth;\\n }\\n else if (hatch_pattern == hatch_left_diagonal_line) {\\n dist = abs(wrap(2.0*coords.x - coords.y))/sqrt(5.0) - halfwidth;\\n }\\n else if (hatch_pattern == hatch_diagonal_cross) {\\n coords = vec2(coords.x + coords.y + 0.5, coords.x - coords.y + 0.5);\\n dist = min(abs(wrap(coords.x)), abs(wrap(coords.y))) / SQRT2 - halfwidth;\\n }\\n else if (hatch_pattern == hatch_right_diagonal_dash) {\\n float across = coords.x + coords.y + 0.5;\\n dist = abs(wrap(across)) / SQRT2; // Distance to nearest solid line.\\n\\n across = floor(across); // Offset for dash.\\n float along = wrap(0.5*(coords.x - coords.y + across));\\n const float halflength = 0.25;\\n along = abs(along) - halflength; // Distance along line.\\n\\n dist = max(dist, along) - halfwidth;\\n }\\n else if (hatch_pattern == hatch_left_diagonal_dash) {\\n float across = coords.x - coords.y + 0.5;\\n dist = abs(wrap(across)) / SQRT2; // Distance to nearest solid line.\\n\\n across = floor(across); // Offset for dash.\\n float along = wrap(0.5*(coords.x + coords.y + across));\\n const float halflength = 0.25;\\n along = abs(along) - halflength; // Distance along line.\\n\\n dist = max(dist, along) - halfwidth;\\n }\\n else if (hatch_pattern == hatch_horizontal_wave) {\\n float wrapx = wrap(coords.x);\\n float wrapy = wrap(coords.y - 0.25 + abs(wrapx));\\n dist = abs(wrapy) / SQRT2 - halfwidth;\\n }\\n else if (hatch_pattern == hatch_vertical_wave) {\\n float wrapy = wrap(coords.y);\\n float wrapx = wrap(coords.x - 0.25 + abs(wrapy));\\n dist = abs(wrapx) / SQRT2 - halfwidth;\\n }\\n else if (hatch_pattern == hatch_criss_cross) {\\n float plus = min(abs(wrap(coords.x)), abs(wrap(coords.y)));\\n\\n coords = vec2(coords.x + coords.y + 0.5, coords.x - coords.y + 0.5);\\n float X = min(abs(wrap(coords.x)), abs(wrap(coords.y))) / SQRT2;\\n\\n dist = min(plus, X) - halfwidth;\\n }\\n\\n return distance_to_fraction(dist*scale);\\n}\\n#endif\\n\\nvoid main()\\n{\\n int line_cap = int(v_line_cap + 0.5);\\n int line_join = int(v_line_join + 0.5);\\n#ifdef HATCH\\n int hatch_pattern = int(v_hatch_pattern + 0.5);\\n#endif\\n\\n float dist = marker_distance(v_coords, line_cap, line_join);\\n\\n#ifdef LINE_ONLY\\n vec4 color = vec4(0.0, 0.0, 0.0, 0.0);\\n#else\\n float fill_frac = fill_fraction(dist);\\n vec4 color = fractional_color(v_fill_color, fill_frac);\\n#endif\\n\\n#if defined(HATCH) && !defined(LINE_ONLY)\\n if (hatch_pattern > 0 && fill_frac > 0.0) {\\n float hatch_frac = hatch_fraction(v_hatch_coords, hatch_pattern);\\n vec4 hatch_color = fractional_color(v_hatch_color, hatch_frac*fill_frac);\\n color = blend_colors(hatch_color, color);\\n }\\n#endif\\n\\n float line_frac = line_fraction(dist);\\n\\n#ifdef APPEND_DOT\\n line_frac = max(line_frac, dot_fraction(v_coords));\\n#endif\\n#ifdef APPEND_CROSS\\n line_frac = max(line_frac, line_fraction(one_cross(v_coords, line_cap, 0.5*v_size.x)));\\n#endif\\n#ifdef APPEND_CROSS_2\\n vec2 lengths = vec2(v_size.x/3.0, v_size.x/2.0);\\n line_frac = max(line_frac, line_fraction(one_cross_2(v_coords, line_cap, lengths)));\\n#endif\\n#ifdef APPEND_X\\n vec2 p = vec2((v_coords.x + v_coords.y)/SQRT2, (v_coords.x - v_coords.y)/SQRT2);\\n line_frac = max(line_frac, line_fraction(one_cross(p, line_cap, APPEND_X_LEN)));\\n#endif\\n#ifdef APPEND_Y\\n line_frac = max(line_frac, line_fraction(one_y(v_coords, line_cap, 0.5*v_size.x)));\\n#endif\\n\\n if (line_frac > 0.0) {\\n vec4 line_color = fractional_color(v_line_color, line_frac);\\n color = blend_colors(line_color, color);\\n }\\n\\n gl_FragColor = color;\\n}\\n\"},\n", + " 419: function _(t,_,i,h,e){h();const s=t(420),a=t(421),r=t(422);class l extends s.BaseGLGlyph{constructor(t,_){super(t,_),this.glyph=_,this._antialias=1.5,this._show_all=!1}_draw_one_marker_type(t,_,i){const h={scissor:this.regl_wrapper.scissor,viewport:this.regl_wrapper.viewport,canvas_size:[_.width,_.height],pixel_ratio:_.pixel_ratio,center:i._centers,width:i._widths,height:i._heights,angle:i._angles,size_hint:(0,r.marker_type_to_size_hint)(t),nmarkers:i.nvertices,antialias:this._antialias,linewidth:this._linewidths,line_color:this._line_rgba,fill_color:this._fill_rgba,line_cap:this._line_caps,line_join:this._line_joins,show:this._show};if(this._have_hatch){const _=Object.assign(Object.assign({},h),{hatch_pattern:this._hatch_patterns,hatch_scale:this._hatch_scales,hatch_weight:this._hatch_weights,hatch_color:this._hatch_rgba});this.regl_wrapper.marker_hatch(t)(_)}else this.regl_wrapper.marker_no_hatch(t)(h)}_set_visuals(){const t=this._get_visuals(),_=t.fill,i=t.line;if(null==this._linewidths&&(this._linewidths=new a.Float32Buffer(this.regl_wrapper),this._line_caps=new a.Uint8Buffer(this.regl_wrapper),this._line_joins=new a.Uint8Buffer(this.regl_wrapper),this._line_rgba=new a.NormalizedUint8Buffer(this.regl_wrapper),this._fill_rgba=new a.NormalizedUint8Buffer(this.regl_wrapper)),this._linewidths.set_from_prop(i.line_width),this._line_caps.set_from_line_cap(i.line_cap),this._line_joins.set_from_line_join(i.line_join),this._line_rgba.set_from_color(i.line_color,i.line_alpha),this._fill_rgba.set_from_color(_.fill_color,_.fill_alpha),this._have_hatch=t.hatch.doit,this._have_hatch){const _=t.hatch;null==this._hatch_patterns&&(this._hatch_patterns=new a.Uint8Buffer(this.regl_wrapper),this._hatch_scales=new a.Float32Buffer(this.regl_wrapper),this._hatch_weights=new a.Float32Buffer(this.regl_wrapper),this._hatch_rgba=new a.NormalizedUint8Buffer(this.regl_wrapper)),this._hatch_patterns.set_from_hatch_pattern(_.hatch_pattern),this._hatch_scales.set_from_prop(_.hatch_scale),this._hatch_weights.set_from_prop(_.hatch_weight),this._hatch_rgba.set_from_color(_.hatch_color,_.hatch_alpha)}}}i.BaseMarkerGL=l,l.__name__=\"BaseMarkerGL\",l.missing_point=-1e4},\n", + " 420: function _(e,t,s,i,h){i();class a{constructor(e,t){this.glyph=t,this.nvertices=0,this.size_changed=!1,this.data_changed=!1,this.visuals_changed=!1,this.regl_wrapper=e}set_data_changed(){const{data_size:e}=this.glyph;e!=this.nvertices&&(this.nvertices=e,this.size_changed=!0),this.data_changed=!0}set_visuals_changed(){this.visuals_changed=!0}render(e,t,s){if(0==t.length)return!0;const{width:i,height:h}=this.glyph.renderer.plot_view.canvas_view.webgl.canvas,a={pixel_ratio:this.glyph.renderer.plot_view.canvas_view.pixel_ratio,width:i,height:h};return this.draw(t,s,a),!0}}s.BaseGLGlyph=a,a.__name__=\"BaseGLGlyph\"},\n", + " 421: function _(r,t,a,e,s){e();const i=r(422),_=r(22);class n{constructor(r){this.regl_wrapper=r,this.is_scalar=!0}get_sized_array(r){return null!=this.array&&this.array.length==r||(this.array=this.new_array(r)),this.array}is_normalized(){return!1}get length(){return null!=this.array?this.array.length:0}set_from_array(r){const t=r.length,a=this.get_sized_array(t);for(let e=0;e0}_set_data(){const s=this.glyph.sx.length,i=s-1;this._is_closed=s>2&&this.glyph.sx[0]==this.glyph.sx[s-1]&&this.glyph.sy[0]==this.glyph.sy[s-1]&&isFinite(this.glyph.sx[0])&&isFinite(this.glyph.sy[0]),null==this._points&&(this._points=new o.Float32Buffer(this.regl_wrapper));const t=this._points.get_sized_array(2*(s+2));for(let i=1;is/255)),this._linewidth=s.line_width.value,this._linewidth<1&&(this._color[3]*=this._linewidth,this._linewidth=1),this._line_dash=(0,a.resolve_line_dash)(s.line_dash.value),this._is_dashed()&&([this._dash_tex_info,this._dash_tex,this._dash_scale]=this.regl_wrapper.get_dash(this._line_dash),this._dash_offset=s.line_dash_offset.value)}}t.LineGL=r,r.__name__=\"LineGL\"},\n", + " 427: function _(s,t,i,e,r){e();const h=s(421),a=s(424);class n extends a.SingleMarkerGL{constructor(s,t){super(s,t),this.glyph=t}draw(s,t,i){this._draw_impl(s,i,t.glglyph,\"square\")}_get_visuals(){return this.glyph.visuals}_set_data(){const s=this.nvertices;null==this._centers&&(this._centers=new h.Float32Buffer(this.regl_wrapper),this._widths=new h.Float32Buffer(this.regl_wrapper),this._heights=new h.Float32Buffer(this.regl_wrapper),this._angles=new h.Float32Buffer(this.regl_wrapper),this._angles.set_from_scalar(0));const t=this._centers.get_sized_array(2*s),i=this._heights.get_sized_array(s),e=this._widths.get_sized_array(s);for(let r=0;r1||s.length<_){this._show_all=!1,n.fill(0),r=0;for(const e of s)1!=h&&i._marker_types.get(e)!=t||(n[e]=255,r++)}else this._show_all&&a==_||(this._show_all=!0,n.fill(255));this._show.update(),0!=r&&this._draw_one_marker_type(t,e,i)}}_get_visuals(){return this.glyph.visuals}_set_data(){const s=this.nvertices;null==this._centers&&(this._centers=new r.Float32Buffer(this.regl_wrapper),this._widths=new r.Float32Buffer(this.regl_wrapper),this._heights=this._widths,this._angles=new r.Float32Buffer(this.regl_wrapper));const t=this._centers.get_sized_array(2*s);for(let e=0;ethis.render()))}remove(){null!=this.icon_view&&this.icon_view.remove(),super.remove()}styles(){return[...super.styles(),d.default]}_render_button(...t){return(0,c.button)({type:\"button\",disabled:this.model.disabled,class:[h.btn,h[`btn_${this.model.button_type}`]]},...t)}render(){super.render(),this.button_el=this._render_button(this.model.label),this.button_el.addEventListener(\"click\",(()=>this.click())),null!=this.icon_view&&(\"\"!=this.model.label?(0,c.prepend)(this.button_el,this.icon_view.el,(0,c.nbsp)()):(0,c.prepend)(this.button_el,this.icon_view.el),this.icon_view.render()),this.group_el=(0,c.div)({class:h.btn_group},this.button_el),this.el.appendChild(this.group_el)}click(){}}n.AbstractButtonView=b,b.__name__=\"AbstractButtonView\";class p extends _.Control{constructor(t){super(t)}}n.AbstractButton=p,o=p,p.__name__=\"AbstractButton\",o.define((({String:t,Ref:e,Nullable:n})=>({label:[t,\"Button\"],icon:[n(e(a.AbstractIcon)),null],button_type:[r.ButtonType,\"default\"]})))},\n", - " 439: function _(t,e,o,s,n){s();const i=t(508),l=t(43);class c extends i.WidgetView{connect_signals(){super.connect_signals();const t=this.model.properties;this.on_change(t.disabled,(()=>{for(const t of this.controls())(0,l.toggle_attribute)(t,\"disabled\",this.model.disabled)}))}}o.ControlView=c,c.__name__=\"ControlView\";class r extends i.Widget{constructor(t){super(t)}}o.Control=r,r.__name__=\"Control\"},\n", - " 508: function _(i,e,t,n,o){var r;n();const s=i(312);class _ extends s.HTMLBoxView{get orientation(){return\"horizontal\"}get default_size(){return this.model.default_size}_width_policy(){return\"horizontal\"==this.orientation?super._width_policy():\"fixed\"}_height_policy(){return\"horizontal\"==this.orientation?\"fixed\":super._height_policy()}box_sizing(){const i=super.box_sizing();return\"horizontal\"==this.orientation?null==i.width&&(i.width=this.default_size):null==i.height&&(i.height=this.default_size),i}}t.WidgetView=_,_.__name__=\"WidgetView\";class h extends s.HTMLBox{constructor(i){super(i)}}t.Widget=h,r=h,h.__name__=\"Widget\",r.define((({Number:i})=>({default_size:[i,300]}))),r.override({margin:[5,5,5,5]})},\n", - " 441: function _(c,t,s,n,e){n();const o=c(53),_=c(226);class a extends _.DOMView{}s.AbstractIconView=a,a.__name__=\"AbstractIconView\";class r extends o.Model{constructor(c){super(c)}}s.AbstractIcon=r,r.__name__=\"AbstractIcon\"},\n", - " 442: function _(e,t,n,s,i){s();const h=e(1);var o;const _=e(443),u=e(43),r=e(10),c=(0,h.__importStar)(e(229)),a=c;class l extends _.TextInputView{constructor(){super(...arguments),this._open=!1,this._last_value=\"\",this._hover_index=0}styles(){return[...super.styles(),c.default]}render(){super.render(),this.input_el.addEventListener(\"keydown\",(e=>this._keydown(e))),this.input_el.addEventListener(\"keyup\",(e=>this._keyup(e))),this.menu=(0,u.div)({class:[a.menu,a.below]}),this.menu.addEventListener(\"click\",(e=>this._menu_click(e))),this.menu.addEventListener(\"mouseover\",(e=>this._menu_hover(e))),this.el.appendChild(this.menu),(0,u.undisplay)(this.menu)}change_input(){this._open&&this.menu.children.length>0?(this.model.value=this.menu.children[this._hover_index].textContent,this.input_el.focus(),this._hide_menu()):this.model.restrict||super.change_input()}_update_completions(e){(0,u.empty)(this.menu);for(const t of e){const e=(0,u.div)(t);this.menu.appendChild(e)}e.length>0&&this.menu.children[0].classList.add(a.active)}_show_menu(){if(!this._open){this._open=!0,this._hover_index=0,this._last_value=this.model.value,(0,u.display)(this.menu);const e=t=>{const{target:n}=t;n instanceof HTMLElement&&!this.el.contains(n)&&(document.removeEventListener(\"click\",e),this._hide_menu())};document.addEventListener(\"click\",e)}}_hide_menu(){this._open&&(this._open=!1,(0,u.undisplay)(this.menu))}_menu_click(e){e.target!=e.currentTarget&&e.target instanceof Element&&(this.model.value=e.target.textContent,this.input_el.focus(),this._hide_menu())}_menu_hover(e){if(e.target!=e.currentTarget&&e.target instanceof Element){let t=0;for(t=0;t0&&(this.menu.children[this._hover_index].classList.remove(a.active),this._hover_index=(0,r.clamp)(e,0,t-1),this.menu.children[this._hover_index].classList.add(a.active))}_keydown(e){}_keyup(e){switch(e.keyCode){case u.Keys.Enter:this.change_input();break;case u.Keys.Esc:this._hide_menu();break;case u.Keys.Up:this._bump_hover(this._hover_index-1);break;case u.Keys.Down:this._bump_hover(this._hover_index+1);break;default:{const e=this.input_el.value;if(e.lengthe:e=>e.toLowerCase();for(const n of this.model.completions)s(n).startsWith(s(e))&&t.push(n);this._update_completions(t),0==t.length?this._hide_menu():this._show_menu()}}}}n.AutocompleteInputView=l,l.__name__=\"AutocompleteInputView\";class d extends _.TextInput{constructor(e){super(e)}}n.AutocompleteInput=d,o=d,d.__name__=\"AutocompleteInput\",o.prototype.default_view=l,o.define((({Boolean:e,Int:t,String:n,Array:s})=>({completions:[s(n),[]],min_characters:[t,2],case_sensitive:[e,!0],restrict:[e,!0]})))},\n", - " 443: function _(t,e,n,p,_){p();const u=t(1);var i;const s=t(444),r=t(43),x=(0,u.__importStar)(t(446));class a extends s.TextLikeInputView{_render_input(){this.input_el=(0,r.input)({type:\"text\",class:x.input})}}n.TextInputView=a,a.__name__=\"TextInputView\";class c extends s.TextLikeInput{constructor(t){super(t)}}n.TextInput=c,i=c,c.__name__=\"TextInput\",i.prototype.default_view=a},\n", - " 444: function _(e,t,n,i,l){var s;i();const h=e(445);class a extends h.InputWidgetView{connect_signals(){super.connect_signals(),this.connect(this.model.properties.name.change,(()=>{var e;return this.input_el.name=null!==(e=this.model.name)&&void 0!==e?e:\"\"})),this.connect(this.model.properties.value.change,(()=>this.input_el.value=this.model.value)),this.connect(this.model.properties.value_input.change,(()=>this.input_el.value=this.model.value_input)),this.connect(this.model.properties.disabled.change,(()=>this.input_el.disabled=this.model.disabled)),this.connect(this.model.properties.placeholder.change,(()=>this.input_el.placeholder=this.model.placeholder)),this.connect(this.model.properties.max_length.change,(()=>{const{max_length:e}=this.model;null!=e?this.input_el.maxLength=e:this.input_el.removeAttribute(\"maxLength\")}))}render(){var e;super.render(),this._render_input();const{input_el:t}=this;t.name=null!==(e=this.model.name)&&void 0!==e?e:\"\",t.value=this.model.value,t.disabled=this.model.disabled,t.placeholder=this.model.placeholder,null!=this.model.max_length&&(t.maxLength=this.model.max_length),t.addEventListener(\"change\",(()=>this.change_input())),t.addEventListener(\"input\",(()=>this.change_input_value())),this.group_el.appendChild(t)}change_input(){this.model.value=this.input_el.value,super.change_input()}change_input_value(){this.model.value_input=this.input_el.value,super.change_input()}}n.TextLikeInputView=a,a.__name__=\"TextLikeInputView\";class u extends h.InputWidget{constructor(e){super(e)}}n.TextLikeInput=u,s=u,u.__name__=\"TextLikeInput\",s.define((({Int:e,String:t,Nullable:n})=>({value:[t,\"\"],value_input:[t,\"\"],placeholder:[t,\"\"],max_length:[n(e),null]})))},\n", - " 445: function _(e,t,n,s,l){s();const i=e(1);var o;const r=e(439),_=e(43),p=(0,i.__importStar)(e(446)),a=p;class c extends r.ControlView{*controls(){yield this.input_el}connect_signals(){super.connect_signals(),this.connect(this.model.properties.title.change,(()=>{this.label_el.textContent=this.model.title}))}styles(){return[...super.styles(),p.default]}render(){super.render();const{title:e}=this.model;this.label_el=(0,_.label)({style:{display:0==e.length?\"none\":\"\"}},e),this.group_el=(0,_.div)({class:a.input_group},this.label_el),this.el.appendChild(this.group_el)}change_input(){}}n.InputWidgetView=c,c.__name__=\"InputWidgetView\";class d extends r.Control{constructor(e){super(e)}}n.InputWidget=d,o=d,d.__name__=\"InputWidget\",o.define((({String:e})=>({title:[e,\"\"]})))},\n", - " 446: function _(o,p,t,n,i){n(),t.root=\"bk-root\",t.input=\"bk-input\",t.input_group=\"bk-input-group\",t.inline=\"bk-inline\",t.spin_wrapper=\"bk-spin-wrapper\",t.spin_btn=\"bk-spin-btn\",t.spin_btn_up=\"bk-spin-btn-up\",t.spin_btn_down=\"bk-spin-btn-down\",t.default='.bk-root .bk-input{display:inline-block;width:100%;flex-grow:1;min-height:31px;padding:0 12px;background-color:#fff;border:1px solid #ccc;border-radius:4px;}.bk-root .bk-input:focus{border-color:#66afe9;outline:0;box-shadow:inset 0 1px 1px rgba(0, 0, 0, 0.075), 0 0 8px rgba(102, 175, 233, 0.6);}.bk-root .bk-input::placeholder,.bk-root .bk-input:-ms-input-placeholder,.bk-root .bk-input::-moz-placeholder,.bk-root .bk-input::-webkit-input-placeholder{color:#999;opacity:1;}.bk-root .bk-input[disabled]{cursor:not-allowed;background-color:#eee;opacity:1;}.bk-root select:not([multiple]).bk-input,.bk-root select:not([size]).bk-input{height:auto;appearance:none;-webkit-appearance:none;background-image:url(\\'data:image/svg+xml;utf8,\\');background-position:right 0.5em center;background-size:8px 6px;background-repeat:no-repeat;}.bk-root select[multiple].bk-input,.bk-root select[size].bk-input,.bk-root textarea.bk-input{height:auto;}.bk-root .bk-input-group{width:100%;height:100%;display:inline-flex;flex-wrap:nowrap;align-items:start;flex-direction:column;white-space:nowrap;}.bk-root .bk-input-group.bk-inline{flex-direction:row;}.bk-root .bk-input-group.bk-inline > *:not(:first-child){margin-left:5px;}.bk-root .bk-input-group input[type=\"checkbox\"] + span,.bk-root .bk-input-group input[type=\"radio\"] + span{position:relative;top:-2px;margin-left:3px;}.bk-root .bk-input-group > .bk-spin-wrapper{display:inherit;width:inherit;height:inherit;position:relative;overflow:hidden;padding:0;vertical-align:middle;}.bk-root .bk-input-group > .bk-spin-wrapper input{padding-right:20px;}.bk-root .bk-input-group > .bk-spin-wrapper > .bk-spin-btn{position:absolute;display:block;height:50%;min-height:0;min-width:0;width:30px;padding:0;margin:0;right:0;border:none;background:none;cursor:pointer;}.bk-root .bk-input-group > .bk-spin-wrapper > .bk-spin-btn:before{content:\"\";display:inline-block;transform:translateY(-50%);border-left:5px solid transparent;border-right:5px solid transparent;}.bk-root .bk-input-group > .bk-spin-wrapper > .bk-spin-btn.bk-spin-btn-up{top:0;}.bk-root .bk-input-group > .bk-spin-wrapper > .bk-spin-btn.bk-spin-btn-up:before{border-bottom:5px solid black;}.bk-root .bk-input-group > .bk-spin-wrapper > .bk-spin-btn.bk-spin-btn-up:disabled:before{border-bottom-color:grey;}.bk-root .bk-input-group > .bk-spin-wrapper > .bk-spin-btn.bk-spin-btn-down{bottom:0;}.bk-root .bk-input-group > .bk-spin-wrapper > .bk-spin-btn.bk-spin-btn-down:before{border-top:5px solid black;}.bk-root .bk-input-group > .bk-spin-wrapper > .bk-spin-btn.bk-spin-btn-down:disabled:before{border-top-color:grey;}'},\n", - " 447: function _(t,e,n,o,c){var s;o();const u=t(438),r=t(251);class i extends u.AbstractButtonView{click(){this.model.trigger_event(new r.ButtonClick),super.click()}}n.ButtonView=i,i.__name__=\"ButtonView\";class _ extends u.AbstractButton{constructor(t){super(t)}}n.Button=_,s=_,_.__name__=\"Button\",s.prototype.default_view=i,s.override({label:\"Button\"})},\n", - " 448: function _(t,e,o,c,a){c();const s=t(1);var n;const i=t(449),r=t(43),u=(0,s.__importStar)(t(318));class _ extends i.ButtonGroupView{get active(){return new Set(this.model.active)}change_active(t){const{active:e}=this;e.has(t)?e.delete(t):e.add(t),this.model.active=[...e].sort()}_update_active(){const{active:t}=this;this._buttons.forEach(((e,o)=>{(0,r.classes)(e).toggle(u.active,t.has(o))}))}}o.CheckboxButtonGroupView=_,_.__name__=\"CheckboxButtonGroupView\";class h extends i.ButtonGroup{constructor(t){super(t)}}o.CheckboxButtonGroup=h,n=h,h.__name__=\"CheckboxButtonGroup\",n.prototype.default_view=_,n.define((({Int:t,Array:e})=>({active:[e(t),[]]})))},\n", - " 449: function _(t,e,n,s,i){s();const o=t(1);var r;const a=t(450),l=t(20),d=t(43),u=(0,o.__importStar)(t(318)),_=u;class c extends a.OrientedControlView{get default_size(){return\"horizontal\"==this.orientation?this.model.default_size:void 0}*controls(){yield*this._buttons}connect_signals(){super.connect_signals();const t=this.model.properties;this.on_change(t.button_type,(()=>this.render())),this.on_change(t.labels,(()=>this.render())),this.on_change(t.active,(()=>this._update_active()))}styles(){return[...super.styles(),u.default]}render(){super.render(),this._buttons=this.model.labels.map(((t,e)=>{const n=(0,d.div)({class:[_.btn,_[`btn_${this.model.button_type}`]],disabled:this.model.disabled},t);return n.addEventListener(\"click\",(()=>this.change_active(e))),n})),this._update_active();const t=\"horizontal\"==this.model.orientation?_.horizontal:_.vertical,e=(0,d.div)({class:[_.btn_group,t]},this._buttons);this.el.appendChild(e)}}n.ButtonGroupView=c,c.__name__=\"ButtonGroupView\";class h extends a.OrientedControl{constructor(t){super(t)}}n.ButtonGroup=h,r=h,h.__name__=\"ButtonGroup\",r.define((({String:t,Array:e})=>({labels:[e(t),[]],button_type:[l.ButtonType,\"default\"]})))},\n", - " 450: function _(n,t,e,o,r){var i;o();const a=n(439),l=n(20);class s extends a.ControlView{get orientation(){return this.model.orientation}}e.OrientedControlView=s,s.__name__=\"OrientedControlView\";class _ extends a.Control{constructor(n){super(n)}}e.OrientedControl=_,i=_,_.__name__=\"OrientedControl\",i.define((()=>({orientation:[l.Orientation,\"horizontal\"]})))},\n", - " 451: function _(e,t,n,i,s){i();const o=e(1);var a;const c=e(452),l=e(43),d=e(9),p=(0,o.__importStar)(e(446));class r extends c.InputGroupView{render(){super.render();const e=(0,l.div)({class:[p.input_group,this.model.inline?p.inline:null]});this.el.appendChild(e);const{active:t,labels:n}=this.model;this._inputs=[];for(let i=0;ithis.change_active(i))),this._inputs.push(s),this.model.disabled&&(s.disabled=!0),(0,d.includes)(t,i)&&(s.checked=!0);const o=(0,l.label)(s,(0,l.span)(n[i]));e.appendChild(o)}}change_active(e){const t=new Set(this.model.active);t.has(e)?t.delete(e):t.add(e),this.model.active=[...t].sort()}}n.CheckboxGroupView=r,r.__name__=\"CheckboxGroupView\";class h extends c.InputGroup{constructor(e){super(e)}}n.CheckboxGroup=h,a=h,h.__name__=\"CheckboxGroup\",a.prototype.default_view=r,a.define((({Boolean:e,Int:t,String:n,Array:i})=>({active:[i(t),[]],labels:[i(n),[]],inline:[e,!1]})))},\n", - " 452: function _(n,t,e,s,o){s();const r=n(1),u=n(439),c=(0,r.__importDefault)(n(446));class _ extends u.ControlView{*controls(){yield*this._inputs}connect_signals(){super.connect_signals(),this.connect(this.model.change,(()=>this.render()))}styles(){return[...super.styles(),c.default]}}e.InputGroupView=_,_.__name__=\"InputGroupView\";class i extends u.Control{constructor(n){super(n)}}e.InputGroup=i,i.__name__=\"InputGroup\"},\n", - " 453: function _(e,t,i,n,o){n();const s=e(1);var l;const r=e(445),c=e(43),a=e(22),d=(0,s.__importStar)(e(446));class h extends r.InputWidgetView{connect_signals(){super.connect_signals(),this.connect(this.model.properties.name.change,(()=>{var e;return this.input_el.name=null!==(e=this.model.name)&&void 0!==e?e:\"\"})),this.connect(this.model.properties.color.change,(()=>this.input_el.value=(0,a.color2hexrgb)(this.model.color))),this.connect(this.model.properties.disabled.change,(()=>this.input_el.disabled=this.model.disabled))}render(){super.render(),this.input_el=(0,c.input)({type:\"color\",class:d.input,name:this.model.name,value:this.model.color,disabled:this.model.disabled}),this.input_el.addEventListener(\"change\",(()=>this.change_input())),this.group_el.appendChild(this.input_el)}change_input(){this.model.color=this.input_el.value,super.change_input()}}i.ColorPickerView=h,h.__name__=\"ColorPickerView\";class p extends r.InputWidget{constructor(e){super(e)}}i.ColorPicker=p,l=p,p.__name__=\"ColorPicker\",l.prototype.default_view=h,l.define((({Color:e})=>({color:[e,\"#000000\"]})))},\n", - " 454: function _(e,t,i,n,s){n();const a=e(1);var l;const o=(0,a.__importDefault)(e(455)),d=e(445),r=e(43),c=e(20),u=e(8),h=(0,a.__importStar)(e(446)),_=(0,a.__importDefault)(e(456));function p(e){const t=[];for(const i of e)if((0,u.isString)(i))t.push(i);else{const[e,n]=i;t.push({from:e,to:n})}return t}class m extends d.InputWidgetView{connect_signals(){super.connect_signals();const{value:e,min_date:t,max_date:i,disabled_dates:n,enabled_dates:s,position:a,inline:l}=this.model.properties;this.connect(e.change,(()=>{var e;return null===(e=this._picker)||void 0===e?void 0:e.setDate(this.model.value)})),this.connect(t.change,(()=>{var e;return null===(e=this._picker)||void 0===e?void 0:e.set(\"minDate\",this.model.min_date)})),this.connect(i.change,(()=>{var e;return null===(e=this._picker)||void 0===e?void 0:e.set(\"maxDate\",this.model.max_date)})),this.connect(n.change,(()=>{var e;return null===(e=this._picker)||void 0===e?void 0:e.set(\"disable\",this.model.disabled_dates)})),this.connect(s.change,(()=>{var e;return null===(e=this._picker)||void 0===e?void 0:e.set(\"enable\",this.model.enabled_dates)})),this.connect(a.change,(()=>{var e;return null===(e=this._picker)||void 0===e?void 0:e.set(\"position\",this.model.position)})),this.connect(l.change,(()=>{var e;return null===(e=this._picker)||void 0===e?void 0:e.set(\"inline\",this.model.inline)}))}remove(){var e;null===(e=this._picker)||void 0===e||e.destroy(),super.remove()}styles(){return[...super.styles(),_.default]}render(){var e,t;null==this._picker&&(super.render(),this.input_el=(0,r.input)({type:\"text\",class:h.input,disabled:this.model.disabled}),this.group_el.appendChild(this.input_el),this._picker=(0,o.default)(this.input_el,{defaultDate:this.model.value,minDate:null!==(e=this.model.min_date)&&void 0!==e?e:void 0,maxDate:null!==(t=this.model.max_date)&&void 0!==t?t:void 0,inline:this.model.inline,position:this.model.position,disable:p(this.model.disabled_dates),enable:p(this.model.enabled_dates),onChange:(e,t,i)=>this._on_change(e,t,i)}))}_on_change(e,t,i){this.model.value=t,this.change_input()}}i.DatePickerView=m,m.__name__=\"DatePickerView\";class v extends d.InputWidget{constructor(e){super(e)}}i.DatePicker=v,l=v,v.__name__=\"DatePicker\",l.prototype.default_view=m,l.define((({Boolean:e,String:t,Array:i,Tuple:n,Or:s,Nullable:a})=>{const l=i(s(t,n(t,t)));return{value:[t],min_date:[a(t),null],max_date:[a(t),null],disabled_dates:[l,[]],enabled_dates:[l,[]],position:[c.CalendarPosition,\"auto\"],inline:[e,!1]}}))},\n", - " 455: function _(e,n,t,a,i){\n", + " 439: function _(t,e,i,o,r){o();const s=(0,t(1).__importStar)(t(440));i.Widgets=s;(0,t(7).register_models)(s)},\n", + " 440: function _(t,e,r,o,u){o(),u(\"AbstractButton\",t(441).AbstractButton),u(\"AbstractIcon\",t(444).AbstractIcon),u(\"AutocompleteInput\",t(445).AutocompleteInput),u(\"Button\",t(450).Button),u(\"CheckboxButtonGroup\",t(451).CheckboxButtonGroup),u(\"CheckboxGroup\",t(454).CheckboxGroup),u(\"ColorPicker\",t(456).ColorPicker),u(\"DatePicker\",t(457).DatePicker),u(\"DateRangeSlider\",t(460).DateRangeSlider),u(\"DateSlider\",t(465).DateSlider),u(\"DatetimeRangeSlider\",t(466).DatetimeRangeSlider),u(\"Div\",t(467).Div),u(\"Dropdown\",t(470).Dropdown),u(\"FileInput\",t(471).FileInput),u(\"InputWidget\",t(448).InputWidget),u(\"Markup\",t(468).Markup),u(\"MultiSelect\",t(472).MultiSelect),u(\"Paragraph\",t(473).Paragraph),u(\"PasswordInput\",t(474).PasswordInput),u(\"MultiChoice\",t(475).MultiChoice),u(\"NumericInput\",t(478).NumericInput),u(\"PreText\",t(479).PreText),u(\"RadioButtonGroup\",t(480).RadioButtonGroup),u(\"RadioGroup\",t(481).RadioGroup),u(\"RangeSlider\",t(482).RangeSlider),u(\"Select\",t(483).Select),u(\"Slider\",t(484).Slider),u(\"Spinner\",t(485).Spinner),u(\"TextInput\",t(446).TextInput),u(\"TextAreaInput\",t(486).TextAreaInput),u(\"Toggle\",t(487).Toggle),u(\"Widget\",t(512).Widget)},\n", + " 441: function _(t,e,n,i,s){i();const l=t(1);var o;const r=t(20),c=t(43),u=t(113),_=t(442),a=t(444),d=(0,l.__importStar)(t(318)),h=d;class b extends _.ControlView{*controls(){yield this.button_el}async lazy_initialize(){await super.lazy_initialize();const{icon:t}=this.model;null!=t&&(this.icon_view=await(0,u.build_view)(t,{parent:this}))}connect_signals(){super.connect_signals(),this.connect(this.model.change,(()=>this.render()))}remove(){null!=this.icon_view&&this.icon_view.remove(),super.remove()}styles(){return[...super.styles(),d.default]}_render_button(...t){return(0,c.button)({type:\"button\",disabled:this.model.disabled,class:[h.btn,h[`btn_${this.model.button_type}`]]},...t)}render(){super.render(),this.button_el=this._render_button(this.model.label),this.button_el.addEventListener(\"click\",(()=>this.click())),null!=this.icon_view&&(\"\"!=this.model.label?(0,c.prepend)(this.button_el,this.icon_view.el,(0,c.nbsp)()):(0,c.prepend)(this.button_el,this.icon_view.el),this.icon_view.render()),this.group_el=(0,c.div)({class:h.btn_group},this.button_el),this.el.appendChild(this.group_el)}click(){}}n.AbstractButtonView=b,b.__name__=\"AbstractButtonView\";class p extends _.Control{constructor(t){super(t)}}n.AbstractButton=p,o=p,p.__name__=\"AbstractButton\",o.define((({String:t,Ref:e,Nullable:n})=>({label:[t,\"Button\"],icon:[n(e(a.AbstractIcon)),null],button_type:[r.ButtonType,\"default\"]})))},\n", + " 442: function _(t,e,o,s,n){s();const i=t(512),l=t(43);class c extends i.WidgetView{connect_signals(){super.connect_signals();const t=this.model.properties;this.on_change(t.disabled,(()=>{for(const t of this.controls())(0,l.toggle_attribute)(t,\"disabled\",this.model.disabled)}))}}o.ControlView=c,c.__name__=\"ControlView\";class r extends i.Widget{constructor(t){super(t)}}o.Control=r,r.__name__=\"Control\"},\n", + " 512: function _(i,e,t,n,o){var r;n();const s=i(312);class _ extends s.HTMLBoxView{get orientation(){return\"horizontal\"}get default_size(){return this.model.default_size}_width_policy(){return\"horizontal\"==this.orientation?super._width_policy():\"fixed\"}_height_policy(){return\"horizontal\"==this.orientation?\"fixed\":super._height_policy()}box_sizing(){const i=super.box_sizing();return\"horizontal\"==this.orientation?null==i.width&&(i.width=this.default_size):null==i.height&&(i.height=this.default_size),i}}t.WidgetView=_,_.__name__=\"WidgetView\";class h extends s.HTMLBox{constructor(i){super(i)}}t.Widget=h,r=h,h.__name__=\"Widget\",r.define((({Number:i})=>({default_size:[i,300]}))),r.override({margin:[5,5,5,5]})},\n", + " 444: function _(c,t,s,n,e){n();const o=c(53),_=c(226);class a extends _.DOMView{}s.AbstractIconView=a,a.__name__=\"AbstractIconView\";class r extends o.Model{constructor(c){super(c)}}s.AbstractIcon=r,r.__name__=\"AbstractIcon\"},\n", + " 445: function _(e,t,n,s,i){s();const h=e(1);var o;const _=e(446),u=e(43),r=e(10),c=(0,h.__importStar)(e(229)),a=c;class l extends _.TextInputView{constructor(){super(...arguments),this._open=!1,this._last_value=\"\",this._hover_index=0}styles(){return[...super.styles(),c.default]}render(){super.render(),this.input_el.addEventListener(\"keydown\",(e=>this._keydown(e))),this.input_el.addEventListener(\"keyup\",(e=>this._keyup(e))),this.menu=(0,u.div)({class:[a.menu,a.below]}),this.menu.addEventListener(\"click\",(e=>this._menu_click(e))),this.menu.addEventListener(\"mouseover\",(e=>this._menu_hover(e))),this.el.appendChild(this.menu),(0,u.undisplay)(this.menu)}change_input(){this._open&&this.menu.children.length>0?(this.model.value=this.menu.children[this._hover_index].textContent,this.input_el.focus(),this._hide_menu()):this.model.restrict||super.change_input()}_update_completions(e){(0,u.empty)(this.menu);for(const t of e){const e=(0,u.div)(t);this.menu.appendChild(e)}e.length>0&&this.menu.children[0].classList.add(a.active)}_show_menu(){if(!this._open){this._open=!0,this._hover_index=0,this._last_value=this.model.value,(0,u.display)(this.menu);const e=t=>{const{target:n}=t;n instanceof HTMLElement&&!this.el.contains(n)&&(document.removeEventListener(\"click\",e),this._hide_menu())};document.addEventListener(\"click\",e)}}_hide_menu(){this._open&&(this._open=!1,(0,u.undisplay)(this.menu))}_menu_click(e){e.target!=e.currentTarget&&e.target instanceof Element&&(this.model.value=e.target.textContent,this.input_el.focus(),this._hide_menu())}_menu_hover(e){if(e.target!=e.currentTarget&&e.target instanceof Element){let t=0;for(t=0;t0&&(this.menu.children[this._hover_index].classList.remove(a.active),this._hover_index=(0,r.clamp)(e,0,t-1),this.menu.children[this._hover_index].classList.add(a.active))}_keydown(e){}_keyup(e){switch(e.keyCode){case u.Keys.Enter:this.change_input();break;case u.Keys.Esc:this._hide_menu();break;case u.Keys.Up:this._bump_hover(this._hover_index-1);break;case u.Keys.Down:this._bump_hover(this._hover_index+1);break;default:{const e=this.input_el.value;if(e.lengthe:e=>e.toLowerCase();for(const n of this.model.completions)s(n).startsWith(s(e))&&t.push(n);this._update_completions(t),0==t.length?this._hide_menu():this._show_menu()}}}}n.AutocompleteInputView=l,l.__name__=\"AutocompleteInputView\";class d extends _.TextInput{constructor(e){super(e)}}n.AutocompleteInput=d,o=d,d.__name__=\"AutocompleteInput\",o.prototype.default_view=l,o.define((({Boolean:e,Int:t,String:n,Array:s})=>({completions:[s(n),[]],min_characters:[t,2],case_sensitive:[e,!0],restrict:[e,!0]})))},\n", + " 446: function _(t,e,n,p,_){p();const u=t(1);var i;const s=t(447),r=t(43),x=(0,u.__importStar)(t(449));class a extends s.TextLikeInputView{_render_input(){this.input_el=(0,r.input)({type:\"text\",class:x.input})}}n.TextInputView=a,a.__name__=\"TextInputView\";class c extends s.TextLikeInput{constructor(t){super(t)}}n.TextInput=c,i=c,c.__name__=\"TextInput\",i.prototype.default_view=a},\n", + " 447: function _(e,t,n,i,l){var s;i();const h=e(448);class a extends h.InputWidgetView{connect_signals(){super.connect_signals(),this.connect(this.model.properties.name.change,(()=>{var e;return this.input_el.name=null!==(e=this.model.name)&&void 0!==e?e:\"\"})),this.connect(this.model.properties.value.change,(()=>this.input_el.value=this.model.value)),this.connect(this.model.properties.value_input.change,(()=>this.input_el.value=this.model.value_input)),this.connect(this.model.properties.disabled.change,(()=>this.input_el.disabled=this.model.disabled)),this.connect(this.model.properties.placeholder.change,(()=>this.input_el.placeholder=this.model.placeholder)),this.connect(this.model.properties.max_length.change,(()=>{const{max_length:e}=this.model;null!=e?this.input_el.maxLength=e:this.input_el.removeAttribute(\"maxLength\")}))}render(){var e;super.render(),this._render_input();const{input_el:t}=this;t.name=null!==(e=this.model.name)&&void 0!==e?e:\"\",t.value=this.model.value,t.disabled=this.model.disabled,t.placeholder=this.model.placeholder,null!=this.model.max_length&&(t.maxLength=this.model.max_length),t.addEventListener(\"change\",(()=>this.change_input())),t.addEventListener(\"input\",(()=>this.change_input_value())),this.group_el.appendChild(t)}change_input(){this.model.value=this.input_el.value,super.change_input()}change_input_value(){this.model.value_input=this.input_el.value,super.change_input()}}n.TextLikeInputView=a,a.__name__=\"TextLikeInputView\";class u extends h.InputWidget{constructor(e){super(e)}}n.TextLikeInput=u,s=u,u.__name__=\"TextLikeInput\",s.define((({Int:e,String:t,Nullable:n})=>({value:[t,\"\"],value_input:[t,\"\"],placeholder:[t,\"\"],max_length:[n(e),null]})))},\n", + " 448: function _(e,t,n,s,l){s();const i=e(1);var o;const r=e(442),_=e(43),p=(0,i.__importStar)(e(449)),a=p;class c extends r.ControlView{*controls(){yield this.input_el}connect_signals(){super.connect_signals(),this.connect(this.model.properties.title.change,(()=>{this.label_el.textContent=this.model.title}))}styles(){return[...super.styles(),p.default]}render(){super.render();const{title:e}=this.model;this.label_el=(0,_.label)({style:{display:0==e.length?\"none\":\"\"}},e),this.group_el=(0,_.div)({class:a.input_group},this.label_el),this.el.appendChild(this.group_el)}change_input(){}}n.InputWidgetView=c,c.__name__=\"InputWidgetView\";class d extends r.Control{constructor(e){super(e)}}n.InputWidget=d,o=d,d.__name__=\"InputWidget\",o.define((({String:e})=>({title:[e,\"\"]})))},\n", + " 449: function _(o,p,t,n,i){n(),t.root=\"bk-root\",t.input=\"bk-input\",t.input_group=\"bk-input-group\",t.inline=\"bk-inline\",t.spin_wrapper=\"bk-spin-wrapper\",t.spin_btn=\"bk-spin-btn\",t.spin_btn_up=\"bk-spin-btn-up\",t.spin_btn_down=\"bk-spin-btn-down\",t.default='.bk-root .bk-input{display:inline-block;width:100%;flex-grow:1;min-height:31px;padding:0 12px;background-color:#fff;border:1px solid #ccc;border-radius:4px;}.bk-root .bk-input:focus{border-color:#66afe9;outline:0;box-shadow:inset 0 1px 1px rgba(0, 0, 0, 0.075), 0 0 8px rgba(102, 175, 233, 0.6);}.bk-root .bk-input::placeholder,.bk-root .bk-input:-ms-input-placeholder,.bk-root .bk-input::-moz-placeholder,.bk-root .bk-input::-webkit-input-placeholder{color:#999;opacity:1;}.bk-root .bk-input[disabled]{cursor:not-allowed;background-color:#eee;opacity:1;}.bk-root select:not([multiple]).bk-input,.bk-root select:not([size]).bk-input{height:auto;appearance:none;-webkit-appearance:none;background-image:url(\\'data:image/svg+xml;utf8,\\');background-position:right 0.5em center;background-size:8px 6px;background-repeat:no-repeat;}.bk-root select[multiple].bk-input,.bk-root select[size].bk-input,.bk-root textarea.bk-input{height:auto;}.bk-root .bk-input-group{width:100%;height:100%;display:inline-flex;flex-wrap:nowrap;align-items:start;flex-direction:column;white-space:nowrap;}.bk-root .bk-input-group.bk-inline{flex-direction:row;}.bk-root .bk-input-group.bk-inline > *:not(:first-child){margin-left:5px;}.bk-root .bk-input-group input[type=\"checkbox\"] + span,.bk-root .bk-input-group input[type=\"radio\"] + span{position:relative;top:-2px;margin-left:3px;}.bk-root .bk-input-group > .bk-spin-wrapper{display:inherit;width:inherit;height:inherit;position:relative;overflow:hidden;padding:0;vertical-align:middle;}.bk-root .bk-input-group > .bk-spin-wrapper input{padding-right:20px;}.bk-root .bk-input-group > .bk-spin-wrapper > .bk-spin-btn{position:absolute;display:block;height:50%;min-height:0;min-width:0;width:30px;padding:0;margin:0;right:0;border:none;background:none;cursor:pointer;}.bk-root .bk-input-group > .bk-spin-wrapper > .bk-spin-btn:before{content:\"\";display:inline-block;transform:translateY(-50%);border-left:5px solid transparent;border-right:5px solid transparent;}.bk-root .bk-input-group > .bk-spin-wrapper > .bk-spin-btn.bk-spin-btn-up{top:0;}.bk-root .bk-input-group > .bk-spin-wrapper > .bk-spin-btn.bk-spin-btn-up:before{border-bottom:5px solid black;}.bk-root .bk-input-group > .bk-spin-wrapper > .bk-spin-btn.bk-spin-btn-up:disabled:before{border-bottom-color:grey;}.bk-root .bk-input-group > .bk-spin-wrapper > .bk-spin-btn.bk-spin-btn-down{bottom:0;}.bk-root .bk-input-group > .bk-spin-wrapper > .bk-spin-btn.bk-spin-btn-down:before{border-top:5px solid black;}.bk-root .bk-input-group > .bk-spin-wrapper > .bk-spin-btn.bk-spin-btn-down:disabled:before{border-top-color:grey;}'},\n", + " 450: function _(t,e,n,o,c){var s;o();const u=t(441),r=t(251);class i extends u.AbstractButtonView{click(){this.model.trigger_event(new r.ButtonClick),super.click()}}n.ButtonView=i,i.__name__=\"ButtonView\";class _ extends u.AbstractButton{constructor(t){super(t)}}n.Button=_,s=_,_.__name__=\"Button\",s.prototype.default_view=i,s.override({label:\"Button\"})},\n", + " 451: function _(t,e,o,c,a){c();const s=t(1);var n;const i=t(452),r=t(43),u=(0,s.__importStar)(t(318));class _ extends i.ButtonGroupView{get active(){return new Set(this.model.active)}change_active(t){const{active:e}=this;e.has(t)?e.delete(t):e.add(t),this.model.active=[...e].sort()}_update_active(){const{active:t}=this;this._buttons.forEach(((e,o)=>{(0,r.classes)(e).toggle(u.active,t.has(o))}))}}o.CheckboxButtonGroupView=_,_.__name__=\"CheckboxButtonGroupView\";class h extends i.ButtonGroup{constructor(t){super(t)}}o.CheckboxButtonGroup=h,n=h,h.__name__=\"CheckboxButtonGroup\",n.prototype.default_view=_,n.define((({Int:t,Array:e})=>({active:[e(t),[]]})))},\n", + " 452: function _(t,e,n,s,i){s();const o=t(1);var r;const a=t(453),l=t(20),d=t(43),u=(0,o.__importStar)(t(318)),_=u;class c extends a.OrientedControlView{get default_size(){return\"horizontal\"==this.orientation?this.model.default_size:void 0}*controls(){yield*this._buttons}connect_signals(){super.connect_signals();const t=this.model.properties;this.on_change(t.button_type,(()=>this.render())),this.on_change(t.labels,(()=>this.render())),this.on_change(t.active,(()=>this._update_active()))}styles(){return[...super.styles(),u.default]}render(){super.render(),this._buttons=this.model.labels.map(((t,e)=>{const n=(0,d.div)({class:[_.btn,_[`btn_${this.model.button_type}`]],disabled:this.model.disabled},t);return n.addEventListener(\"click\",(()=>this.change_active(e))),n})),this._update_active();const t=\"horizontal\"==this.model.orientation?_.horizontal:_.vertical,e=(0,d.div)({class:[_.btn_group,t]},this._buttons);this.el.appendChild(e)}}n.ButtonGroupView=c,c.__name__=\"ButtonGroupView\";class h extends a.OrientedControl{constructor(t){super(t)}}n.ButtonGroup=h,r=h,h.__name__=\"ButtonGroup\",r.define((({String:t,Array:e})=>({labels:[e(t),[]],button_type:[l.ButtonType,\"default\"]})))},\n", + " 453: function _(n,t,e,o,r){var i;o();const a=n(442),l=n(20);class s extends a.ControlView{get orientation(){return this.model.orientation}}e.OrientedControlView=s,s.__name__=\"OrientedControlView\";class _ extends a.Control{constructor(n){super(n)}}e.OrientedControl=_,i=_,_.__name__=\"OrientedControl\",i.define((()=>({orientation:[l.Orientation,\"horizontal\"]})))},\n", + " 454: function _(e,t,n,i,s){i();const o=e(1);var a;const c=e(455),l=e(43),d=e(9),p=(0,o.__importStar)(e(449));class r extends c.InputGroupView{render(){super.render();const e=(0,l.div)({class:[p.input_group,this.model.inline?p.inline:null]});this.el.appendChild(e);const{active:t,labels:n}=this.model;this._inputs=[];for(let i=0;ithis.change_active(i))),this._inputs.push(s),this.model.disabled&&(s.disabled=!0),(0,d.includes)(t,i)&&(s.checked=!0);const o=(0,l.label)(s,(0,l.span)(n[i]));e.appendChild(o)}}change_active(e){const t=new Set(this.model.active);t.has(e)?t.delete(e):t.add(e),this.model.active=[...t].sort()}}n.CheckboxGroupView=r,r.__name__=\"CheckboxGroupView\";class h extends c.InputGroup{constructor(e){super(e)}}n.CheckboxGroup=h,a=h,h.__name__=\"CheckboxGroup\",a.prototype.default_view=r,a.define((({Boolean:e,Int:t,String:n,Array:i})=>({active:[i(t),[]],labels:[i(n),[]],inline:[e,!1]})))},\n", + " 455: function _(n,t,e,s,o){s();const r=n(1),u=n(442),c=(0,r.__importDefault)(n(449));class _ extends u.ControlView{*controls(){yield*this._inputs}connect_signals(){super.connect_signals(),this.connect(this.model.change,(()=>this.render()))}styles(){return[...super.styles(),c.default]}}e.InputGroupView=_,_.__name__=\"InputGroupView\";class i extends u.Control{constructor(n){super(n)}}e.InputGroup=i,i.__name__=\"InputGroup\"},\n", + " 456: function _(e,t,i,n,o){n();const s=e(1);var l;const r=e(448),c=e(43),a=e(22),d=(0,s.__importStar)(e(449));class h extends r.InputWidgetView{connect_signals(){super.connect_signals(),this.connect(this.model.properties.name.change,(()=>{var e;return this.input_el.name=null!==(e=this.model.name)&&void 0!==e?e:\"\"})),this.connect(this.model.properties.color.change,(()=>this.input_el.value=(0,a.color2hexrgb)(this.model.color))),this.connect(this.model.properties.disabled.change,(()=>this.input_el.disabled=this.model.disabled))}render(){super.render(),this.input_el=(0,c.input)({type:\"color\",class:d.input,name:this.model.name,value:this.model.color,disabled:this.model.disabled}),this.input_el.addEventListener(\"change\",(()=>this.change_input())),this.group_el.appendChild(this.input_el)}change_input(){this.model.color=this.input_el.value,super.change_input()}}i.ColorPickerView=h,h.__name__=\"ColorPickerView\";class p extends r.InputWidget{constructor(e){super(e)}}i.ColorPicker=p,l=p,p.__name__=\"ColorPicker\",l.prototype.default_view=h,l.define((({Color:e})=>({color:[e,\"#000000\"]})))},\n", + " 457: function _(e,t,i,n,s){n();const a=e(1);var l;const o=(0,a.__importDefault)(e(458)),d=e(448),r=e(43),c=e(20),u=e(8),h=(0,a.__importStar)(e(449)),_=(0,a.__importDefault)(e(459));function p(e){const t=[];for(const i of e)if((0,u.isString)(i))t.push(i);else{const[e,n]=i;t.push({from:e,to:n})}return t}class m extends d.InputWidgetView{connect_signals(){super.connect_signals();const{value:e,min_date:t,max_date:i,disabled_dates:n,enabled_dates:s,position:a,inline:l}=this.model.properties;this.connect(e.change,(()=>{var e;return null===(e=this._picker)||void 0===e?void 0:e.setDate(this.model.value)})),this.connect(t.change,(()=>{var e;return null===(e=this._picker)||void 0===e?void 0:e.set(\"minDate\",this.model.min_date)})),this.connect(i.change,(()=>{var e;return null===(e=this._picker)||void 0===e?void 0:e.set(\"maxDate\",this.model.max_date)})),this.connect(n.change,(()=>{var e;return null===(e=this._picker)||void 0===e?void 0:e.set(\"disable\",this.model.disabled_dates)})),this.connect(s.change,(()=>{var e;return null===(e=this._picker)||void 0===e?void 0:e.set(\"enable\",this.model.enabled_dates)})),this.connect(a.change,(()=>{var e;return null===(e=this._picker)||void 0===e?void 0:e.set(\"position\",this.model.position)})),this.connect(l.change,(()=>{var e;return null===(e=this._picker)||void 0===e?void 0:e.set(\"inline\",this.model.inline)}))}remove(){var e;null===(e=this._picker)||void 0===e||e.destroy(),super.remove()}styles(){return[...super.styles(),_.default]}render(){var e,t;null==this._picker&&(super.render(),this.input_el=(0,r.input)({type:\"text\",class:h.input,disabled:this.model.disabled}),this.group_el.appendChild(this.input_el),this._picker=(0,o.default)(this.input_el,{defaultDate:this.model.value,minDate:null!==(e=this.model.min_date)&&void 0!==e?e:void 0,maxDate:null!==(t=this.model.max_date)&&void 0!==t?t:void 0,inline:this.model.inline,position:this.model.position,disable:p(this.model.disabled_dates),enable:p(this.model.enabled_dates),onChange:(e,t,i)=>this._on_change(e,t,i)}))}_on_change(e,t,i){this.model.value=t,this.change_input()}}i.DatePickerView=m,m.__name__=\"DatePickerView\";class v extends d.InputWidget{constructor(e){super(e)}}i.DatePicker=v,l=v,v.__name__=\"DatePicker\",l.prototype.default_view=m,l.define((({Boolean:e,String:t,Array:i,Tuple:n,Or:s,Nullable:a})=>{const l=i(s(t,n(t,t)));return{value:[t],min_date:[a(t),null],max_date:[a(t),null],disabled_dates:[l,[]],enabled_dates:[l,[]],position:[c.CalendarPosition,\"auto\"],inline:[e,!1]}}))},\n", + " 458: function _(e,n,t,a,i){\n", " /* flatpickr v4.6.6, @license MIT */var o,r;o=this,r=function(){\"use strict\";\n", " /*! *****************************************************************************\n", " Copyright (c) Microsoft Corporation.\n", @@ -978,23 +986,24 @@ " OTHER TORTIOUS ACTION, ARISING OUT OF OR IN CONNECTION WITH THE USE OR\n", " PERFORMANCE OF THIS SOFTWARE.\n", " ***************************************************************************** */var e=function(){return e=Object.assign||function(e){for(var n,t=1,a=arguments.length;t\",noCalendar:!1,now:new Date,onChange:[],onClose:[],onDayCreate:[],onDestroy:[],onKeyDown:[],onMonthChange:[],onOpen:[],onParseConfig:[],onReady:[],onValueUpdate:[],onYearChange:[],onPreCalendarPosition:[],plugins:[],position:\"auto\",positionElement:void 0,prevArrow:\"\",shorthandCurrentMonth:!1,showMonths:1,static:!1,time_24hr:!1,weekNumbers:!1,wrap:!1},i={weekdays:{shorthand:[\"Sun\",\"Mon\",\"Tue\",\"Wed\",\"Thu\",\"Fri\",\"Sat\"],longhand:[\"Sunday\",\"Monday\",\"Tuesday\",\"Wednesday\",\"Thursday\",\"Friday\",\"Saturday\"]},months:{shorthand:[\"Jan\",\"Feb\",\"Mar\",\"Apr\",\"May\",\"Jun\",\"Jul\",\"Aug\",\"Sep\",\"Oct\",\"Nov\",\"Dec\"],longhand:[\"January\",\"February\",\"March\",\"April\",\"May\",\"June\",\"July\",\"August\",\"September\",\"October\",\"November\",\"December\"]},daysInMonth:[31,28,31,30,31,30,31,31,30,31,30,31],firstDayOfWeek:0,ordinal:function(e){var n=e%100;if(n>3&&n<21)return\"th\";switch(n%10){case 1:return\"st\";case 2:return\"nd\";case 3:return\"rd\";default:return\"th\"}},rangeSeparator:\" to \",weekAbbreviation:\"Wk\",scrollTitle:\"Scroll to increment\",toggleTitle:\"Click to toggle\",amPM:[\"AM\",\"PM\"],yearAriaLabel:\"Year\",monthAriaLabel:\"Month\",hourAriaLabel:\"Hour\",minuteAriaLabel:\"Minute\",time_24hr:!1},o=function(e,n){return void 0===n&&(n=2),(\"000\"+e).slice(-1*n)},r=function(e){return!0===e?1:0};function l(e,n,t){var a;return void 0===t&&(t=!1),function(){var i=this,o=arguments;null!==a&&clearTimeout(a),a=window.setTimeout((function(){a=null,t||e.apply(i,o)}),n),t&&!a&&e.apply(i,o)}}var c=function(e){return e instanceof Array?e:[e]};function d(e,n,t){if(!0===t)return e.classList.add(n);e.classList.remove(n)}function s(e,n,t){var a=window.document.createElement(e);return n=n||\"\",t=t||\"\",a.className=n,void 0!==t&&(a.textContent=t),a}function u(e){for(;e.firstChild;)e.removeChild(e.firstChild)}function f(e,n){return n(e)?e:e.parentNode?f(e.parentNode,n):void 0}function m(e,n){var t=s(\"div\",\"numInputWrapper\"),a=s(\"input\",\"numInput \"+e),i=s(\"span\",\"arrowUp\"),o=s(\"span\",\"arrowDown\");if(-1===navigator.userAgent.indexOf(\"MSIE 9.0\")?a.type=\"number\":(a.type=\"text\",a.pattern=\"\\\\d*\"),void 0!==n)for(var r in n)a.setAttribute(r,n[r]);return t.appendChild(a),t.appendChild(i),t.appendChild(o),t}function g(e){try{return\"function\"==typeof e.composedPath?e.composedPath()[0]:e.target}catch(n){return e.target}}var p=function(){},h=function(e,n,t){return t.months[n?\"shorthand\":\"longhand\"][e]},v={D:p,F:function(e,n,t){e.setMonth(t.months.longhand.indexOf(n))},G:function(e,n){e.setHours(parseFloat(n))},H:function(e,n){e.setHours(parseFloat(n))},J:function(e,n){e.setDate(parseFloat(n))},K:function(e,n,t){e.setHours(e.getHours()%12+12*r(new RegExp(t.amPM[1],\"i\").test(n)))},M:function(e,n,t){e.setMonth(t.months.shorthand.indexOf(n))},S:function(e,n){e.setSeconds(parseFloat(n))},U:function(e,n){return new Date(1e3*parseFloat(n))},W:function(e,n,t){var a=parseInt(n),i=new Date(e.getFullYear(),0,2+7*(a-1),0,0,0,0);return i.setDate(i.getDate()-i.getDay()+t.firstDayOfWeek),i},Y:function(e,n){e.setFullYear(parseFloat(n))},Z:function(e,n){return new Date(n)},d:function(e,n){e.setDate(parseFloat(n))},h:function(e,n){e.setHours(parseFloat(n))},i:function(e,n){e.setMinutes(parseFloat(n))},j:function(e,n){e.setDate(parseFloat(n))},l:p,m:function(e,n){e.setMonth(parseFloat(n)-1)},n:function(e,n){e.setMonth(parseFloat(n)-1)},s:function(e,n){e.setSeconds(parseFloat(n))},u:function(e,n){return new Date(parseFloat(n))},w:p,y:function(e,n){e.setFullYear(2e3+parseFloat(n))}},D={D:\"(\\\\w+)\",F:\"(\\\\w+)\",G:\"(\\\\d\\\\d|\\\\d)\",H:\"(\\\\d\\\\d|\\\\d)\",J:\"(\\\\d\\\\d|\\\\d)\\\\w+\",K:\"\",M:\"(\\\\w+)\",S:\"(\\\\d\\\\d|\\\\d)\",U:\"(.+)\",W:\"(\\\\d\\\\d|\\\\d)\",Y:\"(\\\\d{4})\",Z:\"(.+)\",d:\"(\\\\d\\\\d|\\\\d)\",h:\"(\\\\d\\\\d|\\\\d)\",i:\"(\\\\d\\\\d|\\\\d)\",j:\"(\\\\d\\\\d|\\\\d)\",l:\"(\\\\w+)\",m:\"(\\\\d\\\\d|\\\\d)\",n:\"(\\\\d\\\\d|\\\\d)\",s:\"(\\\\d\\\\d|\\\\d)\",u:\"(.+)\",w:\"(\\\\d\\\\d|\\\\d)\",y:\"(\\\\d{2})\"},w={Z:function(e){return e.toISOString()},D:function(e,n,t){return n.weekdays.shorthand[w.w(e,n,t)]},F:function(e,n,t){return h(w.n(e,n,t)-1,!1,n)},G:function(e,n,t){return o(w.h(e,n,t))},H:function(e){return o(e.getHours())},J:function(e,n){return void 0!==n.ordinal?e.getDate()+n.ordinal(e.getDate()):e.getDate()},K:function(e,n){return n.amPM[r(e.getHours()>11)]},M:function(e,n){return h(e.getMonth(),!0,n)},S:function(e){return o(e.getSeconds())},U:function(e){return e.getTime()/1e3},W:function(e,n,t){return t.getWeek(e)},Y:function(e){return o(e.getFullYear(),4)},d:function(e){return o(e.getDate())},h:function(e){return e.getHours()%12?e.getHours()%12:12},i:function(e){return o(e.getMinutes())},j:function(e){return e.getDate()},l:function(e,n){return n.weekdays.longhand[e.getDay()]},m:function(e){return o(e.getMonth()+1)},n:function(e){return e.getMonth()+1},s:function(e){return e.getSeconds()},u:function(e){return e.getTime()},w:function(e){return e.getDay()},y:function(e){return String(e.getFullYear()).substring(2)}},b=function(e){var n=e.config,t=void 0===n?a:n,o=e.l10n,r=void 0===o?i:o,l=e.isMobile,c=void 0!==l&&l;return function(e,n,a){var i=a||r;return void 0===t.formatDate||c?n.split(\"\").map((function(n,a,o){return w[n]&&\"\\\\\"!==o[a-1]?w[n](e,i,t):\"\\\\\"!==n?n:\"\"})).join(\"\"):t.formatDate(e,n,i)}},C=function(e){var n=e.config,t=void 0===n?a:n,o=e.l10n,r=void 0===o?i:o;return function(e,n,i,o){if(0===e||e){var l,c=o||r,d=e;if(e instanceof Date)l=new Date(e.getTime());else if(\"string\"!=typeof e&&void 0!==e.toFixed)l=new Date(e);else if(\"string\"==typeof e){var s=n||(t||a).dateFormat,u=String(e).trim();if(\"today\"===u)l=new Date,i=!0;else if(/Z$/.test(u)||/GMT$/.test(u))l=new Date(e);else if(t&&t.parseDate)l=t.parseDate(e,s);else{l=t&&t.noCalendar?new Date((new Date).setHours(0,0,0,0)):new Date((new Date).getFullYear(),0,1,0,0,0,0);for(var f=void 0,m=[],g=0,p=0,h=\"\";gl&&(u=a===w.hourElement?u-l-r(!w.amPM):i,m&&H(void 0,1,w.hourElement)),w.amPM&&f&&(1===c?u+d===23:Math.abs(u-d)>c)&&(w.amPM.textContent=w.l10n.amPM[r(w.amPM.textContent===w.l10n.amPM[0])]),a.value=o(u)}}(e);var c=w._input.value;I(),be(),w._input.value!==c&&w._debouncedChange()}function I(){if(void 0!==w.hourElement&&void 0!==w.minuteElement){var e,n,t=(parseInt(w.hourElement.value.slice(-2),10)||0)%24,a=(parseInt(w.minuteElement.value,10)||0)%60,i=void 0!==w.secondElement?(parseInt(w.secondElement.value,10)||0)%60:0;void 0!==w.amPM&&(e=t,n=w.amPM.textContent,t=e%12+12*r(n===w.l10n.amPM[1]));var o=void 0!==w.config.minTime||w.config.minDate&&w.minDateHasTime&&w.latestSelectedDateObj&&0===M(w.latestSelectedDateObj,w.config.minDate,!0);if(void 0!==w.config.maxTime||w.config.maxDate&&w.maxDateHasTime&&w.latestSelectedDateObj&&0===M(w.latestSelectedDateObj,w.config.maxDate,!0)){var l=void 0!==w.config.maxTime?w.config.maxTime:w.config.maxDate;(t=Math.min(t,l.getHours()))===l.getHours()&&(a=Math.min(a,l.getMinutes())),a===l.getMinutes()&&(i=Math.min(i,l.getSeconds()))}if(o){var c=void 0!==w.config.minTime?w.config.minTime:w.config.minDate;(t=Math.max(t,c.getHours()))===c.getHours()&&(a=Math.max(a,c.getMinutes())),a===c.getMinutes()&&(i=Math.max(i,c.getSeconds()))}O(t,a,i)}}function S(e){var n=e||w.latestSelectedDateObj;n&&O(n.getHours(),n.getMinutes(),n.getSeconds())}function _(){var e=w.config.defaultHour,n=w.config.defaultMinute,t=w.config.defaultSeconds;if(void 0!==w.config.minDate){var a=w.config.minDate.getHours(),i=w.config.minDate.getMinutes();(e=Math.max(e,a))===a&&(n=Math.max(i,n)),e===a&&n===i&&(t=w.config.minDate.getSeconds())}if(void 0!==w.config.maxDate){var o=w.config.maxDate.getHours(),r=w.config.maxDate.getMinutes();(e=Math.min(e,o))===o&&(n=Math.min(r,n)),e===o&&n===r&&(t=w.config.maxDate.getSeconds())}return{hours:e,minutes:n,seconds:t}}function O(e,n,t){void 0!==w.latestSelectedDateObj&&w.latestSelectedDateObj.setHours(e%24,n,t||0,0),w.hourElement&&w.minuteElement&&!w.isMobile&&(w.hourElement.value=o(w.config.time_24hr?e:(12+e)%12+12*r(e%12==0)),w.minuteElement.value=o(n),void 0!==w.amPM&&(w.amPM.textContent=w.l10n.amPM[r(e>=12)]),void 0!==w.secondElement&&(w.secondElement.value=o(t)))}function F(e){var n=g(e),t=parseInt(n.value)+(e.delta||0);(t/1e3>1||\"Enter\"===e.key&&!/[^\\d]/.test(t.toString()))&&Q(t)}function N(e,n,t,a){return n instanceof Array?n.forEach((function(n){return N(e,n,t,a)})):e instanceof Array?e.forEach((function(e){return N(e,n,t,a)})):(e.addEventListener(n,t,a),void w._handlers.push({element:e,event:n,handler:t,options:a}))}function A(){pe(\"onChange\")}function P(e,n){var t=void 0!==e?w.parseDate(e):w.latestSelectedDateObj||(w.config.minDate&&w.config.minDate>w.now?w.config.minDate:w.config.maxDate&&w.config.maxDate=0&&M(e,w.selectedDates[1])<=0}(n)&&!ve(n)&&o.classList.add(\"inRange\"),w.weekNumbers&&1===w.config.showMonths&&\"prevMonthDay\"!==e&&t%7==1&&w.weekNumbers.insertAdjacentHTML(\"beforeend\",\"\"+w.config.getWeek(n)+\"\"),pe(\"onDayCreate\",o),o}function L(e){e.focus(),\"range\"===w.config.mode&&ae(e)}function W(e){for(var n=e>0?0:w.config.showMonths-1,t=e>0?w.config.showMonths:-1,a=n;a!=t;a+=e)for(var i=w.daysContainer.children[a],o=e>0?0:i.children.length-1,r=e>0?i.children.length:-1,l=o;l!=r;l+=e){var c=i.children[l];if(-1===c.className.indexOf(\"hidden\")&&X(c.dateObj))return c}}function R(e,n){var t=ee(document.activeElement||document.body),a=void 0!==e?e:t?document.activeElement:void 0!==w.selectedDateElem&&ee(w.selectedDateElem)?w.selectedDateElem:void 0!==w.todayDateElem&&ee(w.todayDateElem)?w.todayDateElem:W(n>0?1:-1);void 0===a?w._input.focus():t?function(e,n){for(var t=-1===e.className.indexOf(\"Month\")?e.dateObj.getMonth():w.currentMonth,a=n>0?w.config.showMonths:-1,i=n>0?1:-1,o=t-w.currentMonth;o!=a;o+=i)for(var r=w.daysContainer.children[o],l=t-w.currentMonth===o?e.$i+n:n<0?r.children.length-1:0,c=r.children.length,d=l;d>=0&&d0?c:-1);d+=i){var s=r.children[d];if(-1===s.className.indexOf(\"hidden\")&&X(s.dateObj)&&Math.abs(e.$i-d)>=Math.abs(n))return L(s)}w.changeMonth(i),R(W(i),0)}(a,n):L(a)}function B(e,n){for(var t=(new Date(e,n,1).getDay()-w.l10n.firstDayOfWeek+7)%7,a=w.utils.getDaysInMonth((n-1+12)%12,e),i=w.utils.getDaysInMonth(n,e),o=window.document.createDocumentFragment(),r=w.config.showMonths>1,l=r?\"prevMonthDay hidden\":\"prevMonthDay\",c=r?\"nextMonthDay hidden\":\"nextMonthDay\",d=a+1-t,u=0;d<=a;d++,u++)o.appendChild(j(l,new Date(e,n-1,d),d,u));for(d=1;d<=i;d++,u++)o.appendChild(j(\"\",new Date(e,n,d),d,u));for(var f=i+1;f<=42-t&&(1===w.config.showMonths||u%7!=0);f++,u++)o.appendChild(j(c,new Date(e,n+1,f%i),f,u));var m=s(\"div\",\"dayContainer\");return m.appendChild(o),m}function J(){if(void 0!==w.daysContainer){u(w.daysContainer),w.weekNumbers&&u(w.weekNumbers);for(var e=document.createDocumentFragment(),n=0;n1||\"dropdown\"!==w.config.monthSelectorType)){var e=function(e){return!(void 0!==w.config.minDate&&w.currentYear===w.config.minDate.getFullYear()&&ew.config.maxDate.getMonth())};w.monthsDropdownContainer.tabIndex=-1,w.monthsDropdownContainer.innerHTML=\"\";for(var n=0;n<12;n++)if(e(n)){var t=s(\"option\",\"flatpickr-monthDropdown-month\");t.value=new Date(w.currentYear,n).getMonth().toString(),t.textContent=h(n,w.config.shorthandCurrentMonth,w.l10n),t.tabIndex=-1,w.currentMonth===n&&(t.selected=!0),w.monthsDropdownContainer.appendChild(t)}}}function U(){var e,n=s(\"div\",\"flatpickr-month\"),t=window.document.createDocumentFragment();w.config.showMonths>1||\"static\"===w.config.monthSelectorType?e=s(\"span\",\"cur-month\"):(w.monthsDropdownContainer=s(\"select\",\"flatpickr-monthDropdown-months\"),w.monthsDropdownContainer.setAttribute(\"aria-label\",w.l10n.monthAriaLabel),N(w.monthsDropdownContainer,\"change\",(function(e){var n=g(e),t=parseInt(n.value,10);w.changeMonth(t-w.currentMonth),pe(\"onMonthChange\")})),K(),e=w.monthsDropdownContainer);var a=m(\"cur-year\",{tabindex:\"-1\"}),i=a.getElementsByTagName(\"input\")[0];i.setAttribute(\"aria-label\",w.l10n.yearAriaLabel),w.config.minDate&&i.setAttribute(\"min\",w.config.minDate.getFullYear().toString()),w.config.maxDate&&(i.setAttribute(\"max\",w.config.maxDate.getFullYear().toString()),i.disabled=!!w.config.minDate&&w.config.minDate.getFullYear()===w.config.maxDate.getFullYear());var o=s(\"div\",\"flatpickr-current-month\");return o.appendChild(e),o.appendChild(a),t.appendChild(o),n.appendChild(t),{container:n,yearElement:i,monthElement:e}}function q(){u(w.monthNav),w.monthNav.appendChild(w.prevMonthNav),w.config.showMonths&&(w.yearElements=[],w.monthElements=[]);for(var e=w.config.showMonths;e--;){var n=U();w.yearElements.push(n.yearElement),w.monthElements.push(n.monthElement),w.monthNav.appendChild(n.container)}w.monthNav.appendChild(w.nextMonthNav)}function $(){w.weekdayContainer?u(w.weekdayContainer):w.weekdayContainer=s(\"div\",\"flatpickr-weekdays\");for(var e=w.config.showMonths;e--;){var n=s(\"div\",\"flatpickr-weekdaycontainer\");w.weekdayContainer.appendChild(n)}return z(),w.weekdayContainer}function z(){if(w.weekdayContainer){var e=w.l10n.firstDayOfWeek,t=n(w.l10n.weekdays.shorthand);e>0&&e\\n \"+t.join(\"\")+\"\\n \\n \"}}function G(e,n){void 0===n&&(n=!0);var t=n?e:e-w.currentMonth;t<0&&!0===w._hidePrevMonthArrow||t>0&&!0===w._hideNextMonthArrow||(w.currentMonth+=t,(w.currentMonth<0||w.currentMonth>11)&&(w.currentYear+=w.currentMonth>11?1:-1,w.currentMonth=(w.currentMonth+12)%12,pe(\"onYearChange\"),K()),J(),pe(\"onMonthChange\"),De())}function V(e){return!(!w.config.appendTo||!w.config.appendTo.contains(e))||w.calendarContainer.contains(e)}function Z(e){if(w.isOpen&&!w.config.inline){var n=g(e),t=V(n),a=n===w.input||n===w.altInput||w.element.contains(n)||e.path&&e.path.indexOf&&(~e.path.indexOf(w.input)||~e.path.indexOf(w.altInput)),i=\"blur\"===e.type?a&&e.relatedTarget&&!V(e.relatedTarget):!a&&!t&&!V(e.relatedTarget),o=!w.config.ignoredFocusElements.some((function(e){return e.contains(n)}));i&&o&&(void 0!==w.timeContainer&&void 0!==w.minuteElement&&void 0!==w.hourElement&&\"\"!==w.input.value&&void 0!==w.input.value&&T(),w.close(),w.config&&\"range\"===w.config.mode&&1===w.selectedDates.length&&(w.clear(!1),w.redraw()))}}function Q(e){if(!(!e||w.config.minDate&&ew.config.maxDate.getFullYear())){var n=e,t=w.currentYear!==n;w.currentYear=n||w.currentYear,w.config.maxDate&&w.currentYear===w.config.maxDate.getFullYear()?w.currentMonth=Math.min(w.config.maxDate.getMonth(),w.currentMonth):w.config.minDate&&w.currentYear===w.config.minDate.getFullYear()&&(w.currentMonth=Math.max(w.config.minDate.getMonth(),w.currentMonth)),t&&(w.redraw(),pe(\"onYearChange\"),K())}}function X(e,n){void 0===n&&(n=!0);var t=w.parseDate(e,void 0,n);if(w.config.minDate&&t&&M(t,w.config.minDate,void 0!==n?n:!w.minDateHasTime)<0||w.config.maxDate&&t&&M(t,w.config.maxDate,void 0!==n?n:!w.maxDateHasTime)>0)return!1;if(0===w.config.enable.length&&0===w.config.disable.length)return!0;if(void 0===t)return!1;for(var a=w.config.enable.length>0,i=a?w.config.enable:w.config.disable,o=0,r=void 0;o=r.from.getTime()&&t.getTime()<=r.to.getTime())return a}return!a}function ee(e){return void 0!==w.daysContainer&&-1===e.className.indexOf(\"hidden\")&&-1===e.className.indexOf(\"flatpickr-disabled\")&&w.daysContainer.contains(e)}function ne(e){e.target!==w._input||e.relatedTarget&&V(e.relatedTarget)||w.setDate(w._input.value,!0,e.target===w.altInput?w.config.altFormat:w.config.dateFormat)}function te(e){var n=g(e),t=w.config.wrap?p.contains(n):n===w._input,a=w.config.allowInput,i=w.isOpen&&(!a||!t),o=w.config.inline&&t&&!a;if(13===e.keyCode&&t){if(a)return w.setDate(w._input.value,!0,n===w.altInput?w.config.altFormat:w.config.dateFormat),n.blur();w.open()}else if(V(n)||i||o){var r=!!w.timeContainer&&w.timeContainer.contains(n);switch(e.keyCode){case 13:r?(e.preventDefault(),T(),se()):ue(e);break;case 27:e.preventDefault(),se();break;case 8:case 46:t&&!w.config.allowInput&&(e.preventDefault(),w.clear());break;case 37:case 39:if(r||t)w.hourElement&&w.hourElement.focus();else if(e.preventDefault(),void 0!==w.daysContainer&&(!1===a||document.activeElement&&ee(document.activeElement))){var l=39===e.keyCode?1:-1;e.ctrlKey?(e.stopPropagation(),G(l),R(W(1),0)):R(void 0,l)}break;case 38:case 40:e.preventDefault();var c=40===e.keyCode?1:-1;w.daysContainer&&void 0!==n.$i||n===w.input||n===w.altInput?e.ctrlKey?(e.stopPropagation(),Q(w.currentYear-c),R(W(1),0)):r||R(void 0,7*c):n===w.currentYearElement?Q(w.currentYear-c):w.config.enableTime&&(!r&&w.hourElement&&w.hourElement.focus(),T(e),w._debouncedChange());break;case 9:if(r){var d=[w.hourElement,w.minuteElement,w.secondElement,w.amPM].concat(w.pluginElements).filter((function(e){return e})),s=d.indexOf(n);if(-1!==s){var u=d[s+(e.shiftKey?-1:1)];e.preventDefault(),(u||w._input).focus()}}else!w.config.noCalendar&&w.daysContainer&&w.daysContainer.contains(n)&&e.shiftKey&&(e.preventDefault(),w._input.focus())}}if(void 0!==w.amPM&&n===w.amPM)switch(e.key){case w.l10n.amPM[0].charAt(0):case w.l10n.amPM[0].charAt(0).toLowerCase():w.amPM.textContent=w.l10n.amPM[0],I(),be();break;case w.l10n.amPM[1].charAt(0):case w.l10n.amPM[1].charAt(0).toLowerCase():w.amPM.textContent=w.l10n.amPM[1],I(),be()}(t||V(n))&&pe(\"onKeyDown\",e)}function ae(e){if(1===w.selectedDates.length&&(!e||e.classList.contains(\"flatpickr-day\")&&!e.classList.contains(\"flatpickr-disabled\"))){for(var n=e?e.dateObj.getTime():w.days.firstElementChild.dateObj.getTime(),t=w.parseDate(w.selectedDates[0],void 0,!0).getTime(),a=Math.min(n,w.selectedDates[0].getTime()),i=Math.max(n,w.selectedDates[0].getTime()),o=!1,r=0,l=0,c=a;ca&&cr)?r=c:c>t&&(!l||c0&&m0&&m>l;return g?(f.classList.add(\"notAllowed\"),[\"inRange\",\"startRange\",\"endRange\"].forEach((function(e){f.classList.remove(e)})),\"continue\"):o&&!g?\"continue\":([\"startRange\",\"inRange\",\"endRange\",\"notAllowed\"].forEach((function(e){f.classList.remove(e)})),void(void 0!==e&&(e.classList.add(n<=w.selectedDates[0].getTime()?\"startRange\":\"endRange\"),tn&&m===t&&f.classList.add(\"endRange\"),m>=r&&(0===l||m<=l)&&(d=t,u=n,(c=m)>Math.min(d,u)&&c0||t.getMinutes()>0||t.getSeconds()>0),w.selectedDates&&(w.selectedDates=w.selectedDates.filter((function(e){return X(e)})),w.selectedDates.length||\"min\"!==e||S(t),be()),w.daysContainer&&(de(),void 0!==t?w.currentYearElement[e]=t.getFullYear().toString():w.currentYearElement.removeAttribute(e),w.currentYearElement.disabled=!!a&&void 0!==t&&a.getFullYear()===t.getFullYear())}}function re(){return w.config.wrap?p.querySelector(\"[data-input]\"):p}function le(){\"object\"!=typeof w.config.locale&&void 0===k.l10ns[w.config.locale]&&w.config.errorHandler(new Error(\"flatpickr: invalid locale \"+w.config.locale)),w.l10n=e(e({},k.l10ns.default),\"object\"==typeof w.config.locale?w.config.locale:\"default\"!==w.config.locale?k.l10ns[w.config.locale]:void 0),D.K=\"(\"+w.l10n.amPM[0]+\"|\"+w.l10n.amPM[1]+\"|\"+w.l10n.amPM[0].toLowerCase()+\"|\"+w.l10n.amPM[1].toLowerCase()+\")\",void 0===e(e({},v),JSON.parse(JSON.stringify(p.dataset||{}))).time_24hr&&void 0===k.defaultConfig.time_24hr&&(w.config.time_24hr=w.l10n.time_24hr),w.formatDate=b(w),w.parseDate=C({config:w.config,l10n:w.l10n})}function ce(e){if(void 0!==w.calendarContainer){pe(\"onPreCalendarPosition\");var n=e||w._positionElement,t=Array.prototype.reduce.call(w.calendarContainer.children,(function(e,n){return e+n.offsetHeight}),0),a=w.calendarContainer.offsetWidth,i=w.config.position.split(\" \"),o=i[0],r=i.length>1?i[1]:null,l=n.getBoundingClientRect(),c=window.innerHeight-l.bottom,s=\"above\"===o||\"below\"!==o&&ct,u=window.pageYOffset+l.top+(s?-t-2:n.offsetHeight+2);if(d(w.calendarContainer,\"arrowTop\",!s),d(w.calendarContainer,\"arrowBottom\",s),!w.config.inline){var f=window.pageXOffset+l.left,m=!1,g=!1;\"center\"===r?(f-=(a-l.width)/2,m=!0):\"right\"===r&&(f-=a-l.width,g=!0),d(w.calendarContainer,\"arrowLeft\",!m&&!g),d(w.calendarContainer,\"arrowCenter\",m),d(w.calendarContainer,\"arrowRight\",g);var p=window.document.body.offsetWidth-(window.pageXOffset+l.right),h=f+a>window.document.body.offsetWidth,v=p+a>window.document.body.offsetWidth;if(d(w.calendarContainer,\"rightMost\",h),!w.config.static)if(w.calendarContainer.style.top=u+\"px\",h)if(v){var D=function(){for(var e=null,n=0;nw.currentMonth+w.config.showMonths-1)&&\"range\"!==w.config.mode;if(w.selectedDateElem=t,\"single\"===w.config.mode)w.selectedDates=[a];else if(\"multiple\"===w.config.mode){var o=ve(a);o?w.selectedDates.splice(parseInt(o),1):w.selectedDates.push(a)}else\"range\"===w.config.mode&&(2===w.selectedDates.length&&w.clear(!1,!1),w.latestSelectedDateObj=a,w.selectedDates.push(a),0!==M(a,w.selectedDates[0],!0)&&w.selectedDates.sort((function(e,n){return e.getTime()-n.getTime()})));if(I(),i){var r=w.currentYear!==a.getFullYear();w.currentYear=a.getFullYear(),w.currentMonth=a.getMonth(),r&&(pe(\"onYearChange\"),K()),pe(\"onMonthChange\")}if(De(),J(),be(),i||\"range\"===w.config.mode||1!==w.config.showMonths?void 0!==w.selectedDateElem&&void 0===w.hourElement&&w.selectedDateElem&&w.selectedDateElem.focus():L(t),void 0!==w.hourElement&&void 0!==w.hourElement&&w.hourElement.focus(),w.config.closeOnSelect){var l=\"single\"===w.config.mode&&!w.config.enableTime,c=\"range\"===w.config.mode&&2===w.selectedDates.length&&!w.config.enableTime;(l||c)&&se()}A()}}w.parseDate=C({config:w.config,l10n:w.l10n}),w._handlers=[],w.pluginElements=[],w.loadedPlugins=[],w._bind=N,w._setHoursFromDate=S,w._positionCalendar=ce,w.changeMonth=G,w.changeYear=Q,w.clear=function(e,n){if(void 0===e&&(e=!0),void 0===n&&(n=!0),w.input.value=\"\",void 0!==w.altInput&&(w.altInput.value=\"\"),void 0!==w.mobileInput&&(w.mobileInput.value=\"\"),w.selectedDates=[],w.latestSelectedDateObj=void 0,!0===n&&(w.currentYear=w._initialDate.getFullYear(),w.currentMonth=w._initialDate.getMonth()),!0===w.config.enableTime){var t=_(),a=t.hours,i=t.minutes,o=t.seconds;O(a,i,o)}w.redraw(),e&&pe(\"onChange\")},w.close=function(){w.isOpen=!1,w.isMobile||(void 0!==w.calendarContainer&&w.calendarContainer.classList.remove(\"open\"),void 0!==w._input&&w._input.classList.remove(\"active\")),pe(\"onClose\")},w._createElement=s,w.destroy=function(){void 0!==w.config&&pe(\"onDestroy\");for(var e=w._handlers.length;e--;){var n=w._handlers[e];n.element.removeEventListener(n.event,n.handler,n.options)}if(w._handlers=[],w.mobileInput)w.mobileInput.parentNode&&w.mobileInput.parentNode.removeChild(w.mobileInput),w.mobileInput=void 0;else if(w.calendarContainer&&w.calendarContainer.parentNode)if(w.config.static&&w.calendarContainer.parentNode){var t=w.calendarContainer.parentNode;if(t.lastChild&&t.removeChild(t.lastChild),t.parentNode){for(;t.firstChild;)t.parentNode.insertBefore(t.firstChild,t);t.parentNode.removeChild(t)}}else w.calendarContainer.parentNode.removeChild(w.calendarContainer);w.altInput&&(w.input.type=\"text\",w.altInput.parentNode&&w.altInput.parentNode.removeChild(w.altInput),delete w.altInput),w.input&&(w.input.type=w.input._type,w.input.classList.remove(\"flatpickr-input\"),w.input.removeAttribute(\"readonly\")),[\"_showTimeInput\",\"latestSelectedDateObj\",\"_hideNextMonthArrow\",\"_hidePrevMonthArrow\",\"__hideNextMonthArrow\",\"__hidePrevMonthArrow\",\"isMobile\",\"isOpen\",\"selectedDateElem\",\"minDateHasTime\",\"maxDateHasTime\",\"days\",\"daysContainer\",\"_input\",\"_positionElement\",\"innerContainer\",\"rContainer\",\"monthNav\",\"todayDateElem\",\"calendarContainer\",\"weekdayContainer\",\"prevMonthNav\",\"nextMonthNav\",\"monthsDropdownContainer\",\"currentMonthElement\",\"currentYearElement\",\"navigationCurrentMonth\",\"selectedDateElem\",\"config\"].forEach((function(e){try{delete w[e]}catch(e){}}))},w.isEnabled=X,w.jumpToDate=P,w.open=function(e,n){if(void 0===n&&(n=w._positionElement),!0===w.isMobile){if(e){e.preventDefault();var t=g(e);t&&t.blur()}return void 0!==w.mobileInput&&(w.mobileInput.focus(),w.mobileInput.click()),void pe(\"onOpen\")}if(!w._input.disabled&&!w.config.inline){var a=w.isOpen;w.isOpen=!0,a||(w.calendarContainer.classList.add(\"open\"),w._input.classList.add(\"active\"),pe(\"onOpen\"),ce(n)),!0===w.config.enableTime&&!0===w.config.noCalendar&&(!1!==w.config.allowInput||void 0!==e&&w.timeContainer.contains(e.relatedTarget)||setTimeout((function(){return w.hourElement.select()}),50))}},w.redraw=de,w.set=function(e,n){if(null!==e&&\"object\"==typeof e)for(var a in Object.assign(w.config,e),e)void 0!==fe[a]&&fe[a].forEach((function(e){return e()}));else w.config[e]=n,void 0!==fe[e]?fe[e].forEach((function(e){return e()})):t.indexOf(e)>-1&&(w.config[e]=c(n));w.redraw(),be(!0)},w.setDate=function(e,n,t){if(void 0===n&&(n=!1),void 0===t&&(t=w.config.dateFormat),0!==e&&!e||e instanceof Array&&0===e.length)return w.clear(n);me(e,t),w.latestSelectedDateObj=w.selectedDates[w.selectedDates.length-1],w.redraw(),P(void 0,n),S(),0===w.selectedDates.length&&w.clear(!1),be(n),n&&pe(\"onChange\")},w.toggle=function(e){if(!0===w.isOpen)return w.close();w.open(e)};var fe={locale:[le,z],showMonths:[q,E,$],minDate:[P],maxDate:[P]};function me(e,n){var t=[];if(e instanceof Array)t=e.map((function(e){return w.parseDate(e,n)}));else if(e instanceof Date||\"number\"==typeof e)t=[w.parseDate(e,n)];else if(\"string\"==typeof e)switch(w.config.mode){case\"single\":case\"time\":t=[w.parseDate(e,n)];break;case\"multiple\":t=e.split(w.config.conjunction).map((function(e){return w.parseDate(e,n)}));break;case\"range\":t=e.split(w.l10n.rangeSeparator).map((function(e){return w.parseDate(e,n)}))}else w.config.errorHandler(new Error(\"Invalid date supplied: \"+JSON.stringify(e)));w.selectedDates=w.config.allowInvalidPreload?t:t.filter((function(e){return e instanceof Date&&X(e,!1)})),\"range\"===w.config.mode&&w.selectedDates.sort((function(e,n){return e.getTime()-n.getTime()}))}function ge(e){return e.slice().map((function(e){return\"string\"==typeof e||\"number\"==typeof e||e instanceof Date?w.parseDate(e,void 0,!0):e&&\"object\"==typeof e&&e.from&&e.to?{from:w.parseDate(e.from,void 0),to:w.parseDate(e.to,void 0)}:e})).filter((function(e){return e}))}function pe(e,n){if(void 0!==w.config){var t=w.config[e];if(void 0!==t&&t.length>0)for(var a=0;t[a]&&a1||\"static\"===w.config.monthSelectorType?w.monthElements[n].textContent=h(t.getMonth(),w.config.shorthandCurrentMonth,w.l10n)+\" \":w.monthsDropdownContainer.value=t.getMonth().toString(),e.value=t.getFullYear().toString()})),w._hidePrevMonthArrow=void 0!==w.config.minDate&&(w.currentYear===w.config.minDate.getFullYear()?w.currentMonth<=w.config.minDate.getMonth():w.currentYearw.config.maxDate.getMonth():w.currentYear>w.config.maxDate.getFullYear()))}function we(e){return w.selectedDates.map((function(n){return w.formatDate(n,e)})).filter((function(e,n,t){return\"range\"!==w.config.mode||w.config.enableTime||t.indexOf(e)===n})).join(\"range\"!==w.config.mode?w.config.conjunction:w.l10n.rangeSeparator)}function be(e){void 0===e&&(e=!0),void 0!==w.mobileInput&&w.mobileFormatStr&&(w.mobileInput.value=void 0!==w.latestSelectedDateObj?w.formatDate(w.latestSelectedDateObj,w.mobileFormatStr):\"\"),w.input.value=we(w.config.dateFormat),void 0!==w.altInput&&(w.altInput.value=we(w.config.altFormat)),!1!==e&&pe(\"onValueUpdate\")}function Ce(e){var n=g(e),t=w.prevMonthNav.contains(n),a=w.nextMonthNav.contains(n);t||a?G(t?-1:1):w.yearElements.indexOf(n)>=0?n.select():n.classList.contains(\"arrowUp\")?w.changeYear(w.currentYear+1):n.classList.contains(\"arrowDown\")&&w.changeYear(w.currentYear-1)}return function(){w.element=w.input=p,w.isOpen=!1,function(){var n=[\"wrap\",\"weekNumbers\",\"allowInput\",\"allowInvalidPreload\",\"clickOpens\",\"time_24hr\",\"enableTime\",\"noCalendar\",\"altInput\",\"shorthandCurrentMonth\",\"inline\",\"static\",\"enableSeconds\",\"disableMobile\"],i=e(e({},JSON.parse(JSON.stringify(p.dataset||{}))),v),o={};w.config.parseDate=i.parseDate,w.config.formatDate=i.formatDate,Object.defineProperty(w.config,\"enable\",{get:function(){return w.config._enable},set:function(e){w.config._enable=ge(e)}}),Object.defineProperty(w.config,\"disable\",{get:function(){return w.config._disable},set:function(e){w.config._disable=ge(e)}});var r=\"time\"===i.mode;if(!i.dateFormat&&(i.enableTime||r)){var l=k.defaultConfig.dateFormat||a.dateFormat;o.dateFormat=i.noCalendar||r?\"H:i\"+(i.enableSeconds?\":S\":\"\"):l+\" H:i\"+(i.enableSeconds?\":S\":\"\")}if(i.altInput&&(i.enableTime||r)&&!i.altFormat){var d=k.defaultConfig.altFormat||a.altFormat;o.altFormat=i.noCalendar||r?\"h:i\"+(i.enableSeconds?\":S K\":\" K\"):d+\" h:i\"+(i.enableSeconds?\":S\":\"\")+\" K\"}Object.defineProperty(w.config,\"minDate\",{get:function(){return w.config._minDate},set:oe(\"min\")}),Object.defineProperty(w.config,\"maxDate\",{get:function(){return w.config._maxDate},set:oe(\"max\")});var s=function(e){return function(n){w.config[\"min\"===e?\"_minTime\":\"_maxTime\"]=w.parseDate(n,\"H:i:S\")}};Object.defineProperty(w.config,\"minTime\",{get:function(){return w.config._minTime},set:s(\"min\")}),Object.defineProperty(w.config,\"maxTime\",{get:function(){return w.config._maxTime},set:s(\"max\")}),\"time\"===i.mode&&(w.config.noCalendar=!0,w.config.enableTime=!0),Object.assign(w.config,o,i);for(var u=0;u-1?w.config[m]=c(f[m]).map(x).concat(w.config[m]):void 0===i[m]&&(w.config[m]=f[m])}i.altInputClass||(w.config.altInputClass=re().className+\" \"+w.config.altInputClass),pe(\"onParseConfig\")}(),le(),w.input=re(),w.input?(w.input._type=w.input.type,w.input.type=\"text\",w.input.classList.add(\"flatpickr-input\"),w._input=w.input,w.config.altInput&&(w.altInput=s(w.input.nodeName,w.config.altInputClass),w._input=w.altInput,w.altInput.placeholder=w.input.placeholder,w.altInput.disabled=w.input.disabled,w.altInput.required=w.input.required,w.altInput.tabIndex=w.input.tabIndex,w.altInput.type=\"text\",w.input.setAttribute(\"type\",\"hidden\"),!w.config.static&&w.input.parentNode&&w.input.parentNode.insertBefore(w.altInput,w.input.nextSibling)),w.config.allowInput||w._input.setAttribute(\"readonly\",\"readonly\"),w._positionElement=w.config.positionElement||w._input):w.config.errorHandler(new Error(\"Invalid input element specified\")),function(){w.selectedDates=[],w.now=w.parseDate(w.config.now)||new Date;var e=w.config.defaultDate||(\"INPUT\"!==w.input.nodeName&&\"TEXTAREA\"!==w.input.nodeName||!w.input.placeholder||w.input.value!==w.input.placeholder?w.input.value:null);e&&me(e,w.config.dateFormat),w._initialDate=w.selectedDates.length>0?w.selectedDates[0]:w.config.minDate&&w.config.minDate.getTime()>w.now.getTime()?w.config.minDate:w.config.maxDate&&w.config.maxDate.getTime()0&&(w.latestSelectedDateObj=w.selectedDates[0]),void 0!==w.config.minTime&&(w.config.minTime=w.parseDate(w.config.minTime,\"H:i\")),void 0!==w.config.maxTime&&(w.config.maxTime=w.parseDate(w.config.maxTime,\"H:i\")),w.minDateHasTime=!!w.config.minDate&&(w.config.minDate.getHours()>0||w.config.minDate.getMinutes()>0||w.config.minDate.getSeconds()>0),w.maxDateHasTime=!!w.config.maxDate&&(w.config.maxDate.getHours()>0||w.config.maxDate.getMinutes()>0||w.config.maxDate.getSeconds()>0)}(),w.utils={getDaysInMonth:function(e,n){return void 0===e&&(e=w.currentMonth),void 0===n&&(n=w.currentYear),1===e&&(n%4==0&&n%100!=0||n%400==0)?29:w.l10n.daysInMonth[e]}},w.isMobile||function(){var e=window.document.createDocumentFragment();if(w.calendarContainer=s(\"div\",\"flatpickr-calendar\"),w.calendarContainer.tabIndex=-1,!w.config.noCalendar){if(e.appendChild((w.monthNav=s(\"div\",\"flatpickr-months\"),w.yearElements=[],w.monthElements=[],w.prevMonthNav=s(\"span\",\"flatpickr-prev-month\"),w.prevMonthNav.innerHTML=w.config.prevArrow,w.nextMonthNav=s(\"span\",\"flatpickr-next-month\"),w.nextMonthNav.innerHTML=w.config.nextArrow,q(),Object.defineProperty(w,\"_hidePrevMonthArrow\",{get:function(){return w.__hidePrevMonthArrow},set:function(e){w.__hidePrevMonthArrow!==e&&(d(w.prevMonthNav,\"flatpickr-disabled\",e),w.__hidePrevMonthArrow=e)}}),Object.defineProperty(w,\"_hideNextMonthArrow\",{get:function(){return w.__hideNextMonthArrow},set:function(e){w.__hideNextMonthArrow!==e&&(d(w.nextMonthNav,\"flatpickr-disabled\",e),w.__hideNextMonthArrow=e)}}),w.currentYearElement=w.yearElements[0],De(),w.monthNav)),w.innerContainer=s(\"div\",\"flatpickr-innerContainer\"),w.config.weekNumbers){var n=function(){w.calendarContainer.classList.add(\"hasWeeks\");var e=s(\"div\",\"flatpickr-weekwrapper\");e.appendChild(s(\"span\",\"flatpickr-weekday\",w.l10n.weekAbbreviation));var n=s(\"div\",\"flatpickr-weeks\");return e.appendChild(n),{weekWrapper:e,weekNumbers:n}}(),t=n.weekWrapper,a=n.weekNumbers;w.innerContainer.appendChild(t),w.weekNumbers=a,w.weekWrapper=t}w.rContainer=s(\"div\",\"flatpickr-rContainer\"),w.rContainer.appendChild($()),w.daysContainer||(w.daysContainer=s(\"div\",\"flatpickr-days\"),w.daysContainer.tabIndex=-1),J(),w.rContainer.appendChild(w.daysContainer),w.innerContainer.appendChild(w.rContainer),e.appendChild(w.innerContainer)}w.config.enableTime&&e.appendChild(function(){w.calendarContainer.classList.add(\"hasTime\"),w.config.noCalendar&&w.calendarContainer.classList.add(\"noCalendar\"),w.timeContainer=s(\"div\",\"flatpickr-time\"),w.timeContainer.tabIndex=-1;var e=s(\"span\",\"flatpickr-time-separator\",\":\"),n=m(\"flatpickr-hour\",{\"aria-label\":w.l10n.hourAriaLabel});w.hourElement=n.getElementsByTagName(\"input\")[0];var t=m(\"flatpickr-minute\",{\"aria-label\":w.l10n.minuteAriaLabel});if(w.minuteElement=t.getElementsByTagName(\"input\")[0],w.hourElement.tabIndex=w.minuteElement.tabIndex=-1,w.hourElement.value=o(w.latestSelectedDateObj?w.latestSelectedDateObj.getHours():w.config.time_24hr?w.config.defaultHour:function(e){switch(e%24){case 0:case 12:return 12;default:return e%12}}(w.config.defaultHour)),w.minuteElement.value=o(w.latestSelectedDateObj?w.latestSelectedDateObj.getMinutes():w.config.defaultMinute),w.hourElement.setAttribute(\"step\",w.config.hourIncrement.toString()),w.minuteElement.setAttribute(\"step\",w.config.minuteIncrement.toString()),w.hourElement.setAttribute(\"min\",w.config.time_24hr?\"0\":\"1\"),w.hourElement.setAttribute(\"max\",w.config.time_24hr?\"23\":\"12\"),w.minuteElement.setAttribute(\"min\",\"0\"),w.minuteElement.setAttribute(\"max\",\"59\"),w.timeContainer.appendChild(n),w.timeContainer.appendChild(e),w.timeContainer.appendChild(t),w.config.time_24hr&&w.timeContainer.classList.add(\"time24hr\"),w.config.enableSeconds){w.timeContainer.classList.add(\"hasSeconds\");var a=m(\"flatpickr-second\");w.secondElement=a.getElementsByTagName(\"input\")[0],w.secondElement.value=o(w.latestSelectedDateObj?w.latestSelectedDateObj.getSeconds():w.config.defaultSeconds),w.secondElement.setAttribute(\"step\",w.minuteElement.getAttribute(\"step\")),w.secondElement.setAttribute(\"min\",\"0\"),w.secondElement.setAttribute(\"max\",\"59\"),w.timeContainer.appendChild(s(\"span\",\"flatpickr-time-separator\",\":\")),w.timeContainer.appendChild(a)}return w.config.time_24hr||(w.amPM=s(\"span\",\"flatpickr-am-pm\",w.l10n.amPM[r((w.latestSelectedDateObj?w.hourElement.value:w.config.defaultHour)>11)]),w.amPM.title=w.l10n.toggleTitle,w.amPM.tabIndex=-1,w.timeContainer.appendChild(w.amPM)),w.timeContainer}()),d(w.calendarContainer,\"rangeMode\",\"range\"===w.config.mode),d(w.calendarContainer,\"animate\",!0===w.config.animate),d(w.calendarContainer,\"multiMonth\",w.config.showMonths>1),w.calendarContainer.appendChild(e);var i=void 0!==w.config.appendTo&&void 0!==w.config.appendTo.nodeType;if((w.config.inline||w.config.static)&&(w.calendarContainer.classList.add(w.config.inline?\"inline\":\"static\"),w.config.inline&&(!i&&w.element.parentNode?w.element.parentNode.insertBefore(w.calendarContainer,w._input.nextSibling):void 0!==w.config.appendTo&&w.config.appendTo.appendChild(w.calendarContainer)),w.config.static)){var l=s(\"div\",\"flatpickr-wrapper\");w.element.parentNode&&w.element.parentNode.insertBefore(l,w.element),l.appendChild(w.element),w.altInput&&l.appendChild(w.altInput),l.appendChild(w.calendarContainer)}w.config.static||w.config.inline||(void 0!==w.config.appendTo?w.config.appendTo:window.document.body).appendChild(w.calendarContainer)}(),function(){if(w.config.wrap&&[\"open\",\"close\",\"toggle\",\"clear\"].forEach((function(e){Array.prototype.forEach.call(w.element.querySelectorAll(\"[data-\"+e+\"]\"),(function(n){return N(n,\"click\",w[e])}))})),w.isMobile)!function(){var e=w.config.enableTime?w.config.noCalendar?\"time\":\"datetime-local\":\"date\";w.mobileInput=s(\"input\",w.input.className+\" flatpickr-mobile\"),w.mobileInput.tabIndex=1,w.mobileInput.type=e,w.mobileInput.disabled=w.input.disabled,w.mobileInput.required=w.input.required,w.mobileInput.placeholder=w.input.placeholder,w.mobileFormatStr=\"datetime-local\"===e?\"Y-m-d\\\\TH:i:S\":\"date\"===e?\"Y-m-d\":\"H:i:S\",w.selectedDates.length>0&&(w.mobileInput.defaultValue=w.mobileInput.value=w.formatDate(w.selectedDates[0],w.mobileFormatStr)),w.config.minDate&&(w.mobileInput.min=w.formatDate(w.config.minDate,\"Y-m-d\")),w.config.maxDate&&(w.mobileInput.max=w.formatDate(w.config.maxDate,\"Y-m-d\")),w.input.getAttribute(\"step\")&&(w.mobileInput.step=String(w.input.getAttribute(\"step\"))),w.input.type=\"hidden\",void 0!==w.altInput&&(w.altInput.type=\"hidden\");try{w.input.parentNode&&w.input.parentNode.insertBefore(w.mobileInput,w.input.nextSibling)}catch(e){}N(w.mobileInput,\"change\",(function(e){w.setDate(g(e).value,!1,w.mobileFormatStr),pe(\"onChange\"),pe(\"onClose\")}))}();else{var e=l(ie,50);if(w._debouncedChange=l(A,300),w.daysContainer&&!/iPhone|iPad|iPod/i.test(navigator.userAgent)&&N(w.daysContainer,\"mouseover\",(function(e){\"range\"===w.config.mode&&ae(g(e))})),N(window.document.body,\"keydown\",te),w.config.inline||w.config.static||N(window,\"resize\",e),void 0!==window.ontouchstart?N(window.document,\"touchstart\",Z):N(window.document,\"click\",Z),N(window.document,\"focus\",Z,{capture:!0}),!0===w.config.clickOpens&&(N(w._input,\"focus\",w.open),N(w._input,\"click\",w.open)),void 0!==w.daysContainer&&(N(w.monthNav,\"click\",Ce),N(w.monthNav,[\"keyup\",\"increment\"],F),N(w.daysContainer,\"click\",ue)),void 0!==w.timeContainer&&void 0!==w.minuteElement&&void 0!==w.hourElement){var n=function(e){return g(e).select()};N(w.timeContainer,[\"increment\"],T),N(w.timeContainer,\"blur\",T,{capture:!0}),N(w.timeContainer,\"click\",Y),N([w.hourElement,w.minuteElement],[\"focus\",\"click\"],n),void 0!==w.secondElement&&N(w.secondElement,\"focus\",(function(){return w.secondElement&&w.secondElement.select()})),void 0!==w.amPM&&N(w.amPM,\"click\",(function(e){T(e),A()}))}w.config.allowInput&&N(w._input,\"blur\",ne)}}(),(w.selectedDates.length||w.config.noCalendar)&&(w.config.enableTime&&S(w.config.noCalendar?w.latestSelectedDateObj||w.config.minDate:void 0),be(!1)),E();var n=/^((?!chrome|android).)*safari/i.test(navigator.userAgent);!w.isMobile&&n&&ce(),pe(\"onReady\")}(),w}function E(e,n){for(var t=Array.prototype.slice.call(e).filter((function(e){return e instanceof HTMLElement})),a=[],i=0;ithis.render()));const{start:s,end:l,value:o,step:r,title:n}=this.model.properties;this.on_change([s,l,o,r],(()=>{const{start:t,end:e,value:i,step:s}=this._calc_to();this._noUiSlider.updateOptions({range:{min:t,max:e},start:i,step:s},!0)}));const{bar_color:a}=this.model.properties;this.on_change(a,(()=>{this._set_bar_color()}));const{show_value:d}=this.model.properties;this.on_change([o,n,d],(()=>this._update_title()))}styles(){return[...super.styles(),p.default,u.default]}_update_title(){var t;(0,a.empty)(this.title_el);const e=null==this.model.title||0==this.model.title.length&&!this.model.show_value;if(this.title_el.style.display=e?\"none\":\"\",!e&&(0!=(null===(t=this.model.title)||void 0===t?void 0:t.length)&&(this.title_el.textContent=`${this.model.title}: `),this.model.show_value)){const{value:t}=this._calc_to(),e=t.map((t=>this.model.pretty(t))).join(\" .. \");this.title_el.appendChild((0,a.span)({class:m.slider_value},e))}}_set_bar_color(){if(!this.model.disabled){this.slider_el.querySelector(\".noUi-connect\").style.backgroundColor=(0,_.color2css)(this.model.bar_color)}}render(){super.render();const{start:t,end:e,value:i,step:s}=this._calc_to();let l;if(this.model.tooltips){const t={to:t=>this.model.pretty(t)};l=(0,d.repeat)(t,i.length)}else l=!1;if(null==this.slider_el){this.slider_el=(0,a.div)(),this._noUiSlider=n.default.create(this.slider_el,{range:{min:t,max:e},start:i,step:s,behaviour:this.model.behaviour,connect:this.model.connected,tooltips:l,orientation:this.model.orientation,direction:this.model.direction}),this._noUiSlider.on(\"slide\",((t,e,i)=>this._slide(i))),this._noUiSlider.on(\"change\",((t,e,i)=>this._change(i)));const o=(t,e)=>{if(!l)return;this.slider_el.querySelectorAll(\".noUi-handle\")[t].querySelector(\".noUi-tooltip\").style.display=e?\"block\":\"\"};this._noUiSlider.on(\"start\",((t,e)=>o(e,!0))),this._noUiSlider.on(\"end\",((t,e)=>o(e,!1)))}else this._noUiSlider.updateOptions({range:{min:t,max:e},start:i,step:s},!0);this._set_bar_color(),this.model.disabled?this.slider_el.setAttribute(\"disabled\",\"true\"):this.slider_el.removeAttribute(\"disabled\"),this.title_el=(0,a.div)({class:m.slider_title}),this._update_title(),this.group_el=(0,a.div)({class:v.input_group},this.title_el,this.slider_el),this.el.appendChild(this.group_el)}_slide(t){this.model.value=this._calc_from(t)}_change(t){const e=this._calc_from(t);this.model.setv({value:e,value_throttled:e})}}b.__name__=\"AbstractBaseSliderView\";class g extends b{_calc_to(){return{start:this.model.start,end:this.model.end,value:[this.model.value],step:this.model.step}}_calc_from([t]){return Number.isInteger(this.model.start)&&Number.isInteger(this.model.end)&&Number.isInteger(this.model.step)?Math.round(t):t}}i.AbstractSliderView=g,g.__name__=\"AbstractSliderView\";class f extends b{_calc_to(){return{start:this.model.start,end:this.model.end,value:this.model.value,step:this.model.step}}_calc_from(t){return t}}i.AbstractRangeSliderView=f,f.__name__=\"AbstractRangeSliderView\";class S extends h.OrientedControl{constructor(t){super(t),this.connected=!1}pretty(t){return this._formatter(t,this.format)}}i.AbstractSlider=S,r=S,S.__name__=\"AbstractSlider\",r.define((({Any:t,Boolean:e,Number:i,String:s,Color:l,Or:o,Enum:r,Ref:n,Nullable:a})=>({title:[a(s),\"\"],show_value:[e,!0],start:[t],end:[t],value:[t],value_throttled:[t],step:[i,1],format:[o(s,n(c.TickFormatter))],direction:[r(\"ltr\",\"rtl\"),\"ltr\"],tooltips:[e,!0],bar_color:[l,\"#e6e6e6\"]})))},\n", - " 459: function _(t,e,r,n,i){var o,s;o=this,s=function(t){\"use strict\";var e,r;function n(t){return\"object\"==typeof t&&\"function\"==typeof t.to}function i(t){t.parentElement.removeChild(t)}function o(t){return null!=t}function s(t){t.preventDefault()}function a(t){return\"number\"==typeof t&&!isNaN(t)&&isFinite(t)}function l(t,e,r){r>0&&(f(t,e),setTimeout((function(){d(t,e)}),r))}function u(t){return Math.max(Math.min(t,100),0)}function c(t){return Array.isArray(t)?t:[t]}function p(t){var e=(t=String(t)).split(\".\");return e.length>1?e[1].length:0}function f(t,e){t.classList&&!/\\s/.test(e)?t.classList.add(e):t.className+=\" \"+e}function d(t,e){t.classList&&!/\\s/.test(e)?t.classList.remove(e):t.className=t.className.replace(new RegExp(\"(^|\\\\b)\"+e.split(\" \").join(\"|\")+\"(\\\\b|$)\",\"gi\"),\" \")}function h(t){var e=void 0!==window.pageXOffset,r=\"CSS1Compat\"===(t.compatMode||\"\");return{x:e?window.pageXOffset:r?t.documentElement.scrollLeft:t.body.scrollLeft,y:e?window.pageYOffset:r?t.documentElement.scrollTop:t.body.scrollTop}}function m(t,e){return 100/(e-t)}function g(t,e,r){return 100*e/(t[r+1]-t[r])}function v(t,e){for(var r=1;t>=e[r];)r+=1;return r}function b(t,e,r){if(r>=t.slice(-1)[0])return 100;var n=v(r,t),i=t[n-1],o=t[n],s=e[n-1],a=e[n];return s+function(t,e){return g(t,t[0]<0?e+Math.abs(t[0]):e-t[0],0)}([i,o],r)/m(s,a)}function S(t,e,r,n){if(100===n)return n;var i=v(n,t),o=t[i-1],s=t[i];return r?n-o>(s-o)/2?s:o:e[i-1]?t[i-1]+function(t,e){return Math.round(t/e)*e}(n-t[i-1],e[i-1]):n}t.PipsMode=void 0,(e=t.PipsMode||(t.PipsMode={})).Range=\"range\",e.Steps=\"steps\",e.Positions=\"positions\",e.Count=\"count\",e.Values=\"values\",t.PipsType=void 0,(r=t.PipsType||(t.PipsType={}))[r.None=-1]=\"None\",r[r.NoValue=0]=\"NoValue\",r[r.LargeValue=1]=\"LargeValue\",r[r.SmallValue=2]=\"SmallValue\";var x=function(){function t(t,e,r){var n;this.xPct=[],this.xVal=[],this.xSteps=[],this.xNumSteps=[],this.xHighestCompleteStep=[],this.xSteps=[r||!1],this.xNumSteps=[!1],this.snap=e;var i=[];for(Object.keys(t).forEach((function(e){i.push([c(t[e]),e])})),i.sort((function(t,e){return t[0][0]-e[0][0]})),n=0;nthis.xPct[i+1];)i++;else t===this.xPct[this.xPct.length-1]&&(i=this.xPct.length-2);r||t!==this.xPct[i+1]||i++,null===e&&(e=[]);var o=1,s=e[i],a=0,l=0,u=0,c=0;for(n=r?(t-this.xPct[i])/(this.xPct[i+1]-this.xPct[i]):(this.xPct[i+1]-t)/(this.xPct[i+1]-this.xPct[i]);s>0;)a=this.xPct[i+1+c]-this.xPct[i+c],e[i+c]*o+100-100*n>100?(l=a*n,o=(s-100*n)/e[i+c],n=1):(l=e[i+c]*a/100*o,o=0),r?(u-=l,this.xPct.length+c>=1&&c--):(u+=l,this.xPct.length-c>=1&&c++),s=e[i+c]*o;return t+u},t.prototype.toStepping=function(t){return t=b(this.xVal,this.xPct,t)},t.prototype.fromStepping=function(t){return function(t,e,r){if(r>=100)return t.slice(-1)[0];var n=v(r,e),i=t[n-1],o=t[n],s=e[n-1];return function(t,e){return e*(t[1]-t[0])/100+t[0]}([i,o],(r-s)*m(s,e[n]))}(this.xVal,this.xPct,t)},t.prototype.getStep=function(t){return t=S(this.xPct,this.xSteps,this.snap,t)},t.prototype.getDefaultStep=function(t,e,r){var n=v(t,this.xPct);return(100===t||e&&t===this.xPct[n-1])&&(n=Math.max(n-1,1)),(this.xVal[n]-this.xVal[n-1])/r},t.prototype.getNearbySteps=function(t){var e=v(t,this.xPct);return{stepBefore:{startValue:this.xVal[e-2],step:this.xNumSteps[e-2],highestStep:this.xHighestCompleteStep[e-2]},thisStep:{startValue:this.xVal[e-1],step:this.xNumSteps[e-1],highestStep:this.xHighestCompleteStep[e-1]},stepAfter:{startValue:this.xVal[e],step:this.xNumSteps[e],highestStep:this.xHighestCompleteStep[e]}}},t.prototype.countStepDecimals=function(){var t=this.xNumSteps.map(p);return Math.max.apply(null,t)},t.prototype.hasNoSize=function(){return this.xVal[0]===this.xVal[this.xVal.length-1]},t.prototype.convert=function(t){return this.getStep(this.toStepping(t))},t.prototype.handleEntryPoint=function(t,e){var r;if(!a(r=\"min\"===t?0:\"max\"===t?100:parseFloat(t))||!a(e[0]))throw new Error(\"noUiSlider: 'range' value isn't numeric.\");this.xPct.push(r),this.xVal.push(e[0]);var n=Number(e[1]);r?this.xSteps.push(!isNaN(n)&&n):isNaN(n)||(this.xSteps[0]=n),this.xHighestCompleteStep.push(0)},t.prototype.handleStepPoint=function(t,e){if(e)if(this.xVal[t]!==this.xVal[t+1]){this.xSteps[t]=g([this.xVal[t],this.xVal[t+1]],e,0)/m(this.xPct[t],this.xPct[t+1]);var r=(this.xVal[t+1]-this.xVal[t])/this.xNumSteps[t],n=Math.ceil(Number(r.toFixed(3))-1),i=this.xVal[t]+this.xNumSteps[t]*n;this.xHighestCompleteStep[t]=i}else this.xSteps[t]=this.xHighestCompleteStep[t]=this.xVal[t]},t}(),y={to:function(t){return void 0===t?\"\":t.toFixed(2)},from:Number},w={target:\"target\",base:\"base\",origin:\"origin\",handle:\"handle\",handleLower:\"handle-lower\",handleUpper:\"handle-upper\",touchArea:\"touch-area\",horizontal:\"horizontal\",vertical:\"vertical\",background:\"background\",connect:\"connect\",connects:\"connects\",ltr:\"ltr\",rtl:\"rtl\",textDirectionLtr:\"txt-dir-ltr\",textDirectionRtl:\"txt-dir-rtl\",draggable:\"draggable\",drag:\"state-drag\",tap:\"state-tap\",active:\"active\",tooltip:\"tooltip\",pips:\"pips\",pipsHorizontal:\"pips-horizontal\",pipsVertical:\"pips-vertical\",marker:\"marker\",markerHorizontal:\"marker-horizontal\",markerVertical:\"marker-vertical\",markerNormal:\"marker-normal\",markerLarge:\"marker-large\",markerSub:\"marker-sub\",value:\"value\",valueHorizontal:\"value-horizontal\",valueVertical:\"value-vertical\",valueNormal:\"value-normal\",valueLarge:\"value-large\",valueSub:\"value-sub\"},E=\".__tooltips\",P=\".__aria\";function C(t,e){if(!a(e))throw new Error(\"noUiSlider: 'step' is not numeric.\");t.singleStep=e}function N(t,e){if(!a(e))throw new Error(\"noUiSlider: 'keyboardPageMultiplier' is not numeric.\");t.keyboardPageMultiplier=e}function V(t,e){if(!a(e))throw new Error(\"noUiSlider: 'keyboardMultiplier' is not numeric.\");t.keyboardMultiplier=e}function k(t,e){if(!a(e))throw new Error(\"noUiSlider: 'keyboardDefaultStep' is not numeric.\");t.keyboardDefaultStep=e}function M(t,e){if(\"object\"!=typeof e||Array.isArray(e))throw new Error(\"noUiSlider: 'range' is not an object.\");if(void 0===e.min||void 0===e.max)throw new Error(\"noUiSlider: Missing 'min' or 'max' in 'range'.\");t.spectrum=new x(e,t.snap||!1,t.singleStep)}function A(t,e){if(e=c(e),!Array.isArray(e)||!e.length)throw new Error(\"noUiSlider: 'start' option is incorrect.\");t.handles=e.length,t.start=e}function U(t,e){if(\"boolean\"!=typeof e)throw new Error(\"noUiSlider: 'snap' option must be a boolean.\");t.snap=e}function D(t,e){if(\"boolean\"!=typeof e)throw new Error(\"noUiSlider: 'animate' option must be a boolean.\");t.animate=e}function O(t,e){if(\"number\"!=typeof e)throw new Error(\"noUiSlider: 'animationDuration' option must be a number.\");t.animationDuration=e}function L(t,e){var r,n=[!1];if(\"lower\"===e?e=[!0,!1]:\"upper\"===e&&(e=[!1,!0]),!0===e||!1===e){for(r=1;r1)throw new Error(\"noUiSlider: 'padding' option must not exceed 100% of the range.\")}}function F(t,e){switch(e){case\"ltr\":t.dir=0;break;case\"rtl\":t.dir=1;break;default:throw new Error(\"noUiSlider: 'direction' option was not recognized.\")}}function R(t,e){if(\"string\"!=typeof e)throw new Error(\"noUiSlider: 'behaviour' must be a string containing options.\");var r=e.indexOf(\"tap\")>=0,n=e.indexOf(\"drag\")>=0,i=e.indexOf(\"fixed\")>=0,o=e.indexOf(\"snap\")>=0,s=e.indexOf(\"hover\")>=0,a=e.indexOf(\"unconstrained\")>=0,l=e.indexOf(\"drag-all\")>=0;if(i){if(2!==t.handles)throw new Error(\"noUiSlider: 'fixed' behaviour must be used with 2 handles\");j(t,t.start[1]-t.start[0])}if(a&&(t.margin||t.limit))throw new Error(\"noUiSlider: 'unconstrained' behaviour cannot be used with margin or limit\");t.events={tap:r||o,drag:n,dragAll:l,fixed:i,snap:o,hover:s,unconstrained:a}}function _(t,e){if(!1!==e)if(!0===e||n(e)){t.tooltips=[];for(var r=0;r= 2) required for mode 'count'.\");for(var r=e.values-1,n=100/r,i=[];r--;)i[r]=r*n;return i.push(100),q(i,e.stepped)}return e.mode===t.PipsMode.Positions?q(e.values,e.stepped):e.mode===t.PipsMode.Values?e.stepped?e.values.map((function(t){return C.fromStepping(C.getStep(C.toStepping(t)))})):e.values:[]}(e),i={},o=C.xVal[0],s=C.xVal[C.xVal.length-1],a=!1,l=!1,u=0;return r=n.slice().sort((function(t,e){return t-e})),(n=r.filter((function(t){return!this[t]&&(this[t]=!0)}),{}))[0]!==o&&(n.unshift(o),a=!0),n[n.length-1]!==s&&(n.push(s),l=!0),n.forEach((function(r,o){var s,c,p,f,d,h,m,g,v,b,S=r,x=n[o+1],y=e.mode===t.PipsMode.Steps;for(y&&(s=C.xNumSteps[o]),s||(s=x-S),void 0===x&&(x=S),s=Math.max(s,1e-7),c=S;c<=x;c=Number((c+s).toFixed(7))){for(g=(d=(f=C.toStepping(c))-u)/(e.density||1),b=d/(v=Math.round(g)),p=1;p<=v;p+=1)i[(h=u+p*b).toFixed(5)]=[C.fromStepping(h),0];m=n.indexOf(c)>-1?t.PipsType.LargeValue:y?t.PipsType.SmallValue:t.PipsType.NoValue,!o&&a&&c!==x&&(m=0),c===x&&l||(i[f.toFixed(5)]=[c,m]),u=f}})),i}function Y(e,n,i){var o,s,a=U.createElement(\"div\"),l=((o={})[t.PipsType.None]=\"\",o[t.PipsType.NoValue]=r.cssClasses.valueNormal,o[t.PipsType.LargeValue]=r.cssClasses.valueLarge,o[t.PipsType.SmallValue]=r.cssClasses.valueSub,o),u=((s={})[t.PipsType.None]=\"\",s[t.PipsType.NoValue]=r.cssClasses.markerNormal,s[t.PipsType.LargeValue]=r.cssClasses.markerLarge,s[t.PipsType.SmallValue]=r.cssClasses.markerSub,s),c=[r.cssClasses.valueHorizontal,r.cssClasses.valueVertical],p=[r.cssClasses.markerHorizontal,r.cssClasses.markerVertical];function d(t,e){var n=e===r.cssClasses.value,i=n?l:u;return e+\" \"+(n?c:p)[r.ort]+\" \"+i[t]}return f(a,r.cssClasses.pips),f(a,0===r.ort?r.cssClasses.pipsHorizontal:r.cssClasses.pipsVertical),Object.keys(e).forEach((function(o){!function(e,o,s){if((s=n?n(o,s):s)!==t.PipsType.None){var l=T(a,!1);l.className=d(s,r.cssClasses.marker),l.style[r.style]=e+\"%\",s>t.PipsType.NoValue&&((l=T(a,!1)).className=d(s,r.cssClasses.value),l.setAttribute(\"data-value\",String(o)),l.style[r.style]=e+\"%\",l.innerHTML=String(i.to(o)))}}(o,e[o][0],e[o][1])})),a}function I(){g&&(i(g),g=null)}function W(t){I();var e=X(t),r=t.filter,n=t.format||{to:function(t){return String(Math.round(t))}};return g=w.appendChild(Y(e,r,n))}function $(){var t=a.getBoundingClientRect(),e=\"offset\"+[\"Width\",\"Height\"][r.ort];return 0===r.ort?t.width||a[e]:t.height||a[e]}function J(t,e,n,i){var o=function(o){var s,a,l=function(t,e,r){var n=0===t.type.indexOf(\"touch\"),i=0===t.type.indexOf(\"mouse\"),o=0===t.type.indexOf(\"pointer\"),s=0,a=0;if(0===t.type.indexOf(\"MSPointer\")&&(o=!0),\"mousedown\"===t.type&&!t.buttons&&!t.touches)return!1;if(n){var l=function(e){var n=e.target;return n===r||r.contains(n)||t.composed&&t.composedPath().shift()===r};if(\"touchstart\"===t.type){var u=Array.prototype.filter.call(t.touches,l);if(u.length>1)return!1;s=u[0].pageX,a=u[0].pageY}else{var c=Array.prototype.find.call(t.changedTouches,l);if(!c)return!1;s=c.pageX,a=c.pageY}}return e=e||h(U),(i||o)&&(s=t.clientX+e.x,a=t.clientY+e.y),t.pageOffset=e,t.points=[s,a],t.cursor=i||o,t}(o,i.pageOffset,i.target||e);return!!l&&!(F()&&!i.doNotReject)&&(s=w,a=r.cssClasses.tap,!((s.classList?s.classList.contains(a):new RegExp(\"\\\\b\"+a+\"\\\\b\").test(s.className))&&!i.doNotReject)&&!(t===x.start&&void 0!==l.buttons&&l.buttons>1)&&(!i.hover||!l.buttons)&&(y||l.preventDefault(),l.calcPoint=l.points[r.ort],void n(l,i)))},s=[];return t.split(\" \").forEach((function(t){e.addEventListener(t,o,!!y&&{passive:!0}),s.push([t,o])})),s}function K(t){var e,n,i,o,s,l,c=100*(t-(e=a,n=r.ort,i=e.getBoundingClientRect(),o=e.ownerDocument,s=o.documentElement,l=h(o),/webkit.*Chrome.*Mobile/i.test(navigator.userAgent)&&(l.x=0),n?i.top+l.y-s.clientTop:i.left+l.x-s.clientLeft))/$();return c=u(c),r.dir?100-c:c}function Q(t,e){\"mouseout\"===t.type&&\"HTML\"===t.target.nodeName&&null===t.relatedTarget&&tt(t,e)}function Z(t,e){if(-1===navigator.appVersion.indexOf(\"MSIE 9\")&&0===t.buttons&&0!==e.buttonsProperty)return tt(t,e);var n=(r.dir?-1:1)*(t.calcPoint-e.startCalcPoint);ut(n>0,100*n/e.baseSize,e.locations,e.handleNumbers,e.connect)}function tt(t,e){e.handle&&(d(e.handle,r.cssClasses.active),M-=1),e.listeners.forEach((function(t){D.removeEventListener(t[0],t[1])})),0===M&&(d(w,r.cssClasses.drag),pt(),t.cursor&&(O.style.cursor=\"\",O.removeEventListener(\"selectstart\",s))),e.handleNumbers.forEach((function(t){st(\"change\",t),st(\"set\",t),st(\"end\",t)}))}function et(t,e){if(!e.handleNumbers.some(R)){var n;1===e.handleNumbers.length&&(n=p[e.handleNumbers[0]].children[0],M+=1,f(n,r.cssClasses.active)),t.stopPropagation();var i=[],o=J(x.move,D,Z,{target:t.target,handle:n,connect:e.connect,listeners:i,startCalcPoint:t.calcPoint,baseSize:$(),pageOffset:t.pageOffset,handleNumbers:e.handleNumbers,buttonsProperty:t.buttons,locations:V.slice()}),a=J(x.end,D,tt,{target:t.target,handle:n,listeners:i,doNotReject:!0,handleNumbers:e.handleNumbers}),l=J(\"mouseout\",D,Q,{target:t.target,handle:n,listeners:i,doNotReject:!0,handleNumbers:e.handleNumbers});i.push.apply(i,o.concat(a,l)),t.cursor&&(O.style.cursor=getComputedStyle(t.target).cursor,p.length>1&&f(w,r.cssClasses.drag),O.addEventListener(\"selectstart\",s,!1)),e.handleNumbers.forEach((function(t){st(\"start\",t)}))}}function rt(t){t.stopPropagation();var e=K(t.calcPoint),n=function(t){var e=100,r=!1;return p.forEach((function(n,i){if(!R(i)){var o=V[i],s=Math.abs(o-t);(so||100===s&&100===e)&&(r=i,e=s)}})),r}(e);!1!==n&&(r.events.snap||l(w,r.cssClasses.tap,r.animationDuration),ft(n,e,!0,!0),pt(),st(\"slide\",n,!0),st(\"update\",n,!0),r.events.snap?et(t,{handleNumbers:[n]}):(st(\"change\",n,!0),st(\"set\",n,!0)))}function nt(t){var e=K(t.calcPoint),r=C.getStep(e),n=C.fromStepping(r);Object.keys(A).forEach((function(t){\"hover\"===t.split(\".\")[0]&&A[t].forEach((function(t){t.call(bt,n)}))}))}function it(t,e){A[t]=A[t]||[],A[t].push(e),\"update\"===t.split(\".\")[0]&&p.forEach((function(t,e){st(\"update\",e)}))}function ot(t){var e=t&&t.split(\".\")[0],r=e?t.substring(e.length):t;Object.keys(A).forEach((function(t){var n=t.split(\".\")[0],i=t.substring(n.length);e&&e!==n||r&&r!==i||function(t){return t===P||t===E}(i)&&r!==i||delete A[t]}))}function st(t,e,n){Object.keys(A).forEach((function(i){var o=i.split(\".\")[0];t===o&&A[i].forEach((function(t){t.call(bt,N.map(r.format.to),e,N.slice(),n||!1,V.slice(),bt)}))}))}function at(t,e,n,i,o,s){var a;return p.length>1&&!r.events.unconstrained&&(i&&e>0&&(a=C.getAbsoluteDistance(t[e-1],r.margin,!1),n=Math.max(n,a)),o&&e1&&r.limit&&(i&&e>0&&(a=C.getAbsoluteDistance(t[e-1],r.limit,!1),n=Math.min(n,a)),o&&e1?n.forEach((function(t,r){var n=at(o,t,o[t]+e,a[r],l[r],!1);!1===n?e=0:(e=n-o[t],o[t]=n)})):a=l=[!0];var u=!1;n.forEach((function(t,n){u=ft(t,r[t]+e,a[n],l[n])||u})),u&&(n.forEach((function(t){st(\"update\",t),st(\"slide\",t)})),null!=i&&st(\"drag\",s))}function ct(t,e){return r.dir?100-t-e:t}function pt(){k.forEach((function(t){var e=V[t]>50?-1:1,r=3+(p.length+e*t);p[t].style.zIndex=String(r)}))}function ft(t,e,n,i,o){return o||(e=at(V,t,e,n,i,!1)),!1!==e&&(function(t,e){V[t]=e,N[t]=C.fromStepping(e);var n=\"translate(\"+lt(10*(ct(e,0)-L)+\"%\",\"0\")+\")\";p[t].style[r.transformRule]=n,dt(t),dt(t+1)}(t,e),!0)}function dt(t){if(m[t]){var e=0,n=100;0!==t&&(e=V[t-1]),t!==m.length-1&&(n=V[t]);var i=n-e,o=\"translate(\"+lt(ct(e,i)+\"%\",\"0\")+\")\",s=\"scale(\"+lt(i/100,\"1\")+\")\";m[t].style[r.transformRule]=o+\" \"+s}}function ht(t,e){return null===t||!1===t||void 0===t?V[e]:(\"number\"==typeof t&&(t=String(t)),!1!==(t=r.format.from(t))&&(t=C.toStepping(t)),!1===t||isNaN(t)?V[e]:t)}function mt(t,e,n){var i=c(t),o=void 0===V[0];e=void 0===e||e,r.animate&&!o&&l(w,r.cssClasses.tap,r.animationDuration),k.forEach((function(t){ft(t,ht(i[t],t),!0,!1,n)}));var s=1===k.length?0:1;if(o&&C.hasNoSize()&&(n=!0,V[0]=0,k.length>1)){var a=100/(k.length-1);k.forEach((function(t){V[t]=t*a}))}for(;sn.stepAfter.startValue&&(o=n.stepAfter.startValue-i),s=i>n.thisStep.startValue?n.thisStep.step:!1!==n.stepBefore.step&&i-n.stepBefore.highestStep,100===e?o=null:0===e&&(s=null);var a=C.countStepDecimals();return null!==o&&!1!==o&&(o=Number(o.toFixed(a))),null!==s&&!1!==s&&(s=Number(s.toFixed(a))),[s,o]}f(b=w,r.cssClasses.target),0===r.dir?f(b,r.cssClasses.ltr):f(b,r.cssClasses.rtl),0===r.ort?f(b,r.cssClasses.horizontal):f(b,r.cssClasses.vertical),f(b,\"rtl\"===getComputedStyle(b).direction?r.cssClasses.textDirectionRtl:r.cssClasses.textDirectionLtr),a=T(b,r.cssClasses.base),function(t,e){var n=T(e,r.cssClasses.connects);p=[],(m=[]).push(z(n,t[0]));for(var i=0;i=0&&t .noUi-tooltip{-webkit-transform:translate(50%, 0);transform:translate(50%, 0);left:auto;bottom:10px;}.bk-root .noUi-vertical .noUi-origin > .noUi-tooltip{-webkit-transform:translate(0, -18px);transform:translate(0, -18px);top:auto;right:28px;}.bk-root .noUi-handle{cursor:grab;cursor:-webkit-grab;}.bk-root .noUi-handle.noUi-active{cursor:grabbing;cursor:-webkit-grabbing;}.bk-root .noUi-handle:after,.bk-root .noUi-handle:before{display:none;}.bk-root .noUi-tooltip{display:none;white-space:nowrap;}.bk-root .noUi-handle:hover .noUi-tooltip{display:block;}.bk-root .noUi-horizontal{width:100%;height:10px;}.bk-root .noUi-vertical{width:10px;height:100%;}.bk-root .noUi-horizontal .noUi-handle{width:14px;height:18px;right:-7px;top:-5px;}.bk-root .noUi-vertical .noUi-handle{width:18px;height:14px;right:-5px;top:-7px;}.bk-root .noUi-target.noUi-horizontal{margin:5px 0px;}.bk-root .noUi-target.noUi-vertical{margin:0px 5px;}'},\n", - " 462: function _(e,t,r,a,i){a();var s;const d=(0,e(1).__importDefault)(e(151)),o=e(458),_=e(8);class n extends o.AbstractSliderView{}r.DateSliderView=n,n.__name__=\"DateSliderView\";class c extends o.AbstractSlider{constructor(e){super(e),this.behaviour=\"tap\",this.connected=[!0,!1]}_formatter(e,t){return(0,_.isString)(t)?(0,d.default)(e,t):t.compute(e)}}r.DateSlider=c,s=c,c.__name__=\"DateSlider\",s.prototype.default_view=n,s.override({format:\"%d %b %Y\"})},\n", - " 463: function _(e,t,s,r,i){var _;r();const n=e(464);class a extends n.MarkupView{render(){super.render(),this.model.render_as_text?this.markup_el.textContent=this.model.text:this.markup_el.innerHTML=this.has_math_disabled()?this.model.text:this.process_tex()}}s.DivView=a,a.__name__=\"DivView\";class d extends n.Markup{constructor(e){super(e)}}s.Div=d,_=d,d.__name__=\"Div\",_.prototype.default_view=a,_.define((({Boolean:e})=>({render_as_text:[e,!1]})))},\n", - " 464: function _(t,e,s,i,r){i();const a=t(1);var n;const o=t(210),d=t(43),h=t(137),l=t(508),_=(0,a.__importStar)(t(465));class u extends l.WidgetView{get provider(){return h.default_provider}async lazy_initialize(){await super.lazy_initialize(),\"not_started\"==this.provider.status&&await this.provider.fetch(),\"not_started\"!=this.provider.status&&\"loading\"!=this.provider.status||this.provider.ready.connect((()=>{this.contains_tex_string()&&this.rerender()}))}after_layout(){super.after_layout(),\"loading\"===this.provider.status&&(this._has_finished=!1)}rerender(){this.layout.invalidate_cache(),this.render(),this.root.compute_layout()}connect_signals(){super.connect_signals(),this.connect(this.model.change,(()=>{this.rerender()}))}styles(){return[...super.styles(),_.default]}_update_layout(){this.layout=new o.CachedVariadicBox(this.el),this.layout.set_sizing(this.box_sizing())}render(){super.render();const t=Object.assign(Object.assign({},this.model.style),{display:\"inline-block\"});this.markup_el=(0,d.div)({class:_.clearfix,style:t}),this.el.appendChild(this.markup_el),\"failed\"!=this.provider.status&&\"loaded\"!=this.provider.status||(this._has_finished=!0)}has_math_disabled(){return this.model.disable_math||!this.contains_tex_string()}process_tex(){if(!this.provider.MathJax)return this.model.text;const{text:t}=this.model,e=this.provider.MathJax.find_tex(t),s=[];let i=0;for(const r of e)s.push(t.slice(i,r.start.n)),s.push(this.provider.MathJax.tex2svg(r.math,{display:r.display}).outerHTML),i=r.end.n;return i0}}s.MarkupView=u,u.__name__=\"MarkupView\";class p extends l.Widget{constructor(t){super(t)}}s.Markup=p,n=p,p.__name__=\"Markup\",n.define((({Boolean:t,String:e,Dict:s})=>({text:[e,\"\"],style:[s(e),{}],disable_math:[t,!1]})))},\n", - " 465: function _(o,r,e,t,a){t(),e.root=\"bk-root\",e.clearfix=\"bk-clearfix\",e.default='.bk-root .bk-clearfix:before,.bk-root .bk-clearfix:after{content:\"\";display:table;}.bk-root .bk-clearfix:after{clear:both;}'},\n", - " 466: function _(e,t,i,n,s){n();const o=e(1);var l;const r=e(438),d=e(251),_=e(43),u=e(8),c=(0,o.__importStar)(e(318)),h=(0,o.__importStar)(e(229)),m=h;class p extends r.AbstractButtonView{constructor(){super(...arguments),this._open=!1}styles(){return[...super.styles(),h.default]}render(){super.render();const e=(0,_.div)({class:[m.caret,m.down]});if(this.model.is_split){const t=this._render_button(e);t.classList.add(c.dropdown_toggle),t.addEventListener(\"click\",(()=>this._toggle_menu())),this.group_el.appendChild(t)}else this.button_el.appendChild(e);const t=this.model.menu.map(((e,t)=>{if(null==e)return(0,_.div)({class:m.divider});{const i=(0,u.isString)(e)?e:e[0],n=(0,_.div)(i);return n.addEventListener(\"click\",(()=>this._item_click(t))),n}}));this.menu=(0,_.div)({class:[m.menu,m.below]},t),this.el.appendChild(this.menu),(0,_.undisplay)(this.menu)}_show_menu(){if(!this._open){this._open=!0,(0,_.display)(this.menu);const e=t=>{const{target:i}=t;i instanceof HTMLElement&&!this.el.contains(i)&&(document.removeEventListener(\"click\",e),this._hide_menu())};document.addEventListener(\"click\",e)}}_hide_menu(){this._open&&(this._open=!1,(0,_.undisplay)(this.menu))}_toggle_menu(){this._open?this._hide_menu():this._show_menu()}click(){this.model.is_split?(this._hide_menu(),this.model.trigger_event(new d.ButtonClick),super.click()):this._toggle_menu()}_item_click(e){this._hide_menu();const t=this.model.menu[e];if(null!=t){const i=(0,u.isString)(t)?t:t[1];(0,u.isString)(i)?this.model.trigger_event(new d.MenuItemClick(i)):i.execute(this.model,{index:e})}}}i.DropdownView=p,p.__name__=\"DropdownView\";class a extends r.AbstractButton{constructor(e){super(e)}get is_split(){return this.split}}i.Dropdown=a,l=a,a.__name__=\"Dropdown\",l.prototype.default_view=p,l.define((({Null:e,Boolean:t,String:i,Array:n,Tuple:s,Or:o})=>({split:[t,!1],menu:[n(o(i,s(i,o(i)),e)),[]]}))),l.override({label:\"Dropdown\"})},\n", - " 467: function _(e,l,i,t,s){var n;t();const a=e(43),o=e(508);class d extends o.WidgetView{connect_signals(){super.connect_signals(),this.connect(this.model.change,(()=>this.render()))}render(){const{multiple:e,accept:l,disabled:i,width:t}=this.model;null==this.dialog_el&&(this.dialog_el=(0,a.input)({type:\"file\",multiple:e}),this.dialog_el.onchange=()=>{const{files:e}=this.dialog_el;null!=e&&this.load_files(e)},this.el.appendChild(this.dialog_el)),null!=l&&\"\"!=l&&(this.dialog_el.accept=l),this.dialog_el.style.width=`${t}px`,this.dialog_el.disabled=i}async load_files(e){const l=[],i=[],t=[];for(const s of e){const e=await this._read_file(s),[,n=\"\",,a=\"\"]=e.split(/[:;,]/,4);l.push(a),i.push(s.name),t.push(n)}this.model.multiple?this.model.setv({value:l,filename:i,mime_type:t}):this.model.setv({value:l[0],filename:i[0],mime_type:t[0]})}_read_file(e){return new Promise(((l,i)=>{const t=new FileReader;t.onload=()=>{var s;const{result:n}=t;null!=n?l(n):i(null!==(s=t.error)&&void 0!==s?s:new Error(`unable to read '${e.name}'`))},t.readAsDataURL(e)}))}}i.FileInputView=d,d.__name__=\"FileInputView\";class r extends o.Widget{constructor(e){super(e)}}i.FileInput=r,n=r,r.__name__=\"FileInput\",n.prototype.default_view=d,n.define((({Boolean:e,String:l,Array:i,Or:t})=>({value:[t(l,i(l)),\"\"],mime_type:[t(l,i(l)),\"\"],filename:[t(l,i(l)),\"\"],accept:[l,\"\"],multiple:[e,!1]})))},\n", - " 468: function _(e,t,i,s,n){s();const l=e(1);var o;const r=e(43),c=e(8),h=e(445),p=(0,l.__importStar)(e(446));class d extends h.InputWidgetView{connect_signals(){super.connect_signals(),this.connect(this.model.properties.value.change,(()=>this.render_selection())),this.connect(this.model.properties.options.change,(()=>this.render())),this.connect(this.model.properties.name.change,(()=>this.render())),this.connect(this.model.properties.title.change,(()=>this.render())),this.connect(this.model.properties.size.change,(()=>this.render())),this.connect(this.model.properties.disabled.change,(()=>this.render()))}render(){super.render();const e=this.model.options.map((e=>{let t,i;return(0,c.isString)(e)?t=i=e:[t,i]=e,(0,r.option)({value:t},i)}));this.input_el=(0,r.select)({multiple:!0,class:p.input,name:this.model.name,disabled:this.model.disabled},e),this.input_el.addEventListener(\"change\",(()=>this.change_input())),this.group_el.appendChild(this.input_el),this.render_selection()}render_selection(){const e=new Set(this.model.value);for(const t of this.el.querySelectorAll(\"option\"))t.selected=e.has(t.value);this.input_el.size=this.model.size}change_input(){const e=null!=this.el.querySelector(\"select:focus\"),t=[];for(const e of this.el.querySelectorAll(\"option\"))e.selected&&t.push(e.value);this.model.value=t,super.change_input(),e&&this.input_el.focus()}}i.MultiSelectView=d,d.__name__=\"MultiSelectView\";class u extends h.InputWidget{constructor(e){super(e)}}i.MultiSelect=u,o=u,u.__name__=\"MultiSelect\",o.prototype.default_view=d,o.define((({Int:e,String:t,Array:i,Tuple:s,Or:n})=>({value:[i(t),[]],options:[i(n(t,s(t,t))),[]],size:[e,4]})))},\n", - " 469: function _(e,a,r,t,s){var n;t();const p=e(464),_=e(43);class i extends p.MarkupView{render(){super.render();const e=(0,_.p)({style:{margin:0}});this.has_math_disabled()?e.textContent=this.model.text:e.innerHTML=this.process_tex(),this.markup_el.appendChild(e)}}r.ParagraphView=i,i.__name__=\"ParagraphView\";class h extends p.Markup{constructor(e){super(e)}}r.Paragraph=h,n=h,h.__name__=\"Paragraph\",n.prototype.default_view=i},\n", - " 470: function _(e,s,t,n,r){var p;n();const u=e(443);class a extends u.TextInputView{render(){super.render(),this.input_el.type=\"password\"}}t.PasswordInputView=a,a.__name__=\"PasswordInputView\";class o extends u.TextInput{constructor(e){super(e)}}t.PasswordInput=o,p=o,o.__name__=\"PasswordInput\",p.prototype.default_view=a},\n", - " 471: function _(e,t,i,l,s){l();const o=e(1);var n;const h=(0,o.__importDefault)(e(472)),a=e(43),u=e(8),c=e(210),_=(0,o.__importStar)(e(446)),d=(0,o.__importDefault)(e(473)),r=e(445);class m extends r.InputWidgetView{constructor(){super(...arguments),this._last_height=null}connect_signals(){super.connect_signals(),this.connect(this.model.properties.disabled.change,(()=>this.set_disabled()));const{value:e,max_items:t,option_limit:i,search_option_limit:l,delete_button:s,placeholder:o,options:n,name:h,title:a}=this.model.properties;this.on_change([e,t,i,l,s,o,n,h,a],(()=>this.render()))}styles(){return[...super.styles(),d.default]}_update_layout(){this.layout=new c.CachedVariadicBox(this.el),this.layout.set_sizing(this.box_sizing())}render(){super.render(),this.input_el=(0,a.select)({multiple:!0,class:_.input,name:this.model.name,disabled:this.model.disabled}),this.group_el.appendChild(this.input_el);const e=new Set(this.model.value),t=this.model.options.map((t=>{let i,l;return(0,u.isString)(t)?i=l=t:[i,l]=t,{value:i,label:l,selected:e.has(i)}})),i=this.model.solid?\"solid\":\"light\",l=`choices__item ${i}`,s=`choices__button ${i}`,o={choices:t,duplicateItemsAllowed:!1,removeItemButton:this.model.delete_button,classNames:{item:l,button:s}};null!=this.model.placeholder&&(o.placeholderValue=this.model.placeholder),null!=this.model.max_items&&(o.maxItemCount=this.model.max_items),null!=this.model.option_limit&&(o.renderChoiceLimit=this.model.option_limit),null!=this.model.search_option_limit&&(o.searchResultLimit=this.model.search_option_limit),this.choice_el=new h.default(this.input_el,o);const n=()=>this.choice_el.containerOuter.element.getBoundingClientRect().height;null!=this._last_height&&this._last_height!=n()&&this.root.invalidate_layout(),this._last_height=n(),this.input_el.addEventListener(\"change\",(()=>this.change_input()))}set_disabled(){this.model.disabled?this.choice_el.disable():this.choice_el.enable()}change_input(){const e=null!=this.el.querySelector(\"select:focus\"),t=[];for(const e of this.el.querySelectorAll(\"option\"))e.selected&&t.push(e.value);this.model.value=t,super.change_input(),e&&this.input_el.focus()}}i.MultiChoiceView=m,m.__name__=\"MultiChoiceView\";class p extends r.InputWidget{constructor(e){super(e)}}i.MultiChoice=p,n=p,p.__name__=\"MultiChoice\",n.prototype.default_view=m,n.define((({Boolean:e,Int:t,String:i,Array:l,Tuple:s,Or:o,Nullable:n})=>({value:[l(i),[]],options:[l(o(i,s(i,i))),[]],max_items:[n(t),null],delete_button:[e,!0],placeholder:[n(i),null],option_limit:[n(t),null],search_option_limit:[n(t),null],solid:[e,!0]})))},\n", - " 472: function _(e,t,i,n,s){\n", + " 459: function _(t,e,a,r,i){r(),a.default='.flatpickr-calendar{background:transparent;opacity:0;display:none;text-align:center;visibility:hidden;padding:0;-webkit-animation:none;animation:none;direction:ltr;border:0;font-size:14px;line-height:24px;border-radius:5px;position:absolute;width:307.875px;-webkit-box-sizing:border-box;box-sizing:border-box;-ms-touch-action:manipulation;touch-action:manipulation;background:#fff;-webkit-box-shadow:1px 0 0 #e6e6e6, -1px 0 0 #e6e6e6, 0 1px 0 #e6e6e6, 0 -1px 0 #e6e6e6, 0 3px 13px rgba(0, 0, 0, 0.08);box-shadow:1px 0 0 #e6e6e6, -1px 0 0 #e6e6e6, 0 1px 0 #e6e6e6, 0 -1px 0 #e6e6e6, 0 3px 13px rgba(0, 0, 0, 0.08);}.flatpickr-calendar.open,.flatpickr-calendar.inline{opacity:1;max-height:640px;visibility:visible;}.flatpickr-calendar.open{display:inline-block;z-index:99999;}.flatpickr-calendar.animate.open{-webkit-animation:fpFadeInDown 300ms cubic-bezier(0.23, 1, 0.32, 1);animation:fpFadeInDown 300ms cubic-bezier(0.23, 1, 0.32, 1);}.flatpickr-calendar.inline{display:block;position:relative;top:2px;}.flatpickr-calendar.static{position:absolute;top:calc(100% + 2px);}.flatpickr-calendar.static.open{z-index:999;display:block;}.flatpickr-calendar.multiMonth .flatpickr-days .dayContainer:nth-child(n+1) .flatpickr-day.inRange:nth-child(7n+7){-webkit-box-shadow:none !important;box-shadow:none !important;}.flatpickr-calendar.multiMonth .flatpickr-days .dayContainer:nth-child(n+2) .flatpickr-day.inRange:nth-child(7n+1){-webkit-box-shadow:-2px 0 0 #e6e6e6, 5px 0 0 #e6e6e6;box-shadow:-2px 0 0 #e6e6e6, 5px 0 0 #e6e6e6;}.flatpickr-calendar .hasWeeks .dayContainer,.flatpickr-calendar .hasTime .dayContainer{border-bottom:0;border-bottom-right-radius:0;border-bottom-left-radius:0;}.flatpickr-calendar .hasWeeks .dayContainer{border-left:0;}.flatpickr-calendar.hasTime .flatpickr-time{height:40px;border-top:1px solid #e6e6e6;}.flatpickr-calendar.noCalendar.hasTime .flatpickr-time{height:auto;}.flatpickr-calendar:before,.flatpickr-calendar:after{position:absolute;display:block;pointer-events:none;border:solid transparent;content:\\'\\';height:0;width:0;left:22px;}.flatpickr-calendar.rightMost:before,.flatpickr-calendar.arrowRight:before,.flatpickr-calendar.rightMost:after,.flatpickr-calendar.arrowRight:after{left:auto;right:22px;}.flatpickr-calendar.arrowCenter:before,.flatpickr-calendar.arrowCenter:after{left:50%;right:50%;}.flatpickr-calendar:before{border-width:5px;margin:0 -5px;}.flatpickr-calendar:after{border-width:4px;margin:0 -4px;}.flatpickr-calendar.arrowTop:before,.flatpickr-calendar.arrowTop:after{bottom:100%;}.flatpickr-calendar.arrowTop:before{border-bottom-color:#e6e6e6;}.flatpickr-calendar.arrowTop:after{border-bottom-color:#fff;}.flatpickr-calendar.arrowBottom:before,.flatpickr-calendar.arrowBottom:after{top:100%;}.flatpickr-calendar.arrowBottom:before{border-top-color:#e6e6e6;}.flatpickr-calendar.arrowBottom:after{border-top-color:#fff;}.flatpickr-calendar:focus{outline:0;}.flatpickr-wrapper{position:relative;display:inline-block;}.flatpickr-months{display:-webkit-box;display:-webkit-flex;display:-ms-flexbox;display:flex;}.flatpickr-months .flatpickr-month{background:transparent;color:rgba(0, 0, 0, 0.9);fill:rgba(0, 0, 0, 0.9);height:34px;line-height:1;text-align:center;position:relative;-webkit-user-select:none;-moz-user-select:none;-ms-user-select:none;user-select:none;overflow:hidden;-webkit-box-flex:1;-webkit-flex:1;-ms-flex:1;flex:1;}.flatpickr-months .flatpickr-prev-month,.flatpickr-months .flatpickr-next-month{text-decoration:none;cursor:pointer;position:absolute;top:0;height:34px;padding:10px;z-index:3;color:rgba(0, 0, 0, 0.9);fill:rgba(0, 0, 0, 0.9);}.flatpickr-months .flatpickr-prev-month.flatpickr-disabled,.flatpickr-months .flatpickr-next-month.flatpickr-disabled{display:none;}.flatpickr-months .flatpickr-prev-month i,.flatpickr-months .flatpickr-next-month i{position:relative;}.flatpickr-months .flatpickr-prev-month.flatpickr-prev-month,.flatpickr-months .flatpickr-next-month.flatpickr-prev-month{left:0;}.flatpickr-months .flatpickr-prev-month.flatpickr-next-month,.flatpickr-months .flatpickr-next-month.flatpickr-next-month{right:0;}.flatpickr-months .flatpickr-prev-month:hover,.flatpickr-months .flatpickr-next-month:hover{color:#959ea9;}.flatpickr-months .flatpickr-prev-month:hover svg,.flatpickr-months .flatpickr-next-month:hover svg{fill:#f64747;}.flatpickr-months .flatpickr-prev-month svg,.flatpickr-months .flatpickr-next-month svg{width:14px;height:14px;}.flatpickr-months .flatpickr-prev-month svg path,.flatpickr-months .flatpickr-next-month svg path{-webkit-transition:fill 0.1s;transition:fill 0.1s;fill:inherit;}.numInputWrapper{position:relative;height:auto;}.numInputWrapper input,.numInputWrapper span{display:inline-block;}.numInputWrapper input{width:100%;}.numInputWrapper input::-ms-clear{display:none;}.numInputWrapper input::-webkit-outer-spin-button,.numInputWrapper input::-webkit-inner-spin-button{margin:0;-webkit-appearance:none;}.numInputWrapper span{position:absolute;right:0;width:14px;padding:0 4px 0 2px;height:50%;line-height:50%;opacity:0;cursor:pointer;border:1px solid rgba(57, 57, 57, 0.15);-webkit-box-sizing:border-box;box-sizing:border-box;}.numInputWrapper span:hover{background:rgba(0, 0, 0, 0.1);}.numInputWrapper span:active{background:rgba(0, 0, 0, 0.2);}.numInputWrapper span:after{display:block;content:\"\";position:absolute;}.numInputWrapper span.arrowUp{top:0;border-bottom:0;}.numInputWrapper span.arrowUp:after{border-left:4px solid transparent;border-right:4px solid transparent;border-bottom:4px solid rgba(57, 57, 57, 0.6);top:26%;}.numInputWrapper span.arrowDown{top:50%;}.numInputWrapper span.arrowDown:after{border-left:4px solid transparent;border-right:4px solid transparent;border-top:4px solid rgba(57, 57, 57, 0.6);top:40%;}.numInputWrapper span svg{width:inherit;height:auto;}.numInputWrapper span svg path{fill:rgba(0, 0, 0, 0.5);}.numInputWrapper:hover{background:rgba(0, 0, 0, 0.05);}.numInputWrapper:hover span{opacity:1;}.flatpickr-current-month{font-size:135%;line-height:inherit;font-weight:300;color:inherit;position:absolute;width:75%;left:12.5%;padding:7.48px 0 0 0;line-height:1;height:34px;display:inline-block;text-align:center;-webkit-transform:translate3d(0px, 0px, 0px);transform:translate3d(0px, 0px, 0px);}.flatpickr-current-month span.cur-month{font-family:inherit;font-weight:700;color:inherit;display:inline-block;margin-left:0.5ch;padding:0;}.flatpickr-current-month span.cur-month:hover{background:rgba(0, 0, 0, 0.05);}.flatpickr-current-month .numInputWrapper{width:6ch;width:7ch\\0;display:inline-block;}.flatpickr-current-month .numInputWrapper span.arrowUp:after{border-bottom-color:rgba(0, 0, 0, 0.9);}.flatpickr-current-month .numInputWrapper span.arrowDown:after{border-top-color:rgba(0, 0, 0, 0.9);}.flatpickr-current-month input.cur-year{background:transparent;-webkit-box-sizing:border-box;box-sizing:border-box;color:inherit;cursor:text;padding:0 0 0 0.5ch;margin:0;display:inline-block;font-size:inherit;font-family:inherit;font-weight:300;line-height:inherit;height:auto;border:0;border-radius:0;vertical-align:initial;-webkit-appearance:textfield;-moz-appearance:textfield;appearance:textfield;}.flatpickr-current-month input.cur-year:focus{outline:0;}.flatpickr-current-month input.cur-year[disabled],.flatpickr-current-month input.cur-year[disabled]:hover{font-size:100%;color:rgba(0, 0, 0, 0.5);background:transparent;pointer-events:none;}.flatpickr-current-month .flatpickr-monthDropdown-months{appearance:menulist;background:transparent;border:none;border-radius:0;box-sizing:border-box;color:inherit;cursor:pointer;font-size:inherit;font-family:inherit;font-weight:300;height:auto;line-height:inherit;margin:-1px 0 0 0;outline:none;padding:0 0 0 0.5ch;position:relative;vertical-align:initial;-webkit-box-sizing:border-box;-webkit-appearance:menulist;-moz-appearance:menulist;width:auto;}.flatpickr-current-month .flatpickr-monthDropdown-months:focus,.flatpickr-current-month .flatpickr-monthDropdown-months:active{outline:none;}.flatpickr-current-month .flatpickr-monthDropdown-months:hover{background:rgba(0, 0, 0, 0.05);}.flatpickr-current-month .flatpickr-monthDropdown-months .flatpickr-monthDropdown-month{background-color:transparent;outline:none;padding:0;}.flatpickr-weekdays{background:transparent;text-align:center;overflow:hidden;width:100%;display:-webkit-box;display:-webkit-flex;display:-ms-flexbox;display:flex;-webkit-box-align:center;-webkit-align-items:center;-ms-flex-align:center;align-items:center;height:28px;}.flatpickr-weekdays .flatpickr-weekdaycontainer{display:-webkit-box;display:-webkit-flex;display:-ms-flexbox;display:flex;-webkit-box-flex:1;-webkit-flex:1;-ms-flex:1;flex:1;}span.flatpickr-weekday{cursor:default;font-size:90%;background:transparent;color:rgba(0, 0, 0, 0.54);line-height:1;margin:0;text-align:center;display:block;-webkit-box-flex:1;-webkit-flex:1;-ms-flex:1;flex:1;font-weight:bolder;}.dayContainer,.flatpickr-weeks{padding:1px 0 0 0;}.flatpickr-days{position:relative;overflow:hidden;display:-webkit-box;display:-webkit-flex;display:-ms-flexbox;display:flex;-webkit-box-align:start;-webkit-align-items:flex-start;-ms-flex-align:start;align-items:flex-start;width:307.875px;}.flatpickr-days:focus{outline:0;}.dayContainer{padding:0;outline:0;text-align:left;width:307.875px;min-width:307.875px;max-width:307.875px;-webkit-box-sizing:border-box;box-sizing:border-box;display:inline-block;display:-ms-flexbox;display:-webkit-box;display:-webkit-flex;display:flex;-webkit-flex-wrap:wrap;flex-wrap:wrap;-ms-flex-wrap:wrap;-ms-flex-pack:justify;-webkit-justify-content:space-around;justify-content:space-around;-webkit-transform:translate3d(0px, 0px, 0px);transform:translate3d(0px, 0px, 0px);opacity:1;}.dayContainer + .dayContainer{-webkit-box-shadow:-1px 0 0 #e6e6e6;box-shadow:-1px 0 0 #e6e6e6;}.flatpickr-day{background:none;border:1px solid transparent;border-radius:150px;-webkit-box-sizing:border-box;box-sizing:border-box;color:#393939;cursor:pointer;font-weight:400;width:14.2857143%;-webkit-flex-basis:14.2857143%;-ms-flex-preferred-size:14.2857143%;flex-basis:14.2857143%;max-width:39px;height:39px;line-height:39px;margin:0;display:inline-block;position:relative;-webkit-box-pack:center;-webkit-justify-content:center;-ms-flex-pack:center;justify-content:center;text-align:center;}.flatpickr-day.inRange,.flatpickr-day.prevMonthDay.inRange,.flatpickr-day.nextMonthDay.inRange,.flatpickr-day.today.inRange,.flatpickr-day.prevMonthDay.today.inRange,.flatpickr-day.nextMonthDay.today.inRange,.flatpickr-day:hover,.flatpickr-day.prevMonthDay:hover,.flatpickr-day.nextMonthDay:hover,.flatpickr-day:focus,.flatpickr-day.prevMonthDay:focus,.flatpickr-day.nextMonthDay:focus{cursor:pointer;outline:0;background:#e6e6e6;border-color:#e6e6e6;}.flatpickr-day.today{border-color:#959ea9;}.flatpickr-day.today:hover,.flatpickr-day.today:focus{border-color:#959ea9;background:#959ea9;color:#fff;}.flatpickr-day.selected,.flatpickr-day.startRange,.flatpickr-day.endRange,.flatpickr-day.selected.inRange,.flatpickr-day.startRange.inRange,.flatpickr-day.endRange.inRange,.flatpickr-day.selected:focus,.flatpickr-day.startRange:focus,.flatpickr-day.endRange:focus,.flatpickr-day.selected:hover,.flatpickr-day.startRange:hover,.flatpickr-day.endRange:hover,.flatpickr-day.selected.prevMonthDay,.flatpickr-day.startRange.prevMonthDay,.flatpickr-day.endRange.prevMonthDay,.flatpickr-day.selected.nextMonthDay,.flatpickr-day.startRange.nextMonthDay,.flatpickr-day.endRange.nextMonthDay{background:#569ff7;-webkit-box-shadow:none;box-shadow:none;color:#fff;border-color:#569ff7;}.flatpickr-day.selected.startRange,.flatpickr-day.startRange.startRange,.flatpickr-day.endRange.startRange{border-radius:50px 0 0 50px;}.flatpickr-day.selected.endRange,.flatpickr-day.startRange.endRange,.flatpickr-day.endRange.endRange{border-radius:0 50px 50px 0;}.flatpickr-day.selected.startRange + .endRange:not(:nth-child(7n+1)),.flatpickr-day.startRange.startRange + .endRange:not(:nth-child(7n+1)),.flatpickr-day.endRange.startRange + .endRange:not(:nth-child(7n+1)){-webkit-box-shadow:-10px 0 0 #569ff7;box-shadow:-10px 0 0 #569ff7;}.flatpickr-day.selected.startRange.endRange,.flatpickr-day.startRange.startRange.endRange,.flatpickr-day.endRange.startRange.endRange{border-radius:50px;}.flatpickr-day.inRange{border-radius:0;-webkit-box-shadow:-5px 0 0 #e6e6e6, 5px 0 0 #e6e6e6;box-shadow:-5px 0 0 #e6e6e6, 5px 0 0 #e6e6e6;}.flatpickr-day.flatpickr-disabled,.flatpickr-day.flatpickr-disabled:hover,.flatpickr-day.prevMonthDay,.flatpickr-day.nextMonthDay,.flatpickr-day.notAllowed,.flatpickr-day.notAllowed.prevMonthDay,.flatpickr-day.notAllowed.nextMonthDay{color:rgba(57, 57, 57, 0.3);background:transparent;border-color:transparent;cursor:default;}.flatpickr-day.flatpickr-disabled,.flatpickr-day.flatpickr-disabled:hover{cursor:not-allowed;color:rgba(57, 57, 57, 0.1);}.flatpickr-day.week.selected{border-radius:0;-webkit-box-shadow:-5px 0 0 #569ff7, 5px 0 0 #569ff7;box-shadow:-5px 0 0 #569ff7, 5px 0 0 #569ff7;}.flatpickr-day.hidden{visibility:hidden;}.rangeMode .flatpickr-day{margin-top:1px;}.flatpickr-weekwrapper{float:left;}.flatpickr-weekwrapper .flatpickr-weeks{padding:0 12px;-webkit-box-shadow:1px 0 0 #e6e6e6;box-shadow:1px 0 0 #e6e6e6;}.flatpickr-weekwrapper .flatpickr-weekday{float:none;width:100%;line-height:28px;}.flatpickr-weekwrapper span.flatpickr-day,.flatpickr-weekwrapper span.flatpickr-day:hover{display:block;width:100%;max-width:none;color:rgba(57, 57, 57, 0.3);background:transparent;cursor:default;border:none;}.flatpickr-innerContainer{display:block;display:-webkit-box;display:-webkit-flex;display:-ms-flexbox;display:flex;-webkit-box-sizing:border-box;box-sizing:border-box;overflow:hidden;}.flatpickr-rContainer{display:inline-block;padding:0;-webkit-box-sizing:border-box;box-sizing:border-box;}.flatpickr-time{text-align:center;outline:0;display:block;height:0;line-height:40px;max-height:40px;-webkit-box-sizing:border-box;box-sizing:border-box;overflow:hidden;display:-webkit-box;display:-webkit-flex;display:-ms-flexbox;display:flex;}.flatpickr-time:after{content:\"\";display:table;clear:both;}.flatpickr-time .numInputWrapper{-webkit-box-flex:1;-webkit-flex:1;-ms-flex:1;flex:1;width:40%;height:40px;float:left;}.flatpickr-time .numInputWrapper span.arrowUp:after{border-bottom-color:#393939;}.flatpickr-time .numInputWrapper span.arrowDown:after{border-top-color:#393939;}.flatpickr-time.hasSeconds .numInputWrapper{width:26%;}.flatpickr-time.time24hr .numInputWrapper{width:49%;}.flatpickr-time input{background:transparent;-webkit-box-shadow:none;box-shadow:none;border:0;border-radius:0;text-align:center;margin:0;padding:0;height:inherit;line-height:inherit;color:#393939;font-size:14px;position:relative;-webkit-box-sizing:border-box;box-sizing:border-box;-webkit-appearance:textfield;-moz-appearance:textfield;appearance:textfield;}.flatpickr-time input.flatpickr-hour{font-weight:bold;}.flatpickr-time input.flatpickr-minute,.flatpickr-time input.flatpickr-second{font-weight:400;}.flatpickr-time input:focus{outline:0;border:0;}.flatpickr-time .flatpickr-time-separator,.flatpickr-time .flatpickr-am-pm{height:inherit;float:left;line-height:inherit;color:#393939;font-weight:bold;width:2%;-webkit-user-select:none;-moz-user-select:none;-ms-user-select:none;user-select:none;-webkit-align-self:center;-ms-flex-item-align:center;align-self:center;}.flatpickr-time .flatpickr-am-pm{outline:0;width:18%;cursor:pointer;text-align:center;font-weight:400;}.flatpickr-time input:hover,.flatpickr-time .flatpickr-am-pm:hover,.flatpickr-time input:focus,.flatpickr-time .flatpickr-am-pm:focus{background:#eee;}.flatpickr-input[readonly]{cursor:pointer;}@-webkit-keyframes fpFadeInDown{from{opacity:0;-webkit-transform:translate3d(0, -20px, 0);transform:translate3d(0, -20px, 0);}to{opacity:1;-webkit-transform:translate3d(0, 0, 0);transform:translate3d(0, 0, 0);}}@keyframes fpFadeInDown{from{opacity:0;-webkit-transform:translate3d(0, -20px, 0);transform:translate3d(0, -20px, 0);}to{opacity:1;-webkit-transform:translate3d(0, 0, 0);transform:translate3d(0, 0, 0);}}.flatpickr-calendar{background:transparent;opacity:0;display:none;text-align:center;visibility:hidden;padding:0;-webkit-animation:none;animation:none;direction:ltr;border:0;font-size:14px;line-height:24px;border-radius:5px;position:absolute;width:307.875px;-webkit-box-sizing:border-box;box-sizing:border-box;-ms-touch-action:manipulation;touch-action:manipulation;-webkit-box-shadow:0 3px 13px rgba(0, 0, 0, 0.08);box-shadow:0 3px 13px rgba(0, 0, 0, 0.08);}.flatpickr-calendar.open,.flatpickr-calendar.inline{opacity:1;max-height:640px;visibility:visible;}.flatpickr-calendar.open{display:inline-block;z-index:99999;}.flatpickr-calendar.animate.open{-webkit-animation:fpFadeInDown 300ms cubic-bezier(0.23, 1, 0.32, 1);animation:fpFadeInDown 300ms cubic-bezier(0.23, 1, 0.32, 1);}.flatpickr-calendar.inline{display:block;position:relative;top:2px;}.flatpickr-calendar.static{position:absolute;top:calc(100% + 2px);}.flatpickr-calendar.static.open{z-index:999;display:block;}.flatpickr-calendar.multiMonth .flatpickr-days .dayContainer:nth-child(n+1) .flatpickr-day.inRange:nth-child(7n+7){-webkit-box-shadow:none !important;box-shadow:none !important;}.flatpickr-calendar.multiMonth .flatpickr-days .dayContainer:nth-child(n+2) .flatpickr-day.inRange:nth-child(7n+1){-webkit-box-shadow:-2px 0 0 #e6e6e6, 5px 0 0 #e6e6e6;box-shadow:-2px 0 0 #e6e6e6, 5px 0 0 #e6e6e6;}.flatpickr-calendar .hasWeeks .dayContainer,.flatpickr-calendar .hasTime .dayContainer{border-bottom:0;border-bottom-right-radius:0;border-bottom-left-radius:0;}.flatpickr-calendar .hasWeeks .dayContainer{border-left:0;}.flatpickr-calendar.hasTime .flatpickr-time{height:40px;border-top:1px solid #eceef1;}.flatpickr-calendar.hasTime .flatpickr-innerContainer{border-bottom:0;}.flatpickr-calendar.hasTime .flatpickr-time{border:1px solid #eceef1;}.flatpickr-calendar.noCalendar.hasTime .flatpickr-time{height:auto;}.flatpickr-calendar:before,.flatpickr-calendar:after{position:absolute;display:block;pointer-events:none;border:solid transparent;content:\\'\\';height:0;width:0;left:22px;}.flatpickr-calendar.rightMost:before,.flatpickr-calendar.arrowRight:before,.flatpickr-calendar.rightMost:after,.flatpickr-calendar.arrowRight:after{left:auto;right:22px;}.flatpickr-calendar.arrowCenter:before,.flatpickr-calendar.arrowCenter:after{left:50%;right:50%;}.flatpickr-calendar:before{border-width:5px;margin:0 -5px;}.flatpickr-calendar:after{border-width:4px;margin:0 -4px;}.flatpickr-calendar.arrowTop:before,.flatpickr-calendar.arrowTop:after{bottom:100%;}.flatpickr-calendar.arrowTop:before{border-bottom-color:#eceef1;}.flatpickr-calendar.arrowTop:after{border-bottom-color:#eceef1;}.flatpickr-calendar.arrowBottom:before,.flatpickr-calendar.arrowBottom:after{top:100%;}.flatpickr-calendar.arrowBottom:before{border-top-color:#eceef1;}.flatpickr-calendar.arrowBottom:after{border-top-color:#eceef1;}.flatpickr-calendar:focus{outline:0;}.flatpickr-wrapper{position:relative;display:inline-block;}.flatpickr-months{display:-webkit-box;display:-webkit-flex;display:-ms-flexbox;display:flex;}.flatpickr-months .flatpickr-month{border-radius:5px 5px 0 0;background:#eceef1;color:#5a6171;fill:#5a6171;height:34px;line-height:1;text-align:center;position:relative;-webkit-user-select:none;-moz-user-select:none;-ms-user-select:none;user-select:none;overflow:hidden;-webkit-box-flex:1;-webkit-flex:1;-ms-flex:1;flex:1;}.flatpickr-months .flatpickr-prev-month,.flatpickr-months .flatpickr-next-month{text-decoration:none;cursor:pointer;position:absolute;top:0;height:34px;padding:10px;z-index:3;color:#5a6171;fill:#5a6171;}.flatpickr-months .flatpickr-prev-month.flatpickr-disabled,.flatpickr-months .flatpickr-next-month.flatpickr-disabled{display:none;}.flatpickr-months .flatpickr-prev-month i,.flatpickr-months .flatpickr-next-month i{position:relative;}.flatpickr-months .flatpickr-prev-month.flatpickr-prev-month,.flatpickr-months .flatpickr-next-month.flatpickr-prev-month{left:0;}.flatpickr-months .flatpickr-prev-month.flatpickr-next-month,.flatpickr-months .flatpickr-next-month.flatpickr-next-month{right:0;}.flatpickr-months .flatpickr-prev-month:hover,.flatpickr-months .flatpickr-next-month:hover{color:#bbb;}.flatpickr-months .flatpickr-prev-month:hover svg,.flatpickr-months .flatpickr-next-month:hover svg{fill:#f64747;}.flatpickr-months .flatpickr-prev-month svg,.flatpickr-months .flatpickr-next-month svg{width:14px;height:14px;}.flatpickr-months .flatpickr-prev-month svg path,.flatpickr-months .flatpickr-next-month svg path{-webkit-transition:fill 0.1s;transition:fill 0.1s;fill:inherit;}.numInputWrapper{position:relative;height:auto;}.numInputWrapper input,.numInputWrapper span{display:inline-block;}.numInputWrapper input{width:100%;}.numInputWrapper input::-ms-clear{display:none;}.numInputWrapper input::-webkit-outer-spin-button,.numInputWrapper input::-webkit-inner-spin-button{margin:0;-webkit-appearance:none;}.numInputWrapper span{position:absolute;right:0;width:14px;padding:0 4px 0 2px;height:50%;line-height:50%;opacity:0;cursor:pointer;border:1px solid rgba(72, 72, 72, 0.15);-webkit-box-sizing:border-box;box-sizing:border-box;}.numInputWrapper span:hover{background:rgba(0, 0, 0, 0.1);}.numInputWrapper span:active{background:rgba(0, 0, 0, 0.2);}.numInputWrapper span:after{display:block;content:\"\";position:absolute;}.numInputWrapper span.arrowUp{top:0;border-bottom:0;}.numInputWrapper span.arrowUp:after{border-left:4px solid transparent;border-right:4px solid transparent;border-bottom:4px solid rgba(72, 72, 72, 0.6);top:26%;}.numInputWrapper span.arrowDown{top:50%;}.numInputWrapper span.arrowDown:after{border-left:4px solid transparent;border-right:4px solid transparent;border-top:4px solid rgba(72, 72, 72, 0.6);top:40%;}.numInputWrapper span svg{width:inherit;height:auto;}.numInputWrapper span svg path{fill:rgba(90, 97, 113, 0.5);}.numInputWrapper:hover{background:rgba(0, 0, 0, 0.05);}.numInputWrapper:hover span{opacity:1;}.flatpickr-current-month{font-size:135%;line-height:inherit;font-weight:300;color:inherit;position:absolute;width:75%;left:12.5%;padding:7.48px 0 0 0;line-height:1;height:34px;display:inline-block;text-align:center;-webkit-transform:translate3d(0px, 0px, 0px);transform:translate3d(0px, 0px, 0px);}.flatpickr-current-month span.cur-month{font-family:inherit;font-weight:700;color:inherit;display:inline-block;margin-left:0.5ch;padding:0;}.flatpickr-current-month span.cur-month:hover{background:rgba(0, 0, 0, 0.05);}.flatpickr-current-month .numInputWrapper{width:6ch;width:7ch\\0;display:inline-block;}.flatpickr-current-month .numInputWrapper span.arrowUp:after{border-bottom-color:#5a6171;}.flatpickr-current-month .numInputWrapper span.arrowDown:after{border-top-color:#5a6171;}.flatpickr-current-month input.cur-year{background:transparent;-webkit-box-sizing:border-box;box-sizing:border-box;color:inherit;cursor:text;padding:0 0 0 0.5ch;margin:0;display:inline-block;font-size:inherit;font-family:inherit;font-weight:300;line-height:inherit;height:auto;border:0;border-radius:0;vertical-align:initial;-webkit-appearance:textfield;-moz-appearance:textfield;appearance:textfield;}.flatpickr-current-month input.cur-year:focus{outline:0;}.flatpickr-current-month input.cur-year[disabled],.flatpickr-current-month input.cur-year[disabled]:hover{font-size:100%;color:rgba(90, 97, 113, 0.5);background:transparent;pointer-events:none;}.flatpickr-current-month .flatpickr-monthDropdown-months{appearance:menulist;background:#eceef1;border:none;border-radius:0;box-sizing:border-box;color:inherit;cursor:pointer;font-size:inherit;font-family:inherit;font-weight:300;height:auto;line-height:inherit;margin:-1px 0 0 0;outline:none;padding:0 0 0 0.5ch;position:relative;vertical-align:initial;-webkit-box-sizing:border-box;-webkit-appearance:menulist;-moz-appearance:menulist;width:auto;}.flatpickr-current-month .flatpickr-monthDropdown-months:focus,.flatpickr-current-month .flatpickr-monthDropdown-months:active{outline:none;}.flatpickr-current-month .flatpickr-monthDropdown-months:hover{background:rgba(0, 0, 0, 0.05);}.flatpickr-current-month .flatpickr-monthDropdown-months .flatpickr-monthDropdown-month{background-color:#eceef1;outline:none;padding:0;}.flatpickr-weekdays{background:#eceef1;text-align:center;overflow:hidden;width:100%;display:-webkit-box;display:-webkit-flex;display:-ms-flexbox;display:flex;-webkit-box-align:center;-webkit-align-items:center;-ms-flex-align:center;align-items:center;height:28px;}.flatpickr-weekdays .flatpickr-weekdaycontainer{display:-webkit-box;display:-webkit-flex;display:-ms-flexbox;display:flex;-webkit-box-flex:1;-webkit-flex:1;-ms-flex:1;flex:1;}span.flatpickr-weekday{cursor:default;font-size:90%;background:#eceef1;color:#5a6171;line-height:1;margin:0;text-align:center;display:block;-webkit-box-flex:1;-webkit-flex:1;-ms-flex:1;flex:1;font-weight:bolder;}.dayContainer,.flatpickr-weeks{padding:1px 0 0 0;}.flatpickr-days{position:relative;overflow:hidden;display:-webkit-box;display:-webkit-flex;display:-ms-flexbox;display:flex;-webkit-box-align:start;-webkit-align-items:flex-start;-ms-flex-align:start;align-items:flex-start;width:307.875px;border-left:1px solid #eceef1;border-right:1px solid #eceef1;}.flatpickr-days:focus{outline:0;}.dayContainer{padding:0;outline:0;text-align:left;width:307.875px;min-width:307.875px;max-width:307.875px;-webkit-box-sizing:border-box;box-sizing:border-box;display:inline-block;display:-ms-flexbox;display:-webkit-box;display:-webkit-flex;display:flex;-webkit-flex-wrap:wrap;flex-wrap:wrap;-ms-flex-wrap:wrap;-ms-flex-pack:justify;-webkit-justify-content:space-around;justify-content:space-around;-webkit-transform:translate3d(0px, 0px, 0px);transform:translate3d(0px, 0px, 0px);opacity:1;}.dayContainer + .dayContainer{-webkit-box-shadow:-1px 0 0 #eceef1;box-shadow:-1px 0 0 #eceef1;}.flatpickr-day{background:none;border:1px solid transparent;border-radius:150px;-webkit-box-sizing:border-box;box-sizing:border-box;color:#484848;cursor:pointer;font-weight:400;width:14.2857143%;-webkit-flex-basis:14.2857143%;-ms-flex-preferred-size:14.2857143%;flex-basis:14.2857143%;max-width:39px;height:39px;line-height:39px;margin:0;display:inline-block;position:relative;-webkit-box-pack:center;-webkit-justify-content:center;-ms-flex-pack:center;justify-content:center;text-align:center;}.flatpickr-day.inRange,.flatpickr-day.prevMonthDay.inRange,.flatpickr-day.nextMonthDay.inRange,.flatpickr-day.today.inRange,.flatpickr-day.prevMonthDay.today.inRange,.flatpickr-day.nextMonthDay.today.inRange,.flatpickr-day:hover,.flatpickr-day.prevMonthDay:hover,.flatpickr-day.nextMonthDay:hover,.flatpickr-day:focus,.flatpickr-day.prevMonthDay:focus,.flatpickr-day.nextMonthDay:focus{cursor:pointer;outline:0;background:#e2e2e2;border-color:#e2e2e2;}.flatpickr-day.today{border-color:#bbb;}.flatpickr-day.today:hover,.flatpickr-day.today:focus{border-color:#bbb;background:#bbb;color:#fff;}.flatpickr-day.selected,.flatpickr-day.startRange,.flatpickr-day.endRange,.flatpickr-day.selected.inRange,.flatpickr-day.startRange.inRange,.flatpickr-day.endRange.inRange,.flatpickr-day.selected:focus,.flatpickr-day.startRange:focus,.flatpickr-day.endRange:focus,.flatpickr-day.selected:hover,.flatpickr-day.startRange:hover,.flatpickr-day.endRange:hover,.flatpickr-day.selected.prevMonthDay,.flatpickr-day.startRange.prevMonthDay,.flatpickr-day.endRange.prevMonthDay,.flatpickr-day.selected.nextMonthDay,.flatpickr-day.startRange.nextMonthDay,.flatpickr-day.endRange.nextMonthDay{background:#ff5a5f;-webkit-box-shadow:none;box-shadow:none;color:#fff;border-color:#ff5a5f;}.flatpickr-day.selected.startRange,.flatpickr-day.startRange.startRange,.flatpickr-day.endRange.startRange{border-radius:50px 0 0 50px;}.flatpickr-day.selected.endRange,.flatpickr-day.startRange.endRange,.flatpickr-day.endRange.endRange{border-radius:0 50px 50px 0;}.flatpickr-day.selected.startRange + .endRange:not(:nth-child(7n+1)),.flatpickr-day.startRange.startRange + .endRange:not(:nth-child(7n+1)),.flatpickr-day.endRange.startRange + .endRange:not(:nth-child(7n+1)){-webkit-box-shadow:-10px 0 0 #ff5a5f;box-shadow:-10px 0 0 #ff5a5f;}.flatpickr-day.selected.startRange.endRange,.flatpickr-day.startRange.startRange.endRange,.flatpickr-day.endRange.startRange.endRange{border-radius:50px;}.flatpickr-day.inRange{border-radius:0;-webkit-box-shadow:-5px 0 0 #e2e2e2, 5px 0 0 #e2e2e2;box-shadow:-5px 0 0 #e2e2e2, 5px 0 0 #e2e2e2;}.flatpickr-day.flatpickr-disabled,.flatpickr-day.flatpickr-disabled:hover,.flatpickr-day.prevMonthDay,.flatpickr-day.nextMonthDay,.flatpickr-day.notAllowed,.flatpickr-day.notAllowed.prevMonthDay,.flatpickr-day.notAllowed.nextMonthDay{color:rgba(72, 72, 72, 0.3);background:transparent;border-color:transparent;cursor:default;}.flatpickr-day.flatpickr-disabled,.flatpickr-day.flatpickr-disabled:hover{cursor:not-allowed;color:rgba(72, 72, 72, 0.1);}.flatpickr-day.week.selected{border-radius:0;-webkit-box-shadow:-5px 0 0 #ff5a5f, 5px 0 0 #ff5a5f;box-shadow:-5px 0 0 #ff5a5f, 5px 0 0 #ff5a5f;}.flatpickr-day.hidden{visibility:hidden;}.rangeMode .flatpickr-day{margin-top:1px;}.flatpickr-weekwrapper{float:left;}.flatpickr-weekwrapper .flatpickr-weeks{padding:0 12px;border-left:1px solid #eceef1;}.flatpickr-weekwrapper .flatpickr-weekday{float:none;width:100%;line-height:28px;}.flatpickr-weekwrapper span.flatpickr-day,.flatpickr-weekwrapper span.flatpickr-day:hover{display:block;width:100%;max-width:none;color:rgba(72, 72, 72, 0.3);background:transparent;cursor:default;border:none;}.flatpickr-innerContainer{display:block;display:-webkit-box;display:-webkit-flex;display:-ms-flexbox;display:flex;-webkit-box-sizing:border-box;box-sizing:border-box;overflow:hidden;background:#fff;border-bottom:1px solid #eceef1;}.flatpickr-rContainer{display:inline-block;padding:0;-webkit-box-sizing:border-box;box-sizing:border-box;}.flatpickr-time{text-align:center;outline:0;display:block;height:0;line-height:40px;max-height:40px;-webkit-box-sizing:border-box;box-sizing:border-box;overflow:hidden;display:-webkit-box;display:-webkit-flex;display:-ms-flexbox;display:flex;background:#fff;border-radius:0 0 5px 5px;}.flatpickr-time:after{content:\"\";display:table;clear:both;}.flatpickr-time .numInputWrapper{-webkit-box-flex:1;-webkit-flex:1;-ms-flex:1;flex:1;width:40%;height:40px;float:left;}.flatpickr-time .numInputWrapper span.arrowUp:after{border-bottom-color:#484848;}.flatpickr-time .numInputWrapper span.arrowDown:after{border-top-color:#484848;}.flatpickr-time.hasSeconds .numInputWrapper{width:26%;}.flatpickr-time.time24hr .numInputWrapper{width:49%;}.flatpickr-time input{background:transparent;-webkit-box-shadow:none;box-shadow:none;border:0;border-radius:0;text-align:center;margin:0;padding:0;height:inherit;line-height:inherit;color:#484848;font-size:14px;position:relative;-webkit-box-sizing:border-box;box-sizing:border-box;-webkit-appearance:textfield;-moz-appearance:textfield;appearance:textfield;}.flatpickr-time input.flatpickr-hour{font-weight:bold;}.flatpickr-time input.flatpickr-minute,.flatpickr-time input.flatpickr-second{font-weight:400;}.flatpickr-time input:focus{outline:0;border:0;}.flatpickr-time .flatpickr-time-separator,.flatpickr-time .flatpickr-am-pm{height:inherit;float:left;line-height:inherit;color:#484848;font-weight:bold;width:2%;-webkit-user-select:none;-moz-user-select:none;-ms-user-select:none;user-select:none;-webkit-align-self:center;-ms-flex-item-align:center;align-self:center;}.flatpickr-time .flatpickr-am-pm{outline:0;width:18%;cursor:pointer;text-align:center;font-weight:400;}.flatpickr-time input:hover,.flatpickr-time .flatpickr-am-pm:hover,.flatpickr-time input:focus,.flatpickr-time .flatpickr-am-pm:focus{background:#eaeaea;}.flatpickr-input[readonly]{cursor:pointer;}@-webkit-keyframes fpFadeInDown{from{opacity:0;-webkit-transform:translate3d(0, -20px, 0);transform:translate3d(0, -20px, 0);}to{opacity:1;-webkit-transform:translate3d(0, 0, 0);transform:translate3d(0, 0, 0);}}@keyframes fpFadeInDown{from{opacity:0;-webkit-transform:translate3d(0, -20px, 0);transform:translate3d(0, -20px, 0);}to{opacity:1;-webkit-transform:translate3d(0, 0, 0);transform:translate3d(0, 0, 0);}}span.flatpickr-day.selected{font-weight:bold;}'},\n", + " 460: function _(e,t,r,a,i){a();var n;const d=(0,e(1).__importDefault)(e(151)),s=e(461),o=e(8);class _ extends s.AbstractRangeSliderView{}r.DateRangeSliderView=_,_.__name__=\"DateRangeSliderView\";class c extends s.AbstractSlider{constructor(e){super(e),this.behaviour=\"drag\",this.connected=[!1,!0,!1]}_formatter(e,t){return(0,o.isString)(t)?(0,d.default)(e,t):t.compute(e)}}r.DateRangeSlider=c,n=c,c.__name__=\"DateRangeSlider\",n.prototype.default_view=_,n.override({format:\"%d %b %Y\"})},\n", + " 461: function _(t,e,i,s,l){s();const o=t(1);var r;const n=(0,o.__importDefault)(t(462)),a=t(43),d=t(9),_=t(22),h=t(453),c=t(131),u=(0,o.__importStar)(t(463)),m=u,p=(0,o.__importDefault)(t(464)),v=(0,o.__importStar)(t(449));class b extends h.OrientedControlView{*controls(){yield this.slider_el}connect_signals(){super.connect_signals();const{direction:t,orientation:e,tooltips:i}=this.model.properties;this.on_change([t,e,i],(()=>this.render()));const{start:s,end:l,value:o,step:r,title:n}=this.model.properties;this.on_change([s,l,o,r],(()=>{const{start:t,end:e,value:i,step:s}=this._calc_to();this._noUiSlider.updateOptions({range:{min:t,max:e},start:i,step:s},!0)}));const{bar_color:a}=this.model.properties;this.on_change(a,(()=>{this._set_bar_color()}));const{show_value:d}=this.model.properties;this.on_change([o,n,d],(()=>this._update_title()))}styles(){return[...super.styles(),p.default,u.default]}_update_title(){var t;(0,a.empty)(this.title_el);const e=null==this.model.title||0==this.model.title.length&&!this.model.show_value;if(this.title_el.style.display=e?\"none\":\"\",!e&&(0!=(null===(t=this.model.title)||void 0===t?void 0:t.length)&&(this.title_el.textContent=`${this.model.title}: `),this.model.show_value)){const{value:t}=this._calc_to(),e=t.map((t=>this.model.pretty(t))).join(\" .. \");this.title_el.appendChild((0,a.span)({class:m.slider_value},e))}}_set_bar_color(){if(!this.model.disabled){this.slider_el.querySelector(\".noUi-connect\").style.backgroundColor=(0,_.color2css)(this.model.bar_color)}}render(){super.render();const{start:t,end:e,value:i,step:s}=this._calc_to();let l;if(this.model.tooltips){const t={to:t=>this.model.pretty(t)};l=(0,d.repeat)(t,i.length)}else l=!1;if(null==this.slider_el){this.slider_el=(0,a.div)(),this._noUiSlider=n.default.create(this.slider_el,{range:{min:t,max:e},start:i,step:s,behaviour:this.model.behaviour,connect:this.model.connected,tooltips:l,orientation:this.model.orientation,direction:this.model.direction}),this._noUiSlider.on(\"slide\",((t,e,i)=>this._slide(i))),this._noUiSlider.on(\"change\",((t,e,i)=>this._change(i)));const o=(t,e)=>{if(!l)return;this.slider_el.querySelectorAll(\".noUi-handle\")[t].querySelector(\".noUi-tooltip\").style.display=e?\"block\":\"\"};this._noUiSlider.on(\"start\",((t,e)=>o(e,!0))),this._noUiSlider.on(\"end\",((t,e)=>o(e,!1)))}else this._noUiSlider.updateOptions({range:{min:t,max:e},start:i,step:s},!0);this._set_bar_color(),this.model.disabled?this.slider_el.setAttribute(\"disabled\",\"true\"):this.slider_el.removeAttribute(\"disabled\"),this.title_el=(0,a.div)({class:m.slider_title}),this._update_title(),this.group_el=(0,a.div)({class:v.input_group},this.title_el,this.slider_el),this.el.appendChild(this.group_el)}_slide(t){this.model.value=this._calc_from(t)}_change(t){const e=this._calc_from(t);this.model.setv({value:e,value_throttled:e})}}b.__name__=\"AbstractBaseSliderView\";class g extends b{_calc_to(){return{start:this.model.start,end:this.model.end,value:[this.model.value],step:this.model.step}}_calc_from([t]){return Number.isInteger(this.model.start)&&Number.isInteger(this.model.end)&&Number.isInteger(this.model.step)?Math.round(t):t}}i.AbstractSliderView=g,g.__name__=\"AbstractSliderView\";class f extends b{_calc_to(){return{start:this.model.start,end:this.model.end,value:this.model.value,step:this.model.step}}_calc_from(t){return t}}i.AbstractRangeSliderView=f,f.__name__=\"AbstractRangeSliderView\";class S extends h.OrientedControl{constructor(t){super(t),this.connected=!1}pretty(t){return this._formatter(t,this.format)}}i.AbstractSlider=S,r=S,S.__name__=\"AbstractSlider\",r.define((({Any:t,Boolean:e,Number:i,String:s,Color:l,Or:o,Enum:r,Ref:n,Nullable:a})=>({title:[a(s),\"\"],show_value:[e,!0],start:[t],end:[t],value:[t],value_throttled:[t],step:[i,1],format:[o(s,n(c.TickFormatter))],direction:[r(\"ltr\",\"rtl\"),\"ltr\"],tooltips:[e,!0],bar_color:[l,\"#e6e6e6\"]})))},\n", + " 462: function _(t,e,r,n,i){var o,s;o=this,s=function(t){\"use strict\";var e,r;function n(t){return\"object\"==typeof t&&\"function\"==typeof t.to}function i(t){t.parentElement.removeChild(t)}function o(t){return null!=t}function s(t){t.preventDefault()}function a(t){return\"number\"==typeof t&&!isNaN(t)&&isFinite(t)}function l(t,e,r){r>0&&(f(t,e),setTimeout((function(){d(t,e)}),r))}function u(t){return Math.max(Math.min(t,100),0)}function c(t){return Array.isArray(t)?t:[t]}function p(t){var e=(t=String(t)).split(\".\");return e.length>1?e[1].length:0}function f(t,e){t.classList&&!/\\s/.test(e)?t.classList.add(e):t.className+=\" \"+e}function d(t,e){t.classList&&!/\\s/.test(e)?t.classList.remove(e):t.className=t.className.replace(new RegExp(\"(^|\\\\b)\"+e.split(\" \").join(\"|\")+\"(\\\\b|$)\",\"gi\"),\" \")}function h(t){var e=void 0!==window.pageXOffset,r=\"CSS1Compat\"===(t.compatMode||\"\");return{x:e?window.pageXOffset:r?t.documentElement.scrollLeft:t.body.scrollLeft,y:e?window.pageYOffset:r?t.documentElement.scrollTop:t.body.scrollTop}}function m(t,e){return 100/(e-t)}function g(t,e,r){return 100*e/(t[r+1]-t[r])}function v(t,e){for(var r=1;t>=e[r];)r+=1;return r}function b(t,e,r){if(r>=t.slice(-1)[0])return 100;var n=v(r,t),i=t[n-1],o=t[n],s=e[n-1],a=e[n];return s+function(t,e){return g(t,t[0]<0?e+Math.abs(t[0]):e-t[0],0)}([i,o],r)/m(s,a)}function S(t,e,r,n){if(100===n)return n;var i=v(n,t),o=t[i-1],s=t[i];return r?n-o>(s-o)/2?s:o:e[i-1]?t[i-1]+function(t,e){return Math.round(t/e)*e}(n-t[i-1],e[i-1]):n}t.PipsMode=void 0,(e=t.PipsMode||(t.PipsMode={})).Range=\"range\",e.Steps=\"steps\",e.Positions=\"positions\",e.Count=\"count\",e.Values=\"values\",t.PipsType=void 0,(r=t.PipsType||(t.PipsType={}))[r.None=-1]=\"None\",r[r.NoValue=0]=\"NoValue\",r[r.LargeValue=1]=\"LargeValue\",r[r.SmallValue=2]=\"SmallValue\";var x=function(){function t(t,e,r){var n;this.xPct=[],this.xVal=[],this.xSteps=[],this.xNumSteps=[],this.xHighestCompleteStep=[],this.xSteps=[r||!1],this.xNumSteps=[!1],this.snap=e;var i=[];for(Object.keys(t).forEach((function(e){i.push([c(t[e]),e])})),i.sort((function(t,e){return t[0][0]-e[0][0]})),n=0;nthis.xPct[i+1];)i++;else t===this.xPct[this.xPct.length-1]&&(i=this.xPct.length-2);r||t!==this.xPct[i+1]||i++,null===e&&(e=[]);var o=1,s=e[i],a=0,l=0,u=0,c=0;for(n=r?(t-this.xPct[i])/(this.xPct[i+1]-this.xPct[i]):(this.xPct[i+1]-t)/(this.xPct[i+1]-this.xPct[i]);s>0;)a=this.xPct[i+1+c]-this.xPct[i+c],e[i+c]*o+100-100*n>100?(l=a*n,o=(s-100*n)/e[i+c],n=1):(l=e[i+c]*a/100*o,o=0),r?(u-=l,this.xPct.length+c>=1&&c--):(u+=l,this.xPct.length-c>=1&&c++),s=e[i+c]*o;return t+u},t.prototype.toStepping=function(t){return t=b(this.xVal,this.xPct,t)},t.prototype.fromStepping=function(t){return function(t,e,r){if(r>=100)return t.slice(-1)[0];var n=v(r,e),i=t[n-1],o=t[n],s=e[n-1];return function(t,e){return e*(t[1]-t[0])/100+t[0]}([i,o],(r-s)*m(s,e[n]))}(this.xVal,this.xPct,t)},t.prototype.getStep=function(t){return t=S(this.xPct,this.xSteps,this.snap,t)},t.prototype.getDefaultStep=function(t,e,r){var n=v(t,this.xPct);return(100===t||e&&t===this.xPct[n-1])&&(n=Math.max(n-1,1)),(this.xVal[n]-this.xVal[n-1])/r},t.prototype.getNearbySteps=function(t){var e=v(t,this.xPct);return{stepBefore:{startValue:this.xVal[e-2],step:this.xNumSteps[e-2],highestStep:this.xHighestCompleteStep[e-2]},thisStep:{startValue:this.xVal[e-1],step:this.xNumSteps[e-1],highestStep:this.xHighestCompleteStep[e-1]},stepAfter:{startValue:this.xVal[e],step:this.xNumSteps[e],highestStep:this.xHighestCompleteStep[e]}}},t.prototype.countStepDecimals=function(){var t=this.xNumSteps.map(p);return Math.max.apply(null,t)},t.prototype.hasNoSize=function(){return this.xVal[0]===this.xVal[this.xVal.length-1]},t.prototype.convert=function(t){return this.getStep(this.toStepping(t))},t.prototype.handleEntryPoint=function(t,e){var r;if(!a(r=\"min\"===t?0:\"max\"===t?100:parseFloat(t))||!a(e[0]))throw new Error(\"noUiSlider: 'range' value isn't numeric.\");this.xPct.push(r),this.xVal.push(e[0]);var n=Number(e[1]);r?this.xSteps.push(!isNaN(n)&&n):isNaN(n)||(this.xSteps[0]=n),this.xHighestCompleteStep.push(0)},t.prototype.handleStepPoint=function(t,e){if(e)if(this.xVal[t]!==this.xVal[t+1]){this.xSteps[t]=g([this.xVal[t],this.xVal[t+1]],e,0)/m(this.xPct[t],this.xPct[t+1]);var r=(this.xVal[t+1]-this.xVal[t])/this.xNumSteps[t],n=Math.ceil(Number(r.toFixed(3))-1),i=this.xVal[t]+this.xNumSteps[t]*n;this.xHighestCompleteStep[t]=i}else this.xSteps[t]=this.xHighestCompleteStep[t]=this.xVal[t]},t}(),y={to:function(t){return void 0===t?\"\":t.toFixed(2)},from:Number},w={target:\"target\",base:\"base\",origin:\"origin\",handle:\"handle\",handleLower:\"handle-lower\",handleUpper:\"handle-upper\",touchArea:\"touch-area\",horizontal:\"horizontal\",vertical:\"vertical\",background:\"background\",connect:\"connect\",connects:\"connects\",ltr:\"ltr\",rtl:\"rtl\",textDirectionLtr:\"txt-dir-ltr\",textDirectionRtl:\"txt-dir-rtl\",draggable:\"draggable\",drag:\"state-drag\",tap:\"state-tap\",active:\"active\",tooltip:\"tooltip\",pips:\"pips\",pipsHorizontal:\"pips-horizontal\",pipsVertical:\"pips-vertical\",marker:\"marker\",markerHorizontal:\"marker-horizontal\",markerVertical:\"marker-vertical\",markerNormal:\"marker-normal\",markerLarge:\"marker-large\",markerSub:\"marker-sub\",value:\"value\",valueHorizontal:\"value-horizontal\",valueVertical:\"value-vertical\",valueNormal:\"value-normal\",valueLarge:\"value-large\",valueSub:\"value-sub\"},E=\".__tooltips\",P=\".__aria\";function C(t,e){if(!a(e))throw new Error(\"noUiSlider: 'step' is not numeric.\");t.singleStep=e}function N(t,e){if(!a(e))throw new Error(\"noUiSlider: 'keyboardPageMultiplier' is not numeric.\");t.keyboardPageMultiplier=e}function V(t,e){if(!a(e))throw new Error(\"noUiSlider: 'keyboardMultiplier' is not numeric.\");t.keyboardMultiplier=e}function k(t,e){if(!a(e))throw new Error(\"noUiSlider: 'keyboardDefaultStep' is not numeric.\");t.keyboardDefaultStep=e}function M(t,e){if(\"object\"!=typeof e||Array.isArray(e))throw new Error(\"noUiSlider: 'range' is not an object.\");if(void 0===e.min||void 0===e.max)throw new Error(\"noUiSlider: Missing 'min' or 'max' in 'range'.\");t.spectrum=new x(e,t.snap||!1,t.singleStep)}function A(t,e){if(e=c(e),!Array.isArray(e)||!e.length)throw new Error(\"noUiSlider: 'start' option is incorrect.\");t.handles=e.length,t.start=e}function U(t,e){if(\"boolean\"!=typeof e)throw new Error(\"noUiSlider: 'snap' option must be a boolean.\");t.snap=e}function D(t,e){if(\"boolean\"!=typeof e)throw new Error(\"noUiSlider: 'animate' option must be a boolean.\");t.animate=e}function O(t,e){if(\"number\"!=typeof e)throw new Error(\"noUiSlider: 'animationDuration' option must be a number.\");t.animationDuration=e}function L(t,e){var r,n=[!1];if(\"lower\"===e?e=[!0,!1]:\"upper\"===e&&(e=[!1,!0]),!0===e||!1===e){for(r=1;r1)throw new Error(\"noUiSlider: 'padding' option must not exceed 100% of the range.\")}}function F(t,e){switch(e){case\"ltr\":t.dir=0;break;case\"rtl\":t.dir=1;break;default:throw new Error(\"noUiSlider: 'direction' option was not recognized.\")}}function R(t,e){if(\"string\"!=typeof e)throw new Error(\"noUiSlider: 'behaviour' must be a string containing options.\");var r=e.indexOf(\"tap\")>=0,n=e.indexOf(\"drag\")>=0,i=e.indexOf(\"fixed\")>=0,o=e.indexOf(\"snap\")>=0,s=e.indexOf(\"hover\")>=0,a=e.indexOf(\"unconstrained\")>=0,l=e.indexOf(\"drag-all\")>=0;if(i){if(2!==t.handles)throw new Error(\"noUiSlider: 'fixed' behaviour must be used with 2 handles\");j(t,t.start[1]-t.start[0])}if(a&&(t.margin||t.limit))throw new Error(\"noUiSlider: 'unconstrained' behaviour cannot be used with margin or limit\");t.events={tap:r||o,drag:n,dragAll:l,fixed:i,snap:o,hover:s,unconstrained:a}}function _(t,e){if(!1!==e)if(!0===e||n(e)){t.tooltips=[];for(var r=0;r= 2) required for mode 'count'.\");for(var r=e.values-1,n=100/r,i=[];r--;)i[r]=r*n;return i.push(100),q(i,e.stepped)}return e.mode===t.PipsMode.Positions?q(e.values,e.stepped):e.mode===t.PipsMode.Values?e.stepped?e.values.map((function(t){return C.fromStepping(C.getStep(C.toStepping(t)))})):e.values:[]}(e),i={},o=C.xVal[0],s=C.xVal[C.xVal.length-1],a=!1,l=!1,u=0;return r=n.slice().sort((function(t,e){return t-e})),(n=r.filter((function(t){return!this[t]&&(this[t]=!0)}),{}))[0]!==o&&(n.unshift(o),a=!0),n[n.length-1]!==s&&(n.push(s),l=!0),n.forEach((function(r,o){var s,c,p,f,d,h,m,g,v,b,S=r,x=n[o+1],y=e.mode===t.PipsMode.Steps;for(y&&(s=C.xNumSteps[o]),s||(s=x-S),void 0===x&&(x=S),s=Math.max(s,1e-7),c=S;c<=x;c=Number((c+s).toFixed(7))){for(g=(d=(f=C.toStepping(c))-u)/(e.density||1),b=d/(v=Math.round(g)),p=1;p<=v;p+=1)i[(h=u+p*b).toFixed(5)]=[C.fromStepping(h),0];m=n.indexOf(c)>-1?t.PipsType.LargeValue:y?t.PipsType.SmallValue:t.PipsType.NoValue,!o&&a&&c!==x&&(m=0),c===x&&l||(i[f.toFixed(5)]=[c,m]),u=f}})),i}function Y(e,n,i){var o,s,a=U.createElement(\"div\"),l=((o={})[t.PipsType.None]=\"\",o[t.PipsType.NoValue]=r.cssClasses.valueNormal,o[t.PipsType.LargeValue]=r.cssClasses.valueLarge,o[t.PipsType.SmallValue]=r.cssClasses.valueSub,o),u=((s={})[t.PipsType.None]=\"\",s[t.PipsType.NoValue]=r.cssClasses.markerNormal,s[t.PipsType.LargeValue]=r.cssClasses.markerLarge,s[t.PipsType.SmallValue]=r.cssClasses.markerSub,s),c=[r.cssClasses.valueHorizontal,r.cssClasses.valueVertical],p=[r.cssClasses.markerHorizontal,r.cssClasses.markerVertical];function d(t,e){var n=e===r.cssClasses.value,i=n?l:u;return e+\" \"+(n?c:p)[r.ort]+\" \"+i[t]}return f(a,r.cssClasses.pips),f(a,0===r.ort?r.cssClasses.pipsHorizontal:r.cssClasses.pipsVertical),Object.keys(e).forEach((function(o){!function(e,o,s){if((s=n?n(o,s):s)!==t.PipsType.None){var l=T(a,!1);l.className=d(s,r.cssClasses.marker),l.style[r.style]=e+\"%\",s>t.PipsType.NoValue&&((l=T(a,!1)).className=d(s,r.cssClasses.value),l.setAttribute(\"data-value\",String(o)),l.style[r.style]=e+\"%\",l.innerHTML=String(i.to(o)))}}(o,e[o][0],e[o][1])})),a}function I(){g&&(i(g),g=null)}function W(t){I();var e=X(t),r=t.filter,n=t.format||{to:function(t){return String(Math.round(t))}};return g=w.appendChild(Y(e,r,n))}function $(){var t=a.getBoundingClientRect(),e=\"offset\"+[\"Width\",\"Height\"][r.ort];return 0===r.ort?t.width||a[e]:t.height||a[e]}function J(t,e,n,i){var o=function(o){var s,a,l=function(t,e,r){var n=0===t.type.indexOf(\"touch\"),i=0===t.type.indexOf(\"mouse\"),o=0===t.type.indexOf(\"pointer\"),s=0,a=0;if(0===t.type.indexOf(\"MSPointer\")&&(o=!0),\"mousedown\"===t.type&&!t.buttons&&!t.touches)return!1;if(n){var l=function(e){var n=e.target;return n===r||r.contains(n)||t.composed&&t.composedPath().shift()===r};if(\"touchstart\"===t.type){var u=Array.prototype.filter.call(t.touches,l);if(u.length>1)return!1;s=u[0].pageX,a=u[0].pageY}else{var c=Array.prototype.find.call(t.changedTouches,l);if(!c)return!1;s=c.pageX,a=c.pageY}}return e=e||h(U),(i||o)&&(s=t.clientX+e.x,a=t.clientY+e.y),t.pageOffset=e,t.points=[s,a],t.cursor=i||o,t}(o,i.pageOffset,i.target||e);return!!l&&!(F()&&!i.doNotReject)&&(s=w,a=r.cssClasses.tap,!((s.classList?s.classList.contains(a):new RegExp(\"\\\\b\"+a+\"\\\\b\").test(s.className))&&!i.doNotReject)&&!(t===x.start&&void 0!==l.buttons&&l.buttons>1)&&(!i.hover||!l.buttons)&&(y||l.preventDefault(),l.calcPoint=l.points[r.ort],void n(l,i)))},s=[];return t.split(\" \").forEach((function(t){e.addEventListener(t,o,!!y&&{passive:!0}),s.push([t,o])})),s}function K(t){var e,n,i,o,s,l,c=100*(t-(e=a,n=r.ort,i=e.getBoundingClientRect(),o=e.ownerDocument,s=o.documentElement,l=h(o),/webkit.*Chrome.*Mobile/i.test(navigator.userAgent)&&(l.x=0),n?i.top+l.y-s.clientTop:i.left+l.x-s.clientLeft))/$();return c=u(c),r.dir?100-c:c}function Q(t,e){\"mouseout\"===t.type&&\"HTML\"===t.target.nodeName&&null===t.relatedTarget&&tt(t,e)}function Z(t,e){if(-1===navigator.appVersion.indexOf(\"MSIE 9\")&&0===t.buttons&&0!==e.buttonsProperty)return tt(t,e);var n=(r.dir?-1:1)*(t.calcPoint-e.startCalcPoint);ut(n>0,100*n/e.baseSize,e.locations,e.handleNumbers,e.connect)}function tt(t,e){e.handle&&(d(e.handle,r.cssClasses.active),M-=1),e.listeners.forEach((function(t){D.removeEventListener(t[0],t[1])})),0===M&&(d(w,r.cssClasses.drag),pt(),t.cursor&&(O.style.cursor=\"\",O.removeEventListener(\"selectstart\",s))),e.handleNumbers.forEach((function(t){st(\"change\",t),st(\"set\",t),st(\"end\",t)}))}function et(t,e){if(!e.handleNumbers.some(R)){var n;1===e.handleNumbers.length&&(n=p[e.handleNumbers[0]].children[0],M+=1,f(n,r.cssClasses.active)),t.stopPropagation();var i=[],o=J(x.move,D,Z,{target:t.target,handle:n,connect:e.connect,listeners:i,startCalcPoint:t.calcPoint,baseSize:$(),pageOffset:t.pageOffset,handleNumbers:e.handleNumbers,buttonsProperty:t.buttons,locations:V.slice()}),a=J(x.end,D,tt,{target:t.target,handle:n,listeners:i,doNotReject:!0,handleNumbers:e.handleNumbers}),l=J(\"mouseout\",D,Q,{target:t.target,handle:n,listeners:i,doNotReject:!0,handleNumbers:e.handleNumbers});i.push.apply(i,o.concat(a,l)),t.cursor&&(O.style.cursor=getComputedStyle(t.target).cursor,p.length>1&&f(w,r.cssClasses.drag),O.addEventListener(\"selectstart\",s,!1)),e.handleNumbers.forEach((function(t){st(\"start\",t)}))}}function rt(t){t.stopPropagation();var e=K(t.calcPoint),n=function(t){var e=100,r=!1;return p.forEach((function(n,i){if(!R(i)){var o=V[i],s=Math.abs(o-t);(so||100===s&&100===e)&&(r=i,e=s)}})),r}(e);!1!==n&&(r.events.snap||l(w,r.cssClasses.tap,r.animationDuration),ft(n,e,!0,!0),pt(),st(\"slide\",n,!0),st(\"update\",n,!0),r.events.snap?et(t,{handleNumbers:[n]}):(st(\"change\",n,!0),st(\"set\",n,!0)))}function nt(t){var e=K(t.calcPoint),r=C.getStep(e),n=C.fromStepping(r);Object.keys(A).forEach((function(t){\"hover\"===t.split(\".\")[0]&&A[t].forEach((function(t){t.call(bt,n)}))}))}function it(t,e){A[t]=A[t]||[],A[t].push(e),\"update\"===t.split(\".\")[0]&&p.forEach((function(t,e){st(\"update\",e)}))}function ot(t){var e=t&&t.split(\".\")[0],r=e?t.substring(e.length):t;Object.keys(A).forEach((function(t){var n=t.split(\".\")[0],i=t.substring(n.length);e&&e!==n||r&&r!==i||function(t){return t===P||t===E}(i)&&r!==i||delete A[t]}))}function st(t,e,n){Object.keys(A).forEach((function(i){var o=i.split(\".\")[0];t===o&&A[i].forEach((function(t){t.call(bt,N.map(r.format.to),e,N.slice(),n||!1,V.slice(),bt)}))}))}function at(t,e,n,i,o,s){var a;return p.length>1&&!r.events.unconstrained&&(i&&e>0&&(a=C.getAbsoluteDistance(t[e-1],r.margin,!1),n=Math.max(n,a)),o&&e1&&r.limit&&(i&&e>0&&(a=C.getAbsoluteDistance(t[e-1],r.limit,!1),n=Math.min(n,a)),o&&e1?n.forEach((function(t,r){var n=at(o,t,o[t]+e,a[r],l[r],!1);!1===n?e=0:(e=n-o[t],o[t]=n)})):a=l=[!0];var u=!1;n.forEach((function(t,n){u=ft(t,r[t]+e,a[n],l[n])||u})),u&&(n.forEach((function(t){st(\"update\",t),st(\"slide\",t)})),null!=i&&st(\"drag\",s))}function ct(t,e){return r.dir?100-t-e:t}function pt(){k.forEach((function(t){var e=V[t]>50?-1:1,r=3+(p.length+e*t);p[t].style.zIndex=String(r)}))}function ft(t,e,n,i,o){return o||(e=at(V,t,e,n,i,!1)),!1!==e&&(function(t,e){V[t]=e,N[t]=C.fromStepping(e);var n=\"translate(\"+lt(10*(ct(e,0)-L)+\"%\",\"0\")+\")\";p[t].style[r.transformRule]=n,dt(t),dt(t+1)}(t,e),!0)}function dt(t){if(m[t]){var e=0,n=100;0!==t&&(e=V[t-1]),t!==m.length-1&&(n=V[t]);var i=n-e,o=\"translate(\"+lt(ct(e,i)+\"%\",\"0\")+\")\",s=\"scale(\"+lt(i/100,\"1\")+\")\";m[t].style[r.transformRule]=o+\" \"+s}}function ht(t,e){return null===t||!1===t||void 0===t?V[e]:(\"number\"==typeof t&&(t=String(t)),!1!==(t=r.format.from(t))&&(t=C.toStepping(t)),!1===t||isNaN(t)?V[e]:t)}function mt(t,e,n){var i=c(t),o=void 0===V[0];e=void 0===e||e,r.animate&&!o&&l(w,r.cssClasses.tap,r.animationDuration),k.forEach((function(t){ft(t,ht(i[t],t),!0,!1,n)}));var s=1===k.length?0:1;if(o&&C.hasNoSize()&&(n=!0,V[0]=0,k.length>1)){var a=100/(k.length-1);k.forEach((function(t){V[t]=t*a}))}for(;sn.stepAfter.startValue&&(o=n.stepAfter.startValue-i),s=i>n.thisStep.startValue?n.thisStep.step:!1!==n.stepBefore.step&&i-n.stepBefore.highestStep,100===e?o=null:0===e&&(s=null);var a=C.countStepDecimals();return null!==o&&!1!==o&&(o=Number(o.toFixed(a))),null!==s&&!1!==s&&(s=Number(s.toFixed(a))),[s,o]}f(b=w,r.cssClasses.target),0===r.dir?f(b,r.cssClasses.ltr):f(b,r.cssClasses.rtl),0===r.ort?f(b,r.cssClasses.horizontal):f(b,r.cssClasses.vertical),f(b,\"rtl\"===getComputedStyle(b).direction?r.cssClasses.textDirectionRtl:r.cssClasses.textDirectionLtr),a=T(b,r.cssClasses.base),function(t,e){var n=T(e,r.cssClasses.connects);p=[],(m=[]).push(z(n,t[0]));for(var i=0;i=0&&t .noUi-tooltip{-webkit-transform:translate(50%, 0);transform:translate(50%, 0);left:auto;bottom:10px;}.bk-root .noUi-vertical .noUi-origin > .noUi-tooltip{-webkit-transform:translate(0, -18px);transform:translate(0, -18px);top:auto;right:28px;}.bk-root .noUi-handle{cursor:grab;cursor:-webkit-grab;}.bk-root .noUi-handle.noUi-active{cursor:grabbing;cursor:-webkit-grabbing;}.bk-root .noUi-handle:after,.bk-root .noUi-handle:before{display:none;}.bk-root .noUi-tooltip{display:none;white-space:nowrap;}.bk-root .noUi-handle:hover .noUi-tooltip{display:block;}.bk-root .noUi-horizontal{width:100%;height:10px;}.bk-root .noUi-vertical{width:10px;height:100%;}.bk-root .noUi-horizontal .noUi-handle{width:14px;height:18px;right:-7px;top:-5px;}.bk-root .noUi-vertical .noUi-handle{width:18px;height:14px;right:-5px;top:-7px;}.bk-root .noUi-target.noUi-horizontal{margin:5px 0px;}.bk-root .noUi-target.noUi-vertical{margin:0px 5px;}'},\n", + " 465: function _(e,t,r,a,i){a();var s;const d=(0,e(1).__importDefault)(e(151)),o=e(461),_=e(8);class n extends o.AbstractSliderView{}r.DateSliderView=n,n.__name__=\"DateSliderView\";class c extends o.AbstractSlider{constructor(e){super(e),this.behaviour=\"tap\",this.connected=[!0,!1]}_formatter(e,t){return(0,_.isString)(t)?(0,d.default)(e,t):t.compute(e)}}r.DateSlider=c,s=c,c.__name__=\"DateSlider\",s.prototype.default_view=n,s.override({format:\"%d %b %Y\"})},\n", + " 466: function _(e,t,r,a,i){a();var n;const s=(0,e(1).__importDefault)(e(151)),d=e(461),o=e(8);class _ extends d.AbstractRangeSliderView{}r.DatetimeRangeSliderView=_,_.__name__=\"DatetimeRangeSliderView\";class c extends d.AbstractSlider{constructor(e){super(e),this.behaviour=\"drag\",this.connected=[!1,!0,!1]}_formatter(e,t){return(0,o.isString)(t)?(0,s.default)(e,t):t.compute(e)}}r.DatetimeRangeSlider=c,n=c,c.__name__=\"DatetimeRangeSlider\",n.prototype.default_view=_,n.override({format:\"%d %b %Y %H:%M:%S\",step:36e5})},\n", + " 467: function _(e,t,s,r,i){var _;r();const n=e(468);class a extends n.MarkupView{render(){super.render(),this.model.render_as_text?this.markup_el.textContent=this.model.text:this.markup_el.innerHTML=this.has_math_disabled()?this.model.text:this.process_tex()}}s.DivView=a,a.__name__=\"DivView\";class d extends n.Markup{constructor(e){super(e)}}s.Div=d,_=d,d.__name__=\"Div\",_.prototype.default_view=a,_.define((({Boolean:e})=>({render_as_text:[e,!1]})))},\n", + " 468: function _(t,e,s,i,r){i();const a=t(1);var n;const o=t(210),d=t(43),h=t(137),l=t(512),_=(0,a.__importStar)(t(469));class u extends l.WidgetView{get provider(){return h.default_provider}async lazy_initialize(){await super.lazy_initialize(),\"not_started\"==this.provider.status&&await this.provider.fetch(),\"not_started\"!=this.provider.status&&\"loading\"!=this.provider.status||this.provider.ready.connect((()=>{this.contains_tex_string()&&this.rerender()}))}after_layout(){super.after_layout(),\"loading\"===this.provider.status&&(this._has_finished=!1)}rerender(){this.layout.invalidate_cache(),this.render(),this.root.compute_layout()}connect_signals(){super.connect_signals(),this.connect(this.model.change,(()=>{this.rerender()}))}styles(){return[...super.styles(),_.default]}_update_layout(){this.layout=new o.CachedVariadicBox(this.el),this.layout.set_sizing(this.box_sizing())}render(){super.render();const t=Object.assign(Object.assign({},this.model.style),{display:\"inline-block\"});this.markup_el=(0,d.div)({class:_.clearfix,style:t}),this.el.appendChild(this.markup_el),\"failed\"!=this.provider.status&&\"loaded\"!=this.provider.status||(this._has_finished=!0)}has_math_disabled(){return this.model.disable_math||!this.contains_tex_string()}process_tex(){if(!this.provider.MathJax)return this.model.text;const{text:t}=this.model,e=this.provider.MathJax.find_tex(t),s=[];let i=0;for(const r of e)s.push(t.slice(i,r.start.n)),s.push(this.provider.MathJax.tex2svg(r.math,{display:r.display}).outerHTML),i=r.end.n;return i0}}s.MarkupView=u,u.__name__=\"MarkupView\";class p extends l.Widget{constructor(t){super(t)}}s.Markup=p,n=p,p.__name__=\"Markup\",n.define((({Boolean:t,String:e,Dict:s})=>({text:[e,\"\"],style:[s(e),{}],disable_math:[t,!1]})))},\n", + " 469: function _(o,r,e,t,a){t(),e.root=\"bk-root\",e.clearfix=\"bk-clearfix\",e.default='.bk-root .bk-clearfix:before,.bk-root .bk-clearfix:after{content:\"\";display:table;}.bk-root .bk-clearfix:after{clear:both;}'},\n", + " 470: function _(e,t,i,n,s){n();const o=e(1);var l;const r=e(441),d=e(251),_=e(43),u=e(8),c=(0,o.__importStar)(e(318)),h=(0,o.__importStar)(e(229)),m=h;class p extends r.AbstractButtonView{constructor(){super(...arguments),this._open=!1}styles(){return[...super.styles(),h.default]}render(){super.render();const e=(0,_.div)({class:[m.caret,m.down]});if(this.model.is_split){const t=this._render_button(e);t.classList.add(c.dropdown_toggle),t.addEventListener(\"click\",(()=>this._toggle_menu())),this.group_el.appendChild(t)}else this.button_el.appendChild(e);const t=this.model.menu.map(((e,t)=>{if(null==e)return(0,_.div)({class:m.divider});{const i=(0,u.isString)(e)?e:e[0],n=(0,_.div)(i);return n.addEventListener(\"click\",(()=>this._item_click(t))),n}}));this.menu=(0,_.div)({class:[m.menu,m.below]},t),this.el.appendChild(this.menu),(0,_.undisplay)(this.menu)}_show_menu(){if(!this._open){this._open=!0,(0,_.display)(this.menu);const e=t=>{const{target:i}=t;i instanceof HTMLElement&&!this.el.contains(i)&&(document.removeEventListener(\"click\",e),this._hide_menu())};document.addEventListener(\"click\",e)}}_hide_menu(){this._open&&(this._open=!1,(0,_.undisplay)(this.menu))}_toggle_menu(){this._open?this._hide_menu():this._show_menu()}click(){this.model.is_split?(this._hide_menu(),this.model.trigger_event(new d.ButtonClick),super.click()):this._toggle_menu()}_item_click(e){this._hide_menu();const t=this.model.menu[e];if(null!=t){const i=(0,u.isString)(t)?t:t[1];(0,u.isString)(i)?this.model.trigger_event(new d.MenuItemClick(i)):i.execute(this.model,{index:e})}}}i.DropdownView=p,p.__name__=\"DropdownView\";class a extends r.AbstractButton{constructor(e){super(e)}get is_split(){return this.split}}i.Dropdown=a,l=a,a.__name__=\"Dropdown\",l.prototype.default_view=p,l.define((({Null:e,Boolean:t,String:i,Array:n,Tuple:s,Or:o})=>({split:[t,!1],menu:[n(o(i,s(i,o(i)),e)),[]]}))),l.override({label:\"Dropdown\"})},\n", + " 471: function _(e,l,i,t,s){var n;t();const a=e(43),o=e(512);class d extends o.WidgetView{connect_signals(){super.connect_signals(),this.connect(this.model.change,(()=>this.render()))}render(){const{multiple:e,accept:l,disabled:i,width:t}=this.model;null==this.dialog_el&&(this.dialog_el=(0,a.input)({type:\"file\",multiple:e}),this.dialog_el.onchange=()=>{const{files:e}=this.dialog_el;null!=e&&this.load_files(e)},this.el.appendChild(this.dialog_el)),null!=l&&\"\"!=l&&(this.dialog_el.accept=l),this.dialog_el.style.width=`${t}px`,this.dialog_el.disabled=i}async load_files(e){const l=[],i=[],t=[];for(const s of e){const e=await this._read_file(s),[,n=\"\",,a=\"\"]=e.split(/[:;,]/,4);l.push(a),i.push(s.name),t.push(n)}this.model.multiple?this.model.setv({value:l,filename:i,mime_type:t}):this.model.setv({value:l[0],filename:i[0],mime_type:t[0]})}_read_file(e){return new Promise(((l,i)=>{const t=new FileReader;t.onload=()=>{var s;const{result:n}=t;null!=n?l(n):i(null!==(s=t.error)&&void 0!==s?s:new Error(`unable to read '${e.name}'`))},t.readAsDataURL(e)}))}}i.FileInputView=d,d.__name__=\"FileInputView\";class r extends o.Widget{constructor(e){super(e)}}i.FileInput=r,n=r,r.__name__=\"FileInput\",n.prototype.default_view=d,n.define((({Boolean:e,String:l,Array:i,Or:t})=>({value:[t(l,i(l)),\"\"],mime_type:[t(l,i(l)),\"\"],filename:[t(l,i(l)),\"\"],accept:[l,\"\"],multiple:[e,!1]})))},\n", + " 472: function _(e,t,i,s,n){s();const l=e(1);var o;const r=e(43),c=e(8),h=e(448),p=(0,l.__importStar)(e(449));class d extends h.InputWidgetView{connect_signals(){super.connect_signals(),this.connect(this.model.properties.value.change,(()=>this.render_selection())),this.connect(this.model.properties.options.change,(()=>this.render())),this.connect(this.model.properties.name.change,(()=>this.render())),this.connect(this.model.properties.title.change,(()=>this.render())),this.connect(this.model.properties.size.change,(()=>this.render())),this.connect(this.model.properties.disabled.change,(()=>this.render()))}render(){super.render();const e=this.model.options.map((e=>{let t,i;return(0,c.isString)(e)?t=i=e:[t,i]=e,(0,r.option)({value:t},i)}));this.input_el=(0,r.select)({multiple:!0,class:p.input,name:this.model.name,disabled:this.model.disabled},e),this.input_el.addEventListener(\"change\",(()=>this.change_input())),this.group_el.appendChild(this.input_el),this.render_selection()}render_selection(){const e=new Set(this.model.value);for(const t of this.el.querySelectorAll(\"option\"))t.selected=e.has(t.value);this.input_el.size=this.model.size}change_input(){const e=null!=this.el.querySelector(\"select:focus\"),t=[];for(const e of this.el.querySelectorAll(\"option\"))e.selected&&t.push(e.value);this.model.value=t,super.change_input(),e&&this.input_el.focus()}}i.MultiSelectView=d,d.__name__=\"MultiSelectView\";class u extends h.InputWidget{constructor(e){super(e)}}i.MultiSelect=u,o=u,u.__name__=\"MultiSelect\",o.prototype.default_view=d,o.define((({Int:e,String:t,Array:i,Tuple:s,Or:n})=>({value:[i(t),[]],options:[i(n(t,s(t,t))),[]],size:[e,4]})))},\n", + " 473: function _(e,a,r,t,s){var n;t();const p=e(468),_=e(43);class i extends p.MarkupView{render(){super.render();const e=(0,_.p)({style:{margin:0}});this.has_math_disabled()?e.textContent=this.model.text:e.innerHTML=this.process_tex(),this.markup_el.appendChild(e)}}r.ParagraphView=i,i.__name__=\"ParagraphView\";class h extends p.Markup{constructor(e){super(e)}}r.Paragraph=h,n=h,h.__name__=\"Paragraph\",n.prototype.default_view=i},\n", + " 474: function _(e,s,t,n,r){var p;n();const u=e(446);class a extends u.TextInputView{render(){super.render(),this.input_el.type=\"password\"}}t.PasswordInputView=a,a.__name__=\"PasswordInputView\";class o extends u.TextInput{constructor(e){super(e)}}t.PasswordInput=o,p=o,o.__name__=\"PasswordInput\",p.prototype.default_view=a},\n", + " 475: function _(e,t,i,l,s){l();const o=e(1);var n;const h=(0,o.__importDefault)(e(476)),a=e(43),u=e(8),c=e(210),_=(0,o.__importStar)(e(449)),d=(0,o.__importDefault)(e(477)),r=e(448);class m extends r.InputWidgetView{constructor(){super(...arguments),this._last_height=null}connect_signals(){super.connect_signals(),this.connect(this.model.properties.disabled.change,(()=>this.set_disabled()));const{value:e,max_items:t,option_limit:i,search_option_limit:l,delete_button:s,placeholder:o,options:n,name:h,title:a}=this.model.properties;this.on_change([e,t,i,l,s,o,n,h,a],(()=>this.render()))}styles(){return[...super.styles(),d.default]}_update_layout(){this.layout=new c.CachedVariadicBox(this.el),this.layout.set_sizing(this.box_sizing())}render(){super.render(),this.input_el=(0,a.select)({multiple:!0,class:_.input,name:this.model.name,disabled:this.model.disabled}),this.group_el.appendChild(this.input_el);const e=new Set(this.model.value),t=this.model.options.map((t=>{let i,l;return(0,u.isString)(t)?i=l=t:[i,l]=t,{value:i,label:l,selected:e.has(i)}})),i=this.model.solid?\"solid\":\"light\",l=`choices__item ${i}`,s=`choices__button ${i}`,o={choices:t,duplicateItemsAllowed:!1,removeItemButton:this.model.delete_button,classNames:{item:l,button:s}};null!=this.model.placeholder&&(o.placeholderValue=this.model.placeholder),null!=this.model.max_items&&(o.maxItemCount=this.model.max_items),null!=this.model.option_limit&&(o.renderChoiceLimit=this.model.option_limit),null!=this.model.search_option_limit&&(o.searchResultLimit=this.model.search_option_limit),this.choice_el=new h.default(this.input_el,o);const n=()=>this.choice_el.containerOuter.element.getBoundingClientRect().height;null!=this._last_height&&this._last_height!=n()&&this.root.invalidate_layout(),this._last_height=n(),this.input_el.addEventListener(\"change\",(()=>this.change_input()))}set_disabled(){this.model.disabled?this.choice_el.disable():this.choice_el.enable()}change_input(){const e=null!=this.el.querySelector(\"select:focus\"),t=[];for(const e of this.el.querySelectorAll(\"option\"))e.selected&&t.push(e.value);this.model.value=t,super.change_input(),e&&this.input_el.focus()}}i.MultiChoiceView=m,m.__name__=\"MultiChoiceView\";class p extends r.InputWidget{constructor(e){super(e)}}i.MultiChoice=p,n=p,p.__name__=\"MultiChoice\",n.prototype.default_view=m,n.define((({Boolean:e,Int:t,String:i,Array:l,Tuple:s,Or:o,Nullable:n})=>({value:[l(i),[]],options:[l(o(i,s(i,i))),[]],max_items:[n(t),null],delete_button:[e,!0],placeholder:[n(i),null],option_limit:[n(t),null],search_option_limit:[n(t),null],solid:[e,!0]})))},\n", + " 476: function _(e,t,i,n,s){\n", " /*! choices.js v9.0.1 | © 2019 Josh Johnson | https://github.com/jshjohnson/Choices#readme */\n", " var r,o;r=window,o=function(){return function(e){var t={};function i(n){if(t[n])return t[n].exports;var s=t[n]={i:n,l:!1,exports:{}};return e[n].call(s.exports,s,s.exports,i),s.l=!0,s.exports}return i.m=e,i.c=t,i.d=function(e,t,n){i.o(e,t)||Object.defineProperty(e,t,{enumerable:!0,get:n})},i.r=function(e){\"undefined\"!=typeof Symbol&&Symbol.toStringTag&&Object.defineProperty(e,Symbol.toStringTag,{value:\"Module\"}),Object.defineProperty(e,\"__esModule\",{value:!0})},i.t=function(e,t){if(1&t&&(e=i(e)),8&t)return e;if(4&t&&\"object\"==typeof e&&e&&e.__esModule)return e;var n=Object.create(null);if(i.r(n),Object.defineProperty(n,\"default\",{enumerable:!0,value:e}),2&t&&\"string\"!=typeof e)for(var s in e)i.d(n,s,function(t){return e[t]}.bind(null,s));return n},i.n=function(e){var t=e&&e.__esModule?function(){return e.default}:function(){return e};return i.d(t,\"a\",t),t},i.o=function(e,t){return Object.prototype.hasOwnProperty.call(e,t)},i.p=\"/public/assets/scripts/\",i(i.s=4)}([function(e,t,i){\"use strict\";var n=function(e){return function(e){return!!e&&\"object\"==typeof e}(e)&&!function(e){var t=Object.prototype.toString.call(e);return\"[object RegExp]\"===t||\"[object Date]\"===t||function(e){return e.$$typeof===s}(e)}(e)},s=\"function\"==typeof Symbol&&Symbol.for?Symbol.for(\"react.element\"):60103;function r(e,t){return!1!==t.clone&&t.isMergeableObject(e)?l((i=e,Array.isArray(i)?[]:{}),e,t):e;var i}function o(e,t,i){return e.concat(t).map((function(e){return r(e,i)}))}function a(e){return Object.keys(e).concat(function(e){return Object.getOwnPropertySymbols?Object.getOwnPropertySymbols(e).filter((function(t){return e.propertyIsEnumerable(t)})):[]}(e))}function c(e,t,i){var n={};return i.isMergeableObject(e)&&a(e).forEach((function(t){n[t]=r(e[t],i)})),a(t).forEach((function(s){(function(e,t){try{return t in e&&!(Object.hasOwnProperty.call(e,t)&&Object.propertyIsEnumerable.call(e,t))}catch(e){return!1}})(e,s)||(i.isMergeableObject(t[s])&&e[s]?n[s]=function(e,t){if(!t.customMerge)return l;var i=t.customMerge(e);return\"function\"==typeof i?i:l}(s,i)(e[s],t[s],i):n[s]=r(t[s],i))})),n}function l(e,t,i){(i=i||{}).arrayMerge=i.arrayMerge||o,i.isMergeableObject=i.isMergeableObject||n,i.cloneUnlessOtherwiseSpecified=r;var s=Array.isArray(t);return s===Array.isArray(e)?s?i.arrayMerge(e,t,i):c(e,t,i):r(t,i)}l.all=function(e,t){if(!Array.isArray(e))throw new Error(\"first argument should be an array\");return e.reduce((function(e,i){return l(e,i,t)}),{})};var h=l;e.exports=h},function(e,t,i){\"use strict\";(function(e,n){var s,r=i(3);s=\"undefined\"!=typeof self?self:\"undefined\"!=typeof window?window:void 0!==e?e:n;var o=Object(r.a)(s);t.a=o}).call(this,i(5),i(6)(e))},function(e,t,i){\n", " /*!\n", @@ -1006,26 +1015,25 @@ " * http://www.apache.org/licenses/LICENSE-2.0\n", " */\n", " e.exports=function(e){var t={};function i(n){if(t[n])return t[n].exports;var s=t[n]={i:n,l:!1,exports:{}};return e[n].call(s.exports,s,s.exports,i),s.l=!0,s.exports}return i.m=e,i.c=t,i.d=function(e,t,n){i.o(e,t)||Object.defineProperty(e,t,{enumerable:!0,get:n})},i.r=function(e){\"undefined\"!=typeof Symbol&&Symbol.toStringTag&&Object.defineProperty(e,Symbol.toStringTag,{value:\"Module\"}),Object.defineProperty(e,\"__esModule\",{value:!0})},i.t=function(e,t){if(1&t&&(e=i(e)),8&t)return e;if(4&t&&\"object\"==typeof e&&e&&e.__esModule)return e;var n=Object.create(null);if(i.r(n),Object.defineProperty(n,\"default\",{enumerable:!0,value:e}),2&t&&\"string\"!=typeof e)for(var s in e)i.d(n,s,function(t){return e[t]}.bind(null,s));return n},i.n=function(e){var t=e&&e.__esModule?function(){return e.default}:function(){return e};return i.d(t,\"a\",t),t},i.o=function(e,t){return Object.prototype.hasOwnProperty.call(e,t)},i.p=\"\",i(i.s=1)}([function(e,t){e.exports=function(e){return Array.isArray?Array.isArray(e):\"[object Array]\"===Object.prototype.toString.call(e)}},function(e,t,i){function n(e){return(n=\"function\"==typeof Symbol&&\"symbol\"==typeof Symbol.iterator?function(e){return typeof e}:function(e){return e&&\"function\"==typeof Symbol&&e.constructor===Symbol&&e!==Symbol.prototype?\"symbol\":typeof e})(e)}function s(e,t){for(var i=0;i1&&void 0!==arguments[1]?arguments[1]:{limit:!1};this._log('---------\\nSearch pattern: \"'.concat(e,'\"'));var i=this._prepareSearchers(e),n=i.tokenSearchers,s=i.fullSearcher,r=this._search(n,s),o=r.weights,a=r.results;return this._computeScore(o,a),this.options.shouldSort&&this._sort(a),t.limit&&\"number\"==typeof t.limit&&(a=a.slice(0,t.limit)),this._format(a)}},{key:\"_prepareSearchers\",value:function(){var e=arguments.length>0&&void 0!==arguments[0]?arguments[0]:\"\",t=[];if(this.options.tokenize)for(var i=e.split(this.options.tokenSeparator),n=0,s=i.length;n0&&void 0!==arguments[0]?arguments[0]:[],t=arguments.length>1?arguments[1]:void 0,i=this.list,n={},s=[];if(\"string\"==typeof i[0]){for(var r=0,o=i.length;r1)throw new Error(\"Key weight has to be > 0 and <= 1\");p=p.name}else a[p]={weight:1};this._analyze({key:p,value:this.options.getFn(h,p),record:h,index:c},{resultMap:n,results:s,tokenSearchers:e,fullSearcher:t})}return{weights:a,results:s}}},{key:\"_analyze\",value:function(e,t){var i=e.key,n=e.arrayIndex,s=void 0===n?-1:n,r=e.value,o=e.record,c=e.index,l=t.tokenSearchers,h=void 0===l?[]:l,u=t.fullSearcher,d=void 0===u?[]:u,p=t.resultMap,m=void 0===p?{}:p,f=t.results,v=void 0===f?[]:f;if(null!=r){var g=!1,_=-1,b=0;if(\"string\"==typeof r){this._log(\"\\nKey: \".concat(\"\"===i?\"-\":i));var y=d.search(r);if(this._log('Full text: \"'.concat(r,'\", score: ').concat(y.score)),this.options.tokenize){for(var E=r.split(this.options.tokenSeparator),I=[],S=0;S-1&&(P=(P+_)/2),this._log(\"Score average:\",P);var D=!this.options.tokenize||!this.options.matchAllTokens||b>=h.length;if(this._log(\"\\nCheck Matches: \".concat(D)),(g||y.isMatch)&&D){var M=m[c];M?M.output.push({key:i,arrayIndex:s,value:r,score:P,matchedIndices:y.matchedIndices}):(m[c]={item:o,output:[{key:i,arrayIndex:s,value:r,score:P,matchedIndices:y.matchedIndices}]},v.push(m[c]))}}else if(a(r))for(var N=0,F=r.length;N-1&&(o.arrayIndex=r.arrayIndex),t.matches.push(o)}}})),this.options.includeScore&&s.push((function(e,t){t.score=e.score}));for(var r=0,o=e.length;ri)return s(e,this.pattern,n);var o=this.options,a=o.location,c=o.distance,l=o.threshold,h=o.findAllMatches,u=o.minMatchCharLength;return r(e,this.pattern,this.patternAlphabet,{location:a,distance:c,threshold:l,findAllMatches:h,minMatchCharLength:u})}}])&&n(t.prototype,i),a&&n(t,a),e}();e.exports=a},function(e,t){var i=/[\\-\\[\\]\\/\\{\\}\\(\\)\\*\\+\\?\\.\\\\\\^\\$\\|]/g;e.exports=function(e,t){var n=arguments.length>2&&void 0!==arguments[2]?arguments[2]:/ +/g,s=new RegExp(t.replace(i,\"\\\\$&\").replace(n,\"|\")),r=e.match(s),o=!!r,a=[];if(o)for(var c=0,l=r.length;c=P;N-=1){var F=N-1,j=i[e.charAt(F)];if(j&&(E[F]=1),M[N]=(M[N+1]<<1|1)&j,0!==T&&(M[N]|=(O[N+1]|O[N])<<1|1|O[N+1]),M[N]&L&&(C=n(t,{errors:T,currentLocation:F,expectedLocation:v,distance:l}))<=_){if(_=C,(b=F)<=v)break;P=Math.max(1,2*v-b)}}if(n(t,{errors:T+1,currentLocation:v,expectedLocation:v,distance:l})>_)break;O=M}return{isMatch:b>=0,score:0===C?.001:C,matchedIndices:s(E,f)}}},function(e,t){e.exports=function(e,t){var i=t.errors,n=void 0===i?0:i,s=t.currentLocation,r=void 0===s?0:s,o=t.expectedLocation,a=void 0===o?0:o,c=t.distance,l=void 0===c?100:c,h=n/e.length,u=Math.abs(a-r);return l?h+u/l:u?1:h}},function(e,t){e.exports=function(){for(var e=arguments.length>0&&void 0!==arguments[0]?arguments[0]:[],t=arguments.length>1&&void 0!==arguments[1]?arguments[1]:1,i=[],n=-1,s=-1,r=0,o=e.length;r=t&&i.push([n,s]),n=-1)}return e[r-1]&&r-n>=t&&i.push([n,r-1]),i}},function(e,t){e.exports=function(e){for(var t={},i=e.length,n=0;n/g,\"&rt;\").replace(/-1?e.map((function(e){var i=e;return i.id===parseInt(t.choiceId,10)&&(i.selected=!0),i})):e;case\"REMOVE_ITEM\":return t.choiceId>-1?e.map((function(e){var i=e;return i.id===parseInt(t.choiceId,10)&&(i.selected=!1),i})):e;case\"FILTER_CHOICES\":return e.map((function(e){var i=e;return i.active=t.results.some((function(e){var t=e.item,n=e.score;return t.id===i.id&&(i.score=n,!0)})),i}));case\"ACTIVATE_CHOICES\":return e.map((function(e){var i=e;return i.active=t.active,i}));case\"CLEAR_CHOICES\":return v;default:return e}},general:_}),A=function(e,t){var i=e;if(\"CLEAR_ALL\"===t.type)i=void 0;else if(\"RESET_TO\"===t.type)return O(t.state);return C(i,t)};function L(e,t){for(var i=0;i\"'+I(e)+'\"'},maxItemText:function(e){return\"Only \"+e+\" values can be added\"},valueComparer:function(e,t){return e===t},fuseOptions:{includeScore:!0},callbackOnInit:null,callbackOnCreateTemplates:null,classNames:{containerOuter:\"choices\",containerInner:\"choices__inner\",input:\"choices__input\",inputCloned:\"choices__input--cloned\",list:\"choices__list\",listItems:\"choices__list--multiple\",listSingle:\"choices__list--single\",listDropdown:\"choices__list--dropdown\",item:\"choices__item\",itemSelectable:\"choices__item--selectable\",itemDisabled:\"choices__item--disabled\",itemChoice:\"choices__item--choice\",placeholder:\"choices__placeholder\",group:\"choices__group\",groupHeading:\"choices__heading\",button:\"choices__button\",activeState:\"is-active\",focusState:\"is-focused\",openState:\"is-open\",disabledState:\"is-disabled\",highlightedState:\"is-highlighted\",selectedState:\"is-selected\",flippedState:\"is-flipped\",loadingState:\"is-loading\",noResults:\"has-no-results\",noChoices:\"has-no-choices\"}},D=\"showDropdown\",M=\"hideDropdown\",N=\"change\",F=\"choice\",j=\"search\",K=\"addItem\",R=\"removeItem\",H=\"highlightItem\",B=\"highlightChoice\",V=\"ADD_CHOICE\",G=\"FILTER_CHOICES\",q=\"ACTIVATE_CHOICES\",U=\"CLEAR_CHOICES\",z=\"ADD_GROUP\",W=\"ADD_ITEM\",X=\"REMOVE_ITEM\",$=\"HIGHLIGHT_ITEM\",J=46,Y=8,Z=13,Q=65,ee=27,te=38,ie=40,ne=33,se=34,re=\"text\",oe=\"select-one\",ae=\"select-multiple\",ce=function(){function e(e){var t=e.element,i=e.type,n=e.classNames,s=e.position;this.element=t,this.classNames=n,this.type=i,this.position=s,this.isOpen=!1,this.isFlipped=!1,this.isFocussed=!1,this.isDisabled=!1,this.isLoading=!1,this._onFocus=this._onFocus.bind(this),this._onBlur=this._onBlur.bind(this)}var t=e.prototype;return t.addEventListeners=function(){this.element.addEventListener(\"focus\",this._onFocus),this.element.addEventListener(\"blur\",this._onBlur)},t.removeEventListeners=function(){this.element.removeEventListener(\"focus\",this._onFocus),this.element.removeEventListener(\"blur\",this._onBlur)},t.shouldFlip=function(e){if(\"number\"!=typeof e)return!1;var t=!1;return\"auto\"===this.position?t=!window.matchMedia(\"(min-height: \"+(e+1)+\"px)\").matches:\"top\"===this.position&&(t=!0),t},t.setActiveDescendant=function(e){this.element.setAttribute(\"aria-activedescendant\",e)},t.removeActiveDescendant=function(){this.element.removeAttribute(\"aria-activedescendant\")},t.open=function(e){this.element.classList.add(this.classNames.openState),this.element.setAttribute(\"aria-expanded\",\"true\"),this.isOpen=!0,this.shouldFlip(e)&&(this.element.classList.add(this.classNames.flippedState),this.isFlipped=!0)},t.close=function(){this.element.classList.remove(this.classNames.openState),this.element.setAttribute(\"aria-expanded\",\"false\"),this.removeActiveDescendant(),this.isOpen=!1,this.isFlipped&&(this.element.classList.remove(this.classNames.flippedState),this.isFlipped=!1)},t.focus=function(){this.isFocussed||this.element.focus()},t.addFocusState=function(){this.element.classList.add(this.classNames.focusState)},t.removeFocusState=function(){this.element.classList.remove(this.classNames.focusState)},t.enable=function(){this.element.classList.remove(this.classNames.disabledState),this.element.removeAttribute(\"aria-disabled\"),this.type===oe&&this.element.setAttribute(\"tabindex\",\"0\"),this.isDisabled=!1},t.disable=function(){this.element.classList.add(this.classNames.disabledState),this.element.setAttribute(\"aria-disabled\",\"true\"),this.type===oe&&this.element.setAttribute(\"tabindex\",\"-1\"),this.isDisabled=!0},t.wrap=function(e){!function(e,t){void 0===t&&(t=document.createElement(\"div\")),e.nextSibling?e.parentNode.insertBefore(t,e.nextSibling):e.parentNode.appendChild(t),t.appendChild(e)}(e,this.element)},t.unwrap=function(e){this.element.parentNode.insertBefore(e,this.element),this.element.parentNode.removeChild(this.element)},t.addLoadingState=function(){this.element.classList.add(this.classNames.loadingState),this.element.setAttribute(\"aria-busy\",\"true\"),this.isLoading=!0},t.removeLoadingState=function(){this.element.classList.remove(this.classNames.loadingState),this.element.removeAttribute(\"aria-busy\"),this.isLoading=!1},t._onFocus=function(){this.isFocussed=!0},t._onBlur=function(){this.isFocussed=!1},e}();function le(e,t){for(var i=0;i0?this.element.scrollTop+o-s:e.offsetTop;requestAnimationFrame((function(){i._animateScroll(a,t)}))}},t._scrollDown=function(e,t,i){var n=(i-e)/t,s=n>1?n:1;this.element.scrollTop=e+s},t._scrollUp=function(e,t,i){var n=(e-i)/t,s=n>1?n:1;this.element.scrollTop=e-s},t._animateScroll=function(e,t){var i=this,n=this.element.scrollTop,s=!1;t>0?(this._scrollDown(n,4,e),ne&&(s=!0)),s&&requestAnimationFrame((function(){i._animateScroll(e,t)}))},e}();function de(e,t){for(var i=0;i0?\"treeitem\":\"option\"),Object.assign(g.dataset,{choice:\"\",id:l,value:h,selectText:i}),m?(g.classList.add(a),g.dataset.choiceDisabled=\"\",g.setAttribute(\"aria-disabled\",\"true\")):(g.classList.add(r),g.dataset.choiceSelectable=\"\"),g},input:function(e,t){var i=e.input,n=e.inputCloned,s=Object.assign(document.createElement(\"input\"),{type:\"text\",className:i+\" \"+n,autocomplete:\"off\",autocapitalize:\"off\",spellcheck:!1});return s.setAttribute(\"role\",\"textbox\"),s.setAttribute(\"aria-autocomplete\",\"list\"),s.setAttribute(\"aria-label\",t),s},dropdown:function(e){var t=e.list,i=e.listDropdown,n=document.createElement(\"div\");return n.classList.add(t,i),n.setAttribute(\"aria-expanded\",\"false\"),n},notice:function(e,t,i){var n=e.item,s=e.itemChoice,r=e.noResults,o=e.noChoices;void 0===i&&(i=\"\");var a=[n,s];return\"no-choices\"===i?a.push(o):\"no-results\"===i&&a.push(r),Object.assign(document.createElement(\"div\"),{innerHTML:t,className:a.join(\" \")})},option:function(e){var t=e.label,i=e.value,n=e.customProperties,s=e.active,r=e.disabled,o=new Option(t,i,!1,s);return n&&(o.dataset.customProperties=n),o.disabled=r,o}},be=function(e){return void 0===e&&(e=!0),{type:q,active:e}},ye=function(e,t){return{type:$,id:e,highlighted:t}},Ee=function(e){var t=e.value,i=e.id,n=e.active,s=e.disabled;return{type:z,value:t,id:i,active:n,disabled:s}},Ie=function(e){return{type:\"SET_IS_LOADING\",isLoading:e}};function Se(e,t){for(var i=0;i=0?this._store.getGroupById(s):null;return this._store.dispatch(ye(i,!0)),t&&this.passedElement.triggerEvent(H,{id:i,value:o,label:c,groupValue:l&&l.value?l.value:null}),this},r.unhighlightItem=function(e){if(!e)return this;var t=e.id,i=e.groupId,n=void 0===i?-1:i,s=e.value,r=void 0===s?\"\":s,o=e.label,a=void 0===o?\"\":o,c=n>=0?this._store.getGroupById(n):null;return this._store.dispatch(ye(t,!1)),this.passedElement.triggerEvent(H,{id:t,value:r,label:a,groupValue:c&&c.value?c.value:null}),this},r.highlightAll=function(){var e=this;return this._store.items.forEach((function(t){return e.highlightItem(t)})),this},r.unhighlightAll=function(){var e=this;return this._store.items.forEach((function(t){return e.unhighlightItem(t)})),this},r.removeActiveItemsByValue=function(e){var t=this;return this._store.activeItems.filter((function(t){return t.value===e})).forEach((function(e){return t._removeItem(e)})),this},r.removeActiveItems=function(e){var t=this;return this._store.activeItems.filter((function(t){return t.id!==e})).forEach((function(e){return t._removeItem(e)})),this},r.removeHighlightedItems=function(e){var t=this;return void 0===e&&(e=!1),this._store.highlightedActiveItems.forEach((function(i){t._removeItem(i),e&&t._triggerChange(i.value)})),this},r.showDropdown=function(e){var t=this;return this.dropdown.isActive||requestAnimationFrame((function(){t.dropdown.show(),t.containerOuter.open(t.dropdown.distanceFromTopWindow),!e&&t._canSearch&&t.input.focus(),t.passedElement.triggerEvent(D,{})})),this},r.hideDropdown=function(e){var t=this;return this.dropdown.isActive?(requestAnimationFrame((function(){t.dropdown.hide(),t.containerOuter.close(),!e&&t._canSearch&&(t.input.removeActiveDescendant(),t.input.blur()),t.passedElement.triggerEvent(M,{})})),this):this},r.getValue=function(e){void 0===e&&(e=!1);var t=this._store.activeItems.reduce((function(t,i){var n=e?i.value:i;return t.push(n),t}),[]);return this._isSelectOneElement?t[0]:t},r.setValue=function(e){var t=this;return this.initialised?(e.forEach((function(e){return t._setChoiceOrItem(e)})),this):this},r.setChoiceByValue=function(e){var t=this;return!this.initialised||this._isTextElement||(Array.isArray(e)?e:[e]).forEach((function(e){return t._findAndSelectChoiceByValue(e)})),this},r.setChoices=function(e,t,i,n){var s=this;if(void 0===e&&(e=[]),void 0===t&&(t=\"value\"),void 0===i&&(i=\"label\"),void 0===n&&(n=!1),!this.initialised)throw new ReferenceError(\"setChoices was called on a non-initialized instance of Choices\");if(!this._isSelectElement)throw new TypeError(\"setChoices can't be used with INPUT based Choices\");if(\"string\"!=typeof t||!t)throw new TypeError(\"value parameter must be a name of 'value' field in passed objects\");if(n&&this.clearChoices(),\"function\"==typeof e){var r=e(this);if(\"function\"==typeof Promise&&r instanceof Promise)return new Promise((function(e){return requestAnimationFrame(e)})).then((function(){return s._handleLoadingState(!0)})).then((function(){return r})).then((function(e){return s.setChoices(e,t,i,n)})).catch((function(e){s.config.silent||console.error(e)})).then((function(){return s._handleLoadingState(!1)})).then((function(){return s}));if(!Array.isArray(r))throw new TypeError(\".setChoices first argument function must return either array of choices or Promise, got: \"+typeof r);return this.setChoices(r,t,i,!1)}if(!Array.isArray(e))throw new TypeError(\".setChoices must be called either with array of choices with a function resulting into Promise of array of choices\");return this.containerOuter.removeLoadingState(),this._startLoading(),e.forEach((function(e){e.choices?s._addGroup({id:parseInt(e.id,10)||null,group:e,valueKey:t,labelKey:i}):s._addChoice({value:e[t],label:e[i],isSelected:e.selected,isDisabled:e.disabled,customProperties:e.customProperties,placeholder:e.placeholder})})),this._stopLoading(),this},r.clearChoices=function(){return this._store.dispatch({type:U}),this},r.clearStore=function(){return this._store.dispatch({type:\"CLEAR_ALL\"}),this},r.clearInput=function(){var e=!this._isSelectOneElement;return this.input.clear(e),!this._isTextElement&&this._canSearch&&(this._isSearching=!1,this._store.dispatch(be(!0))),this},r._render=function(){if(!this._store.isLoading()){this._currentState=this._store.state;var e=this._currentState.choices!==this._prevState.choices||this._currentState.groups!==this._prevState.groups||this._currentState.items!==this._prevState.items,t=this._isSelectElement,i=this._currentState.items!==this._prevState.items;e&&(t&&this._renderChoices(),i&&this._renderItems(),this._prevState=this._currentState)}},r._renderChoices=function(){var e=this,t=this._store,i=t.activeGroups,n=t.activeChoices,s=document.createDocumentFragment();if(this.choiceList.clear(),this.config.resetScrollPosition&&requestAnimationFrame((function(){return e.choiceList.scrollToTop()})),i.length>=1&&!this._isSearching){var r=n.filter((function(e){return!0===e.placeholder&&-1===e.groupId}));r.length>=1&&(s=this._createChoicesFragment(r,s)),s=this._createGroupsFragment(i,n,s)}else n.length>=1&&(s=this._createChoicesFragment(n,s));if(s.childNodes&&s.childNodes.length>0){var o=this._store.activeItems,a=this._canAddItem(o,this.input.value);a.response?(this.choiceList.append(s),this._highlightChoice()):this.choiceList.append(this._getTemplate(\"notice\",a.notice))}else{var c,l;this._isSearching?(l=\"function\"==typeof this.config.noResultsText?this.config.noResultsText():this.config.noResultsText,c=this._getTemplate(\"notice\",l,\"no-results\")):(l=\"function\"==typeof this.config.noChoicesText?this.config.noChoicesText():this.config.noChoicesText,c=this._getTemplate(\"notice\",l,\"no-choices\")),this.choiceList.append(c)}},r._renderItems=function(){var e=this._store.activeItems||[];this.itemList.clear();var t=this._createItemsFragment(e);t.childNodes&&this.itemList.append(t)},r._createGroupsFragment=function(e,t,i){var n=this;return void 0===i&&(i=document.createDocumentFragment()),this.config.shouldSort&&e.sort(this.config.sorter),e.forEach((function(e){var s=function(e){return t.filter((function(t){return n._isSelectOneElement?t.groupId===e.id:t.groupId===e.id&&(\"always\"===n.config.renderSelectedChoices||!t.selected)}))}(e);if(s.length>=1){var r=n._getTemplate(\"choiceGroup\",e);i.appendChild(r),n._createChoicesFragment(s,i,!0)}})),i},r._createChoicesFragment=function(e,t,i){var n=this;void 0===t&&(t=document.createDocumentFragment()),void 0===i&&(i=!1);var s=this.config,r=s.renderSelectedChoices,o=s.searchResultLimit,a=s.renderChoiceLimit,c=this._isSearching?w:this.config.sorter,l=function(e){if(\"auto\"!==r||n._isSelectOneElement||!e.selected){var i=n._getTemplate(\"choice\",e,n.config.itemSelectText);t.appendChild(i)}},h=e;\"auto\"!==r||this._isSelectOneElement||(h=e.filter((function(e){return!e.selected})));var u=h.reduce((function(e,t){return t.placeholder?e.placeholderChoices.push(t):e.normalChoices.push(t),e}),{placeholderChoices:[],normalChoices:[]}),d=u.placeholderChoices,p=u.normalChoices;(this.config.shouldSort||this._isSearching)&&p.sort(c);var m=h.length,f=this._isSelectOneElement?[].concat(d,p):p;this._isSearching?m=o:a&&a>0&&!i&&(m=a);for(var v=0;v=n){var o=s?this._searchChoices(e):0;this.passedElement.triggerEvent(j,{value:e,resultCount:o})}else r&&(this._isSearching=!1,this._store.dispatch(be(!0)))}},r._canAddItem=function(e,t){var i=!0,n=\"function\"==typeof this.config.addItemText?this.config.addItemText(t):this.config.addItemText;if(!this._isSelectOneElement){var s=function(e,t,i){return void 0===i&&(i=\"value\"),e.some((function(e){return\"string\"==typeof t?e[i]===t.trim():e[i]===t}))}(e,t);this.config.maxItemCount>0&&this.config.maxItemCount<=e.length&&(i=!1,n=\"function\"==typeof this.config.maxItemText?this.config.maxItemText(this.config.maxItemCount):this.config.maxItemText),!this.config.duplicateItemsAllowed&&s&&i&&(i=!1,n=\"function\"==typeof this.config.uniqueItemText?this.config.uniqueItemText(t):this.config.uniqueItemText),this._isTextElement&&this.config.addItems&&i&&\"function\"==typeof this.config.addItemFilter&&!this.config.addItemFilter(t)&&(i=!1,n=\"function\"==typeof this.config.customAddItemText?this.config.customAddItemText(t):this.config.customAddItemText)}return{response:i,notice:n}},r._searchChoices=function(e){var t=\"string\"==typeof e?e.trim():e,i=\"string\"==typeof this._currentValue?this._currentValue.trim():this._currentValue;if(t.length<1&&t===i+\" \")return 0;var n=this._store.searchableChoices,r=t,o=[].concat(this.config.searchFields),a=Object.assign(this.config.fuseOptions,{keys:o}),c=new s.a(n,a).search(r);return this._currentValue=t,this._highlightPosition=0,this._isSearching=!0,this._store.dispatch(function(e){return{type:G,results:e}}(c)),c.length},r._addEventListeners=function(){var e=document.documentElement;e.addEventListener(\"touchend\",this._onTouchEnd,!0),this.containerOuter.element.addEventListener(\"keydown\",this._onKeyDown,!0),this.containerOuter.element.addEventListener(\"mousedown\",this._onMouseDown,!0),e.addEventListener(\"click\",this._onClick,{passive:!0}),e.addEventListener(\"touchmove\",this._onTouchMove,{passive:!0}),this.dropdown.element.addEventListener(\"mouseover\",this._onMouseOver,{passive:!0}),this._isSelectOneElement&&(this.containerOuter.element.addEventListener(\"focus\",this._onFocus,{passive:!0}),this.containerOuter.element.addEventListener(\"blur\",this._onBlur,{passive:!0})),this.input.element.addEventListener(\"keyup\",this._onKeyUp,{passive:!0}),this.input.element.addEventListener(\"focus\",this._onFocus,{passive:!0}),this.input.element.addEventListener(\"blur\",this._onBlur,{passive:!0}),this.input.element.form&&this.input.element.form.addEventListener(\"reset\",this._onFormReset,{passive:!0}),this.input.addEventListeners()},r._removeEventListeners=function(){var e=document.documentElement;e.removeEventListener(\"touchend\",this._onTouchEnd,!0),this.containerOuter.element.removeEventListener(\"keydown\",this._onKeyDown,!0),this.containerOuter.element.removeEventListener(\"mousedown\",this._onMouseDown,!0),e.removeEventListener(\"click\",this._onClick),e.removeEventListener(\"touchmove\",this._onTouchMove),this.dropdown.element.removeEventListener(\"mouseover\",this._onMouseOver),this._isSelectOneElement&&(this.containerOuter.element.removeEventListener(\"focus\",this._onFocus),this.containerOuter.element.removeEventListener(\"blur\",this._onBlur)),this.input.element.removeEventListener(\"keyup\",this._onKeyUp),this.input.element.removeEventListener(\"focus\",this._onFocus),this.input.element.removeEventListener(\"blur\",this._onBlur),this.input.element.form&&this.input.element.form.removeEventListener(\"reset\",this._onFormReset),this.input.removeEventListeners()},r._onKeyDown=function(e){var t,i=e.target,n=e.keyCode,s=e.ctrlKey,r=e.metaKey,o=this._store.activeItems,a=this.input.isFocussed,c=this.dropdown.isActive,l=this.itemList.hasChildren(),h=String.fromCharCode(n),u=J,d=Y,p=Z,m=Q,f=ee,v=te,g=ie,_=ne,b=se,y=s||r;!this._isTextElement&&/[a-zA-Z0-9-_ ]/.test(h)&&this.showDropdown();var E=((t={})[m]=this._onAKey,t[p]=this._onEnterKey,t[f]=this._onEscapeKey,t[v]=this._onDirectionKey,t[_]=this._onDirectionKey,t[g]=this._onDirectionKey,t[b]=this._onDirectionKey,t[d]=this._onDeleteKey,t[u]=this._onDeleteKey,t);E[n]&&E[n]({event:e,target:i,keyCode:n,metaKey:r,activeItems:o,hasFocusedInput:a,hasActiveDropdown:c,hasItems:l,hasCtrlDownKeyPressed:y})},r._onKeyUp=function(e){var t=e.target,i=e.keyCode,n=this.input.value,s=this._store.activeItems,r=this._canAddItem(s,n),o=J,a=Y;if(this._isTextElement)if(r.notice&&n){var c=this._getTemplate(\"notice\",r.notice);this.dropdown.element.innerHTML=c.outerHTML,this.showDropdown(!0)}else this.hideDropdown(!0);else{var l=(i===o||i===a)&&!t.value,h=!this._isTextElement&&this._isSearching,u=this._canSearch&&r.response;l&&h?(this._isSearching=!1,this._store.dispatch(be(!0))):u&&this._handleSearch(this.input.value)}this._canSearch=this.config.searchEnabled},r._onAKey=function(e){var t=e.hasItems;e.hasCtrlDownKeyPressed&&t&&(this._canSearch=!1,this.config.removeItems&&!this.input.value&&this.input.element===document.activeElement&&this.highlightAll())},r._onEnterKey=function(e){var t=e.event,i=e.target,n=e.activeItems,s=e.hasActiveDropdown,r=Z,o=i.hasAttribute(\"data-button\");if(this._isTextElement&&i.value){var a=this.input.value;this._canAddItem(n,a).response&&(this.hideDropdown(!0),this._addItem({value:a}),this._triggerChange(a),this.clearInput())}if(o&&(this._handleButtonAction(n,i),t.preventDefault()),s){var c=this.dropdown.getChild(\".\"+this.config.classNames.highlightedState);c&&(n[0]&&(n[0].keyCode=r),this._handleChoiceAction(n,c)),t.preventDefault()}else this._isSelectOneElement&&(this.showDropdown(),t.preventDefault())},r._onEscapeKey=function(e){e.hasActiveDropdown&&(this.hideDropdown(!0),this.containerOuter.focus())},r._onDirectionKey=function(e){var t,i,n,s=e.event,r=e.hasActiveDropdown,o=e.keyCode,a=e.metaKey,c=ie,l=ne,h=se;if(r||this._isSelectOneElement){this.showDropdown(),this._canSearch=!1;var u,d=o===c||o===h?1:-1,p=\"[data-choice-selectable]\";if(a||o===h||o===l)u=d>0?this.dropdown.element.querySelector(\"[data-choice-selectable]:last-of-type\"):this.dropdown.element.querySelector(p);else{var m=this.dropdown.element.querySelector(\".\"+this.config.classNames.highlightedState);u=m?function(e,t,i){if(void 0===i&&(i=1),e instanceof Element&&\"string\"==typeof t){for(var n=(i>0?\"next\":\"previous\")+\"ElementSibling\",s=e[n];s;){if(s.matches(t))return s;s=s[n]}return s}}(m,p,d):this.dropdown.element.querySelector(p)}u&&(t=u,i=this.choiceList.element,void 0===(n=d)&&(n=1),t&&(n>0?i.scrollTop+i.offsetHeight>=t.offsetTop+t.offsetHeight:t.offsetTop>=i.scrollTop)||this.choiceList.scrollToChildElement(u,d),this._highlightChoice(u)),s.preventDefault()}},r._onDeleteKey=function(e){var t=e.event,i=e.target,n=e.hasFocusedInput,s=e.activeItems;!n||i.value||this._isSelectOneElement||(this._handleBackspace(s),t.preventDefault())},r._onTouchMove=function(){this._wasTap&&(this._wasTap=!1)},r._onTouchEnd=function(e){var t=(e||e.touches[0]).target;this._wasTap&&this.containerOuter.element.contains(t)&&((t===this.containerOuter.element||t===this.containerInner.element)&&(this._isTextElement?this.input.focus():this._isSelectMultipleElement&&this.showDropdown()),e.stopPropagation()),this._wasTap=!0},r._onMouseDown=function(e){var t=e.target;if(t instanceof HTMLElement){if(we&&this.choiceList.element.contains(t)){var i=this.choiceList.element.firstElementChild,n=\"ltr\"===this._direction?e.offsetX>=i.offsetWidth:e.offsetX0&&this.unhighlightAll(),this.containerOuter.removeFocusState(),this.hideDropdown(!0))},r._onFocus=function(e){var t,i=this,n=e.target;this.containerOuter.element.contains(n)&&((t={}).text=function(){n===i.input.element&&i.containerOuter.addFocusState()},t[\"select-one\"]=function(){i.containerOuter.addFocusState(),n===i.input.element&&i.showDropdown(!0)},t[\"select-multiple\"]=function(){n===i.input.element&&(i.showDropdown(!0),i.containerOuter.addFocusState())},t)[this.passedElement.element.type]()},r._onBlur=function(e){var t=this,i=e.target;if(this.containerOuter.element.contains(i)&&!this._isScrollingOnIe){var n,s=this._store.activeItems.some((function(e){return e.highlighted}));((n={}).text=function(){i===t.input.element&&(t.containerOuter.removeFocusState(),s&&t.unhighlightAll(),t.hideDropdown(!0))},n[\"select-one\"]=function(){t.containerOuter.removeFocusState(),(i===t.input.element||i===t.containerOuter.element&&!t._canSearch)&&t.hideDropdown(!0)},n[\"select-multiple\"]=function(){i===t.input.element&&(t.containerOuter.removeFocusState(),t.hideDropdown(!0),s&&t.unhighlightAll())},n)[this.passedElement.element.type]()}else this._isScrollingOnIe=!1,this.input.element.focus()},r._onFormReset=function(){this._store.dispatch({type:\"RESET_TO\",state:this._initialState})},r._highlightChoice=function(e){var t=this;void 0===e&&(e=null);var i=Array.from(this.dropdown.element.querySelectorAll(\"[data-choice-selectable]\"));if(i.length){var n=e;Array.from(this.dropdown.element.querySelectorAll(\".\"+this.config.classNames.highlightedState)).forEach((function(e){e.classList.remove(t.config.classNames.highlightedState),e.setAttribute(\"aria-selected\",\"false\")})),n?this._highlightPosition=i.indexOf(n):(n=i.length>this._highlightPosition?i[this._highlightPosition]:i[i.length-1])||(n=i[0]),n.classList.add(this.config.classNames.highlightedState),n.setAttribute(\"aria-selected\",\"true\"),this.passedElement.triggerEvent(B,{el:n}),this.dropdown.isActive&&(this.input.setActiveDescendant(n.id),this.containerOuter.setActiveDescendant(n.id))}},r._addItem=function(e){var t=e.value,i=e.label,n=void 0===i?null:i,s=e.choiceId,r=void 0===s?-1:s,o=e.groupId,a=void 0===o?-1:o,c=e.customProperties,l=void 0===c?null:c,h=e.placeholder,u=void 0!==h&&h,d=e.keyCode,p=void 0===d?null:d,m=\"string\"==typeof t?t.trim():t,f=p,v=l,g=this._store.items,_=n||m,b=r||-1,y=a>=0?this._store.getGroupById(a):null,E=g?g.length+1:1;return this.config.prependValue&&(m=this.config.prependValue+m.toString()),this.config.appendValue&&(m+=this.config.appendValue.toString()),this._store.dispatch(function(e){var t=e.value,i=e.label,n=e.id,s=e.choiceId,r=e.groupId,o=e.customProperties,a=e.placeholder,c=e.keyCode;return{type:W,value:t,label:i,id:n,choiceId:s,groupId:r,customProperties:o,placeholder:a,keyCode:c}}({value:m,label:_,id:E,choiceId:b,groupId:a,customProperties:l,placeholder:u,keyCode:f})),this._isSelectOneElement&&this.removeActiveItems(E),this.passedElement.triggerEvent(K,{id:E,value:m,label:_,customProperties:v,groupValue:y&&y.value?y.value:void 0,keyCode:f}),this},r._removeItem=function(e){if(!e||!E(\"Object\",e))return this;var t=e.id,i=e.value,n=e.label,s=e.choiceId,r=e.groupId,o=r>=0?this._store.getGroupById(r):null;return this._store.dispatch(function(e,t){return{type:X,id:e,choiceId:t}}(t,s)),o&&o.value?this.passedElement.triggerEvent(R,{id:t,value:i,label:n,groupValue:o.value}):this.passedElement.triggerEvent(R,{id:t,value:i,label:n}),this},r._addChoice=function(e){var t=e.value,i=e.label,n=void 0===i?null:i,s=e.isSelected,r=void 0!==s&&s,o=e.isDisabled,a=void 0!==o&&o,c=e.groupId,l=void 0===c?-1:c,h=e.customProperties,u=void 0===h?null:h,d=e.placeholder,p=void 0!==d&&d,m=e.keyCode,f=void 0===m?null:m;if(null!=t){var v=this._store.choices,g=n||t,_=v?v.length+1:1,b=this._baseId+\"-\"+this._idNames.itemChoice+\"-\"+_;this._store.dispatch(function(e){var t=e.value,i=e.label,n=e.id,s=e.groupId,r=e.disabled,o=e.elementId,a=e.customProperties,c=e.placeholder,l=e.keyCode;return{type:V,value:t,label:i,id:n,groupId:s,disabled:r,elementId:o,customProperties:a,placeholder:c,keyCode:l}}({id:_,groupId:l,elementId:b,value:t,label:g,disabled:a,customProperties:u,placeholder:p,keyCode:f})),r&&this._addItem({value:t,label:g,choiceId:_,customProperties:u,placeholder:p,keyCode:f})}},r._addGroup=function(e){var t=this,i=e.group,n=e.id,s=e.valueKey,r=void 0===s?\"value\":s,o=e.labelKey,a=void 0===o?\"label\":o,c=E(\"Object\",i)?i.choices:Array.from(i.getElementsByTagName(\"OPTION\")),l=n||Math.floor((new Date).valueOf()*Math.random()),h=!!i.disabled&&i.disabled;c?(this._store.dispatch(Ee({value:i.label,id:l,active:!0,disabled:h})),c.forEach((function(e){var i=e.disabled||e.parentNode&&e.parentNode.disabled;t._addChoice({value:e[r],label:E(\"Object\",e)?e[a]:e.innerHTML,isSelected:e.selected,isDisabled:i,groupId:l,customProperties:e.customProperties,placeholder:e.placeholder})}))):this._store.dispatch(Ee({value:i.label,id:i.id,active:!1,disabled:i.disabled}))},r._getTemplate=function(e){var t;if(!e)return null;for(var i=this.config.classNames,n=arguments.length,s=new Array(n>1?n-1:0),r=1;r{var e;return this.input_el.name=null!==(e=this.model.name)&&void 0!==e?e:\"\"})),this.connect(this.model.properties.value.change,(()=>{this.input_el.value=this.format_value,this.old_value=this.input_el.value})),this.connect(this.model.properties.low.change,(()=>{const{value:e,low:t,high:l}=this.model;null!=t&&null!=l&&(0,p.assert)(t<=l,\"Invalid bounds, low must be inferior to high\"),null!=e&&null!=t&&e{const{value:e,low:t,high:l}=this.model;null!=t&&null!=l&&(0,p.assert)(l>=t,\"Invalid bounds, high must be superior to low\"),null!=e&&null!=l&&e>l&&(this.model.value=l)})),this.connect(this.model.properties.high.change,(()=>this.input_el.placeholder=this.model.placeholder)),this.connect(this.model.properties.disabled.change,(()=>this.input_el.disabled=this.model.disabled)),this.connect(this.model.properties.placeholder.change,(()=>this.input_el.placeholder=this.model.placeholder))}get format_value(){return null!=this.model.value?this.model.pretty(this.model.value):\"\"}_set_input_filter(e){this.input_el.addEventListener(\"input\",(()=>{const{selectionStart:t,selectionEnd:l}=this.input_el;if(e(this.input_el.value))this.old_value=this.input_el.value;else{const e=this.old_value.length-this.input_el.value.length;this.input_el.value=this.old_value,t&&l&&this.input_el.setSelectionRange(t-1,l+e)}}))}render(){super.render(),this.input_el=(0,r.input)({type:\"text\",class:_.input,name:this.model.name,value:this.format_value,disabled:this.model.disabled,placeholder:this.model.placeholder}),this.old_value=this.format_value,this.set_input_filter(),this.input_el.addEventListener(\"change\",(()=>this.change_input())),this.input_el.addEventListener(\"focusout\",(()=>this.input_el.value=this.format_value)),this.group_el.appendChild(this.input_el)}set_input_filter(){\"int\"==this.model.mode?this._set_input_filter((e=>m.test(e))):\"float\"==this.model.mode&&this._set_input_filter((e=>c.test(e)))}bound_value(e){let t=e;const{low:l,high:i}=this.model;return t=null!=l?Math.max(l,t):t,t=null!=i?Math.min(i,t):t,t}get value(){let e=\"\"!=this.input_el.value?Number(this.input_el.value):null;return null!=e&&(e=this.bound_value(e)),e}change_input(){null==this.value?this.model.value=null:Number.isNaN(this.value)||(this.model.value=this.value)}}l.NumericInputView=v,v.__name__=\"NumericInputView\";class g extends o.InputWidget{constructor(e){super(e)}_formatter(e,t){return(0,d.isString)(t)?h.format(e,t):t.doFormat([e],{loc:0})[0]}pretty(e){return null!=this.format?this._formatter(e,this.format):`${e}`}}l.NumericInput=g,u=g,g.__name__=\"NumericInput\",u.prototype.default_view=v,u.define((({Number:e,String:t,Enum:l,Ref:i,Or:n,Nullable:s})=>({value:[s(e),null],placeholder:[t,\"\"],mode:[l(\"int\",\"float\"),\"int\"],format:[s(n(t,i(a.TickFormatter))),null],low:[s(e),null],high:[s(e),null]})))},\n", - " 475: function _(e,t,r,s,n){var a;s();const o=e(464),_=e(43);class p extends o.MarkupView{render(){super.render();const e=(0,_.pre)({style:{overflow:\"auto\"}},this.model.text);this.markup_el.appendChild(e)}}r.PreTextView=p,p.__name__=\"PreTextView\";class u extends o.Markup{constructor(e){super(e)}}r.PreText=u,a=u,u.__name__=\"PreText\",a.prototype.default_view=p},\n", - " 476: function _(t,o,e,a,i){a();const n=t(1);var u;const s=t(449),c=t(43),_=(0,n.__importStar)(t(318));class r extends s.ButtonGroupView{change_active(t){this.model.active!==t&&(this.model.active=t)}_update_active(){const{active:t}=this.model;this._buttons.forEach(((o,e)=>{(0,c.classes)(o).toggle(_.active,t===e)}))}}e.RadioButtonGroupView=r,r.__name__=\"RadioButtonGroupView\";class l extends s.ButtonGroup{constructor(t){super(t)}}e.RadioButtonGroup=l,u=l,l.__name__=\"RadioButtonGroup\",u.prototype.default_view=r,u.define((({Int:t,Nullable:o})=>({active:[o(t),null]})))},\n", - " 477: function _(e,n,i,t,a){t();const s=e(1);var l;const o=e(43),d=e(34),p=e(452),r=(0,s.__importStar)(e(446));class u extends p.InputGroupView{render(){super.render();const e=(0,o.div)({class:[r.input_group,this.model.inline?r.inline:null]});this.el.appendChild(e);const n=(0,d.uniqueId)(),{active:i,labels:t}=this.model;this._inputs=[];for(let a=0;athis.change_active(a))),this._inputs.push(s),this.model.disabled&&(s.disabled=!0),a==i&&(s.checked=!0);const l=(0,o.label)(s,(0,o.span)(t[a]));e.appendChild(l)}}change_active(e){this.model.active=e}}i.RadioGroupView=u,u.__name__=\"RadioGroupView\";class c extends p.InputGroup{constructor(e){super(e)}}i.RadioGroup=c,l=c,c.__name__=\"RadioGroup\",l.prototype.default_view=u,l.define((({Boolean:e,Int:n,String:i,Array:t,Nullable:a})=>({active:[a(n),null],labels:[t(i),[]],inline:[e,!1]})))},\n", - " 478: function _(e,r,t,a,i){a();var n;const o=(0,e(1).__importStar)(e(153)),s=e(458),_=e(8);class d extends s.AbstractRangeSliderView{}t.RangeSliderView=d,d.__name__=\"RangeSliderView\";class c extends s.AbstractSlider{constructor(e){super(e),this.behaviour=\"drag\",this.connected=[!1,!0,!1]}_formatter(e,r){return(0,_.isString)(r)?o.format(e,r):r.compute(e)}}t.RangeSlider=c,n=c,c.__name__=\"RangeSlider\",n.prototype.default_view=d,n.override({format:\"0[.]00\"})},\n", - " 479: function _(e,t,n,s,i){s();const l=e(1);var u;const a=e(43),o=e(8),p=e(13),_=e(445),r=(0,l.__importStar)(e(446));class c extends _.InputWidgetView{constructor(){super(...arguments),this._known_values=new Set}connect_signals(){super.connect_signals();const{value:e,options:t}=this.model.properties;this.on_change(e,(()=>{this._update_value()})),this.on_change(t,(()=>{(0,a.empty)(this.input_el),(0,a.append)(this.input_el,...this.options_el()),this._update_value()}))}options_el(){const{_known_values:e}=this;function t(t){return t.map((t=>{let n,s;return(0,o.isString)(t)?n=s=t:[n,s]=t,e.add(n),(0,a.option)({value:n},s)}))}e.clear();const{options:n}=this.model;return(0,o.isArray)(n)?t(n):(0,p.entries)(n).map((([e,n])=>(0,a.optgroup)({label:e},t(n))))}render(){super.render(),this.input_el=(0,a.select)({class:r.input,name:this.model.name,disabled:this.model.disabled},this.options_el()),this._update_value(),this.input_el.addEventListener(\"change\",(()=>this.change_input())),this.group_el.appendChild(this.input_el)}change_input(){const e=this.input_el.value;this.model.value=e,super.change_input()}_update_value(){const{value:e}=this.model;this._known_values.has(e)?this.input_el.value=e:this.input_el.removeAttribute(\"value\")}}n.SelectView=c,c.__name__=\"SelectView\";class h extends _.InputWidget{constructor(e){super(e)}}n.Select=h,u=h,h.__name__=\"Select\",u.prototype.default_view=c,u.define((({String:e,Array:t,Tuple:n,Dict:s,Or:i})=>{const l=t(i(e,n(e,e)));return{value:[e,\"\"],options:[i(l,s(l)),[]]}}))},\n", - " 480: function _(e,t,r,i,a){i();var o;const s=(0,e(1).__importStar)(e(153)),_=e(458),n=e(8);class c extends _.AbstractSliderView{}r.SliderView=c,c.__name__=\"SliderView\";class d extends _.AbstractSlider{constructor(e){super(e),this.behaviour=\"tap\",this.connected=[!0,!1]}_formatter(e,t){return(0,n.isString)(t)?s.format(e,t):t.compute(e)}}r.Slider=d,o=d,d.__name__=\"Slider\",o.prototype.default_view=c,o.override({format:\"0[.]00\"})},\n", - " 481: function _(e,t,i,n,s){var l;n();const o=e(474),r=e(43),{min:a,max:h,floor:_,abs:u}=Math;function d(e){return _(e)!==e?e.toFixed(16).replace(/0+$/,\"\").split(\".\")[1].length:0}class p extends o.NumericInputView{*buttons(){yield this.btn_up_el,yield this.btn_down_el}initialize(){super.initialize(),this._handles={interval:void 0,timeout:void 0},this._interval=200}connect_signals(){super.connect_signals();const e=this.model.properties;this.on_change(e.disabled,(()=>{for(const e of this.buttons())(0,r.toggle_attribute)(e,\"disabled\",this.model.disabled)}))}render(){super.render(),this.wrapper_el=(0,r.div)({class:\"bk-spin-wrapper\"}),this.group_el.replaceChild(this.wrapper_el,this.input_el),this.btn_up_el=(0,r.button)({class:\"bk-spin-btn bk-spin-btn-up\"}),this.btn_down_el=(0,r.button)({class:\"bk-spin-btn bk-spin-btn-down\"}),this.wrapper_el.appendChild(this.input_el),this.wrapper_el.appendChild(this.btn_up_el),this.wrapper_el.appendChild(this.btn_down_el);for(const e of this.buttons())(0,r.toggle_attribute)(e,\"disabled\",this.model.disabled),e.addEventListener(\"mousedown\",(e=>this._btn_mouse_down(e))),e.addEventListener(\"mouseup\",(()=>this._btn_mouse_up())),e.addEventListener(\"mouseleave\",(()=>this._btn_mouse_leave()));this.input_el.addEventListener(\"keydown\",(e=>this._input_key_down(e))),this.input_el.addEventListener(\"keyup\",(()=>this.model.value_throttled=this.model.value)),this.input_el.addEventListener(\"wheel\",(e=>this._input_mouse_wheel(e))),this.input_el.addEventListener(\"wheel\",function(e,t,i=!1){let n;return function(...s){const l=this,o=i&&void 0===n;void 0!==n&&clearTimeout(n),n=setTimeout((function(){n=void 0,i||e.apply(l,s)}),t),o&&e.apply(l,s)}}((()=>{this.model.value_throttled=this.model.value}),this.model.wheel_wait,!1))}get precision(){const{low:e,high:t,step:i}=this.model,n=d;return h(n(u(null!=e?e:0)),n(u(null!=t?t:0)),n(u(i)))}remove(){this._stop_incrementation(),super.remove()}_start_incrementation(e){clearInterval(this._handles.interval),this._counter=0;const{step:t}=this.model,i=e=>{if(this._counter+=1,this._counter%5==0){const t=Math.floor(this._counter/5);t<10?(clearInterval(this._handles.interval),this._handles.interval=setInterval((()=>i(e)),this._interval/(t+1))):t>=10&&t<=13&&(clearInterval(this._handles.interval),this._handles.interval=setInterval((()=>i(2*e)),this._interval/10))}this.increment(e)};this._handles.interval=setInterval((()=>i(e*t)),this._interval)}_stop_incrementation(){clearTimeout(this._handles.timeout),this._handles.timeout=void 0,clearInterval(this._handles.interval),this._handles.interval=void 0,this.model.value_throttled=this.model.value}_btn_mouse_down(e){e.preventDefault();const t=e.currentTarget===this.btn_up_el?1:-1;this.increment(t*this.model.step),this.input_el.focus(),this._handles.timeout=setTimeout((()=>this._start_incrementation(t)),this._interval)}_btn_mouse_up(){this._stop_incrementation()}_btn_mouse_leave(){this._stop_incrementation()}_input_mouse_wheel(e){if(document.activeElement===this.input_el){e.preventDefault();const t=e.deltaY>0?-1:1;this.increment(t*this.model.step)}}_input_key_down(e){switch(e.keyCode){case r.Keys.Up:return e.preventDefault(),this.increment(this.model.step);case r.Keys.Down:return e.preventDefault(),this.increment(-this.model.step);case r.Keys.PageUp:return e.preventDefault(),this.increment(this.model.page_step_multiplier*this.model.step);case r.Keys.PageDown:return e.preventDefault(),this.increment(-this.model.page_step_multiplier*this.model.step)}}adjust_to_precision(e){return this.bound_value(Number(e.toFixed(this.precision)))}increment(e){const{low:t,high:i}=this.model;null==this.model.value?e>0?this.model.value=null!=t?t:null!=i?a(0,i):0:e<0&&(this.model.value=null!=i?i:null!=t?h(t,0):0):this.model.value=this.adjust_to_precision(this.model.value+e)}change_input(){super.change_input(),this.model.value_throttled=this.model.value}}i.SpinnerView=p,p.__name__=\"SpinnerView\";class m extends o.NumericInput{constructor(e){super(e)}}i.Spinner=m,l=m,m.__name__=\"Spinner\",l.prototype.default_view=p,l.define((({Number:e,Nullable:t})=>({value_throttled:[t(e),null],step:[e,1],page_step_multiplier:[e,10],wheel_wait:[e,100]}))),l.override({mode:\"float\"})},\n", - " 482: function _(e,t,s,n,i){n();const o=e(1);var r;const c=e(444),l=e(43),p=(0,o.__importStar)(e(446));class _ extends c.TextLikeInputView{connect_signals(){super.connect_signals(),this.connect(this.model.properties.rows.change,(()=>this.input_el.rows=this.model.rows)),this.connect(this.model.properties.cols.change,(()=>this.input_el.cols=this.model.cols))}_render_input(){this.input_el=(0,l.textarea)({class:p.input})}render(){super.render(),this.input_el.cols=this.model.cols,this.input_el.rows=this.model.rows}}s.TextAreaInputView=_,_.__name__=\"TextAreaInputView\";class a extends c.TextLikeInput{constructor(e){super(e)}}s.TextAreaInput=a,r=a,a.__name__=\"TextAreaInput\",r.prototype.default_view=_,r.define((({Int:e})=>({cols:[e,20],rows:[e,2]}))),r.override({max_length:500})},\n", - " 483: function _(e,t,s,c,i){c();const o=e(1);var a;const n=e(438),l=e(43),_=(0,o.__importStar)(e(318));class r extends n.AbstractButtonView{connect_signals(){super.connect_signals(),this.connect(this.model.properties.active.change,(()=>this._update_active()))}render(){super.render(),this._update_active()}click(){this.model.active=!this.model.active,super.click()}_update_active(){(0,l.classes)(this.button_el).toggle(_.active,this.model.active)}}s.ToggleView=r,r.__name__=\"ToggleView\";class g extends n.AbstractButton{constructor(e){super(e)}}s.Toggle=g,a=g,g.__name__=\"Toggle\",a.prototype.default_view=r,a.define((({Boolean:e})=>({active:[e,!1]}))),a.override({label:\"Toggle\"})},\n", - " }, 436, {\"models/widgets/main\":436,\"models/widgets/index\":437,\"models/widgets/abstract_button\":438,\"models/widgets/control\":439,\"models/widgets/widget\":508,\"models/widgets/abstract_icon\":441,\"models/widgets/autocomplete_input\":442,\"models/widgets/text_input\":443,\"models/widgets/text_like_input\":444,\"models/widgets/input_widget\":445,\"styles/widgets/inputs.css\":446,\"models/widgets/button\":447,\"models/widgets/checkbox_button_group\":448,\"models/widgets/button_group\":449,\"models/widgets/oriented_control\":450,\"models/widgets/checkbox_group\":451,\"models/widgets/input_group\":452,\"models/widgets/color_picker\":453,\"models/widgets/date_picker\":454,\"styles/widgets/flatpickr.css\":456,\"models/widgets/date_range_slider\":457,\"models/widgets/abstract_slider\":458,\"styles/widgets/sliders.css\":460,\"styles/widgets/nouislider.css\":461,\"models/widgets/date_slider\":462,\"models/widgets/div\":463,\"models/widgets/markup\":464,\"styles/clearfix.css\":465,\"models/widgets/dropdown\":466,\"models/widgets/file_input\":467,\"models/widgets/multiselect\":468,\"models/widgets/paragraph\":469,\"models/widgets/password_input\":470,\"models/widgets/multichoice\":471,\"styles/widgets/choices.css\":473,\"models/widgets/numeric_input\":474,\"models/widgets/pretext\":475,\"models/widgets/radio_button_group\":476,\"models/widgets/radio_group\":477,\"models/widgets/range_slider\":478,\"models/widgets/selectbox\":479,\"models/widgets/slider\":480,\"models/widgets/spinner\":481,\"models/widgets/textarea_input\":482,\"models/widgets/toggle\":483}, {});});\n", + " 477: function _(o,e,i,t,r){t(),i.root=\"bk-root\",i.default=\".bk-root{}.bk-root .choices{position:relative;margin-bottom:24px;font-size:16px;}.bk-root .choices:focus{outline:none;}.bk-root .choices:last-child{margin-bottom:0;}.bk-root .choices.is-disabled .choices__inner,.bk-root .choices.is-disabled .choices__input{background-color:#eaeaea;cursor:not-allowed;-webkit-user-select:none;-ms-user-select:none;user-select:none;}.bk-root .choices.is-disabled .choices__item{cursor:not-allowed;}.bk-root .choices [hidden]{display:none !important;}.bk-root .choices[data-type*='select-one']{cursor:pointer;}.bk-root .choices[data-type*='select-one'] .choices__inner{padding-bottom:7.5px;}.bk-root .choices[data-type*='select-one'] .choices__input{display:block;width:100%;padding:10px;border-bottom:1px solid #dddddd;background-color:#ffffff;margin:0;}.bk-root .choices[data-type*='select-one'] .choices__button{background-image:url(data:image/svg+xml;base64,PHN2ZyB3aWR0aD0iMjEiIGhlaWdodD0iMjEiIHZpZXdCb3g9IjAgMCAyMSAyMSIgeG1sbnM9Imh0dHA6Ly93d3cudzMub3JnLzIwMDAvc3ZnIj48ZyBmaWxsPSIjMDAwIiBmaWxsLXJ1bGU9ImV2ZW5vZGQiPjxwYXRoIGQ9Ik0yLjU5Mi4wNDRsMTguMzY0IDE4LjM2NC0yLjU0OCAyLjU0OEwuMDQ0IDIuNTkyeiIvPjxwYXRoIGQ9Ik0wIDE4LjM2NEwxOC4zNjQgMGwyLjU0OCAyLjU0OEwyLjU0OCAyMC45MTJ6Ii8+PC9nPjwvc3ZnPg==);padding:0;background-size:8px;position:absolute;top:50%;right:0;margin-top:-10px;margin-right:25px;height:20px;width:20px;border-radius:10em;opacity:0.5;}.bk-root .choices[data-type*='select-one'] .choices__button:hover,.bk-root .choices[data-type*='select-one'] .choices__button:focus{opacity:1;}.bk-root .choices[data-type*='select-one'] .choices__button:focus{box-shadow:0px 0px 0px 2px #00bcd4;}.bk-root .choices[data-type*='select-one'] .choices__item[data-value=''] .choices__button{display:none;}.bk-root .choices[data-type*='select-one']:after{content:'';height:0;width:0;border-style:solid;border-color:#333333 transparent transparent transparent;border-width:5px;position:absolute;right:11.5px;top:50%;margin-top:-2.5px;pointer-events:none;}.bk-root .choices[data-type*='select-one'].is-open:after{border-color:transparent transparent #333333 transparent;margin-top:-7.5px;}.bk-root .choices[data-type*='select-one'][dir='rtl']:after{left:11.5px;right:auto;}.bk-root .choices[data-type*='select-one'][dir='rtl'] .choices__button{right:auto;left:0;margin-left:25px;margin-right:0;}.bk-root .choices[data-type*='select-multiple'] .choices__inner,.bk-root .choices[data-type*='text'] .choices__inner{cursor:text;}.bk-root .choices[data-type*='select-multiple'] .choices__button,.bk-root .choices[data-type*='text'] .choices__button{position:relative;display:inline-block;margin-top:0;margin-right:-4px;margin-bottom:0;margin-left:8px;padding-left:16px;border-left:1px solid #008fa1;background-image:url(data:image/svg+xml;base64,PHN2ZyB3aWR0aD0iMjEiIGhlaWdodD0iMjEiIHZpZXdCb3g9IjAgMCAyMSAyMSIgeG1sbnM9Imh0dHA6Ly93d3cudzMub3JnLzIwMDAvc3ZnIj48ZyBmaWxsPSIjRkZGIiBmaWxsLXJ1bGU9ImV2ZW5vZGQiPjxwYXRoIGQ9Ik0yLjU5Mi4wNDRsMTguMzY0IDE4LjM2NC0yLjU0OCAyLjU0OEwuMDQ0IDIuNTkyeiIvPjxwYXRoIGQ9Ik0wIDE4LjM2NEwxOC4zNjQgMGwyLjU0OCAyLjU0OEwyLjU0OCAyMC45MTJ6Ii8+PC9nPjwvc3ZnPg==);background-size:8px;width:8px;line-height:1;opacity:0.75;border-radius:0;}.bk-root .choices[data-type*='select-multiple'] .choices__button:hover,.bk-root .choices[data-type*='select-multiple'] .choices__button:focus,.bk-root .choices[data-type*='text'] .choices__button:hover,.bk-root .choices[data-type*='text'] .choices__button:focus{opacity:1;}.bk-root .choices__inner{display:inline-block;vertical-align:top;width:100%;background-color:#f9f9f9;padding:7.5px 7.5px 3.75px;border:1px solid #dddddd;border-radius:2.5px;font-size:14px;min-height:44px;overflow:hidden;}.bk-root .is-focused .choices__inner,.bk-root .is-open .choices__inner{border-color:#b7b7b7;}.bk-root .is-open .choices__inner{border-radius:2.5px 2.5px 0 0;}.bk-root .is-flipped.is-open .choices__inner{border-radius:0 0 2.5px 2.5px;}.bk-root .choices__list{margin:0;padding-left:0;list-style:none;}.bk-root .choices__list--single{display:inline-block;padding:4px 16px 4px 4px;width:100%;}.bk-root [dir='rtl'] .choices__list--single{padding-right:4px;padding-left:16px;}.bk-root .choices__list--single .choices__item{width:100%;}.bk-root .choices__list--multiple{display:inline;}.bk-root .choices__list--multiple .choices__item{display:inline-block;vertical-align:middle;border-radius:20px;padding:4px 10px;font-size:12px;font-weight:500;margin-right:3.75px;margin-bottom:3.75px;background-color:#00bcd4;border:1px solid #00a5bb;color:#ffffff;word-break:break-all;box-sizing:border-box;}.bk-root .choices__list--multiple .choices__item[data-deletable]{padding-right:5px;}.bk-root [dir='rtl'] .choices__list--multiple .choices__item{margin-right:0;margin-left:3.75px;}.bk-root .choices__list--multiple .choices__item.is-highlighted{background-color:#00a5bb;border:1px solid #008fa1;}.bk-root .is-disabled .choices__list--multiple .choices__item{background-color:#aaaaaa;border:1px solid #919191;}.bk-root .choices__list--dropdown{visibility:hidden;z-index:1;position:absolute;width:100%;background-color:#ffffff;border:1px solid #dddddd;top:100%;margin-top:-1px;border-bottom-left-radius:2.5px;border-bottom-right-radius:2.5px;overflow:hidden;word-break:break-all;will-change:visibility;}.bk-root .choices__list--dropdown.is-active{visibility:visible;}.bk-root .is-open .choices__list--dropdown{border-color:#b7b7b7;}.bk-root .is-flipped .choices__list--dropdown{top:auto;bottom:100%;margin-top:0;margin-bottom:-1px;border-radius:0.25rem 0.25rem 0 0;}.bk-root .choices__list--dropdown .choices__list{position:relative;max-height:300px;overflow:auto;-webkit-overflow-scrolling:touch;will-change:scroll-position;}.bk-root .choices__list--dropdown .choices__item{position:relative;padding:10px;font-size:14px;}.bk-root [dir='rtl'] .choices__list--dropdown .choices__item{text-align:right;}@media (min-width: 640px){.bk-root .choices__list--dropdown .choices__item--selectable{padding-right:100px;}.bk-root .choices__list--dropdown .choices__item--selectable:after{content:attr(data-select-text);font-size:12px;opacity:0;position:absolute;right:10px;top:50%;transform:translateY(-50%);}.bk-root [dir='rtl'] .choices__list--dropdown .choices__item--selectable{text-align:right;padding-left:100px;padding-right:10px;}.bk-root [dir='rtl'] .choices__list--dropdown .choices__item--selectable:after{right:auto;left:10px;}}.bk-root .choices__list--dropdown .choices__item--selectable.is-highlighted{background-color:#f2f2f2;}.bk-root .choices__list--dropdown .choices__item--selectable.is-highlighted:after{opacity:0.5;}.bk-root .choices__item{cursor:default;}.bk-root .choices__item--selectable{cursor:pointer;}.bk-root .choices__item--disabled{cursor:not-allowed;-webkit-user-select:none;-ms-user-select:none;user-select:none;opacity:0.5;}.bk-root .choices__heading{font-weight:600;font-size:12px;padding:10px;border-bottom:1px solid #f7f7f7;color:gray;}.bk-root .choices__button{text-indent:-9999px;-webkit-appearance:none;-moz-appearance:none;appearance:none;border:0;background-color:transparent;background-repeat:no-repeat;background-position:center;cursor:pointer;}.bk-root .choices__button:focus{outline:none;}.bk-root .choices__input{display:inline-block;vertical-align:baseline;background-color:#f9f9f9;font-size:14px;margin-bottom:5px;border:0;border-radius:0;max-width:100%;padding:4px 0 4px 2px;}.bk-root .choices__input:focus{outline:0;}.bk-root [dir='rtl'] .choices__input{padding-right:2px;padding-left:0;}.bk-root .choices__placeholder{opacity:0.5;}.bk-root .choices{width:100%;}.bk-root .choices{box-sizing:border-box;}.bk-root .choices *,.bk-root .choices *:before,.bk-root .choices *:after{box-sizing:inherit;}.bk-root .choices__inner .choices__item.light{background-color:rgba(0, 126, 255, 0.08);border-radius:5px;border:1px solid rgba(0, 126, 255, 0.24);color:#007eff;}.bk-root .choices__inner .choices__item.solid{background-color:#1f77b4;border:none;border-radius:5px;color:white;}.bk-root .choices__inner .choices__item.solid .is-highlighted{background-color:#1f77b4;border:none;}.bk-root .choices__input{background-color:transparent;}.bk-root .choices__inner{background:transparent;border:1px solid darkgray;border-radius:5px;min-height:unset;}.bk-root .choices__list{white-space:initial;}.bk-root .choices__list--dropdown{z-index:100;}.bk-root .choices[data-type*=select-multiple] .choices__button.light{background-image:url(data:image/svg+xml;base64,PHN2ZyB3aWR0aD0iMjEiIGhlaWdodD0iMjEiIHZpZXdCb3g9IjAgMCAyMSAyMSIgeG1sbnM9Imh0dHA6Ly93d3cudzMub3JnLzIwMDAvc3ZnIj48ZyBmaWxsPSIjMDA3ZWZmIiBmaWxsLXJ1bGU9ImV2ZW5vZGQiPjxwYXRoIGQ9Ik0yLjU5Mi4wNDRsMTguMzY0IDE4LjM2NC0yLjU0OCAyLjU0OEwuMDQ0IDIuNTkyeiIvPjxwYXRoIGQ9Ik0wIDE4LjM2NEwxOC4zNjQgMGwyLjU0OCAyLjU0OEwyLjU0OCAyMC45MTJ6Ii8+PC9nPjwvc3ZnPg==);}.bk-root .choices[data-type*=select-multiple] .choices__button.solid{background-image:url(data:image/svg+xml;base64,PHN2ZyB3aWR0aD0iMjEiIGhlaWdodD0iMjEiIHZpZXdCb3g9IjAgMCAyMSAyMSIgeG1sbnM9Imh0dHA6Ly93d3cudzMub3JnLzIwMDAvc3ZnIj48ZyBmaWxsPSIjZmZmZmZmIiBmaWxsLXJ1bGU9ImV2ZW5vZGQiPjxwYXRoIGQ9Ik0yLjU5Mi4wNDRsMTguMzY0IDE4LjM2NC0yLjU0OCAyLjU0OEwuMDQ0IDIuNTkyeiIvPjxwYXRoIGQ9Ik0wIDE4LjM2NEwxOC4zNjQgMGwyLjU0OCAyLjU0OEwyLjU0OCAyMC45MTJ6Ii8+PC9nPjwvc3ZnPg==);border-left:1px solid white;opacity:1;}\"},\n", + " 478: function _(e,t,l,i,n){i();const s=e(1);var u;const h=(0,s.__importStar)(e(153)),o=e(448),a=e(131),r=e(43),d=e(8),p=e(11),_=(0,s.__importStar)(e(449)),m=/^[-+]?\\d*$/,c=/^[-+]?\\d*\\.?\\d*(?:(?:\\d|\\d.)[eE][-+]?)*\\d*$/;class v extends o.InputWidgetView{connect_signals(){super.connect_signals(),this.connect(this.model.properties.name.change,(()=>{var e;return this.input_el.name=null!==(e=this.model.name)&&void 0!==e?e:\"\"})),this.connect(this.model.properties.value.change,(()=>{this.input_el.value=this.format_value,this.old_value=this.input_el.value})),this.connect(this.model.properties.low.change,(()=>{const{value:e,low:t,high:l}=this.model;null!=t&&null!=l&&(0,p.assert)(t<=l,\"Invalid bounds, low must be inferior to high\"),null!=e&&null!=t&&e{const{value:e,low:t,high:l}=this.model;null!=t&&null!=l&&(0,p.assert)(l>=t,\"Invalid bounds, high must be superior to low\"),null!=e&&null!=l&&e>l&&(this.model.value=l)})),this.connect(this.model.properties.high.change,(()=>this.input_el.placeholder=this.model.placeholder)),this.connect(this.model.properties.disabled.change,(()=>this.input_el.disabled=this.model.disabled)),this.connect(this.model.properties.placeholder.change,(()=>this.input_el.placeholder=this.model.placeholder))}get format_value(){return null!=this.model.value?this.model.pretty(this.model.value):\"\"}_set_input_filter(e){this.input_el.addEventListener(\"input\",(()=>{const{selectionStart:t,selectionEnd:l}=this.input_el;if(e(this.input_el.value))this.old_value=this.input_el.value;else{const e=this.old_value.length-this.input_el.value.length;this.input_el.value=this.old_value,t&&l&&this.input_el.setSelectionRange(t-1,l+e)}}))}render(){super.render(),this.input_el=(0,r.input)({type:\"text\",class:_.input,name:this.model.name,value:this.format_value,disabled:this.model.disabled,placeholder:this.model.placeholder}),this.old_value=this.format_value,this.set_input_filter(),this.input_el.addEventListener(\"change\",(()=>this.change_input())),this.input_el.addEventListener(\"focusout\",(()=>this.input_el.value=this.format_value)),this.group_el.appendChild(this.input_el)}set_input_filter(){\"int\"==this.model.mode?this._set_input_filter((e=>m.test(e))):\"float\"==this.model.mode&&this._set_input_filter((e=>c.test(e)))}bound_value(e){let t=e;const{low:l,high:i}=this.model;return t=null!=l?Math.max(l,t):t,t=null!=i?Math.min(i,t):t,t}get value(){let e=\"\"!=this.input_el.value?Number(this.input_el.value):null;return null!=e&&(e=this.bound_value(e)),e}change_input(){null==this.value?this.model.value=null:Number.isNaN(this.value)||(this.model.value=this.value)}}l.NumericInputView=v,v.__name__=\"NumericInputView\";class g extends o.InputWidget{constructor(e){super(e)}_formatter(e,t){return(0,d.isString)(t)?h.format(e,t):t.doFormat([e],{loc:0})[0]}pretty(e){return null!=this.format?this._formatter(e,this.format):`${e}`}}l.NumericInput=g,u=g,g.__name__=\"NumericInput\",u.prototype.default_view=v,u.define((({Number:e,String:t,Enum:l,Ref:i,Or:n,Nullable:s})=>({value:[s(e),null],placeholder:[t,\"\"],mode:[l(\"int\",\"float\"),\"int\"],format:[s(n(t,i(a.TickFormatter))),null],low:[s(e),null],high:[s(e),null]})))},\n", + " 479: function _(e,t,r,s,n){var a;s();const o=e(468),_=e(43);class p extends o.MarkupView{render(){super.render();const e=(0,_.pre)({style:{overflow:\"auto\"}},this.model.text);this.markup_el.appendChild(e)}}r.PreTextView=p,p.__name__=\"PreTextView\";class u extends o.Markup{constructor(e){super(e)}}r.PreText=u,a=u,u.__name__=\"PreText\",a.prototype.default_view=p},\n", + " 480: function _(t,o,e,a,i){a();const n=t(1);var u;const s=t(452),c=t(43),_=(0,n.__importStar)(t(318));class r extends s.ButtonGroupView{change_active(t){this.model.active!==t&&(this.model.active=t)}_update_active(){const{active:t}=this.model;this._buttons.forEach(((o,e)=>{(0,c.classes)(o).toggle(_.active,t===e)}))}}e.RadioButtonGroupView=r,r.__name__=\"RadioButtonGroupView\";class l extends s.ButtonGroup{constructor(t){super(t)}}e.RadioButtonGroup=l,u=l,l.__name__=\"RadioButtonGroup\",u.prototype.default_view=r,u.define((({Int:t,Nullable:o})=>({active:[o(t),null]})))},\n", + " 481: function _(e,n,i,t,a){t();const s=e(1);var l;const o=e(43),d=e(34),p=e(455),r=(0,s.__importStar)(e(449));class u extends p.InputGroupView{render(){super.render();const e=(0,o.div)({class:[r.input_group,this.model.inline?r.inline:null]});this.el.appendChild(e);const n=(0,d.uniqueId)(),{active:i,labels:t}=this.model;this._inputs=[];for(let a=0;athis.change_active(a))),this._inputs.push(s),this.model.disabled&&(s.disabled=!0),a==i&&(s.checked=!0);const l=(0,o.label)(s,(0,o.span)(t[a]));e.appendChild(l)}}change_active(e){this.model.active=e}}i.RadioGroupView=u,u.__name__=\"RadioGroupView\";class c extends p.InputGroup{constructor(e){super(e)}}i.RadioGroup=c,l=c,c.__name__=\"RadioGroup\",l.prototype.default_view=u,l.define((({Boolean:e,Int:n,String:i,Array:t,Nullable:a})=>({active:[a(n),null],labels:[t(i),[]],inline:[e,!1]})))},\n", + " 482: function _(e,r,t,a,i){a();var n;const o=(0,e(1).__importStar)(e(153)),s=e(461),_=e(8);class d extends s.AbstractRangeSliderView{}t.RangeSliderView=d,d.__name__=\"RangeSliderView\";class c extends s.AbstractSlider{constructor(e){super(e),this.behaviour=\"drag\",this.connected=[!1,!0,!1]}_formatter(e,r){return(0,_.isString)(r)?o.format(e,r):r.compute(e)}}t.RangeSlider=c,n=c,c.__name__=\"RangeSlider\",n.prototype.default_view=d,n.override({format:\"0[.]00\"})},\n", + " 483: function _(e,t,n,s,i){s();const l=e(1);var u;const a=e(43),o=e(8),p=e(13),_=e(448),r=(0,l.__importStar)(e(449));class c extends _.InputWidgetView{constructor(){super(...arguments),this._known_values=new Set}connect_signals(){super.connect_signals();const{value:e,options:t}=this.model.properties;this.on_change(e,(()=>{this._update_value()})),this.on_change(t,(()=>{(0,a.empty)(this.input_el),(0,a.append)(this.input_el,...this.options_el()),this._update_value()}))}options_el(){const{_known_values:e}=this;function t(t){return t.map((t=>{let n,s;return(0,o.isString)(t)?n=s=t:[n,s]=t,e.add(n),(0,a.option)({value:n},s)}))}e.clear();const{options:n}=this.model;return(0,o.isArray)(n)?t(n):(0,p.entries)(n).map((([e,n])=>(0,a.optgroup)({label:e},t(n))))}render(){super.render(),this.input_el=(0,a.select)({class:r.input,name:this.model.name,disabled:this.model.disabled},this.options_el()),this._update_value(),this.input_el.addEventListener(\"change\",(()=>this.change_input())),this.group_el.appendChild(this.input_el)}change_input(){const e=this.input_el.value;this.model.value=e,super.change_input()}_update_value(){const{value:e}=this.model;this._known_values.has(e)?this.input_el.value=e:this.input_el.removeAttribute(\"value\")}}n.SelectView=c,c.__name__=\"SelectView\";class h extends _.InputWidget{constructor(e){super(e)}}n.Select=h,u=h,h.__name__=\"Select\",u.prototype.default_view=c,u.define((({String:e,Array:t,Tuple:n,Dict:s,Or:i})=>{const l=t(i(e,n(e,e)));return{value:[e,\"\"],options:[i(l,s(l)),[]]}}))},\n", + " 484: function _(e,t,r,i,a){i();var o;const s=(0,e(1).__importStar)(e(153)),_=e(461),n=e(8);class c extends _.AbstractSliderView{}r.SliderView=c,c.__name__=\"SliderView\";class d extends _.AbstractSlider{constructor(e){super(e),this.behaviour=\"tap\",this.connected=[!0,!1]}_formatter(e,t){return(0,n.isString)(t)?s.format(e,t):t.compute(e)}}r.Slider=d,o=d,d.__name__=\"Slider\",o.prototype.default_view=c,o.override({format:\"0[.]00\"})},\n", + " 485: function _(e,t,i,n,s){var l;n();const o=e(478),r=e(43),{min:a,max:h,floor:_,abs:u}=Math;function d(e){return _(e)!==e?e.toFixed(16).replace(/0+$/,\"\").split(\".\")[1].length:0}class p extends o.NumericInputView{*buttons(){yield this.btn_up_el,yield this.btn_down_el}initialize(){super.initialize(),this._handles={interval:void 0,timeout:void 0},this._interval=200}connect_signals(){super.connect_signals();const e=this.model.properties;this.on_change(e.disabled,(()=>{for(const e of this.buttons())(0,r.toggle_attribute)(e,\"disabled\",this.model.disabled)}))}render(){super.render(),this.wrapper_el=(0,r.div)({class:\"bk-spin-wrapper\"}),this.group_el.replaceChild(this.wrapper_el,this.input_el),this.btn_up_el=(0,r.button)({class:\"bk-spin-btn bk-spin-btn-up\"}),this.btn_down_el=(0,r.button)({class:\"bk-spin-btn bk-spin-btn-down\"}),this.wrapper_el.appendChild(this.input_el),this.wrapper_el.appendChild(this.btn_up_el),this.wrapper_el.appendChild(this.btn_down_el);for(const e of this.buttons())(0,r.toggle_attribute)(e,\"disabled\",this.model.disabled),e.addEventListener(\"mousedown\",(e=>this._btn_mouse_down(e))),e.addEventListener(\"mouseup\",(()=>this._btn_mouse_up())),e.addEventListener(\"mouseleave\",(()=>this._btn_mouse_leave()));this.input_el.addEventListener(\"keydown\",(e=>this._input_key_down(e))),this.input_el.addEventListener(\"keyup\",(()=>this.model.value_throttled=this.model.value)),this.input_el.addEventListener(\"wheel\",(e=>this._input_mouse_wheel(e))),this.input_el.addEventListener(\"wheel\",function(e,t,i=!1){let n;return function(...s){const l=this,o=i&&void 0===n;void 0!==n&&clearTimeout(n),n=setTimeout((function(){n=void 0,i||e.apply(l,s)}),t),o&&e.apply(l,s)}}((()=>{this.model.value_throttled=this.model.value}),this.model.wheel_wait,!1))}get precision(){const{low:e,high:t,step:i}=this.model,n=d;return h(n(u(null!=e?e:0)),n(u(null!=t?t:0)),n(u(i)))}remove(){this._stop_incrementation(),super.remove()}_start_incrementation(e){clearInterval(this._handles.interval),this._counter=0;const{step:t}=this.model,i=e=>{if(this._counter+=1,this._counter%5==0){const t=Math.floor(this._counter/5);t<10?(clearInterval(this._handles.interval),this._handles.interval=setInterval((()=>i(e)),this._interval/(t+1))):t>=10&&t<=13&&(clearInterval(this._handles.interval),this._handles.interval=setInterval((()=>i(2*e)),this._interval/10))}this.increment(e)};this._handles.interval=setInterval((()=>i(e*t)),this._interval)}_stop_incrementation(){clearTimeout(this._handles.timeout),this._handles.timeout=void 0,clearInterval(this._handles.interval),this._handles.interval=void 0,this.model.value_throttled=this.model.value}_btn_mouse_down(e){e.preventDefault();const t=e.currentTarget===this.btn_up_el?1:-1;this.increment(t*this.model.step),this.input_el.focus(),this._handles.timeout=setTimeout((()=>this._start_incrementation(t)),this._interval)}_btn_mouse_up(){this._stop_incrementation()}_btn_mouse_leave(){this._stop_incrementation()}_input_mouse_wheel(e){if(document.activeElement===this.input_el){e.preventDefault();const t=e.deltaY>0?-1:1;this.increment(t*this.model.step)}}_input_key_down(e){switch(e.keyCode){case r.Keys.Up:return e.preventDefault(),this.increment(this.model.step);case r.Keys.Down:return e.preventDefault(),this.increment(-this.model.step);case r.Keys.PageUp:return e.preventDefault(),this.increment(this.model.page_step_multiplier*this.model.step);case r.Keys.PageDown:return e.preventDefault(),this.increment(-this.model.page_step_multiplier*this.model.step)}}adjust_to_precision(e){return this.bound_value(Number(e.toFixed(this.precision)))}increment(e){const{low:t,high:i}=this.model;null==this.model.value?e>0?this.model.value=null!=t?t:null!=i?a(0,i):0:e<0&&(this.model.value=null!=i?i:null!=t?h(t,0):0):this.model.value=this.adjust_to_precision(this.model.value+e)}change_input(){super.change_input(),this.model.value_throttled=this.model.value}}i.SpinnerView=p,p.__name__=\"SpinnerView\";class m extends o.NumericInput{constructor(e){super(e)}}i.Spinner=m,l=m,m.__name__=\"Spinner\",l.prototype.default_view=p,l.define((({Number:e,Nullable:t})=>({value_throttled:[t(e),null],step:[e,1],page_step_multiplier:[e,10],wheel_wait:[e,100]}))),l.override({mode:\"float\"})},\n", + " 486: function _(e,t,s,n,i){n();const o=e(1);var r;const c=e(447),l=e(43),p=(0,o.__importStar)(e(449));class _ extends c.TextLikeInputView{connect_signals(){super.connect_signals(),this.connect(this.model.properties.rows.change,(()=>this.input_el.rows=this.model.rows)),this.connect(this.model.properties.cols.change,(()=>this.input_el.cols=this.model.cols))}_render_input(){this.input_el=(0,l.textarea)({class:p.input})}render(){super.render(),this.input_el.cols=this.model.cols,this.input_el.rows=this.model.rows}}s.TextAreaInputView=_,_.__name__=\"TextAreaInputView\";class a extends c.TextLikeInput{constructor(e){super(e)}}s.TextAreaInput=a,r=a,a.__name__=\"TextAreaInput\",r.prototype.default_view=_,r.define((({Int:e})=>({cols:[e,20],rows:[e,2]}))),r.override({max_length:500})},\n", + " 487: function _(e,t,s,c,i){c();const o=e(1);var a;const n=e(441),l=e(43),_=(0,o.__importStar)(e(318));class r extends n.AbstractButtonView{connect_signals(){super.connect_signals(),this.connect(this.model.properties.active.change,(()=>this._update_active()))}render(){super.render(),this._update_active()}click(){this.model.active=!this.model.active,super.click()}_update_active(){(0,l.classes)(this.button_el).toggle(_.active,this.model.active)}}s.ToggleView=r,r.__name__=\"ToggleView\";class g extends n.AbstractButton{constructor(e){super(e)}}s.Toggle=g,a=g,g.__name__=\"Toggle\",a.prototype.default_view=r,a.define((({Boolean:e})=>({active:[e,!1]}))),a.override({label:\"Toggle\"})},\n", + " }, 439, {\"models/widgets/main\":439,\"models/widgets/index\":440,\"models/widgets/abstract_button\":441,\"models/widgets/control\":442,\"models/widgets/widget\":512,\"models/widgets/abstract_icon\":444,\"models/widgets/autocomplete_input\":445,\"models/widgets/text_input\":446,\"models/widgets/text_like_input\":447,\"models/widgets/input_widget\":448,\"styles/widgets/inputs.css\":449,\"models/widgets/button\":450,\"models/widgets/checkbox_button_group\":451,\"models/widgets/button_group\":452,\"models/widgets/oriented_control\":453,\"models/widgets/checkbox_group\":454,\"models/widgets/input_group\":455,\"models/widgets/color_picker\":456,\"models/widgets/date_picker\":457,\"styles/widgets/flatpickr.css\":459,\"models/widgets/date_range_slider\":460,\"models/widgets/abstract_slider\":461,\"styles/widgets/sliders.css\":463,\"styles/widgets/nouislider.css\":464,\"models/widgets/date_slider\":465,\"models/widgets/datetime_range_slider\":466,\"models/widgets/div\":467,\"models/widgets/markup\":468,\"styles/clearfix.css\":469,\"models/widgets/dropdown\":470,\"models/widgets/file_input\":471,\"models/widgets/multiselect\":472,\"models/widgets/paragraph\":473,\"models/widgets/password_input\":474,\"models/widgets/multichoice\":475,\"styles/widgets/choices.css\":477,\"models/widgets/numeric_input\":478,\"models/widgets/pretext\":479,\"models/widgets/radio_button_group\":480,\"models/widgets/radio_group\":481,\"models/widgets/range_slider\":482,\"models/widgets/selectbox\":483,\"models/widgets/slider\":484,\"models/widgets/spinner\":485,\"models/widgets/textarea_input\":486,\"models/widgets/toggle\":487}, {});});\n", "\n", " /* END bokeh-widgets.min.js */\n", " },\n", - " \n", " function(Bokeh) {\n", " /* BEGIN bokeh-tables.min.js */\n", " /*!\n", - " * Copyright (c) 2012 - 2021, Anaconda, Inc., and Bokeh Contributors\n", + " * Copyright (c) 2012 - 2022, Anaconda, Inc., and Bokeh Contributors\n", " * All rights reserved.\n", " * \n", " * Redistribution and use in source and binary forms, with or without modification,\n", @@ -1055,7 +1063,7 @@ " * THE POSSIBILITY OF SUCH DAMAGE.\n", " */\n", " (function(root, factory) {\n", - " factory(root[\"Bokeh\"], \"2.4.1\");\n", + " factory(root[\"Bokeh\"], \"2.4.3\");\n", " })(this, function(Bokeh, version) {\n", " let define;\n", " return (function(modules, entry, aliases, externals) {\n", @@ -1067,21 +1075,21 @@ " }\n", " })\n", " ({\n", - " 484: function _(t,e,o,r,s){r();const _=(0,t(1).__importStar)(t(485));o.Tables=_;(0,t(7).register_models)(_)},\n", - " 485: function _(g,a,r,e,t){e();const o=g(1);(0,o.__exportStar)(g(486),r),(0,o.__exportStar)(g(489),r),t(\"DataTable\",g(492).DataTable),t(\"TableColumn\",g(510).TableColumn),t(\"TableWidget\",g(509).TableWidget);var n=g(512);t(\"AvgAggregator\",n.AvgAggregator),t(\"MinAggregator\",n.MinAggregator),t(\"MaxAggregator\",n.MaxAggregator),t(\"SumAggregator\",n.SumAggregator);var A=g(513);t(\"GroupingInfo\",A.GroupingInfo),t(\"DataCube\",A.DataCube)},\n", - " 486: function _(e,t,i,s,a){s();const r=e(1);var l,n,u,d,o,p,_,c,h;const E=e(43),V=e(226),m=e(53),f=e(487),v=(0,r.__importStar)(e(488));class w extends V.DOMView{constructor(e){const{model:t,parent:i}=e.column;super(Object.assign({model:t,parent:i},e)),this.args=e,this.initialize(),this.render()}get emptyValue(){return null}initialize(){super.initialize(),this.inputEl=this._createInput(),this.defaultValue=null}async lazy_initialize(){throw new Error(\"unsupported\")}css_classes(){return super.css_classes().concat(v.cell_editor)}render(){super.render(),this.args.container.append(this.el),this.el.appendChild(this.inputEl),this.renderEditor(),this.disableNavigation()}renderEditor(){}disableNavigation(){this.inputEl.addEventListener(\"keydown\",(e=>{switch(e.keyCode){case E.Keys.Left:case E.Keys.Right:case E.Keys.Up:case E.Keys.Down:case E.Keys.PageUp:case E.Keys.PageDown:e.stopImmediatePropagation()}}))}destroy(){this.remove()}focus(){this.inputEl.focus()}show(){}hide(){}position(){}getValue(){return this.inputEl.value}setValue(e){this.inputEl.value=e}serializeValue(){return this.getValue()}isValueChanged(){return!(\"\"==this.getValue()&&null==this.defaultValue)&&this.getValue()!==this.defaultValue}applyValue(e,t){const i=this.args.grid.getData(),s=i.index.indexOf(e[f.DTINDEX_NAME]);i.setField(s,this.args.column.field,t)}loadValue(e){const t=e[this.args.column.field];this.defaultValue=null!=t?t:this.emptyValue,this.setValue(this.defaultValue)}validateValue(e){if(this.args.column.validator){const t=this.args.column.validator(e);if(!t.valid)return t}return{valid:!0,msg:null}}validate(){return this.validateValue(this.getValue())}}i.CellEditorView=w,w.__name__=\"CellEditorView\";class g extends m.Model{}i.CellEditor=g,g.__name__=\"CellEditor\";class x extends w{get emptyValue(){return\"\"}_createInput(){return(0,E.input)({type:\"text\"})}renderEditor(){this.inputEl.focus(),this.inputEl.select()}loadValue(e){super.loadValue(e),this.inputEl.defaultValue=this.defaultValue,this.inputEl.select()}}i.StringEditorView=x,x.__name__=\"StringEditorView\";class y extends g{}i.StringEditor=y,l=y,y.__name__=\"StringEditor\",l.prototype.default_view=x,l.define((({String:e,Array:t})=>({completions:[t(e),[]]})));class I extends w{_createInput(){return(0,E.textarea)()}renderEditor(){this.inputEl.focus(),this.inputEl.select()}}i.TextEditorView=I,I.__name__=\"TextEditorView\";class b extends g{}i.TextEditor=b,n=b,b.__name__=\"TextEditor\",n.prototype.default_view=I;class N extends w{_createInput(){return(0,E.select)()}renderEditor(){for(const e of this.model.options)this.inputEl.appendChild((0,E.option)({value:e},e));this.focus()}}i.SelectEditorView=N,N.__name__=\"SelectEditorView\";class C extends g{}i.SelectEditor=C,u=C,C.__name__=\"SelectEditor\",u.prototype.default_view=N,u.define((({String:e,Array:t})=>({options:[t(e),[]]})));class D extends w{_createInput(){return(0,E.input)({type:\"text\"})}}i.PercentEditorView=D,D.__name__=\"PercentEditorView\";class S extends g{}i.PercentEditor=S,d=S,S.__name__=\"PercentEditor\",d.prototype.default_view=D;class k extends w{_createInput(){return(0,E.input)({type:\"checkbox\"})}renderEditor(){this.focus()}loadValue(e){this.defaultValue=!!e[this.args.column.field],this.inputEl.checked=this.defaultValue}serializeValue(){return this.inputEl.checked}}i.CheckboxEditorView=k,k.__name__=\"CheckboxEditorView\";class z extends g{}i.CheckboxEditor=z,o=z,z.__name__=\"CheckboxEditor\",o.prototype.default_view=k;class P extends w{_createInput(){return(0,E.input)({type:\"text\"})}renderEditor(){this.inputEl.focus(),this.inputEl.select()}remove(){super.remove()}serializeValue(){var e;return null!==(e=parseInt(this.getValue(),10))&&void 0!==e?e:0}loadValue(e){super.loadValue(e),this.inputEl.defaultValue=this.defaultValue,this.inputEl.select()}validateValue(e){return isNaN(e)?{valid:!1,msg:\"Please enter a valid integer\"}:super.validateValue(e)}}i.IntEditorView=P,P.__name__=\"IntEditorView\";class T extends g{}i.IntEditor=T,p=T,T.__name__=\"IntEditor\",p.prototype.default_view=P,p.define((({Int:e})=>({step:[e,1]})));class K extends w{_createInput(){return(0,E.input)({type:\"text\"})}renderEditor(){this.inputEl.focus(),this.inputEl.select()}remove(){super.remove()}serializeValue(){var e;return null!==(e=parseFloat(this.getValue()))&&void 0!==e?e:0}loadValue(e){super.loadValue(e),this.inputEl.defaultValue=this.defaultValue,this.inputEl.select()}validateValue(e){return isNaN(e)?{valid:!1,msg:\"Please enter a valid number\"}:super.validateValue(e)}}i.NumberEditorView=K,K.__name__=\"NumberEditorView\";class A extends g{}i.NumberEditor=A,_=A,A.__name__=\"NumberEditor\",_.prototype.default_view=K,_.define((({Number:e})=>({step:[e,.01]})));class M extends w{_createInput(){return(0,E.input)({type:\"text\"})}}i.TimeEditorView=M,M.__name__=\"TimeEditorView\";class O extends g{}i.TimeEditor=O,c=O,O.__name__=\"TimeEditor\",c.prototype.default_view=M;class F extends w{_createInput(){return(0,E.input)({type:\"text\"})}get emptyValue(){return new Date}renderEditor(){this.inputEl.focus(),this.inputEl.select()}destroy(){super.destroy()}show(){super.show()}hide(){super.hide()}position(){return super.position()}getValue(){}setValue(e){}}i.DateEditorView=F,F.__name__=\"DateEditorView\";class L extends g{}i.DateEditor=L,h=L,L.__name__=\"DateEditor\",h.prototype.default_view=F},\n", - " 487: function _(_,n,i,t,d){t(),i.DTINDEX_NAME=\"__bkdt_internal_index__\"},\n", - " 488: function _(e,l,o,t,r){t(),o.root=\"bk-root\",o.data_table=\"bk-data-table\",o.cell_special_defaults=\"bk-cell-special-defaults\",o.cell_select=\"bk-cell-select\",o.cell_index=\"bk-cell-index\",o.header_index=\"bk-header-index\",o.cell_editor=\"bk-cell-editor\",o.cell_editor_completion=\"bk-cell-editor-completion\",o.default='.bk-root .bk-data-table{box-sizing:content-box;font-size:11px;}.bk-root .bk-data-table input[type=\"checkbox\"]{margin-left:4px;margin-right:4px;}.bk-root .bk-cell-special-defaults{border-right-color:silver;border-right-style:solid;background:#f5f5f5;}.bk-root .bk-cell-select{border-right-color:silver;border-right-style:solid;background:#f5f5f5;}.bk-root .slick-cell.bk-cell-index{border-right-color:silver;border-right-style:solid;background:#f5f5f5;text-align:right;background:#f0f0f0;color:#909090;}.bk-root .bk-header-index .slick-column-name{float:right;}.bk-root .slick-row.selected .bk-cell-index{background-color:transparent;}.bk-root .slick-row.odd{background:#f0f0f0;}.bk-root .slick-cell{padding-left:4px;padding-right:4px;border-right-color:transparent;border:0.25px solid transparent;}.bk-root .slick-cell .bk{line-height:inherit;}.bk-root .slick-cell.active{border-style:dashed;}.bk-root .slick-cell.selected{background-color:#F0F8FF;}.bk-root .slick-cell.editable{padding-left:0;padding-right:0;}.bk-root .bk-cell-editor{display:contents;}.bk-root .bk-cell-editor input,.bk-root .bk-cell-editor select{width:100%;height:100%;border:0;margin:0;padding:0;outline:0;background:transparent;vertical-align:baseline;}.bk-root .bk-cell-editor input{padding-left:4px;padding-right:4px;}.bk-root .bk-cell-editor-completion{font-size:11px;}'},\n", - " 489: function _(t,e,r,n,a){n();const o=t(1);var l,s,i,c,u,m;const _=(0,o.__importDefault)(t(151)),d=(0,o.__importStar)(t(153)),f=t(490),g=t(43),h=t(20),F=t(8),p=t(34),b=t(22),S=t(53);class x extends S.Model{constructor(t){super(t)}doFormat(t,e,r,n,a){return null==r?\"\":`${r}`.replace(/&/g,\"&\").replace(//g,\">\")}}r.CellFormatter=x,x.__name__=\"CellFormatter\";class M extends x{constructor(t){super(t)}doFormat(t,e,r,n,a){const{font_style:o,text_align:l,text_color:s}=this,i=(0,g.div)(null==r?\"\":`${r}`);switch(o){case\"bold\":i.style.fontWeight=\"bold\";break;case\"italic\":i.style.fontStyle=\"italic\"}return null!=l&&(i.style.textAlign=l),null!=s&&(i.style.color=(0,b.color2css)(s)),i.outerHTML}}r.StringFormatter=M,l=M,M.__name__=\"StringFormatter\",l.define((({Color:t,Nullable:e})=>({font_style:[h.FontStyle,\"normal\"],text_align:[h.TextAlign,\"left\"],text_color:[e(t),null]})));class N extends M{constructor(t){super(t)}get scientific_limit_low(){return 10**this.power_limit_low}get scientific_limit_high(){return 10**this.power_limit_high}doFormat(t,e,r,n,a){const o=Math.abs(r)<=this.scientific_limit_low||Math.abs(r)>=this.scientific_limit_high;let l=this.precision;return l<1&&(l=1),r=null!=r&&!isNaN(r)||null==this.nan_format?0==r?(0,p.to_fixed)(r,1):o?r.toExponential(l):(0,p.to_fixed)(r,l):this.nan_format,super.doFormat(t,e,r,n,a)}}r.ScientificFormatter=N,s=N,N.__name__=\"ScientificFormatter\",s.define((({Number:t,String:e,Nullable:r})=>({nan_format:[r(e),null],precision:[t,10],power_limit_high:[t,5],power_limit_low:[t,-3]})));class w extends M{constructor(t){super(t)}doFormat(t,e,r,n,a){const{format:o,language:l,nan_format:s}=this,i=(()=>{switch(this.rounding){case\"round\":case\"nearest\":return Math.round;case\"floor\":case\"rounddown\":return Math.floor;case\"ceil\":case\"roundup\":return Math.ceil}})();return r=null!=r&&!isNaN(r)||null==s?d.format(r,o,l,i):s,super.doFormat(t,e,r,n,a)}}r.NumberFormatter=w,i=w,w.__name__=\"NumberFormatter\",i.define((({String:t,Nullable:e})=>({format:[t,\"0,0\"],language:[t,\"en\"],rounding:[h.RoundingFunction,\"round\"],nan_format:[e(t),null]})));class C extends x{constructor(t){super(t)}doFormat(t,e,r,n,a){return r?(0,g.i)({class:this.icon}).outerHTML:\"\"}}r.BooleanFormatter=C,c=C,C.__name__=\"BooleanFormatter\",c.define((({String:t})=>({icon:[t,\"check\"]})));class y extends M{constructor(t){super(t)}getFormat(){switch(this.format){case\"ATOM\":case\"W3C\":case\"RFC-3339\":case\"ISO-8601\":return\"%Y-%m-%d\";case\"COOKIE\":return\"%a, %d %b %Y\";case\"RFC-850\":return\"%A, %d-%b-%y\";case\"RFC-1123\":case\"RFC-2822\":return\"%a, %e %b %Y\";case\"RSS\":case\"RFC-822\":case\"RFC-1036\":return\"%a, %e %b %y\";case\"TIMESTAMP\":return;default:return this.format}}doFormat(t,e,r,n,a){const{nan_format:o}=this;let l;return l=null!=(r=(0,F.isString)(r)?parseInt(r,10):r)&&!isNaN(r)&&-9223372036854776!==r||null==o?null==r?\"\":(0,_.default)(r,this.getFormat()):o,super.doFormat(t,e,l,n,a)}}r.DateFormatter=y,u=y,y.__name__=\"DateFormatter\",u.define((({String:t,Nullable:e})=>({format:[t,\"ISO-8601\"],nan_format:[e(t),null]})));class T extends x{constructor(t){super(t)}doFormat(t,e,r,n,a){const{template:o}=this;if(null==r)return\"\";return f._.template(o)(Object.assign(Object.assign({},a),{value:r}))}}r.HTMLTemplateFormatter=T,m=T,T.__name__=\"HTMLTemplateFormatter\",m.define((({String:t})=>({template:[t,\"<%= value %>\"]})))},\n", - " 490: function _(e,n,t,f,i){var o=e(491),d=o.template;function r(e,n,t){return d(e,n,t)}r._=o,n.exports=r,\"function\"==typeof define&&define.amd?define((function(){return r})):\"undefined\"==typeof window&&\"undefined\"==typeof navigator||(window.UnderscoreTemplate=r)},\n", - " 491: function _(r,e,n,t,a){\n", + " 488: function _(t,e,o,r,s){r();const _=(0,t(1).__importStar)(t(489));o.Tables=_;(0,t(7).register_models)(_)},\n", + " 489: function _(g,a,r,e,t){e();const o=g(1);(0,o.__exportStar)(g(490),r),(0,o.__exportStar)(g(493),r),t(\"DataTable\",g(496).DataTable),t(\"TableColumn\",g(514).TableColumn),t(\"TableWidget\",g(513).TableWidget);var n=g(516);t(\"AvgAggregator\",n.AvgAggregator),t(\"MinAggregator\",n.MinAggregator),t(\"MaxAggregator\",n.MaxAggregator),t(\"SumAggregator\",n.SumAggregator);var A=g(517);t(\"GroupingInfo\",A.GroupingInfo),t(\"DataCube\",A.DataCube)},\n", + " 490: function _(e,t,i,s,a){s();const r=e(1);var l,n,u,d,o,p,_,c,h;const E=e(43),V=e(226),m=e(53),f=e(491),v=(0,r.__importStar)(e(492));class w extends V.DOMView{constructor(e){const{model:t,parent:i}=e.column;super(Object.assign({model:t,parent:i},e)),this.args=e,this.initialize(),this.render()}get emptyValue(){return null}initialize(){super.initialize(),this.inputEl=this._createInput(),this.defaultValue=null}async lazy_initialize(){throw new Error(\"unsupported\")}css_classes(){return super.css_classes().concat(v.cell_editor)}render(){super.render(),this.args.container.append(this.el),this.el.appendChild(this.inputEl),this.renderEditor(),this.disableNavigation()}renderEditor(){}disableNavigation(){this.inputEl.addEventListener(\"keydown\",(e=>{switch(e.keyCode){case E.Keys.Left:case E.Keys.Right:case E.Keys.Up:case E.Keys.Down:case E.Keys.PageUp:case E.Keys.PageDown:e.stopImmediatePropagation()}}))}destroy(){this.remove()}focus(){this.inputEl.focus()}show(){}hide(){}position(){}getValue(){return this.inputEl.value}setValue(e){this.inputEl.value=e}serializeValue(){return this.getValue()}isValueChanged(){return!(\"\"==this.getValue()&&null==this.defaultValue)&&this.getValue()!==this.defaultValue}applyValue(e,t){const i=this.args.grid.getData(),s=i.index.indexOf(e[f.DTINDEX_NAME]);i.setField(s,this.args.column.field,t)}loadValue(e){const t=e[this.args.column.field];this.defaultValue=null!=t?t:this.emptyValue,this.setValue(this.defaultValue)}validateValue(e){if(this.args.column.validator){const t=this.args.column.validator(e);if(!t.valid)return t}return{valid:!0,msg:null}}validate(){return this.validateValue(this.getValue())}}i.CellEditorView=w,w.__name__=\"CellEditorView\";class g extends m.Model{}i.CellEditor=g,g.__name__=\"CellEditor\";class x extends w{get emptyValue(){return\"\"}_createInput(){return(0,E.input)({type:\"text\"})}renderEditor(){this.inputEl.focus(),this.inputEl.select()}loadValue(e){super.loadValue(e),this.inputEl.defaultValue=this.defaultValue,this.inputEl.select()}}i.StringEditorView=x,x.__name__=\"StringEditorView\";class y extends g{}i.StringEditor=y,l=y,y.__name__=\"StringEditor\",l.prototype.default_view=x,l.define((({String:e,Array:t})=>({completions:[t(e),[]]})));class I extends w{_createInput(){return(0,E.textarea)()}renderEditor(){this.inputEl.focus(),this.inputEl.select()}}i.TextEditorView=I,I.__name__=\"TextEditorView\";class b extends g{}i.TextEditor=b,n=b,b.__name__=\"TextEditor\",n.prototype.default_view=I;class N extends w{_createInput(){return(0,E.select)()}renderEditor(){for(const e of this.model.options)this.inputEl.appendChild((0,E.option)({value:e},e));this.focus()}}i.SelectEditorView=N,N.__name__=\"SelectEditorView\";class C extends g{}i.SelectEditor=C,u=C,C.__name__=\"SelectEditor\",u.prototype.default_view=N,u.define((({String:e,Array:t})=>({options:[t(e),[]]})));class D extends w{_createInput(){return(0,E.input)({type:\"text\"})}}i.PercentEditorView=D,D.__name__=\"PercentEditorView\";class S extends g{}i.PercentEditor=S,d=S,S.__name__=\"PercentEditor\",d.prototype.default_view=D;class k extends w{_createInput(){return(0,E.input)({type:\"checkbox\"})}renderEditor(){this.focus()}loadValue(e){this.defaultValue=!!e[this.args.column.field],this.inputEl.checked=this.defaultValue}serializeValue(){return this.inputEl.checked}}i.CheckboxEditorView=k,k.__name__=\"CheckboxEditorView\";class z extends g{}i.CheckboxEditor=z,o=z,z.__name__=\"CheckboxEditor\",o.prototype.default_view=k;class P extends w{_createInput(){return(0,E.input)({type:\"text\"})}renderEditor(){this.inputEl.focus(),this.inputEl.select()}remove(){super.remove()}serializeValue(){var e;return null!==(e=parseInt(this.getValue(),10))&&void 0!==e?e:0}loadValue(e){super.loadValue(e),this.inputEl.defaultValue=this.defaultValue,this.inputEl.select()}validateValue(e){return isNaN(e)?{valid:!1,msg:\"Please enter a valid integer\"}:super.validateValue(e)}}i.IntEditorView=P,P.__name__=\"IntEditorView\";class T extends g{}i.IntEditor=T,p=T,T.__name__=\"IntEditor\",p.prototype.default_view=P,p.define((({Int:e})=>({step:[e,1]})));class K extends w{_createInput(){return(0,E.input)({type:\"text\"})}renderEditor(){this.inputEl.focus(),this.inputEl.select()}remove(){super.remove()}serializeValue(){var e;return null!==(e=parseFloat(this.getValue()))&&void 0!==e?e:0}loadValue(e){super.loadValue(e),this.inputEl.defaultValue=this.defaultValue,this.inputEl.select()}validateValue(e){return isNaN(e)?{valid:!1,msg:\"Please enter a valid number\"}:super.validateValue(e)}}i.NumberEditorView=K,K.__name__=\"NumberEditorView\";class A extends g{}i.NumberEditor=A,_=A,A.__name__=\"NumberEditor\",_.prototype.default_view=K,_.define((({Number:e})=>({step:[e,.01]})));class M extends w{_createInput(){return(0,E.input)({type:\"text\"})}}i.TimeEditorView=M,M.__name__=\"TimeEditorView\";class O extends g{}i.TimeEditor=O,c=O,O.__name__=\"TimeEditor\",c.prototype.default_view=M;class F extends w{_createInput(){return(0,E.input)({type:\"text\"})}get emptyValue(){return new Date}renderEditor(){this.inputEl.focus(),this.inputEl.select()}destroy(){super.destroy()}show(){super.show()}hide(){super.hide()}position(){return super.position()}getValue(){}setValue(e){}}i.DateEditorView=F,F.__name__=\"DateEditorView\";class L extends g{}i.DateEditor=L,h=L,L.__name__=\"DateEditor\",h.prototype.default_view=F},\n", + " 491: function _(_,n,i,t,d){t(),i.DTINDEX_NAME=\"__bkdt_internal_index__\"},\n", + " 492: function _(e,l,o,t,r){t(),o.root=\"bk-root\",o.data_table=\"bk-data-table\",o.cell_special_defaults=\"bk-cell-special-defaults\",o.cell_select=\"bk-cell-select\",o.cell_index=\"bk-cell-index\",o.header_index=\"bk-header-index\",o.cell_editor=\"bk-cell-editor\",o.cell_editor_completion=\"bk-cell-editor-completion\",o.default='.bk-root .bk-data-table{box-sizing:content-box;font-size:11px;}.bk-root .bk-data-table input[type=\"checkbox\"]{margin-left:4px;margin-right:4px;}.bk-root .bk-cell-special-defaults{border-right-color:silver;border-right-style:solid;background:#f5f5f5;}.bk-root .bk-cell-select{border-right-color:silver;border-right-style:solid;background:#f5f5f5;}.bk-root .slick-cell.bk-cell-index{border-right-color:silver;border-right-style:solid;background:#f5f5f5;text-align:right;background:#f0f0f0;color:#909090;}.bk-root .bk-header-index .slick-column-name{float:right;}.bk-root .slick-row.selected .bk-cell-index{background-color:transparent;}.bk-root .slick-row.odd{background:#f0f0f0;}.bk-root .slick-cell{padding-left:4px;padding-right:4px;border-right-color:transparent;border:0.25px solid transparent;}.bk-root .slick-cell .bk{line-height:inherit;}.bk-root .slick-cell.active{border-style:dashed;}.bk-root .slick-cell.selected{background-color:#F0F8FF;}.bk-root .slick-cell.editable{padding-left:0;padding-right:0;}.bk-root .bk-cell-editor{display:contents;}.bk-root .bk-cell-editor input,.bk-root .bk-cell-editor select{width:100%;height:100%;border:0;margin:0;padding:0;outline:0;background:transparent;vertical-align:baseline;}.bk-root .bk-cell-editor input{padding-left:4px;padding-right:4px;}.bk-root .bk-cell-editor-completion{font-size:11px;}'},\n", + " 493: function _(t,e,r,n,o){n();const a=t(1);var s,i,l,c,u,m;const _=(0,a.__importDefault)(t(151)),d=(0,a.__importStar)(t(153)),f=t(494),g=t(43),F=t(20),h=t(8),p=t(34),S=t(22),x=t(53);class b extends x.Model{constructor(t){super(t)}doFormat(t,e,r,n,o){return null==r?\"\":`${r}`.replace(/&/g,\"&\").replace(//g,\">\")}}r.CellFormatter=b,b.__name__=\"CellFormatter\";class M extends b{constructor(t){super(t)}doFormat(t,e,r,n,o){const{font_style:a,text_align:s,text_color:i}=this,l=(0,g.div)(null==r?\"\":`${r}`);switch(a){case\"bold\":l.style.fontWeight=\"bold\";break;case\"italic\":l.style.fontStyle=\"italic\"}return null!=s&&(l.style.textAlign=s),null!=i&&(l.style.color=(0,S.color2css)(i)),l.outerHTML}}r.StringFormatter=M,s=M,M.__name__=\"StringFormatter\",s.define((({Color:t,Nullable:e,String:r})=>({font_style:[F.FontStyle,\"normal\"],text_align:[F.TextAlign,\"left\"],text_color:[e(t),null],nan_format:[r,\"-\"]})));class w extends M{constructor(t){super(t)}get scientific_limit_low(){return 10**this.power_limit_low}get scientific_limit_high(){return 10**this.power_limit_high}doFormat(t,e,r,n,o){const a=Math.abs(r)<=this.scientific_limit_low||Math.abs(r)>=this.scientific_limit_high;let s=this.precision;return s<1&&(s=1),r=null==r||isNaN(r)?this.nan_format:0==r?(0,p.to_fixed)(r,1):a?r.toExponential(s):(0,p.to_fixed)(r,s),super.doFormat(t,e,r,n,o)}}r.ScientificFormatter=w,i=w,w.__name__=\"ScientificFormatter\",i.define((({Number:t})=>({precision:[t,10],power_limit_high:[t,5],power_limit_low:[t,-3]})));class C extends M{constructor(t){super(t)}doFormat(t,e,r,n,o){const{format:a,language:s,nan_format:i}=this,l=(()=>{switch(this.rounding){case\"round\":case\"nearest\":return Math.round;case\"floor\":case\"rounddown\":return Math.floor;case\"ceil\":case\"roundup\":return Math.ceil}})();return r=null==r||isNaN(r)?i:d.format(r,a,s,l),super.doFormat(t,e,r,n,o)}}r.NumberFormatter=C,l=C,C.__name__=\"NumberFormatter\",l.define((({String:t})=>({format:[t,\"0,0\"],language:[t,\"en\"],rounding:[F.RoundingFunction,\"round\"]})));class y extends b{constructor(t){super(t)}doFormat(t,e,r,n,o){return r?(0,g.i)({class:this.icon}).outerHTML:\"\"}}r.BooleanFormatter=y,c=y,y.__name__=\"BooleanFormatter\",c.define((({String:t})=>({icon:[t,\"check\"]})));class N extends M{constructor(t){super(t)}getFormat(){switch(this.format){case\"ATOM\":case\"W3C\":case\"RFC-3339\":case\"ISO-8601\":return\"%Y-%m-%d\";case\"COOKIE\":return\"%a, %d %b %Y\";case\"RFC-850\":return\"%A, %d-%b-%y\";case\"RFC-1123\":case\"RFC-2822\":return\"%a, %e %b %Y\";case\"RSS\":case\"RFC-822\":case\"RFC-1036\":return\"%a, %e %b %y\";case\"TIMESTAMP\":return;default:return this.format}}doFormat(t,e,r,n,o){const{nan_format:a}=this;let s;return s=null==(r=(0,h.isString)(r)?parseInt(r,10):r)||isNaN(r)||-9223372036854776===r?a:(0,_.default)(r,this.getFormat()),super.doFormat(t,e,s,n,o)}}r.DateFormatter=N,u=N,N.__name__=\"DateFormatter\",u.define((({String:t})=>({format:[t,\"ISO-8601\"]})));class T extends b{constructor(t){super(t)}doFormat(t,e,r,n,o){const{template:a}=this;if(null==r)return\"\";return f._.template(a)(Object.assign(Object.assign({},o),{value:r}))}}r.HTMLTemplateFormatter=T,m=T,T.__name__=\"HTMLTemplateFormatter\",m.define((({String:t})=>({template:[t,\"<%= value %>\"]})))},\n", + " 494: function _(e,n,t,f,i){var o=e(495),d=o.template;function r(e,n,t){return d(e,n,t)}r._=o,n.exports=r,\"function\"==typeof define&&define.amd?define((function(){return r})):\"undefined\"==typeof window&&\"undefined\"==typeof navigator||(window.UnderscoreTemplate=r)},\n", + " 495: function _(r,e,n,t,a){\n", " // (c) 2009-2013 Jeremy Ashkenas, DocumentCloud and Investigative Reporters & Editors\n", " // Underscore may be freely distributed under the MIT license.\n", " var u={},c=Array.prototype,o=Object.prototype,l=c.slice,i=o.toString,f=o.hasOwnProperty,s=c.forEach,p=Object.keys,_=Array.isArray,h=function(){},v=h.each=h.forEach=function(r,e,n){if(null!=r)if(s&&r.forEach===s)r.forEach(e,n);else if(r.length===+r.length){for(var t=0,a=r.length;t\":\">\",'\"':\""\",\"'\":\"'\"}},y={escape:new RegExp(\"[\"+h.keys(g.escape).join(\"\")+\"]\",\"g\")};h.each([\"escape\"],(function(r){h[r]=function(e){return null==e?\"\":(\"\"+e).replace(y[r],(function(e){return g[r][e]}))}})),h.templateSettings={evaluate:/<%([\\s\\S]+?)%>/g,interpolate:/<%=([\\s\\S]+?)%>/g,escape:/<%-([\\s\\S]+?)%>/g};var j=/(.)^/,b={\"'\":\"'\",\"\\\\\":\"\\\\\",\"\\r\":\"r\",\"\\n\":\"n\",\"\\t\":\"t\",\"\\u2028\":\"u2028\",\"\\u2029\":\"u2029\"},w=/\\\\|'|\\r|\\n|\\t|\\u2028|\\u2029/g;h.template=function(r,e,n){var t;n=h.defaults({},n,h.templateSettings);var a=new RegExp([(n.escape||j).source,(n.interpolate||j).source,(n.evaluate||j).source].join(\"|\")+\"|$\",\"g\"),u=0,c=\"__p+='\";r.replace(a,(function(e,n,t,a,o){return c+=r.slice(u,o).replace(w,(function(r){return\"\\\\\"+b[r]})),n&&(c+=\"'+\\n((__t=(\"+n+\"))==null?'':_.escape(__t))+\\n'\"),t&&(c+=\"'+\\n((__t=(\"+t+\"))==null?'':__t)+\\n'\"),a&&(c+=\"';\\n\"+a+\"\\n__p+='\"),u=o+e.length,e})),c+=\"';\\n\",n.variable||(c=\"with(obj||{}){\\n\"+c+\"}\\n\"),c=\"var __t,__p='',__j=Array.prototype.join,print=function(){__p+=__j.call(arguments,'');};\\n\"+c+\"return __p;\\n\";try{t=new Function(n.variable||\"obj\",\"_\",c)}catch(r){throw r.source=c,r}if(e)return t(e,h);var o=function(r){return t.call(this,r,h)};return o.source=\"function(\"+(n.variable||\"obj\")+\"){\\n\"+c+\"}\",o},e.exports=h},\n", - " 492: function _(e,t,i,s,o){s();const n=e(1);var l;const r=e(493),d=e(497),a=e(498),h=e(499),u=e(34),c=e(8),_=e(9),m=e(13),g=e(19),p=e(508),f=e(487),b=e(509),w=e(510),x=(0,n.__importStar)(e(488)),C=x,v=(0,n.__importDefault)(e(511));i.AutosizeModes={fit_columns:\"FCV\",fit_viewport:\"FVC\",force_fit:\"LFF\",none:\"NOA\"};let z=!1;class A{constructor(e,t){this.init(e,t)}init(e,t){if(f.DTINDEX_NAME in e.data)throw new Error(`special name ${f.DTINDEX_NAME} cannot be used as a data table column`);this.source=e,this.view=t,this.index=[...this.view.indices]}getLength(){return this.index.length}getItem(e){const t={};for(const i of(0,m.keys)(this.source.data))t[i]=this.source.data[i][this.index[e]];return t[f.DTINDEX_NAME]=this.index[e],t}getField(e,t){return t==f.DTINDEX_NAME?this.index[e]:this.source.data[t][this.index[e]]}setField(e,t,i){const s=this.index[e];this.source.patch({[t]:[[s,i]]})}getRecords(){return(0,_.range)(0,this.getLength()).map((e=>this.getItem(e)))}getItems(){return this.getRecords()}slice(e,t,i){return e=null!=e?e:0,t=null!=t?t:this.getLength(),i=null!=i?i:1,(0,_.range)(e,t,i).map((e=>this.getItem(e)))}sort(e){let t=e.map((e=>[e.sortCol.field,e.sortAsc?1:-1]));0==t.length&&(t=[[f.DTINDEX_NAME,1]]);const i=this.getRecords(),s=this.index.slice();this.index.sort(((e,o)=>{for(const[n,l]of t){const t=i[s.indexOf(e)][n],r=i[s.indexOf(o)][n];if(t!==r)return(0,c.isNumber)(t)&&(0,c.isNumber)(r)?l*(t-r||+isNaN(t)-+isNaN(r)):`${t}`>`${r}`?l:-l}return 0}))}}i.TableDataProvider=A,A.__name__=\"TableDataProvider\";class M extends p.WidgetView{constructor(){super(...arguments),this._in_selection_update=!1,this._width=null}connect_signals(){super.connect_signals(),this.connect(this.model.change,(()=>this.render())),this.connect(this.model.source.streaming,(()=>this.updateGrid())),this.connect(this.model.source.patching,(()=>this.updateGrid())),this.connect(this.model.source.change,(()=>this.updateGrid())),this.connect(this.model.source.properties.data.change,(()=>this.updateGrid())),this.connect(this.model.source.selected.change,(()=>this.updateSelection())),this.connect(this.model.source.selected.properties.indices.change,(()=>this.updateSelection()));for(const e of this.model.columns)this.connect(e.change,(()=>{this.invalidate_layout(),this.render()}))}remove(){var e;null===(e=this.grid)||void 0===e||e.destroy(),super.remove()}styles(){return[...super.styles(),v.default,x.default]}update_position(){super.update_position(),this.grid.resizeCanvas()}after_layout(){super.after_layout(),this.updateLayout(!0,!1)}box_sizing(){const e=super.box_sizing();return\"fit_viewport\"===this.model.autosize_mode&&null!=this._width&&(e.width=this._width),e}updateLayout(e,t){const s=this.autosize;s===i.AutosizeModes.fit_columns||s===i.AutosizeModes.force_fit?(e||this.grid.resizeCanvas(),this.grid.autosizeColumns()):e&&t&&s===i.AutosizeModes.fit_viewport&&this.invalidate_layout()}updateGrid(){if(this.model.view.compute_indices(),this.data.init(this.model.source,this.model.view),this.model.sortable){const e=this.grid.getColumns(),t=this.grid.getSortColumns().map((t=>({sortCol:{field:e[this.grid.getColumnIndex(t.columnId)].field},sortAsc:t.sortAsc})));this.data.sort(t)}this.grid.invalidate(),this.updateLayout(!0,!0)}updateSelection(){if(this._in_selection_update)return;const{selected:e}=this.model.source,t=e.indices.map((e=>this.data.index.indexOf(e))).sort();this._in_selection_update=!0,this.grid.setSelectedRows(t),this._in_selection_update=!1;const i=this.grid.getViewport(),s=this.model.get_scroll_index(i,t);null!=s&&this.grid.scrollRowToTop(s)}newIndexColumn(){return{id:(0,u.uniqueId)(),name:this.model.index_header,field:f.DTINDEX_NAME,width:this.model.index_width,behavior:\"select\",cannotTriggerInsert:!0,resizable:!1,selectable:!1,sortable:!0,cssClass:C.cell_index,headerCssClass:C.header_index}}css_classes(){return super.css_classes().concat(C.data_table)}get autosize(){let e;return e=!0===this.model.fit_columns?i.AutosizeModes.force_fit:!1===this.model.fit_columns?i.AutosizeModes.none:i.AutosizeModes[this.model.autosize_mode],e}render(){var e;const t=this.model.columns.filter((e=>e.visible)).map((e=>Object.assign(Object.assign({},e.toColumn()),{parent:this})));let s=null;if(\"checkbox\"==this.model.selectable&&(s=new d.CheckboxSelectColumn({cssClass:C.cell_select}),t.unshift(s.getColumnDefinition())),null!=this.model.index_position){const e=this.model.index_position,i=this.newIndexColumn();-1==e?t.push(i):e<-1?t.splice(e+1,0,i):t.splice(e,0,i)}let{reorderable:o}=this.model;!o||\"undefined\"!=typeof $&&null!=$.fn&&null!=$.fn.sortable||(z||(g.logger.warn(\"jquery-ui is required to enable DataTable.reorderable\"),z=!0),o=!1);let n=-1,l=!1;const{frozen_rows:u,frozen_columns:_}=this.model,m=null==_?-1:_-1;null!=u&&(l=u<0,n=Math.abs(u));const p={enableCellNavigation:!1!==this.model.selectable,enableColumnReorder:o,autosizeColsMode:this.autosize,multiColumnSort:this.model.sortable,editable:this.model.editable,autoEdit:this.model.auto_edit,autoHeight:!1,rowHeight:this.model.row_height,frozenColumn:m,frozenRow:n,frozenBottom:l},f=null!=this.grid;if(this.data=new A(this.model.source,this.model.view),this.grid=new h.Grid(this.el,this.data,t,p),this.autosize==i.AutosizeModes.fit_viewport){this.grid.autosizeColumns();let i=0;for(const s of t)i+=null!==(e=s.width)&&void 0!==e?e:0;this._width=Math.ceil(i)}if(this.grid.onSort.subscribe(((e,t)=>{if(!this.model.sortable)return;const i=t.sortCols;null!=i&&(this.data.sort(i),this.grid.invalidate(),this.updateSelection(),this.grid.render(),this.model.header_row||this._hide_header(),this.model.update_sort_columns(i))})),!1!==this.model.selectable){this.grid.setSelectionModel(new r.RowSelectionModel({selectActiveRow:null==s})),null!=s&&this.grid.registerPlugin(s);const e={dataItemColumnValueExtractor(e,t){let i=e[t.field];return(0,c.isString)(i)&&(i=i.replace(/\\n/g,\"\\\\n\")),i},includeHeaderWhenCopying:!1};this.grid.registerPlugin(new a.CellExternalCopyManager(e)),this.grid.onSelectedRowsChanged.subscribe(((e,t)=>{this._in_selection_update||(this.model.source.selected.indices=t.rows.map((e=>this.data.index[e])))})),this.updateSelection(),this.model.header_row||this._hide_header()}f&&this.updateLayout(f,!1)}_hide_header(){for(const e of this.el.querySelectorAll(\".slick-header-columns\"))e.style.height=\"0px\";this.grid.resizeCanvas()}}i.DataTableView=M,M.__name__=\"DataTableView\";class D extends b.TableWidget{constructor(e){super(e),this._sort_columns=[]}get sort_columns(){return this._sort_columns}update_sort_columns(e){this._sort_columns=e.map((({sortCol:e,sortAsc:t})=>({field:e.field,sortAsc:t})))}get_scroll_index(e,t){return this.scroll_to_selection&&0!=t.length?(0,_.some)(t,(t=>e.top<=t&&t<=e.bottom))?null:Math.max(0,Math.min(...t)-1):null}}i.DataTable=D,l=D,D.__name__=\"DataTable\",l.prototype.default_view=M,l.define((({Array:e,Boolean:t,Int:i,Ref:s,String:o,Enum:n,Or:l,Nullable:r})=>({autosize_mode:[n(\"fit_columns\",\"fit_viewport\",\"none\",\"force_fit\"),\"force_fit\"],auto_edit:[t,!1],columns:[e(s(w.TableColumn)),[]],fit_columns:[r(t),null],frozen_columns:[r(i),null],frozen_rows:[r(i),null],sortable:[t,!0],reorderable:[t,!0],editable:[t,!1],selectable:[l(t,n(\"checkbox\")),!0],index_position:[r(i),0],index_header:[o,\"#\"],index_width:[i,40],scroll_to_selection:[t,!0],header_row:[t,!0],row_height:[i,25]}))),l.override({width:600,height:400})},\n", - " 493: function _(e,t,n,o,r){var l=e(494),i=e(496);t.exports={RowSelectionModel:function(e){var t,n,o,r=[],c=this,u=new i.EventHandler,s={selectActiveRow:!0};function a(e){return function(){n||(n=!0,e.apply(this,arguments),n=!1)}}function f(e){for(var t=[],n=0;n=0&&rthis.getItem(e)))}getItems(){return this.getRecords()}slice(e,t,i){return e=null!=e?e:0,t=null!=t?t:this.getLength(),i=null!=i?i:1,(0,_.range)(e,t,i).map((e=>this.getItem(e)))}sort(e){let t=e.map((e=>[e.sortCol.field,e.sortAsc?1:-1]));0==t.length&&(t=[[f.DTINDEX_NAME,1]]);const i=this.getRecords(),s=this.index.slice();this.index.sort(((e,o)=>{for(const[n,l]of t){const t=i[s.indexOf(e)][n],r=i[s.indexOf(o)][n];if(t!==r)return(0,c.isNumber)(t)&&(0,c.isNumber)(r)?l*(t-r||+isNaN(t)-+isNaN(r)):`${t}`>`${r}`?l:-l}return 0}))}}i.TableDataProvider=A,A.__name__=\"TableDataProvider\";class M extends p.WidgetView{constructor(){super(...arguments),this._in_selection_update=!1,this._width=null}connect_signals(){super.connect_signals(),this.connect(this.model.change,(()=>this.render())),this.connect(this.model.source.streaming,(()=>this.updateGrid())),this.connect(this.model.source.patching,(()=>this.updateGrid())),this.connect(this.model.source.change,(()=>this.updateGrid())),this.connect(this.model.source.properties.data.change,(()=>this.updateGrid())),this.connect(this.model.source.selected.change,(()=>this.updateSelection())),this.connect(this.model.source.selected.properties.indices.change,(()=>this.updateSelection()));for(const e of this.model.columns)this.connect(e.change,(()=>{this.invalidate_layout(),this.render()}))}remove(){var e;null===(e=this.grid)||void 0===e||e.destroy(),super.remove()}styles(){return[...super.styles(),v.default,x.default]}update_position(){super.update_position(),this.grid.resizeCanvas()}after_layout(){super.after_layout(),this.updateLayout(!0,!1)}box_sizing(){const e=super.box_sizing();return\"fit_viewport\"===this.model.autosize_mode&&null!=this._width&&(e.width=this._width),e}updateLayout(e,t){const s=this.autosize;s===i.AutosizeModes.fit_columns||s===i.AutosizeModes.force_fit?(e||this.grid.resizeCanvas(),this.grid.autosizeColumns()):e&&t&&s===i.AutosizeModes.fit_viewport&&this.invalidate_layout()}updateGrid(){if(this.model.view.compute_indices(),this.data.init(this.model.source,this.model.view),this.model.sortable){const e=this.grid.getColumns(),t=this.grid.getSortColumns().map((t=>({sortCol:{field:e[this.grid.getColumnIndex(t.columnId)].field},sortAsc:t.sortAsc})));this.data.sort(t)}this.grid.invalidate(),this.updateLayout(!0,!0)}updateSelection(){if(this._in_selection_update)return;const{selected:e}=this.model.source,t=e.indices.map((e=>this.data.index.indexOf(e))).sort();this._in_selection_update=!0,this.grid.setSelectedRows(t),this._in_selection_update=!1;const i=this.grid.getViewport(),s=this.model.get_scroll_index(i,t);null!=s&&this.grid.scrollRowToTop(s)}newIndexColumn(){return{id:(0,u.uniqueId)(),name:this.model.index_header,field:f.DTINDEX_NAME,width:this.model.index_width,behavior:\"select\",cannotTriggerInsert:!0,resizable:!1,selectable:!1,sortable:!0,cssClass:C.cell_index,headerCssClass:C.header_index}}css_classes(){return super.css_classes().concat(C.data_table)}get autosize(){let e;return e=!0===this.model.fit_columns?i.AutosizeModes.force_fit:!1===this.model.fit_columns?i.AutosizeModes.none:i.AutosizeModes[this.model.autosize_mode],e}render(){var e;const t=this.model.columns.filter((e=>e.visible)).map((e=>Object.assign(Object.assign({},e.toColumn()),{parent:this})));let s=null;if(\"checkbox\"==this.model.selectable&&(s=new d.CheckboxSelectColumn({cssClass:C.cell_select}),t.unshift(s.getColumnDefinition())),null!=this.model.index_position){const e=this.model.index_position,i=this.newIndexColumn();-1==e?t.push(i):e<-1?t.splice(e+1,0,i):t.splice(e,0,i)}let{reorderable:o}=this.model;!o||\"undefined\"!=typeof $&&null!=$.fn&&null!=$.fn.sortable||(z||(g.logger.warn(\"jquery-ui is required to enable DataTable.reorderable\"),z=!0),o=!1);let n=-1,l=!1;const{frozen_rows:u,frozen_columns:_}=this.model,m=null==_?-1:_-1;null!=u&&(l=u<0,n=Math.abs(u));const p={enableCellNavigation:!1!==this.model.selectable,enableColumnReorder:o,autosizeColsMode:this.autosize,multiColumnSort:this.model.sortable,editable:this.model.editable,autoEdit:this.model.auto_edit,autoHeight:!1,rowHeight:this.model.row_height,frozenColumn:m,frozenRow:n,frozenBottom:l},f=null!=this.grid;if(this.data=new A(this.model.source,this.model.view),this.grid=new h.Grid(this.el,this.data,t,p),this.autosize==i.AutosizeModes.fit_viewport){this.grid.autosizeColumns();let i=0;for(const s of t)i+=null!==(e=s.width)&&void 0!==e?e:0;this._width=Math.ceil(i)}if(this.grid.onSort.subscribe(((e,t)=>{if(!this.model.sortable)return;const i=t.sortCols;null!=i&&(this.data.sort(i),this.grid.invalidate(),this.updateSelection(),this.grid.render(),this.model.header_row||this._hide_header(),this.model.update_sort_columns(i))})),!1!==this.model.selectable){this.grid.setSelectionModel(new r.RowSelectionModel({selectActiveRow:null==s})),null!=s&&this.grid.registerPlugin(s);const e={dataItemColumnValueExtractor(e,t){let i=e[t.field];return(0,c.isString)(i)&&(i=i.replace(/\\n/g,\"\\\\n\")),i},includeHeaderWhenCopying:!1};this.grid.registerPlugin(new a.CellExternalCopyManager(e)),this.grid.onSelectedRowsChanged.subscribe(((e,t)=>{this._in_selection_update||(this.model.source.selected.indices=t.rows.map((e=>this.data.index[e])))})),this.updateSelection(),this.model.header_row||this._hide_header()}f&&this.updateLayout(f,!1)}_hide_header(){for(const e of this.el.querySelectorAll(\".slick-header-columns\"))e.style.height=\"0px\";this.grid.resizeCanvas()}}i.DataTableView=M,M.__name__=\"DataTableView\";class D extends b.TableWidget{constructor(e){super(e),this._sort_columns=[]}get sort_columns(){return this._sort_columns}update_sort_columns(e){this._sort_columns=e.map((({sortCol:e,sortAsc:t})=>({field:e.field,sortAsc:t})))}get_scroll_index(e,t){return this.scroll_to_selection&&0!=t.length?(0,_.some)(t,(t=>e.top<=t&&t<=e.bottom))?null:Math.max(0,Math.min(...t)-1):null}}i.DataTable=D,l=D,D.__name__=\"DataTable\",l.prototype.default_view=M,l.define((({Array:e,Boolean:t,Int:i,Ref:s,String:o,Enum:n,Or:l,Nullable:r})=>({autosize_mode:[n(\"fit_columns\",\"fit_viewport\",\"none\",\"force_fit\"),\"force_fit\"],auto_edit:[t,!1],columns:[e(s(w.TableColumn)),[]],fit_columns:[r(t),null],frozen_columns:[r(i),null],frozen_rows:[r(i),null],sortable:[t,!0],reorderable:[t,!0],editable:[t,!1],selectable:[l(t,n(\"checkbox\")),!0],index_position:[r(i),0],index_header:[o,\"#\"],index_width:[i,40],scroll_to_selection:[t,!0],header_row:[t,!0],row_height:[i,25]}))),l.override({width:600,height:400})},\n", + " 497: function _(e,t,n,o,r){var l=e(498),i=e(500);t.exports={RowSelectionModel:function(e){var t,n,o,r=[],c=this,u=new i.EventHandler,s={selectActiveRow:!0};function a(e){return function(){n||(n=!0,e.apply(this,arguments),n=!1)}}function f(e){for(var t=[],n=0;n=0&&r+~]|[\\\\x20\\\\t\\\\r\\\\n\\\\f])[\\\\x20\\\\t\\\\r\\\\n\\\\f]*\"),U=new RegExp(M+\"|>\"),X=new RegExp(F),V=new RegExp(\"^\"+I+\"$\"),G={ID:new RegExp(\"^#(\"+I+\")\"),CLASS:new RegExp(\"^\\\\.(\"+I+\")\"),TAG:new RegExp(\"^(\"+I+\"|[*])\"),ATTR:new RegExp(\"^\"+W),PSEUDO:new RegExp(\"^\"+F),CHILD:new RegExp(\"^:(only|first|last|nth|nth-last)-(child|of-type)(?:\\\\([\\\\x20\\\\t\\\\r\\\\n\\\\f]*(even|odd|(([+-]|)(\\\\d*)n|)[\\\\x20\\\\t\\\\r\\\\n\\\\f]*(?:([+-]|)[\\\\x20\\\\t\\\\r\\\\n\\\\f]*(\\\\d+)|))[\\\\x20\\\\t\\\\r\\\\n\\\\f]*\\\\)|)\",\"i\"),bool:new RegExp(\"^(?:\"+R+\")$\",\"i\"),needsContext:new RegExp(\"^[\\\\x20\\\\t\\\\r\\\\n\\\\f]*[>+~]|:(even|odd|eq|gt|lt|nth|first|last)(?:\\\\([\\\\x20\\\\t\\\\r\\\\n\\\\f]*((?:-\\\\d)?\\\\d*)[\\\\x20\\\\t\\\\r\\\\n\\\\f]*\\\\)|)(?=[^-]|$)\",\"i\")},Y=/HTML$/i,Q=/^(?:input|select|textarea|button)$/i,J=/^h\\d$/i,K=/^[^{]+\\{\\s*\\[native \\w/,Z=/^(?:#([\\w-]+)|(\\w+)|\\.([\\w-]+))$/,ee=/[+~]/,te=new RegExp(\"\\\\\\\\[\\\\da-fA-F]{1,6}[\\\\x20\\\\t\\\\r\\\\n\\\\f]?|\\\\\\\\([^\\\\r\\\\n\\\\f])\",\"g\"),ne=function(e,t){var n=\"0x\"+e.slice(1)-65536;return t||(n<0?String.fromCharCode(n+65536):String.fromCharCode(n>>10|55296,1023&n|56320))},re=/([\\0-\\x1f\\x7f]|^-?\\d)|^-$|[^\\0-\\x1f\\x7f-\\uFFFF\\w-]/g,ie=function(e,t){return t?\"\\0\"===e?\"\\ufffd\":e.slice(0,-1)+\"\\\\\"+e.charCodeAt(e.length-1).toString(16)+\" \":\"\\\\\"+e},oe=function(){p()},ae=be((function(e){return!0===e.disabled&&\"fieldset\"===e.nodeName.toLowerCase()}),{dir:\"parentNode\",next:\"legend\"});try{H.apply(D=O.call(w.childNodes),w.childNodes),D[w.childNodes.length].nodeType}catch(e){H={apply:D.length?function(e,t){L.apply(e,O.call(t))}:function(e,t){for(var n=e.length,r=0;e[n++]=t[r++];);e.length=n-1}}}function se(e,t,r,i){var o,s,l,c,f,h,y,m=t&&t.ownerDocument,w=t?t.nodeType:9;if(r=r||[],\"string\"!=typeof e||!e||1!==w&&9!==w&&11!==w)return r;if(!i&&(p(t),t=t||d,g)){if(11!==w&&(f=Z.exec(e)))if(o=f[1]){if(9===w){if(!(l=t.getElementById(o)))return r;if(l.id===o)return r.push(l),r}else if(m&&(l=m.getElementById(o))&&x(t,l)&&l.id===o)return r.push(l),r}else{if(f[2])return H.apply(r,t.getElementsByTagName(e)),r;if((o=f[3])&&n.getElementsByClassName&&t.getElementsByClassName)return H.apply(r,t.getElementsByClassName(o)),r}if(n.qsa&&!A[e+\" \"]&&(!v||!v.test(e))&&(1!==w||\"object\"!==t.nodeName.toLowerCase())){if(y=e,m=t,1===w&&(U.test(e)||z.test(e))){for((m=ee.test(e)&&ye(t.parentNode)||t)===t&&n.scope||((c=t.getAttribute(\"id\"))?c=c.replace(re,ie):t.setAttribute(\"id\",c=b)),s=(h=a(e)).length;s--;)h[s]=(c?\"#\"+c:\":scope\")+\" \"+xe(h[s]);y=h.join(\",\")}try{return H.apply(r,m.querySelectorAll(y)),r}catch(t){A(e,!0)}finally{c===b&&t.removeAttribute(\"id\")}}}return u(e.replace($,\"$1\"),t,r,i)}function ue(){var e=[];return function t(n,i){return e.push(n+\" \")>r.cacheLength&&delete t[e.shift()],t[n+\" \"]=i}}function le(e){return e[b]=!0,e}function ce(e){var t=d.createElement(\"fieldset\");try{return!!e(t)}catch(e){return!1}finally{t.parentNode&&t.parentNode.removeChild(t),t=null}}function fe(e,t){for(var n=e.split(\"|\"),i=n.length;i--;)r.attrHandle[n[i]]=t}function pe(e,t){var n=t&&e,r=n&&1===e.nodeType&&1===t.nodeType&&e.sourceIndex-t.sourceIndex;if(r)return r;if(n)for(;n=n.nextSibling;)if(n===t)return-1;return e?1:-1}function de(e){return function(t){return\"input\"===t.nodeName.toLowerCase()&&t.type===e}}function he(e){return function(t){var n=t.nodeName.toLowerCase();return(\"input\"===n||\"button\"===n)&&t.type===e}}function ge(e){return function(t){return\"form\"in t?t.parentNode&&!1===t.disabled?\"label\"in t?\"label\"in t.parentNode?t.parentNode.disabled===e:t.disabled===e:t.isDisabled===e||t.isDisabled!==!e&&ae(t)===e:t.disabled===e:\"label\"in t&&t.disabled===e}}function ve(e){return le((function(t){return t=+t,le((function(n,r){for(var i,o=e([],n.length,t),a=o.length;a--;)n[i=o[a]]&&(n[i]=!(r[i]=n[i]))}))}))}function ye(e){return e&&void 0!==e.getElementsByTagName&&e}for(t in n=se.support={},o=se.isXML=function(e){var t=e&&e.namespaceURI,n=e&&(e.ownerDocument||e).documentElement;return!Y.test(t||n&&n.nodeName||\"HTML\")},p=se.setDocument=function(e){var t,i,a=e?e.ownerDocument||e:w;return a!=d&&9===a.nodeType&&a.documentElement?(h=(d=a).documentElement,g=!o(d),w!=d&&(i=d.defaultView)&&i.top!==i&&(i.addEventListener?i.addEventListener(\"unload\",oe,!1):i.attachEvent&&i.attachEvent(\"onunload\",oe)),n.scope=ce((function(e){return h.appendChild(e).appendChild(d.createElement(\"div\")),void 0!==e.querySelectorAll&&!e.querySelectorAll(\":scope fieldset div\").length})),n.attributes=ce((function(e){return e.className=\"i\",!e.getAttribute(\"className\")})),n.getElementsByTagName=ce((function(e){return e.appendChild(d.createComment(\"\")),!e.getElementsByTagName(\"*\").length})),n.getElementsByClassName=K.test(d.getElementsByClassName),n.getById=ce((function(e){return h.appendChild(e).id=b,!d.getElementsByName||!d.getElementsByName(b).length})),n.getById?(r.filter.ID=function(e){var t=e.replace(te,ne);return function(e){return e.getAttribute(\"id\")===t}},r.find.ID=function(e,t){if(void 0!==t.getElementById&&g){var n=t.getElementById(e);return n?[n]:[]}}):(r.filter.ID=function(e){var t=e.replace(te,ne);return function(e){var n=void 0!==e.getAttributeNode&&e.getAttributeNode(\"id\");return n&&n.value===t}},r.find.ID=function(e,t){if(void 0!==t.getElementById&&g){var n,r,i,o=t.getElementById(e);if(o){if((n=o.getAttributeNode(\"id\"))&&n.value===e)return[o];for(i=t.getElementsByName(e),r=0;o=i[r++];)if((n=o.getAttributeNode(\"id\"))&&n.value===e)return[o]}return[]}}),r.find.TAG=n.getElementsByTagName?function(e,t){return void 0!==t.getElementsByTagName?t.getElementsByTagName(e):n.qsa?t.querySelectorAll(e):void 0}:function(e,t){var n,r=[],i=0,o=t.getElementsByTagName(e);if(\"*\"===e){for(;n=o[i++];)1===n.nodeType&&r.push(n);return r}return o},r.find.CLASS=n.getElementsByClassName&&function(e,t){if(void 0!==t.getElementsByClassName&&g)return t.getElementsByClassName(e)},y=[],v=[],(n.qsa=K.test(d.querySelectorAll))&&(ce((function(e){var t;h.appendChild(e).innerHTML=\"\",e.querySelectorAll(\"[msallowcapture^='']\").length&&v.push(\"[*^$]=[\\\\x20\\\\t\\\\r\\\\n\\\\f]*(?:''|\\\"\\\")\"),e.querySelectorAll(\"[selected]\").length||v.push(\"\\\\[[\\\\x20\\\\t\\\\r\\\\n\\\\f]*(?:value|\"+R+\")\"),e.querySelectorAll(\"[id~=\"+b+\"-]\").length||v.push(\"~=\"),(t=d.createElement(\"input\")).setAttribute(\"name\",\"\"),e.appendChild(t),e.querySelectorAll(\"[name='']\").length||v.push(\"\\\\[[\\\\x20\\\\t\\\\r\\\\n\\\\f]*name[\\\\x20\\\\t\\\\r\\\\n\\\\f]*=[\\\\x20\\\\t\\\\r\\\\n\\\\f]*(?:''|\\\"\\\")\"),e.querySelectorAll(\":checked\").length||v.push(\":checked\"),e.querySelectorAll(\"a#\"+b+\"+*\").length||v.push(\".#.+[+~]\"),e.querySelectorAll(\"\\\\\\f\"),v.push(\"[\\\\r\\\\n\\\\f]\")})),ce((function(e){e.innerHTML=\"\";var t=d.createElement(\"input\");t.setAttribute(\"type\",\"hidden\"),e.appendChild(t).setAttribute(\"name\",\"D\"),e.querySelectorAll(\"[name=d]\").length&&v.push(\"name[\\\\x20\\\\t\\\\r\\\\n\\\\f]*[*^$|!~]?=\"),2!==e.querySelectorAll(\":enabled\").length&&v.push(\":enabled\",\":disabled\"),h.appendChild(e).disabled=!0,2!==e.querySelectorAll(\":disabled\").length&&v.push(\":enabled\",\":disabled\"),e.querySelectorAll(\"*,:x\"),v.push(\",.*:\")}))),(n.matchesSelector=K.test(m=h.matches||h.webkitMatchesSelector||h.mozMatchesSelector||h.oMatchesSelector||h.msMatchesSelector))&&ce((function(e){n.disconnectedMatch=m.call(e,\"*\"),m.call(e,\"[s!='']:x\"),y.push(\"!=\",F)})),v=v.length&&new RegExp(v.join(\"|\")),y=y.length&&new RegExp(y.join(\"|\")),t=K.test(h.compareDocumentPosition),x=t||K.test(h.contains)?function(e,t){var n=9===e.nodeType?e.documentElement:e,r=t&&t.parentNode;return e===r||!(!r||1!==r.nodeType||!(n.contains?n.contains(r):e.compareDocumentPosition&&16&e.compareDocumentPosition(r)))}:function(e,t){if(t)for(;t=t.parentNode;)if(t===e)return!0;return!1},N=t?function(e,t){if(e===t)return f=!0,0;var r=!e.compareDocumentPosition-!t.compareDocumentPosition;return r||(1&(r=(e.ownerDocument||e)==(t.ownerDocument||t)?e.compareDocumentPosition(t):1)||!n.sortDetached&&t.compareDocumentPosition(e)===r?e==d||e.ownerDocument==w&&x(w,e)?-1:t==d||t.ownerDocument==w&&x(w,t)?1:c?P(c,e)-P(c,t):0:4&r?-1:1)}:function(e,t){if(e===t)return f=!0,0;var n,r=0,i=e.parentNode,o=t.parentNode,a=[e],s=[t];if(!i||!o)return e==d?-1:t==d?1:i?-1:o?1:c?P(c,e)-P(c,t):0;if(i===o)return pe(e,t);for(n=e;n=n.parentNode;)a.unshift(n);for(n=t;n=n.parentNode;)s.unshift(n);for(;a[r]===s[r];)r++;return r?pe(a[r],s[r]):a[r]==w?-1:s[r]==w?1:0},d):d},se.matches=function(e,t){return se(e,null,null,t)},se.matchesSelector=function(e,t){if(p(e),n.matchesSelector&&g&&!A[t+\" \"]&&(!y||!y.test(t))&&(!v||!v.test(t)))try{var r=m.call(e,t);if(r||n.disconnectedMatch||e.document&&11!==e.document.nodeType)return r}catch(e){A(t,!0)}return se(t,d,null,[e]).length>0},se.contains=function(e,t){return(e.ownerDocument||e)!=d&&p(e),x(e,t)},se.attr=function(e,t){(e.ownerDocument||e)!=d&&p(e);var i=r.attrHandle[t.toLowerCase()],o=i&&j.call(r.attrHandle,t.toLowerCase())?i(e,t,!g):void 0;return void 0!==o?o:n.attributes||!g?e.getAttribute(t):(o=e.getAttributeNode(t))&&o.specified?o.value:null},se.escape=function(e){return(e+\"\").replace(re,ie)},se.error=function(e){throw new Error(\"Syntax error, unrecognized expression: \"+e)},se.uniqueSort=function(e){var t,r=[],i=0,o=0;if(f=!n.detectDuplicates,c=!n.sortStable&&e.slice(0),e.sort(N),f){for(;t=e[o++];)t===e[o]&&(i=r.push(o));for(;i--;)e.splice(r[i],1)}return c=null,e},i=se.getText=function(e){var t,n=\"\",r=0,o=e.nodeType;if(o){if(1===o||9===o||11===o){if(\"string\"==typeof e.textContent)return e.textContent;for(e=e.firstChild;e;e=e.nextSibling)n+=i(e)}else if(3===o||4===o)return e.nodeValue}else for(;t=e[r++];)n+=i(t);return n},r=se.selectors={cacheLength:50,createPseudo:le,match:G,attrHandle:{},find:{},relative:{\">\":{dir:\"parentNode\",first:!0},\" \":{dir:\"parentNode\"},\"+\":{dir:\"previousSibling\",first:!0},\"~\":{dir:\"previousSibling\"}},preFilter:{ATTR:function(e){return e[1]=e[1].replace(te,ne),e[3]=(e[3]||e[4]||e[5]||\"\").replace(te,ne),\"~=\"===e[2]&&(e[3]=\" \"+e[3]+\" \"),e.slice(0,4)},CHILD:function(e){return e[1]=e[1].toLowerCase(),\"nth\"===e[1].slice(0,3)?(e[3]||se.error(e[0]),e[4]=+(e[4]?e[5]+(e[6]||1):2*(\"even\"===e[3]||\"odd\"===e[3])),e[5]=+(e[7]+e[8]||\"odd\"===e[3])):e[3]&&se.error(e[0]),e},PSEUDO:function(e){var t,n=!e[6]&&e[2];return G.CHILD.test(e[0])?null:(e[3]?e[2]=e[4]||e[5]||\"\":n&&X.test(n)&&(t=a(n,!0))&&(t=n.indexOf(\")\",n.length-t)-n.length)&&(e[0]=e[0].slice(0,t),e[2]=n.slice(0,t)),e.slice(0,3))}},filter:{TAG:function(e){var t=e.replace(te,ne).toLowerCase();return\"*\"===e?function(){return!0}:function(e){return e.nodeName&&e.nodeName.toLowerCase()===t}},CLASS:function(e){var t=E[e+\" \"];return t||(t=new RegExp(\"(^|[\\\\x20\\\\t\\\\r\\\\n\\\\f])\"+e+\"(\"+M+\"|$)\"))&&E(e,(function(e){return t.test(\"string\"==typeof e.className&&e.className||void 0!==e.getAttribute&&e.getAttribute(\"class\")||\"\")}))},ATTR:function(e,t,n){return function(r){var i=se.attr(r,e);return null==i?\"!=\"===t:!t||(i+=\"\",\"=\"===t?i===n:\"!=\"===t?i!==n:\"^=\"===t?n&&0===i.indexOf(n):\"*=\"===t?n&&i.indexOf(n)>-1:\"$=\"===t?n&&i.slice(-n.length)===n:\"~=\"===t?(\" \"+i.replace(B,\" \")+\" \").indexOf(n)>-1:\"|=\"===t&&(i===n||i.slice(0,n.length+1)===n+\"-\"))}},CHILD:function(e,t,n,r,i){var o=\"nth\"!==e.slice(0,3),a=\"last\"!==e.slice(-4),s=\"of-type\"===t;return 1===r&&0===i?function(e){return!!e.parentNode}:function(t,n,u){var l,c,f,p,d,h,g=o!==a?\"nextSibling\":\"previousSibling\",v=t.parentNode,y=s&&t.nodeName.toLowerCase(),m=!u&&!s,x=!1;if(v){if(o){for(;g;){for(p=t;p=p[g];)if(s?p.nodeName.toLowerCase()===y:1===p.nodeType)return!1;h=g=\"only\"===e&&!h&&\"nextSibling\"}return!0}if(h=[a?v.firstChild:v.lastChild],a&&m){for(x=(d=(l=(c=(f=(p=v)[b]||(p[b]={}))[p.uniqueID]||(f[p.uniqueID]={}))[e]||[])[0]===T&&l[1])&&l[2],p=d&&v.childNodes[d];p=++d&&p&&p[g]||(x=d=0)||h.pop();)if(1===p.nodeType&&++x&&p===t){c[e]=[T,d,x];break}}else if(m&&(x=d=(l=(c=(f=(p=t)[b]||(p[b]={}))[p.uniqueID]||(f[p.uniqueID]={}))[e]||[])[0]===T&&l[1]),!1===x)for(;(p=++d&&p&&p[g]||(x=d=0)||h.pop())&&((s?p.nodeName.toLowerCase()!==y:1!==p.nodeType)||!++x||(m&&((c=(f=p[b]||(p[b]={}))[p.uniqueID]||(f[p.uniqueID]={}))[e]=[T,x]),p!==t)););return(x-=i)===r||x%r==0&&x/r>=0}}},PSEUDO:function(e,t){var n,i=r.pseudos[e]||r.setFilters[e.toLowerCase()]||se.error(\"unsupported pseudo: \"+e);return i[b]?i(t):i.length>1?(n=[e,e,\"\",t],r.setFilters.hasOwnProperty(e.toLowerCase())?le((function(e,n){for(var r,o=i(e,t),a=o.length;a--;)e[r=P(e,o[a])]=!(n[r]=o[a])})):function(e){return i(e,0,n)}):i}},pseudos:{not:le((function(e){var t=[],n=[],r=s(e.replace($,\"$1\"));return r[b]?le((function(e,t,n,i){for(var o,a=r(e,null,i,[]),s=e.length;s--;)(o=a[s])&&(e[s]=!(t[s]=o))})):function(e,i,o){return t[0]=e,r(t,null,o,n),t[0]=null,!n.pop()}})),has:le((function(e){return function(t){return se(e,t).length>0}})),contains:le((function(e){return e=e.replace(te,ne),function(t){return(t.textContent||i(t)).indexOf(e)>-1}})),lang:le((function(e){return V.test(e||\"\")||se.error(\"unsupported lang: \"+e),e=e.replace(te,ne).toLowerCase(),function(t){var n;do{if(n=g?t.lang:t.getAttribute(\"xml:lang\")||t.getAttribute(\"lang\"))return(n=n.toLowerCase())===e||0===n.indexOf(e+\"-\")}while((t=t.parentNode)&&1===t.nodeType);return!1}})),target:function(t){var n=e.location&&e.location.hash;return n&&n.slice(1)===t.id},root:function(e){return e===h},focus:function(e){return e===d.activeElement&&(!d.hasFocus||d.hasFocus())&&!!(e.type||e.href||~e.tabIndex)},enabled:ge(!1),disabled:ge(!0),checked:function(e){var t=e.nodeName.toLowerCase();return\"input\"===t&&!!e.checked||\"option\"===t&&!!e.selected},selected:function(e){return e.parentNode&&e.parentNode.selectedIndex,!0===e.selected},empty:function(e){for(e=e.firstChild;e;e=e.nextSibling)if(e.nodeType<6)return!1;return!0},parent:function(e){return!r.pseudos.empty(e)},header:function(e){return J.test(e.nodeName)},input:function(e){return Q.test(e.nodeName)},button:function(e){var t=e.nodeName.toLowerCase();return\"input\"===t&&\"button\"===e.type||\"button\"===t},text:function(e){var t;return\"input\"===e.nodeName.toLowerCase()&&\"text\"===e.type&&(null==(t=e.getAttribute(\"type\"))||\"text\"===t.toLowerCase())},first:ve((function(){return[0]})),last:ve((function(e,t){return[t-1]})),eq:ve((function(e,t,n){return[n<0?n+t:n]})),even:ve((function(e,t){for(var n=0;nt?t:n;--r>=0;)e.push(r);return e})),gt:ve((function(e,t,n){for(var r=n<0?n+t:n;++r1?function(t,n,r){for(var i=e.length;i--;)if(!e[i](t,n,r))return!1;return!0}:e[0]}function Te(e,t,n,r,i){for(var o,a=[],s=0,u=e.length,l=null!=t;s-1&&(o[l]=!(a[l]=f))}}else y=Te(y===a?y.splice(h,y.length):y),i?i(null,a,y,u):H.apply(a,y)}))}function Ee(e){for(var t,n,i,o=e.length,a=r.relative[e[0].type],s=a||r.relative[\" \"],u=a?1:0,c=be((function(e){return e===t}),s,!0),f=be((function(e){return P(t,e)>-1}),s,!0),p=[function(e,n,r){var i=!a&&(r||n!==l)||((t=n).nodeType?c(e,n,r):f(e,n,r));return t=null,i}];u1&&we(p),u>1&&xe(e.slice(0,u-1).concat({value:\" \"===e[u-2].type?\"*\":\"\"})).replace($,\"$1\"),n,u0,i=e.length>0,o=function(o,a,s,u,c){var f,h,v,y=0,m=\"0\",x=o&&[],b=[],w=l,C=o||i&&r.find.TAG(\"*\",c),E=T+=null==w?1:Math.random()||.1,S=C.length;for(c&&(l=a==d||a||c);m!==S&&null!=(f=C[m]);m++){if(i&&f){for(h=0,a||f.ownerDocument==d||(p(f),s=!g);v=e[h++];)if(v(f,a||d,s)){u.push(f);break}c&&(T=E)}n&&((f=!v&&f)&&y--,o&&x.push(f))}if(y+=m,n&&m!==y){for(h=0;v=t[h++];)v(x,b,a,s);if(o){if(y>0)for(;m--;)x[m]||b[m]||(b[m]=q.call(u));b=Te(b)}H.apply(u,b),c&&!o&&b.length>0&&y+t.length>1&&se.uniqueSort(u)}return c&&(T=E,l=w),x};return n?le(o):o}(o,i)),s.selector=e}return s},u=se.select=function(e,t,n,i){var o,u,l,c,f,p=\"function\"==typeof e&&e,d=!i&&a(e=p.selector||e);if(n=n||[],1===d.length){if((u=d[0]=d[0].slice(0)).length>2&&\"ID\"===(l=u[0]).type&&9===t.nodeType&&g&&r.relative[u[1].type]){if(!(t=(r.find.ID(l.matches[0].replace(te,ne),t)||[])[0]))return n;p&&(t=t.parentNode),e=e.slice(u.shift().value.length)}for(o=G.needsContext.test(e)?0:u.length;o--&&(l=u[o],!r.relative[c=l.type]);)if((f=r.find[c])&&(i=f(l.matches[0].replace(te,ne),ee.test(u[0].type)&&ye(t.parentNode)||t))){if(u.splice(o,1),!(e=i.length&&xe(u)))return H.apply(n,i),n;break}}return(p||s(e,d))(i,t,!g,n,!t||ee.test(e)&&ye(t.parentNode)||t),n},n.sortStable=b.split(\"\").sort(N).join(\"\")===b,n.detectDuplicates=!!f,p(),n.sortDetached=ce((function(e){return 1&e.compareDocumentPosition(d.createElement(\"fieldset\"))})),ce((function(e){return e.innerHTML=\"\",\"#\"===e.firstChild.getAttribute(\"href\")}))||fe(\"type|href|height|width\",(function(e,t,n){if(!n)return e.getAttribute(t,\"type\"===t.toLowerCase()?1:2)})),n.attributes&&ce((function(e){return e.innerHTML=\"\",e.firstChild.setAttribute(\"value\",\"\"),\"\"===e.firstChild.getAttribute(\"value\")}))||fe(\"value\",(function(e,t,n){if(!n&&\"input\"===e.nodeName.toLowerCase())return e.defaultValue})),ce((function(e){return null==e.getAttribute(\"disabled\")}))||fe(R,(function(e,t,n){var r;if(!n)return!0===e[t]?t.toLowerCase():(r=e.getAttributeNode(t))&&r.specified?r.value:null})),se}(e);w.find=C,w.expr=C.selectors,w.expr[\":\"]=w.expr.pseudos,w.uniqueSort=w.unique=C.uniqueSort,w.text=C.getText,w.isXMLDoc=C.isXML,w.contains=C.contains,w.escapeSelector=C.escape;var E=function(e,t,n){for(var r=[],i=void 0!==n;(e=e[t])&&9!==e.nodeType;)if(1===e.nodeType){if(i&&w(e).is(n))break;r.push(e)}return r},S=function(e,t){for(var n=[];e;e=e.nextSibling)1===e.nodeType&&e!==t&&n.push(e);return n},k=w.expr.match.needsContext;function A(e,t){return e.nodeName&&e.nodeName.toLowerCase()===t.toLowerCase()}var N=/^<([a-z][^\\/\\0>:\\x20\\t\\r\\n\\f]*)[\\x20\\t\\r\\n\\f]*\\/?>(?:<\\/\\1>|)$/i;function j(e,t,n){return h(t)?w.grep(e,(function(e,r){return!!t.call(e,r,e)!==n})):t.nodeType?w.grep(e,(function(e){return e===t!==n})):\"string\"!=typeof t?w.grep(e,(function(e){return s.call(t,e)>-1!==n})):w.filter(t,e,n)}w.filter=function(e,t,n){var r=t[0];return n&&(e=\":not(\"+e+\")\"),1===t.length&&1===r.nodeType?w.find.matchesSelector(r,e)?[r]:[]:w.find.matches(e,w.grep(t,(function(e){return 1===e.nodeType})))},w.fn.extend({find:function(e){var t,n,r=this.length,i=this;if(\"string\"!=typeof e)return this.pushStack(w(e).filter((function(){for(t=0;t1?w.uniqueSort(n):n},filter:function(e){return this.pushStack(j(this,e||[],!1))},not:function(e){return this.pushStack(j(this,e||[],!0))},is:function(e){return!!j(this,\"string\"==typeof e&&k.test(e)?w(e):e||[],!1).length}});var D,q=/^(?:\\s*(<[\\w\\W]+>)[^>]*|#([\\w-]+))$/;(w.fn.init=function(e,t,n){var r,i;if(!e)return this;if(n=n||D,\"string\"==typeof e){if(!(r=\"<\"===e[0]&&\">\"===e[e.length-1]&&e.length>=3?[null,e,null]:q.exec(e))||!r[1]&&t)return!t||t.jquery?(t||n).find(e):this.constructor(t).find(e);if(r[1]){if(t=t instanceof w?t[0]:t,w.merge(this,w.parseHTML(r[1],t&&t.nodeType?t.ownerDocument||t:v,!0)),N.test(r[1])&&w.isPlainObject(t))for(r in t)h(this[r])?this[r](t[r]):this.attr(r,t[r]);return this}return(i=v.getElementById(r[2]))&&(this[0]=i,this.length=1),this}return e.nodeType?(this[0]=e,this.length=1,this):h(e)?void 0!==n.ready?n.ready(e):e(w):w.makeArray(e,this)}).prototype=w.fn,D=w(v);var L=/^(?:parents|prev(?:Until|All))/,H={children:!0,contents:!0,next:!0,prev:!0};function O(e,t){for(;(e=e[t])&&1!==e.nodeType;);return e}w.fn.extend({has:function(e){var t=w(e,this),n=t.length;return this.filter((function(){for(var e=0;e-1:1===n.nodeType&&w.find.matchesSelector(n,e))){o.push(n);break}return this.pushStack(o.length>1?w.uniqueSort(o):o)},index:function(e){return e?\"string\"==typeof e?s.call(w(e),this[0]):s.call(this,e.jquery?e[0]:e):this[0]&&this[0].parentNode?this.first().prevAll().length:-1},add:function(e,t){return this.pushStack(w.uniqueSort(w.merge(this.get(),w(e,t))))},addBack:function(e){return this.add(null==e?this.prevObject:this.prevObject.filter(e))}}),w.each({parent:function(e){var t=e.parentNode;return t&&11!==t.nodeType?t:null},parents:function(e){return E(e,\"parentNode\")},parentsUntil:function(e,t,n){return E(e,\"parentNode\",n)},next:function(e){return O(e,\"nextSibling\")},prev:function(e){return O(e,\"previousSibling\")},nextAll:function(e){return E(e,\"nextSibling\")},prevAll:function(e){return E(e,\"previousSibling\")},nextUntil:function(e,t,n){return E(e,\"nextSibling\",n)},prevUntil:function(e,t,n){return E(e,\"previousSibling\",n)},siblings:function(e){return S((e.parentNode||{}).firstChild,e)},children:function(e){return S(e.firstChild)},contents:function(e){return null!=e.contentDocument&&r(e.contentDocument)?e.contentDocument:(A(e,\"template\")&&(e=e.content||e),w.merge([],e.childNodes))}},(function(e,t){w.fn[e]=function(n,r){var i=w.map(this,t,n);return\"Until\"!==e.slice(-5)&&(r=n),r&&\"string\"==typeof r&&(i=w.filter(r,i)),this.length>1&&(H[e]||w.uniqueSort(i),L.test(e)&&i.reverse()),this.pushStack(i)}}));var P=/[^\\x20\\t\\r\\n\\f]+/g;function R(e){return e}function M(e){throw e}function I(e,t,n,r){var i;try{e&&h(i=e.promise)?i.call(e).done(t).fail(n):e&&h(i=e.then)?i.call(e,t,n):t.apply(void 0,[e].slice(r))}catch(e){n.apply(void 0,[e])}}w.Callbacks=function(e){e=\"string\"==typeof e?function(e){var t={};return w.each(e.match(P)||[],(function(e,n){t[n]=!0})),t}(e):w.extend({},e);var t,n,r,i,o=[],a=[],s=-1,u=function(){for(i=i||e.once,r=t=!0;a.length;s=-1)for(n=a.shift();++s-1;)o.splice(n,1),n<=s&&s--})),this},has:function(e){return e?w.inArray(e,o)>-1:o.length>0},empty:function(){return o&&(o=[]),this},disable:function(){return i=a=[],o=n=\"\",this},disabled:function(){return!o},lock:function(){return i=a=[],n||t||(o=n=\"\"),this},locked:function(){return!!i},fireWith:function(e,n){return i||(n=[e,(n=n||[]).slice?n.slice():n],a.push(n),t||u()),this},fire:function(){return l.fireWith(this,arguments),this},fired:function(){return!!r}};return l},w.extend({Deferred:function(t){var n=[[\"notify\",\"progress\",w.Callbacks(\"memory\"),w.Callbacks(\"memory\"),2],[\"resolve\",\"done\",w.Callbacks(\"once memory\"),w.Callbacks(\"once memory\"),0,\"resolved\"],[\"reject\",\"fail\",w.Callbacks(\"once memory\"),w.Callbacks(\"once memory\"),1,\"rejected\"]],r=\"pending\",i={state:function(){return r},always:function(){return o.done(arguments).fail(arguments),this},catch:function(e){return i.then(null,e)},pipe:function(){var e=arguments;return w.Deferred((function(t){w.each(n,(function(n,r){var i=h(e[r[4]])&&e[r[4]];o[r[1]]((function(){var e=i&&i.apply(this,arguments);e&&h(e.promise)?e.promise().progress(t.notify).done(t.resolve).fail(t.reject):t[r[0]+\"With\"](this,i?[e]:arguments)}))})),e=null})).promise()},then:function(t,r,i){var o=0;function a(t,n,r,i){return function(){var s=this,u=arguments,l=function(){var e,l;if(!(t=o&&(r!==M&&(s=void 0,u=[e]),n.rejectWith(s,u))}};t?c():(w.Deferred.getStackHook&&(c.stackTrace=w.Deferred.getStackHook()),e.setTimeout(c))}}return w.Deferred((function(e){n[0][3].add(a(0,e,h(i)?i:R,e.notifyWith)),n[1][3].add(a(0,e,h(t)?t:R)),n[2][3].add(a(0,e,h(r)?r:M))})).promise()},promise:function(e){return null!=e?w.extend(e,i):i}},o={};return w.each(n,(function(e,t){var a=t[2],s=t[5];i[t[1]]=a.add,s&&a.add((function(){r=s}),n[3-e][2].disable,n[3-e][3].disable,n[0][2].lock,n[0][3].lock),a.add(t[3].fire),o[t[0]]=function(){return o[t[0]+\"With\"](this===o?void 0:this,arguments),this},o[t[0]+\"With\"]=a.fireWith})),i.promise(o),t&&t.call(o,o),o},when:function(e){var t=arguments.length,n=t,r=Array(n),o=i.call(arguments),a=w.Deferred(),s=function(e){return function(n){r[e]=this,o[e]=arguments.length>1?i.call(arguments):n,--t||a.resolveWith(r,o)}};if(t<=1&&(I(e,a.done(s(n)).resolve,a.reject,!t),\"pending\"===a.state()||h(o[n]&&o[n].then)))return a.then();for(;n--;)I(o[n],s(n),a.reject);return a.promise()}});var W=/^(Eval|Internal|Range|Reference|Syntax|Type|URI)Error$/;w.Deferred.exceptionHook=function(t,n){e.console&&e.console.warn&&t&&W.test(t.name)&&e.console.warn(\"jQuery.Deferred exception: \"+t.message,t.stack,n)},w.readyException=function(t){e.setTimeout((function(){throw t}))};var F=w.Deferred();function B(){v.removeEventListener(\"DOMContentLoaded\",B),e.removeEventListener(\"load\",B),w.ready()}w.fn.ready=function(e){return F.then(e).catch((function(e){w.readyException(e)})),this},w.extend({isReady:!1,readyWait:1,ready:function(e){(!0===e?--w.readyWait:w.isReady)||(w.isReady=!0,!0!==e&&--w.readyWait>0||F.resolveWith(v,[w]))}}),w.ready.then=F.then,\"complete\"===v.readyState||\"loading\"!==v.readyState&&!v.documentElement.doScroll?e.setTimeout(w.ready):(v.addEventListener(\"DOMContentLoaded\",B),e.addEventListener(\"load\",B));var $=function(e,t,n,r,i,o,a){var s=0,u=e.length,l=null==n;if(\"object\"===x(n))for(s in i=!0,n)$(e,t,s,n[s],!0,o,a);else if(void 0!==r&&(i=!0,h(r)||(a=!0),l&&(a?(t.call(e,r),t=null):(l=t,t=function(e,t,n){return l.call(w(e),n)})),t))for(;s1,null,!0)},removeData:function(e){return this.each((function(){Q.remove(this,e)}))}}),w.extend({queue:function(e,t,n){var r;if(e)return t=(t||\"fx\")+\"queue\",r=Y.get(e,t),n&&(!r||Array.isArray(n)?r=Y.access(e,t,w.makeArray(n)):r.push(n)),r||[]},dequeue:function(e,t){t=t||\"fx\";var n=w.queue(e,t),r=n.length,i=n.shift(),o=w._queueHooks(e,t);\"inprogress\"===i&&(i=n.shift(),r--),i&&(\"fx\"===t&&n.unshift(\"inprogress\"),delete o.stop,i.call(e,(function(){w.dequeue(e,t)}),o)),!r&&o&&o.empty.fire()},_queueHooks:function(e,t){var n=t+\"queueHooks\";return Y.get(e,n)||Y.access(e,n,{empty:w.Callbacks(\"once memory\").add((function(){Y.remove(e,[t+\"queue\",n])}))})}}),w.fn.extend({queue:function(e,t){var n=2;return\"string\"!=typeof e&&(t=e,e=\"fx\",n--),arguments.length\\x20\\t\\r\\n\\f]*)/i,ge=/^$|^module$|\\/(?:java|ecma)script/i;fe=v.createDocumentFragment().appendChild(v.createElement(\"div\")),(pe=v.createElement(\"input\")).setAttribute(\"type\",\"radio\"),pe.setAttribute(\"checked\",\"checked\"),pe.setAttribute(\"name\",\"t\"),fe.appendChild(pe),d.checkClone=fe.cloneNode(!0).cloneNode(!0).lastChild.checked,fe.innerHTML=\"\",d.noCloneChecked=!!fe.cloneNode(!0).lastChild.defaultValue,fe.innerHTML=\"\",d.option=!!fe.lastChild;var ve={thead:[1,\"\",\"
\"],col:[2,\"\",\"
\"],tr:[2,\"\",\"
\"],td:[3,\"\",\"
\"],_default:[0,\"\",\"\"]};function ye(e,t){var n;return n=void 0!==e.getElementsByTagName?e.getElementsByTagName(t||\"*\"):void 0!==e.querySelectorAll?e.querySelectorAll(t||\"*\"):[],void 0===t||t&&A(e,t)?w.merge([e],n):n}function me(e,t){for(var n=0,r=e.length;n\",\"\"]);var xe=/<|&#?\\w+;/;function be(e,t,n,r,i){for(var o,a,s,u,l,c,f=t.createDocumentFragment(),p=[],d=0,h=e.length;d-1)i&&i.push(o);else if(l=ie(o),a=ye(f.appendChild(o),\"script\"),l&&me(a),n)for(c=0;o=a[c++];)ge.test(o.type||\"\")&&n.push(o);return f}var we=/^([^.]*)(?:\\.(.+)|)/;function Te(){return!0}function Ce(){return!1}function Ee(e,t){return e===function(){try{return v.activeElement}catch(e){}}()==(\"focus\"===t)}function Se(e,t,n,r,i,o){var a,s;if(\"object\"==typeof t){for(s in\"string\"!=typeof n&&(r=r||n,n=void 0),t)Se(e,s,n,r,t[s],o);return e}if(null==r&&null==i?(i=n,r=n=void 0):null==i&&(\"string\"==typeof n?(i=r,r=void 0):(i=r,r=n,n=void 0)),!1===i)i=Ce;else if(!i)return e;return 1===o&&(a=i,i=function(e){return w().off(e),a.apply(this,arguments)},i.guid=a.guid||(a.guid=w.guid++)),e.each((function(){w.event.add(this,t,i,r,n)}))}function ke(e,t,n){n?(Y.set(e,t,!1),w.event.add(e,t,{namespace:!1,handler:function(e){var r,o,a=Y.get(this,t);if(1&e.isTrigger&&this[t]){if(a.length)(w.event.special[t]||{}).delegateType&&e.stopPropagation();else if(a=i.call(arguments),Y.set(this,t,a),r=n(this,t),this[t](),a!==(o=Y.get(this,t))||r?Y.set(this,t,!1):o={},a!==o)return e.stopImmediatePropagation(),e.preventDefault(),o&&o.value}else a.length&&(Y.set(this,t,{value:w.event.trigger(w.extend(a[0],w.Event.prototype),a.slice(1),this)}),e.stopImmediatePropagation())}})):void 0===Y.get(e,t)&&w.event.add(e,t,Te)}w.event={global:{},add:function(e,t,n,r,i){var o,a,s,u,l,c,f,p,d,h,g,v=Y.get(e);if(V(e))for(n.handler&&(n=(o=n).handler,i=o.selector),i&&w.find.matchesSelector(re,i),n.guid||(n.guid=w.guid++),(u=v.events)||(u=v.events=Object.create(null)),(a=v.handle)||(a=v.handle=function(t){return void 0!==w&&w.event.triggered!==t.type?w.event.dispatch.apply(e,arguments):void 0}),l=(t=(t||\"\").match(P)||[\"\"]).length;l--;)d=g=(s=we.exec(t[l])||[])[1],h=(s[2]||\"\").split(\".\").sort(),d&&(f=w.event.special[d]||{},d=(i?f.delegateType:f.bindType)||d,f=w.event.special[d]||{},c=w.extend({type:d,origType:g,data:r,handler:n,guid:n.guid,selector:i,needsContext:i&&w.expr.match.needsContext.test(i),namespace:h.join(\".\")},o),(p=u[d])||((p=u[d]=[]).delegateCount=0,f.setup&&!1!==f.setup.call(e,r,h,a)||e.addEventListener&&e.addEventListener(d,a)),f.add&&(f.add.call(e,c),c.handler.guid||(c.handler.guid=n.guid)),i?p.splice(p.delegateCount++,0,c):p.push(c),w.event.global[d]=!0)},remove:function(e,t,n,r,i){var o,a,s,u,l,c,f,p,d,h,g,v=Y.hasData(e)&&Y.get(e);if(v&&(u=v.events)){for(l=(t=(t||\"\").match(P)||[\"\"]).length;l--;)if(d=g=(s=we.exec(t[l])||[])[1],h=(s[2]||\"\").split(\".\").sort(),d){for(f=w.event.special[d]||{},p=u[d=(r?f.delegateType:f.bindType)||d]||[],s=s[2]&&new RegExp(\"(^|\\\\.)\"+h.join(\"\\\\.(?:.*\\\\.|)\")+\"(\\\\.|$)\"),a=o=p.length;o--;)c=p[o],!i&&g!==c.origType||n&&n.guid!==c.guid||s&&!s.test(c.namespace)||r&&r!==c.selector&&(\"**\"!==r||!c.selector)||(p.splice(o,1),c.selector&&p.delegateCount--,f.remove&&f.remove.call(e,c));a&&!p.length&&(f.teardown&&!1!==f.teardown.call(e,h,v.handle)||w.removeEvent(e,d,v.handle),delete u[d])}else for(d in u)w.event.remove(e,d+t[l],n,r,!0);w.isEmptyObject(u)&&Y.remove(e,\"handle events\")}},dispatch:function(e){var t,n,r,i,o,a,s=new Array(arguments.length),u=w.event.fix(e),l=(Y.get(this,\"events\")||Object.create(null))[u.type]||[],c=w.event.special[u.type]||{};for(s[0]=u,t=1;t=1))for(;l!==this;l=l.parentNode||this)if(1===l.nodeType&&(\"click\"!==e.type||!0!==l.disabled)){for(o=[],a={},n=0;n-1:w.find(i,this,null,[l]).length),a[i]&&o.push(r);o.length&&s.push({elem:l,handlers:o})}return l=this,u\\s*$/g;function De(e,t){return A(e,\"table\")&&A(11!==t.nodeType?t:t.firstChild,\"tr\")&&w(e).children(\"tbody\")[0]||e}function qe(e){return e.type=(null!==e.getAttribute(\"type\"))+\"/\"+e.type,e}function Le(e){return\"true/\"===(e.type||\"\").slice(0,5)?e.type=e.type.slice(5):e.removeAttribute(\"type\"),e}function He(e,t){var n,r,i,o,a,s;if(1===t.nodeType){if(Y.hasData(e)&&(s=Y.get(e).events))for(i in Y.remove(t,\"handle events\"),s)for(n=0,r=s[i].length;n1&&\"string\"==typeof v&&!d.checkClone&&Ne.test(v))return e.each((function(i){var o=e.eq(i);y&&(t[0]=v.call(this,i,o.html())),Pe(o,t,n,r)}));if(p&&(a=(i=be(t,e[0].ownerDocument,!1,e,r)).firstChild,1===i.childNodes.length&&(i=a),a||r)){for(u=(s=w.map(ye(i,\"script\"),qe)).length;f0&&me(a,!u&&ye(e,\"script\")),s},cleanData:function(e){for(var t,n,r,i=w.event.special,o=0;void 0!==(n=e[o]);o++)if(V(n)){if(t=n[Y.expando]){if(t.events)for(r in t.events)i[r]?w.event.remove(n,r):w.removeEvent(n,r,t.handle);n[Y.expando]=void 0}n[Q.expando]&&(n[Q.expando]=void 0)}}}),w.fn.extend({detach:function(e){return Re(this,e,!0)},remove:function(e){return Re(this,e)},text:function(e){return $(this,(function(e){return void 0===e?w.text(this):this.empty().each((function(){1!==this.nodeType&&11!==this.nodeType&&9!==this.nodeType||(this.textContent=e)}))}),null,e,arguments.length)},append:function(){return Pe(this,arguments,(function(e){1!==this.nodeType&&11!==this.nodeType&&9!==this.nodeType||De(this,e).appendChild(e)}))},prepend:function(){return Pe(this,arguments,(function(e){if(1===this.nodeType||11===this.nodeType||9===this.nodeType){var t=De(this,e);t.insertBefore(e,t.firstChild)}}))},before:function(){return Pe(this,arguments,(function(e){this.parentNode&&this.parentNode.insertBefore(e,this)}))},after:function(){return Pe(this,arguments,(function(e){this.parentNode&&this.parentNode.insertBefore(e,this.nextSibling)}))},empty:function(){for(var e,t=0;null!=(e=this[t]);t++)1===e.nodeType&&(w.cleanData(ye(e,!1)),e.textContent=\"\");return this},clone:function(e,t){return e=null!=e&&e,t=null==t?e:t,this.map((function(){return w.clone(this,e,t)}))},html:function(e){return $(this,(function(e){var t=this[0]||{},n=0,r=this.length;if(void 0===e&&1===t.nodeType)return t.innerHTML;if(\"string\"==typeof e&&!Ae.test(e)&&!ve[(he.exec(e)||[\"\",\"\"])[1].toLowerCase()]){e=w.htmlPrefilter(e);try{for(;n=0&&(u+=Math.max(0,Math.ceil(e[\"offset\"+t[0].toUpperCase()+t.slice(1)]-o-u-s-.5))||0),u}function Ze(e,t,n){var r=Ie(e),i=(!d.boxSizingReliable()||n)&&\"border-box\"===w.css(e,\"boxSizing\",!1,r),o=i,a=Be(e,t,r),s=\"offset\"+t[0].toUpperCase()+t.slice(1);if(Me.test(a)){if(!n)return a;a=\"auto\"}return(!d.boxSizingReliable()&&i||!d.reliableTrDimensions()&&A(e,\"tr\")||\"auto\"===a||!parseFloat(a)&&\"inline\"===w.css(e,\"display\",!1,r))&&e.getClientRects().length&&(i=\"border-box\"===w.css(e,\"boxSizing\",!1,r),(o=s in e)&&(a=e[s])),(a=parseFloat(a)||0)+Ke(e,t,n||(i?\"border\":\"content\"),o,r,a)+\"px\"}function et(e,t,n,r,i){return new et.prototype.init(e,t,n,r,i)}w.extend({cssHooks:{opacity:{get:function(e,t){if(t){var n=Be(e,\"opacity\");return\"\"===n?\"1\":n}}}},cssNumber:{animationIterationCount:!0,columnCount:!0,fillOpacity:!0,flexGrow:!0,flexShrink:!0,fontWeight:!0,gridArea:!0,gridColumn:!0,gridColumnEnd:!0,gridColumnStart:!0,gridRow:!0,gridRowEnd:!0,gridRowStart:!0,lineHeight:!0,opacity:!0,order:!0,orphans:!0,widows:!0,zIndex:!0,zoom:!0},cssProps:{},style:function(e,t,n,r){if(e&&3!==e.nodeType&&8!==e.nodeType&&e.style){var i,o,a,s=X(t),u=Ge.test(t),l=e.style;if(u||(t=Xe(s)),a=w.cssHooks[t]||w.cssHooks[s],void 0===n)return a&&\"get\"in a&&void 0!==(i=a.get(e,!1,r))?i:l[t];\"string\"===(o=typeof n)&&(i=te.exec(n))&&i[1]&&(n=se(e,t,i),o=\"number\"),null!=n&&n==n&&(\"number\"!==o||u||(n+=i&&i[3]||(w.cssNumber[s]?\"\":\"px\")),d.clearCloneStyle||\"\"!==n||0!==t.indexOf(\"background\")||(l[t]=\"inherit\"),a&&\"set\"in a&&void 0===(n=a.set(e,n,r))||(u?l.setProperty(t,n):l[t]=n))}},css:function(e,t,n,r){var i,o,a,s=X(t);return Ge.test(t)||(t=Xe(s)),(a=w.cssHooks[t]||w.cssHooks[s])&&\"get\"in a&&(i=a.get(e,!0,n)),void 0===i&&(i=Be(e,t,r)),\"normal\"===i&&t in Qe&&(i=Qe[t]),\"\"===n||n?(o=parseFloat(i),!0===n||isFinite(o)?o||0:i):i}}),w.each([\"height\",\"width\"],(function(e,t){w.cssHooks[t]={get:function(e,n,r){if(n)return!Ve.test(w.css(e,\"display\"))||e.getClientRects().length&&e.getBoundingClientRect().width?Ze(e,t,r):We(e,Ye,(function(){return Ze(e,t,r)}))},set:function(e,n,r){var i,o=Ie(e),a=!d.scrollboxSize()&&\"absolute\"===o.position,s=(a||r)&&\"border-box\"===w.css(e,\"boxSizing\",!1,o),u=r?Ke(e,t,r,s,o):0;return s&&a&&(u-=Math.ceil(e[\"offset\"+t[0].toUpperCase()+t.slice(1)]-parseFloat(o[t])-Ke(e,t,\"border\",!1,o)-.5)),u&&(i=te.exec(n))&&\"px\"!==(i[3]||\"px\")&&(e.style[t]=n,n=w.css(e,t)),Je(0,n,u)}}})),w.cssHooks.marginLeft=$e(d.reliableMarginLeft,(function(e,t){if(t)return(parseFloat(Be(e,\"marginLeft\"))||e.getBoundingClientRect().left-We(e,{marginLeft:0},(function(){return e.getBoundingClientRect().left})))+\"px\"})),w.each({margin:\"\",padding:\"\",border:\"Width\"},(function(e,t){w.cssHooks[e+t]={expand:function(n){for(var r=0,i={},o=\"string\"==typeof n?n.split(\" \"):[n];r<4;r++)i[e+ne[r]+t]=o[r]||o[r-2]||o[0];return i}},\"margin\"!==e&&(w.cssHooks[e+t].set=Je)})),w.fn.extend({css:function(e,t){return $(this,(function(e,t,n){var r,i,o={},a=0;if(Array.isArray(t)){for(r=Ie(e),i=t.length;a1)}}),w.Tween=et,et.prototype={constructor:et,init:function(e,t,n,r,i,o){this.elem=e,this.prop=n,this.easing=i||w.easing._default,this.options=t,this.start=this.now=this.cur(),this.end=r,this.unit=o||(w.cssNumber[n]?\"\":\"px\")},cur:function(){var e=et.propHooks[this.prop];return e&&e.get?e.get(this):et.propHooks._default.get(this)},run:function(e){var t,n=et.propHooks[this.prop];return this.options.duration?this.pos=t=w.easing[this.easing](e,this.options.duration*e,0,1,this.options.duration):this.pos=t=e,this.now=(this.end-this.start)*t+this.start,this.options.step&&this.options.step.call(this.elem,this.now,this),n&&n.set?n.set(this):et.propHooks._default.set(this),this}},et.prototype.init.prototype=et.prototype,et.propHooks={_default:{get:function(e){var t;return 1!==e.elem.nodeType||null!=e.elem[e.prop]&&null==e.elem.style[e.prop]?e.elem[e.prop]:(t=w.css(e.elem,e.prop,\"\"))&&\"auto\"!==t?t:0},set:function(e){w.fx.step[e.prop]?w.fx.step[e.prop](e):1!==e.elem.nodeType||!w.cssHooks[e.prop]&&null==e.elem.style[Xe(e.prop)]?e.elem[e.prop]=e.now:w.style(e.elem,e.prop,e.now+e.unit)}}},et.propHooks.scrollTop=et.propHooks.scrollLeft={set:function(e){e.elem.nodeType&&e.elem.parentNode&&(e.elem[e.prop]=e.now)}},w.easing={linear:function(e){return e},swing:function(e){return.5-Math.cos(e*Math.PI)/2},_default:\"swing\"},w.fx=et.prototype.init,w.fx.step={};var tt,nt,rt=/^(?:toggle|show|hide)$/,it=/queueHooks$/;function ot(){nt&&(!1===v.hidden&&e.requestAnimationFrame?e.requestAnimationFrame(ot):e.setTimeout(ot,w.fx.interval),w.fx.tick())}function at(){return e.setTimeout((function(){tt=void 0})),tt=Date.now()}function st(e,t){var n,r=0,i={height:e};for(t=t?1:0;r<4;r+=2-t)i[\"margin\"+(n=ne[r])]=i[\"padding\"+n]=e;return t&&(i.opacity=i.width=e),i}function ut(e,t,n){for(var r,i=(lt.tweeners[t]||[]).concat(lt.tweeners[\"*\"]),o=0,a=i.length;o1)},removeAttr:function(e){return this.each((function(){w.removeAttr(this,e)}))}}),w.extend({attr:function(e,t,n){var r,i,o=e.nodeType;if(3!==o&&8!==o&&2!==o)return void 0===e.getAttribute?w.prop(e,t,n):(1===o&&w.isXMLDoc(e)||(i=w.attrHooks[t.toLowerCase()]||(w.expr.match.bool.test(t)?ct:void 0)),void 0!==n?null===n?void w.removeAttr(e,t):i&&\"set\"in i&&void 0!==(r=i.set(e,n,t))?r:(e.setAttribute(t,n+\"\"),n):i&&\"get\"in i&&null!==(r=i.get(e,t))?r:null==(r=w.find.attr(e,t))?void 0:r)},attrHooks:{type:{set:function(e,t){if(!d.radioValue&&\"radio\"===t&&A(e,\"input\")){var n=e.value;return e.setAttribute(\"type\",t),n&&(e.value=n),t}}}},removeAttr:function(e,t){var n,r=0,i=t&&t.match(P);if(i&&1===e.nodeType)for(;n=i[r++];)e.removeAttribute(n)}}),ct={set:function(e,t,n){return!1===t?w.removeAttr(e,n):e.setAttribute(n,n),n}},w.each(w.expr.match.bool.source.match(/\\w+/g),(function(e,t){var n=ft[t]||w.find.attr;ft[t]=function(e,t,r){var i,o,a=t.toLowerCase();return r||(o=ft[a],ft[a]=i,i=null!=n(e,t,r)?a:null,ft[a]=o),i}}));var pt=/^(?:input|select|textarea|button)$/i,dt=/^(?:a|area)$/i;function ht(e){return(e.match(P)||[]).join(\" \")}function gt(e){return e.getAttribute&&e.getAttribute(\"class\")||\"\"}function vt(e){return Array.isArray(e)?e:\"string\"==typeof e&&e.match(P)||[]}w.fn.extend({prop:function(e,t){return $(this,w.prop,e,t,arguments.length>1)},removeProp:function(e){return this.each((function(){delete this[w.propFix[e]||e]}))}}),w.extend({prop:function(e,t,n){var r,i,o=e.nodeType;if(3!==o&&8!==o&&2!==o)return 1===o&&w.isXMLDoc(e)||(t=w.propFix[t]||t,i=w.propHooks[t]),void 0!==n?i&&\"set\"in i&&void 0!==(r=i.set(e,n,t))?r:e[t]=n:i&&\"get\"in i&&null!==(r=i.get(e,t))?r:e[t]},propHooks:{tabIndex:{get:function(e){var t=w.find.attr(e,\"tabindex\");return t?parseInt(t,10):pt.test(e.nodeName)||dt.test(e.nodeName)&&e.href?0:-1}}},propFix:{for:\"htmlFor\",class:\"className\"}}),d.optSelected||(w.propHooks.selected={get:function(e){var t=e.parentNode;return t&&t.parentNode&&t.parentNode.selectedIndex,null},set:function(e){var t=e.parentNode;t&&(t.selectedIndex,t.parentNode&&t.parentNode.selectedIndex)}}),w.each([\"tabIndex\",\"readOnly\",\"maxLength\",\"cellSpacing\",\"cellPadding\",\"rowSpan\",\"colSpan\",\"useMap\",\"frameBorder\",\"contentEditable\"],(function(){w.propFix[this.toLowerCase()]=this})),w.fn.extend({addClass:function(e){var t,n,r,i,o,a,s,u=0;if(h(e))return this.each((function(t){w(this).addClass(e.call(this,t,gt(this)))}));if((t=vt(e)).length)for(;n=this[u++];)if(i=gt(n),r=1===n.nodeType&&\" \"+ht(i)+\" \"){for(a=0;o=t[a++];)r.indexOf(\" \"+o+\" \")<0&&(r+=o+\" \");i!==(s=ht(r))&&n.setAttribute(\"class\",s)}return this},removeClass:function(e){var t,n,r,i,o,a,s,u=0;if(h(e))return this.each((function(t){w(this).removeClass(e.call(this,t,gt(this)))}));if(!arguments.length)return this.attr(\"class\",\"\");if((t=vt(e)).length)for(;n=this[u++];)if(i=gt(n),r=1===n.nodeType&&\" \"+ht(i)+\" \"){for(a=0;o=t[a++];)for(;r.indexOf(\" \"+o+\" \")>-1;)r=r.replace(\" \"+o+\" \",\" \");i!==(s=ht(r))&&n.setAttribute(\"class\",s)}return this},toggleClass:function(e,t){var n=typeof e,r=\"string\"===n||Array.isArray(e);return\"boolean\"==typeof t&&r?t?this.addClass(e):this.removeClass(e):h(e)?this.each((function(n){w(this).toggleClass(e.call(this,n,gt(this),t),t)})):this.each((function(){var t,i,o,a;if(r)for(i=0,o=w(this),a=vt(e);t=a[i++];)o.hasClass(t)?o.removeClass(t):o.addClass(t);else void 0!==e&&\"boolean\"!==n||((t=gt(this))&&Y.set(this,\"__className__\",t),this.setAttribute&&this.setAttribute(\"class\",t||!1===e?\"\":Y.get(this,\"__className__\")||\"\"))}))},hasClass:function(e){var t,n,r=0;for(t=\" \"+e+\" \";n=this[r++];)if(1===n.nodeType&&(\" \"+ht(gt(n))+\" \").indexOf(t)>-1)return!0;return!1}});var yt=/\\r/g;w.fn.extend({val:function(e){var t,n,r,i=this[0];return arguments.length?(r=h(e),this.each((function(n){var i;1===this.nodeType&&(null==(i=r?e.call(this,n,w(this).val()):e)?i=\"\":\"number\"==typeof i?i+=\"\":Array.isArray(i)&&(i=w.map(i,(function(e){return null==e?\"\":e+\"\"}))),(t=w.valHooks[this.type]||w.valHooks[this.nodeName.toLowerCase()])&&\"set\"in t&&void 0!==t.set(this,i,\"value\")||(this.value=i))}))):i?(t=w.valHooks[i.type]||w.valHooks[i.nodeName.toLowerCase()])&&\"get\"in t&&void 0!==(n=t.get(i,\"value\"))?n:\"string\"==typeof(n=i.value)?n.replace(yt,\"\"):null==n?\"\":n:void 0}}),w.extend({valHooks:{option:{get:function(e){var t=w.find.attr(e,\"value\");return null!=t?t:ht(w.text(e))}},select:{get:function(e){var t,n,r,i=e.options,o=e.selectedIndex,a=\"select-one\"===e.type,s=a?null:[],u=a?o+1:i.length;for(r=o<0?u:a?o:0;r-1)&&(n=!0);return n||(e.selectedIndex=-1),o}}}}),w.each([\"radio\",\"checkbox\"],(function(){w.valHooks[this]={set:function(e,t){if(Array.isArray(t))return e.checked=w.inArray(w(e).val(),t)>-1}},d.checkOn||(w.valHooks[this].get=function(e){return null===e.getAttribute(\"value\")?\"on\":e.value})})),d.focusin=\"onfocusin\"in e;var mt=/^(?:focusinfocus|focusoutblur)$/,xt=function(e){e.stopPropagation()};w.extend(w.event,{trigger:function(t,n,r,i){var o,a,s,u,l,f,p,d,y=[r||v],m=c.call(t,\"type\")?t.type:t,x=c.call(t,\"namespace\")?t.namespace.split(\".\"):[];if(a=d=s=r=r||v,3!==r.nodeType&&8!==r.nodeType&&!mt.test(m+w.event.triggered)&&(m.indexOf(\".\")>-1&&(x=m.split(\".\"),m=x.shift(),x.sort()),l=m.indexOf(\":\")<0&&\"on\"+m,(t=t[w.expando]?t:new w.Event(m,\"object\"==typeof t&&t)).isTrigger=i?2:3,t.namespace=x.join(\".\"),t.rnamespace=t.namespace?new RegExp(\"(^|\\\\.)\"+x.join(\"\\\\.(?:.*\\\\.|)\")+\"(\\\\.|$)\"):null,t.result=void 0,t.target||(t.target=r),n=null==n?[t]:w.makeArray(n,[t]),p=w.event.special[m]||{},i||!p.trigger||!1!==p.trigger.apply(r,n))){if(!i&&!p.noBubble&&!g(r)){for(u=p.delegateType||m,mt.test(u+m)||(a=a.parentNode);a;a=a.parentNode)y.push(a),s=a;s===(r.ownerDocument||v)&&y.push(s.defaultView||s.parentWindow||e)}for(o=0;(a=y[o++])&&!t.isPropagationStopped();)d=a,t.type=o>1?u:p.bindType||m,(f=(Y.get(a,\"events\")||Object.create(null))[t.type]&&Y.get(a,\"handle\"))&&f.apply(a,n),(f=l&&a[l])&&f.apply&&V(a)&&(t.result=f.apply(a,n),!1===t.result&&t.preventDefault());return t.type=m,i||t.isDefaultPrevented()||p._default&&!1!==p._default.apply(y.pop(),n)||!V(r)||l&&h(r[m])&&!g(r)&&((s=r[l])&&(r[l]=null),w.event.triggered=m,t.isPropagationStopped()&&d.addEventListener(m,xt),r[m](),t.isPropagationStopped()&&d.removeEventListener(m,xt),w.event.triggered=void 0,s&&(r[l]=s)),t.result}},simulate:function(e,t,n){var r=w.extend(new w.Event,n,{type:e,isSimulated:!0});w.event.trigger(r,null,t)}}),w.fn.extend({trigger:function(e,t){return this.each((function(){w.event.trigger(e,t,this)}))},triggerHandler:function(e,t){var n=this[0];if(n)return w.event.trigger(e,t,n,!0)}}),d.focusin||w.each({focus:\"focusin\",blur:\"focusout\"},(function(e,t){var n=function(e){w.event.simulate(t,e.target,w.event.fix(e))};w.event.special[t]={setup:function(){var r=this.ownerDocument||this.document||this,i=Y.access(r,t);i||r.addEventListener(e,n,!0),Y.access(r,t,(i||0)+1)},teardown:function(){var r=this.ownerDocument||this.document||this,i=Y.access(r,t)-1;i?Y.access(r,t,i):(r.removeEventListener(e,n,!0),Y.remove(r,t))}}}));var bt=e.location,wt={guid:Date.now()},Tt=/\\?/;w.parseXML=function(t){var n,r;if(!t||\"string\"!=typeof t)return null;try{n=(new e.DOMParser).parseFromString(t,\"text/xml\")}catch(e){}return r=n&&n.getElementsByTagName(\"parsererror\")[0],n&&!r||w.error(\"Invalid XML: \"+(r?w.map(r.childNodes,(function(e){return e.textContent})).join(\"\\n\"):t)),n};var Ct=/\\[\\]$/,Et=/\\r?\\n/g,St=/^(?:submit|button|image|reset|file)$/i,kt=/^(?:input|select|textarea|keygen)/i;function At(e,t,n,r){var i;if(Array.isArray(t))w.each(t,(function(t,i){n||Ct.test(e)?r(e,i):At(e+\"[\"+(\"object\"==typeof i&&null!=i?t:\"\")+\"]\",i,n,r)}));else if(n||\"object\"!==x(t))r(e,t);else for(i in t)At(e+\"[\"+i+\"]\",t[i],n,r)}w.param=function(e,t){var n,r=[],i=function(e,t){var n=h(t)?t():t;r[r.length]=encodeURIComponent(e)+\"=\"+encodeURIComponent(null==n?\"\":n)};if(null==e)return\"\";if(Array.isArray(e)||e.jquery&&!w.isPlainObject(e))w.each(e,(function(){i(this.name,this.value)}));else for(n in e)At(n,e[n],t,i);return r.join(\"&\")},w.fn.extend({serialize:function(){return w.param(this.serializeArray())},serializeArray:function(){return this.map((function(){var e=w.prop(this,\"elements\");return e?w.makeArray(e):this})).filter((function(){var e=this.type;return this.name&&!w(this).is(\":disabled\")&&kt.test(this.nodeName)&&!St.test(e)&&(this.checked||!de.test(e))})).map((function(e,t){var n=w(this).val();return null==n?null:Array.isArray(n)?w.map(n,(function(e){return{name:t.name,value:e.replace(Et,\"\\r\\n\")}})):{name:t.name,value:n.replace(Et,\"\\r\\n\")}})).get()}});var Nt=/%20/g,jt=/#.*$/,Dt=/([?&])_=[^&]*/,qt=/^(.*?):[ \\t]*([^\\r\\n]*)$/gm,Lt=/^(?:GET|HEAD)$/,Ht=/^\\/\\//,Ot={},Pt={},Rt=\"*/\".concat(\"*\"),Mt=v.createElement(\"a\");function It(e){return function(t,n){\"string\"!=typeof t&&(n=t,t=\"*\");var r,i=0,o=t.toLowerCase().match(P)||[];if(h(n))for(;r=o[i++];)\"+\"===r[0]?(r=r.slice(1)||\"*\",(e[r]=e[r]||[]).unshift(n)):(e[r]=e[r]||[]).push(n)}}function Wt(e,t,n,r){var i={},o=e===Pt;function a(s){var u;return i[s]=!0,w.each(e[s]||[],(function(e,s){var l=s(t,n,r);return\"string\"!=typeof l||o||i[l]?o?!(u=l):void 0:(t.dataTypes.unshift(l),a(l),!1)})),u}return a(t.dataTypes[0])||!i[\"*\"]&&a(\"*\")}function Ft(e,t){var n,r,i=w.ajaxSettings.flatOptions||{};for(n in t)void 0!==t[n]&&((i[n]?e:r||(r={}))[n]=t[n]);return r&&w.extend(!0,e,r),e}Mt.href=bt.href,w.extend({active:0,lastModified:{},etag:{},ajaxSettings:{url:bt.href,type:\"GET\",isLocal:/^(?:about|app|app-storage|.+-extension|file|res|widget):$/.test(bt.protocol),global:!0,processData:!0,async:!0,contentType:\"application/x-www-form-urlencoded; charset=UTF-8\",accepts:{\"*\":Rt,text:\"text/plain\",html:\"text/html\",xml:\"application/xml, text/xml\",json:\"application/json, text/javascript\"},contents:{xml:/\\bxml\\b/,html:/\\bhtml/,json:/\\bjson\\b/},responseFields:{xml:\"responseXML\",text:\"responseText\",json:\"responseJSON\"},converters:{\"* text\":String,\"text html\":!0,\"text json\":JSON.parse,\"text xml\":w.parseXML},flatOptions:{url:!0,context:!0}},ajaxSetup:function(e,t){return t?Ft(Ft(e,w.ajaxSettings),t):Ft(w.ajaxSettings,e)},ajaxPrefilter:It(Ot),ajaxTransport:It(Pt),ajax:function(t,n){\"object\"==typeof t&&(n=t,t=void 0),n=n||{};var r,i,o,a,s,u,l,c,f,p,d=w.ajaxSetup({},n),h=d.context||d,g=d.context&&(h.nodeType||h.jquery)?w(h):w.event,y=w.Deferred(),m=w.Callbacks(\"once memory\"),x=d.statusCode||{},b={},T={},C=\"canceled\",E={readyState:0,getResponseHeader:function(e){var t;if(l){if(!a)for(a={};t=qt.exec(o);)a[t[1].toLowerCase()+\" \"]=(a[t[1].toLowerCase()+\" \"]||[]).concat(t[2]);t=a[e.toLowerCase()+\" \"]}return null==t?null:t.join(\", \")},getAllResponseHeaders:function(){return l?o:null},setRequestHeader:function(e,t){return null==l&&(e=T[e.toLowerCase()]=T[e.toLowerCase()]||e,b[e]=t),this},overrideMimeType:function(e){return null==l&&(d.mimeType=e),this},statusCode:function(e){var t;if(e)if(l)E.always(e[E.status]);else for(t in e)x[t]=[x[t],e[t]];return this},abort:function(e){var t=e||C;return r&&r.abort(t),S(0,t),this}};if(y.promise(E),d.url=((t||d.url||bt.href)+\"\").replace(Ht,bt.protocol+\"//\"),d.type=n.method||n.type||d.method||d.type,d.dataTypes=(d.dataType||\"*\").toLowerCase().match(P)||[\"\"],null==d.crossDomain){u=v.createElement(\"a\");try{u.href=d.url,u.href=u.href,d.crossDomain=Mt.protocol+\"//\"+Mt.host!=u.protocol+\"//\"+u.host}catch(e){d.crossDomain=!0}}if(d.data&&d.processData&&\"string\"!=typeof d.data&&(d.data=w.param(d.data,d.traditional)),Wt(Ot,d,n,E),l)return E;for(f in(c=w.event&&d.global)&&0==w.active++&&w.event.trigger(\"ajaxStart\"),d.type=d.type.toUpperCase(),d.hasContent=!Lt.test(d.type),i=d.url.replace(jt,\"\"),d.hasContent?d.data&&d.processData&&0===(d.contentType||\"\").indexOf(\"application/x-www-form-urlencoded\")&&(d.data=d.data.replace(Nt,\"+\")):(p=d.url.slice(i.length),d.data&&(d.processData||\"string\"==typeof d.data)&&(i+=(Tt.test(i)?\"&\":\"?\")+d.data,delete d.data),!1===d.cache&&(i=i.replace(Dt,\"$1\"),p=(Tt.test(i)?\"&\":\"?\")+\"_=\"+wt.guid+++p),d.url=i+p),d.ifModified&&(w.lastModified[i]&&E.setRequestHeader(\"If-Modified-Since\",w.lastModified[i]),w.etag[i]&&E.setRequestHeader(\"If-None-Match\",w.etag[i])),(d.data&&d.hasContent&&!1!==d.contentType||n.contentType)&&E.setRequestHeader(\"Content-Type\",d.contentType),E.setRequestHeader(\"Accept\",d.dataTypes[0]&&d.accepts[d.dataTypes[0]]?d.accepts[d.dataTypes[0]]+(\"*\"!==d.dataTypes[0]?\", \"+Rt+\"; q=0.01\":\"\"):d.accepts[\"*\"]),d.headers)E.setRequestHeader(f,d.headers[f]);if(d.beforeSend&&(!1===d.beforeSend.call(h,E,d)||l))return E.abort();if(C=\"abort\",m.add(d.complete),E.done(d.success),E.fail(d.error),r=Wt(Pt,d,n,E)){if(E.readyState=1,c&&g.trigger(\"ajaxSend\",[E,d]),l)return E;d.async&&d.timeout>0&&(s=e.setTimeout((function(){E.abort(\"timeout\")}),d.timeout));try{l=!1,r.send(b,S)}catch(e){if(l)throw e;S(-1,e)}}else S(-1,\"No Transport\");function S(t,n,a,u){var f,p,v,b,T,C=n;l||(l=!0,s&&e.clearTimeout(s),r=void 0,o=u||\"\",E.readyState=t>0?4:0,f=t>=200&&t<300||304===t,a&&(b=function(e,t,n){for(var r,i,o,a,s=e.contents,u=e.dataTypes;\"*\"===u[0];)u.shift(),void 0===r&&(r=e.mimeType||t.getResponseHeader(\"Content-Type\"));if(r)for(i in s)if(s[i]&&s[i].test(r)){u.unshift(i);break}if(u[0]in n)o=u[0];else{for(i in n){if(!u[0]||e.converters[i+\" \"+u[0]]){o=i;break}a||(a=i)}o=o||a}if(o)return o!==u[0]&&u.unshift(o),n[o]}(d,E,a)),!f&&w.inArray(\"script\",d.dataTypes)>-1&&w.inArray(\"json\",d.dataTypes)<0&&(d.converters[\"text script\"]=function(){}),b=function(e,t,n,r){var i,o,a,s,u,l={},c=e.dataTypes.slice();if(c[1])for(a in e.converters)l[a.toLowerCase()]=e.converters[a];for(o=c.shift();o;)if(e.responseFields[o]&&(n[e.responseFields[o]]=t),!u&&r&&e.dataFilter&&(t=e.dataFilter(t,e.dataType)),u=o,o=c.shift())if(\"*\"===o)o=u;else if(\"*\"!==u&&u!==o){if(!(a=l[u+\" \"+o]||l[\"* \"+o]))for(i in l)if((s=i.split(\" \"))[1]===o&&(a=l[u+\" \"+s[0]]||l[\"* \"+s[0]])){!0===a?a=l[i]:!0!==l[i]&&(o=s[0],c.unshift(s[1]));break}if(!0!==a)if(a&&e.throws)t=a(t);else try{t=a(t)}catch(e){return{state:\"parsererror\",error:a?e:\"No conversion from \"+u+\" to \"+o}}}return{state:\"success\",data:t}}(d,b,E,f),f?(d.ifModified&&((T=E.getResponseHeader(\"Last-Modified\"))&&(w.lastModified[i]=T),(T=E.getResponseHeader(\"etag\"))&&(w.etag[i]=T)),204===t||\"HEAD\"===d.type?C=\"nocontent\":304===t?C=\"notmodified\":(C=b.state,p=b.data,f=!(v=b.error))):(v=C,!t&&C||(C=\"error\",t<0&&(t=0))),E.status=t,E.statusText=(n||C)+\"\",f?y.resolveWith(h,[p,C,E]):y.rejectWith(h,[E,C,v]),E.statusCode(x),x=void 0,c&&g.trigger(f?\"ajaxSuccess\":\"ajaxError\",[E,d,f?p:v]),m.fireWith(h,[E,C]),c&&(g.trigger(\"ajaxComplete\",[E,d]),--w.active||w.event.trigger(\"ajaxStop\")))}return E},getJSON:function(e,t,n){return w.get(e,t,n,\"json\")},getScript:function(e,t){return w.get(e,void 0,t,\"script\")}}),w.each([\"get\",\"post\"],(function(e,t){w[t]=function(e,n,r,i){return h(n)&&(i=i||r,r=n,n=void 0),w.ajax(w.extend({url:e,type:t,dataType:i,data:n,success:r},w.isPlainObject(e)&&e))}})),w.ajaxPrefilter((function(e){var t;for(t in e.headers)\"content-type\"===t.toLowerCase()&&(e.contentType=e.headers[t]||\"\")})),w._evalUrl=function(e,t,n){return w.ajax({url:e,type:\"GET\",dataType:\"script\",cache:!0,async:!1,global:!1,converters:{\"text script\":function(){}},dataFilter:function(e){w.globalEval(e,t,n)}})},w.fn.extend({wrapAll:function(e){var t;return this[0]&&(h(e)&&(e=e.call(this[0])),t=w(e,this[0].ownerDocument).eq(0).clone(!0),this[0].parentNode&&t.insertBefore(this[0]),t.map((function(){for(var e=this;e.firstElementChild;)e=e.firstElementChild;return e})).append(this)),this},wrapInner:function(e){return h(e)?this.each((function(t){w(this).wrapInner(e.call(this,t))})):this.each((function(){var t=w(this),n=t.contents();n.length?n.wrapAll(e):t.append(e)}))},wrap:function(e){var t=h(e);return this.each((function(n){w(this).wrapAll(t?e.call(this,n):e)}))},unwrap:function(e){return this.parent(e).not(\"body\").each((function(){w(this).replaceWith(this.childNodes)})),this}}),w.expr.pseudos.hidden=function(e){return!w.expr.pseudos.visible(e)},w.expr.pseudos.visible=function(e){return!!(e.offsetWidth||e.offsetHeight||e.getClientRects().length)},w.ajaxSettings.xhr=function(){try{return new e.XMLHttpRequest}catch(e){}};var Bt={0:200,1223:204},$t=w.ajaxSettings.xhr();d.cors=!!$t&&\"withCredentials\"in $t,d.ajax=$t=!!$t,w.ajaxTransport((function(t){var n,r;if(d.cors||$t&&!t.crossDomain)return{send:function(i,o){var a,s=t.xhr();if(s.open(t.type,t.url,t.async,t.username,t.password),t.xhrFields)for(a in t.xhrFields)s[a]=t.xhrFields[a];for(a in t.mimeType&&s.overrideMimeType&&s.overrideMimeType(t.mimeType),t.crossDomain||i[\"X-Requested-With\"]||(i[\"X-Requested-With\"]=\"XMLHttpRequest\"),i)s.setRequestHeader(a,i[a]);n=function(e){return function(){n&&(n=r=s.onload=s.onerror=s.onabort=s.ontimeout=s.onreadystatechange=null,\"abort\"===e?s.abort():\"error\"===e?\"number\"!=typeof s.status?o(0,\"error\"):o(s.status,s.statusText):o(Bt[s.status]||s.status,s.statusText,\"text\"!==(s.responseType||\"text\")||\"string\"!=typeof s.responseText?{binary:s.response}:{text:s.responseText},s.getAllResponseHeaders()))}},s.onload=n(),r=s.onerror=s.ontimeout=n(\"error\"),void 0!==s.onabort?s.onabort=r:s.onreadystatechange=function(){4===s.readyState&&e.setTimeout((function(){n&&r()}))},n=n(\"abort\");try{s.send(t.hasContent&&t.data||null)}catch(e){if(n)throw e}},abort:function(){n&&n()}}})),w.ajaxPrefilter((function(e){e.crossDomain&&(e.contents.script=!1)})),w.ajaxSetup({accepts:{script:\"text/javascript, application/javascript, application/ecmascript, application/x-ecmascript\"},contents:{script:/\\b(?:java|ecma)script\\b/},converters:{\"text script\":function(e){return w.globalEval(e),e}}}),w.ajaxPrefilter(\"script\",(function(e){void 0===e.cache&&(e.cache=!1),e.crossDomain&&(e.type=\"GET\")})),w.ajaxTransport(\"script\",(function(e){var t,n;if(e.crossDomain||e.scriptAttrs)return{send:function(r,i){t=w(\"