aggregate_api 1.0.0__py3-none-any.whl
This diff represents the content of publicly available package versions that have been released to one of the supported registries. The information contained in this diff is provided for informational purposes only and reflects changes between package versions as they appear in their respective public registries.
- aggregate_api/__init__.py +41 -0
- aggregate_api/__main__.py +154 -0
- aggregate_api/app.py +206 -0
- aggregate_api/audit.py +395 -0
- aggregate_api/bounds.py +331 -0
- aggregate_api/cache.py +319 -0
- aggregate_api/capability.py +823 -0
- aggregate_api/completion.py +219 -0
- aggregate_api/config.py +363 -0
- aggregate_api/cors.py +61 -0
- aggregate_api/examples.py +620 -0
- aggregate_api/layer_pricing.py +840 -0
- aggregate_api/library.py +94 -0
- aggregate_api/library_notes.py +96 -0
- aggregate_api/models.py +1407 -0
- aggregate_api/net.py +281 -0
- aggregate_api/pnl.py +101 -0
- aggregate_api/pricing.py +778 -0
- aggregate_api/resources.py +257 -0
- aggregate_api/routes/__init__.py +8 -0
- aggregate_api/routes/decl.py +327 -0
- aggregate_api/routes/examples.py +82 -0
- aggregate_api/routes/meta.py +282 -0
- aggregate_api/routes/objects.py +4119 -0
- aggregate_api/routes/status.py +466 -0
- aggregate_api/serializers.py +565 -0
- aggregate_api/sessions.py +353 -0
- aggregate_api/static/aggregate-api-logo-512.png +0 -0
- aggregate_api/static/aggregate-api-logo.png +0 -0
- aggregate_api/static/aggregate-api-trim.png +0 -0
- aggregate_api/static/android-chrome-192x192.png +0 -0
- aggregate_api/static/android-chrome-512x512.png +0 -0
- aggregate_api/static/apple-touch-icon.png +0 -0
- aggregate_api/static/assets/bootstrap-icons-BeopsB42.woff +0 -0
- aggregate_api/static/assets/bootstrap-icons-mSm7cUeB.woff2 +0 -0
- aggregate_api/static/assets/bootstrap-ohb1VZ53.js +5 -0
- aggregate_api/static/assets/codemirror-h62DHGGa.js +14 -0
- aggregate_api/static/assets/csv-grid.worker-DKzHGXac.js +4 -0
- aggregate_api/static/assets/echarts-B7o9sc00.js +40 -0
- aggregate_api/static/assets/echarts-gl-DG1Uf6wE.js +4282 -0
- aggregate_api/static/assets/lite-CUlcD8p4.css +1 -0
- aggregate_api/static/assets/lite-Dd2TnT4M.js +1 -0
- aggregate_api/static/assets/main-Bxhxa55v.css +9 -0
- aggregate_api/static/assets/main-CmoEiPit.js +9 -0
- aggregate_api/static/assets/tables-BHCF7qIF.js +8 -0
- aggregate_api/static/assets/tables-CxvajLr7.css +1 -0
- aggregate_api/static/favicon-16x16.png +0 -0
- aggregate_api/static/favicon-32x32.png +0 -0
- aggregate_api/static/favicon.ico +0 -0
- aggregate_api/static/index.html +912 -0
- aggregate_api/static/lite.html +83 -0
- aggregate_api/static/logo.png +0 -0
- aggregate_api/static/site.webmanifest +14 -0
- aggregate_api/static/sw.js +78 -0
- aggregate_api/status.py +536 -0
- aggregate_api/status_page.html +546 -0
- aggregate_api/tables.py +316 -0
- aggregate_api-1.0.0.dist-info/METADATA +187 -0
- aggregate_api-1.0.0.dist-info/RECORD +63 -0
- aggregate_api-1.0.0.dist-info/WHEEL +5 -0
- aggregate_api-1.0.0.dist-info/entry_points.txt +2 -0
- aggregate_api-1.0.0.dist-info/licenses/LICENSE +28 -0
- aggregate_api-1.0.0.dist-info/top_level.txt +1 -0
|
@@ -0,0 +1,353 @@
|
|
|
1
|
+
"""One recipe base per session, forked from the process's own.
|
|
2
|
+
|
|
3
|
+
The api builds through an underwriter, and a build registers what it parsed:
|
|
4
|
+
every named declaration becomes a ``Recipe`` filed under ``(kind, name)`` with
|
|
5
|
+
``source='session'``. One shared base therefore accumulates every visitor's
|
|
6
|
+
declarations for the life of the process, last writer wins by name, and one
|
|
7
|
+
user's ``agg Cat`` is what another user's ``sev agg.Cat`` means. On a personal
|
|
8
|
+
instance that is invisible. On a shared one it is wrong.
|
|
9
|
+
|
|
10
|
+
The fix is ``Underwriter.fork()``: a copy whose recipe dict is a fresh dict over
|
|
11
|
+
the same parsed ``Recipe`` objects, so the library is read and parsed once and
|
|
12
|
+
each session gets a private namespace over it for the price of a dict copy.
|
|
13
|
+
Measured at about 6 microseconds against the 3,185 milliseconds a fresh load
|
|
14
|
+
costs, which is why a registry of hundreds is affordable and why nothing here
|
|
15
|
+
tries to be clever about reuse.
|
|
16
|
+
|
|
17
|
+
What a session id is, and is not
|
|
18
|
+
--------------------------------
|
|
19
|
+
|
|
20
|
+
It is a **namespace**, not a security boundary. Anyone holding your id gets your
|
|
21
|
+
objects, which is exactly why no login is needed for it: it separates users who
|
|
22
|
+
are not trying to reach each other, which is the demo case. Do not build
|
|
23
|
+
anything on it that would matter if it leaked.
|
|
24
|
+
|
|
25
|
+
It is minted client side and arrives in the ``X-Aggregate-Session`` header, so
|
|
26
|
+
the server treats it as untrusted text: bounded in length, restricted in
|
|
27
|
+
charset, and anything failing that is read as no header at all. A missing or
|
|
28
|
+
unusable header falls back to one per-process anonymous session, so ``curl`` and
|
|
29
|
+
the test suite keep working and keep today's collision behavior among
|
|
30
|
+
themselves. That is a stated tradeoff, not an oversight.
|
|
31
|
+
|
|
32
|
+
Eviction is the registry's, on its own clock
|
|
33
|
+
--------------------------------------------
|
|
34
|
+
|
|
35
|
+
Bounded LRU with a TTL, both configurable. The id carries a client timestamp,
|
|
36
|
+
which is an audit and display key and nothing more: client clocks are not
|
|
37
|
+
trustworthy and eviction does not need them. When a fork is evicted the session
|
|
38
|
+
survives as an id, and its next reference to something it built itself raises
|
|
39
|
+
``RecipeNotFound``, which the routes turn into a 422 naming the missing entry so
|
|
40
|
+
the app can offer a rebuild.
|
|
41
|
+
"""
|
|
42
|
+
|
|
43
|
+
from __future__ import annotations
|
|
44
|
+
|
|
45
|
+
import re
|
|
46
|
+
import threading
|
|
47
|
+
import time
|
|
48
|
+
from collections import OrderedDict
|
|
49
|
+
from dataclasses import dataclass
|
|
50
|
+
from datetime import datetime, timezone
|
|
51
|
+
|
|
52
|
+
# The header a browser sends its session id in. Read in ``routes/objects.py``
|
|
53
|
+
# and, because a download cannot set headers, accepted in the query string
|
|
54
|
+
# there as well.
|
|
55
|
+
SESSION_HEADER = "X-Aggregate-Session"
|
|
56
|
+
|
|
57
|
+
# The id every headerless client shares. Not a valid minted id (a real one
|
|
58
|
+
# carries a timestamp and a uuid4), so no browser can collide with it by
|
|
59
|
+
# accident, and legible in an audit row.
|
|
60
|
+
ANONYMOUS = "anonymous"
|
|
61
|
+
|
|
62
|
+
# Minted as ``<utc timestamp>-<uuid4>``, so an ISO timestamp's colons, dots and
|
|
63
|
+
# hyphens plus hex. Deliberately a shape check and not a parse: the server has
|
|
64
|
+
# no use for the timestamp, and a client that formats it differently should not
|
|
65
|
+
# be told its session is invalid. Length is bounded because an id is a dict key
|
|
66
|
+
# on an untrusted string.
|
|
67
|
+
_SESSION_ID = re.compile(r"\A[A-Za-z0-9:.\-_]{8,200}\Z")
|
|
68
|
+
|
|
69
|
+
|
|
70
|
+
def normalize_session_id(raw: str | None) -> str:
|
|
71
|
+
"""Return a usable session id, or :data:`ANONYMOUS`.
|
|
72
|
+
|
|
73
|
+
Parameters
|
|
74
|
+
----------
|
|
75
|
+
raw : str or None
|
|
76
|
+
The header (or query parameter) value as it arrived.
|
|
77
|
+
|
|
78
|
+
Returns
|
|
79
|
+
-------
|
|
80
|
+
str
|
|
81
|
+
``raw`` stripped, if it is a plausible minted id; otherwise
|
|
82
|
+
:data:`ANONYMOUS`.
|
|
83
|
+
|
|
84
|
+
Notes
|
|
85
|
+
-----
|
|
86
|
+
An unusable id reads as absent rather than as an error. A 400 would teach a
|
|
87
|
+
client nothing it can act on (the id is its own invention) and would break
|
|
88
|
+
the headerless callers this fallback exists for.
|
|
89
|
+
"""
|
|
90
|
+
if not raw:
|
|
91
|
+
return ANONYMOUS
|
|
92
|
+
candidate = raw.strip()
|
|
93
|
+
if not _SESSION_ID.match(candidate):
|
|
94
|
+
return ANONYMOUS
|
|
95
|
+
return candidate
|
|
96
|
+
|
|
97
|
+
|
|
98
|
+
@dataclass
|
|
99
|
+
class SessionEntry:
|
|
100
|
+
"""One session's fork and what the registry knows about it.
|
|
101
|
+
|
|
102
|
+
A dataclass rather than the ``(fork, touched)`` tuple this started as,
|
|
103
|
+
because ``GET /v1/status`` reports a row per live session and a tuple grows
|
|
104
|
+
a field at a time until nobody remembers the order. Everything here is
|
|
105
|
+
written by the registry under its lock and read through
|
|
106
|
+
:meth:`SessionRegistry.rows`.
|
|
107
|
+
|
|
108
|
+
Attributes
|
|
109
|
+
----------
|
|
110
|
+
fork : aggregate.underwriter.Underwriter
|
|
111
|
+
The session's own recipe base.
|
|
112
|
+
created_at : datetime
|
|
113
|
+
Wall clock, for display. Not used for eviction: see ``touched``.
|
|
114
|
+
created : float
|
|
115
|
+
Monotonic seconds at creation, for the age.
|
|
116
|
+
touched : float
|
|
117
|
+
Monotonic seconds at the last access, which is what the TTL reads. A
|
|
118
|
+
monotonic clock rather than the wall clock, because a machine adjusting
|
|
119
|
+
its time should not expire or resurrect a session.
|
|
120
|
+
requests : int
|
|
121
|
+
How many times this session asked the registry for its base.
|
|
122
|
+
builds : int
|
|
123
|
+
How many objects this session caused to be built, meaning cache misses
|
|
124
|
+
that produced one. A session with many requests and no builds is a
|
|
125
|
+
reader, and the pair says more than either number alone.
|
|
126
|
+
"""
|
|
127
|
+
|
|
128
|
+
fork: object
|
|
129
|
+
created_at: datetime
|
|
130
|
+
created: float
|
|
131
|
+
touched: float
|
|
132
|
+
requests: int = 0
|
|
133
|
+
builds: int = 0
|
|
134
|
+
|
|
135
|
+
|
|
136
|
+
class SessionRegistry:
|
|
137
|
+
"""Session id to forked ``Underwriter``, bounded LRU with a TTL.
|
|
138
|
+
|
|
139
|
+
Modeled on :class:`aggregate_api.cache.ObjectCache`: one lock, an
|
|
140
|
+
``OrderedDict`` for the LRU, move-to-end on read, ``popitem(last=False)``
|
|
141
|
+
to evict. It differs in one way that matters: a miss is not a miss to
|
|
142
|
+
report but a fork to take, so :meth:`underwriter` always returns a base.
|
|
143
|
+
|
|
144
|
+
Parameters
|
|
145
|
+
----------
|
|
146
|
+
max_sessions : int
|
|
147
|
+
How many forks to hold. Generous is the right setting: a fork is
|
|
148
|
+
microseconds and a few hundred kilobytes, and the TTL is what actually
|
|
149
|
+
bounds the memory.
|
|
150
|
+
ttl_s : float
|
|
151
|
+
Seconds of inactivity after which a fork is dropped. Read on access,
|
|
152
|
+
so an idle session is evicted the next time anything asks the registry
|
|
153
|
+
for anything, not on a timer thread.
|
|
154
|
+
|
|
155
|
+
Notes
|
|
156
|
+
-----
|
|
157
|
+
The lock guards the registry, not the forks. A fork is single-session by
|
|
158
|
+
construction, so two concurrent requests from **one** session can still
|
|
159
|
+
race each other inside it, which is the same exposure the shared base
|
|
160
|
+
always had and no worse. What the lock does buy is that two concurrent
|
|
161
|
+
first requests from one session get one fork rather than two, so the
|
|
162
|
+
second does not silently start from a base the first has already written
|
|
163
|
+
to.
|
|
164
|
+
"""
|
|
165
|
+
|
|
166
|
+
def __init__(self, max_sessions: int = 500, ttl_s: float = 28800.0) -> None:
|
|
167
|
+
self._max = max_sessions
|
|
168
|
+
self._ttl = ttl_s
|
|
169
|
+
self._store: OrderedDict[str, SessionEntry] = OrderedDict()
|
|
170
|
+
self._lock = threading.Lock()
|
|
171
|
+
# Counters for the audit and for anything reporting on the process.
|
|
172
|
+
# Dropped forks are split by cause because the three causes mean
|
|
173
|
+
# different things to an operator: expiry is the TTL working, eviction
|
|
174
|
+
# is the capacity being too small for the room, and an explicit drop is
|
|
175
|
+
# somebody asking. A single total cannot tell them apart, and "sessions
|
|
176
|
+
# keep vanishing" is exactly the report where the difference is the
|
|
177
|
+
# answer. ``forks_dropped`` stays as the total, since it shipped at
|
|
178
|
+
# a110 under that meaning.
|
|
179
|
+
self.forks_taken = 0
|
|
180
|
+
self.forks_expired = 0
|
|
181
|
+
self.forks_evicted = 0
|
|
182
|
+
self.forks_dropped = 0
|
|
183
|
+
self.high_water = 0
|
|
184
|
+
|
|
185
|
+
def underwriter(self, session_id: str, parent):
|
|
186
|
+
"""Return this session's fork of ``parent``, taking one if needed.
|
|
187
|
+
|
|
188
|
+
Parameters
|
|
189
|
+
----------
|
|
190
|
+
session_id : str
|
|
191
|
+
Already normalized: see :func:`normalize_session_id`.
|
|
192
|
+
parent : aggregate.underwriter.Underwriter
|
|
193
|
+
The process's own base, from
|
|
194
|
+
:func:`aggregate_api.library.get_underwriter`. Passed rather than
|
|
195
|
+
imported so this module knows nothing about configuration.
|
|
196
|
+
|
|
197
|
+
Returns
|
|
198
|
+
-------
|
|
199
|
+
aggregate.underwriter.Underwriter
|
|
200
|
+
The fork, already loaded.
|
|
201
|
+
"""
|
|
202
|
+
now = time.monotonic()
|
|
203
|
+
with self._lock:
|
|
204
|
+
self._expire(now)
|
|
205
|
+
found = self._store.get(session_id)
|
|
206
|
+
if found is not None:
|
|
207
|
+
found.touched = now
|
|
208
|
+
found.requests += 1
|
|
209
|
+
self._store.move_to_end(session_id)
|
|
210
|
+
return found.fork
|
|
211
|
+
# The fork is taken outside the lock: it is microseconds, but it runs
|
|
212
|
+
# library code, and holding a registry-wide lock across a call into
|
|
213
|
+
# another package is how a deadlock gets written. Two threads racing
|
|
214
|
+
# here both fork and one wins the insert; the loser's fork is empty and
|
|
215
|
+
# unreferenced, so it is garbage rather than a lost registration.
|
|
216
|
+
fork = parent.fork(name=f"session-{session_id}")
|
|
217
|
+
with self._lock:
|
|
218
|
+
found = self._store.get(session_id)
|
|
219
|
+
if found is not None:
|
|
220
|
+
found.touched = now
|
|
221
|
+
found.requests += 1
|
|
222
|
+
self._store.move_to_end(session_id)
|
|
223
|
+
return found.fork
|
|
224
|
+
self._store[session_id] = SessionEntry(
|
|
225
|
+
fork=fork, created_at=datetime.now(timezone.utc),
|
|
226
|
+
created=now, touched=now, requests=1)
|
|
227
|
+
self.forks_taken += 1
|
|
228
|
+
self.high_water = max(self.high_water, len(self._store))
|
|
229
|
+
while len(self._store) > self._max:
|
|
230
|
+
self._store.popitem(last=False)
|
|
231
|
+
self.forks_evicted += 1
|
|
232
|
+
self.forks_dropped += 1
|
|
233
|
+
return fork
|
|
234
|
+
|
|
235
|
+
def _expire(self, now: float) -> None:
|
|
236
|
+
"""Drop forks idle longer than the TTL. The caller holds the lock.
|
|
237
|
+
|
|
238
|
+
Walks from the LRU end and stops at the first live entry, which is
|
|
239
|
+
correct because the order is by last touch.
|
|
240
|
+
"""
|
|
241
|
+
if self._ttl <= 0:
|
|
242
|
+
return
|
|
243
|
+
while self._store:
|
|
244
|
+
session_id, entry = next(iter(self._store.items()))
|
|
245
|
+
if now - entry.touched <= self._ttl:
|
|
246
|
+
return
|
|
247
|
+
self._store.pop(session_id)
|
|
248
|
+
self.forks_expired += 1
|
|
249
|
+
self.forks_dropped += 1
|
|
250
|
+
|
|
251
|
+
def drop(self, session_id: str) -> bool:
|
|
252
|
+
"""Forget one session's fork; return True if it was held."""
|
|
253
|
+
with self._lock:
|
|
254
|
+
dropped = self._store.pop(session_id, None) is not None
|
|
255
|
+
if dropped:
|
|
256
|
+
self.forks_dropped += 1
|
|
257
|
+
return dropped
|
|
258
|
+
|
|
259
|
+
def clear(self) -> None:
|
|
260
|
+
"""Forget every fork. Used by ``reset_singletons`` and by tests."""
|
|
261
|
+
with self._lock:
|
|
262
|
+
self._store.clear()
|
|
263
|
+
|
|
264
|
+
def ids(self) -> list[str]:
|
|
265
|
+
"""Snapshot of the session ids held, LRU first."""
|
|
266
|
+
with self._lock:
|
|
267
|
+
return list(self._store.keys())
|
|
268
|
+
|
|
269
|
+
def record_build(self, session_id: str) -> None:
|
|
270
|
+
"""Note that ``session_id`` caused one object to be built.
|
|
271
|
+
|
|
272
|
+
Called on a cache miss that produced an object. A no-op for a session
|
|
273
|
+
whose fork has since been evicted, because the counter lives on the
|
|
274
|
+
entry and there is nothing left to count against. The audit log holds
|
|
275
|
+
that build either way, which is where a permanent record belongs.
|
|
276
|
+
"""
|
|
277
|
+
with self._lock:
|
|
278
|
+
entry = self._store.get(session_id)
|
|
279
|
+
if entry is not None:
|
|
280
|
+
entry.builds += 1
|
|
281
|
+
|
|
282
|
+
def __contains__(self, session_id: str) -> bool:
|
|
283
|
+
with self._lock:
|
|
284
|
+
return session_id in self._store
|
|
285
|
+
|
|
286
|
+
def __len__(self) -> int:
|
|
287
|
+
with self._lock:
|
|
288
|
+
return len(self._store)
|
|
289
|
+
|
|
290
|
+
def stats(self) -> dict:
|
|
291
|
+
"""Aggregate counters and the configured bounds, in one critical section."""
|
|
292
|
+
with self._lock:
|
|
293
|
+
return {
|
|
294
|
+
"live": len(self._store),
|
|
295
|
+
"max": self._max,
|
|
296
|
+
"ttl_s": self._ttl,
|
|
297
|
+
"high_water": self.high_water,
|
|
298
|
+
"taken": self.forks_taken,
|
|
299
|
+
"dropped": self.forks_dropped,
|
|
300
|
+
"expired": self.forks_expired,
|
|
301
|
+
"evicted": self.forks_evicted,
|
|
302
|
+
}
|
|
303
|
+
|
|
304
|
+
def rows(self, baseline: int = 0) -> list[dict]:
|
|
305
|
+
"""One row per live session, LRU first, for ``GET /v1/status``.
|
|
306
|
+
|
|
307
|
+
Parameters
|
|
308
|
+
----------
|
|
309
|
+
baseline : int
|
|
310
|
+
The reference underwriter's recipe count, subtracted from each
|
|
311
|
+
fork's so the column reads "what this session declared" rather than
|
|
312
|
+
"the library plus what this session declared", where the second
|
|
313
|
+
number is the same few hundred on every row and says nothing.
|
|
314
|
+
|
|
315
|
+
Returns
|
|
316
|
+
-------
|
|
317
|
+
list of dict
|
|
318
|
+
``session_id``, ``created_at``, ``age_s``, ``idle_s``, ``requests``,
|
|
319
|
+
``builds`` and ``recipes``, LRU first, so what is about to be
|
|
320
|
+
expired reads first. The id travels in full: truncating it is the
|
|
321
|
+
page's job, since the payload is already behind the private gate and
|
|
322
|
+
a machine reader may want to correlate it with an audit row.
|
|
323
|
+
|
|
324
|
+
Notes
|
|
325
|
+
-----
|
|
326
|
+
``len(fork._recipes)`` is a private attribute of a stable-tier library
|
|
327
|
+
class, taken deliberately and recorded in the oversight charter's
|
|
328
|
+
tolerated list (author ruling, 2026-08-18). The public route is
|
|
329
|
+
``Underwriter.recipes``, which builds a pandas frame per call, and this
|
|
330
|
+
page would call it once per live session on every refresh: hundreds of
|
|
331
|
+
frames every ten seconds to report hundreds of integers. The read is
|
|
332
|
+
guarded, so a rename upstream costs one field reading ``None`` rather
|
|
333
|
+
than a broken route.
|
|
334
|
+
"""
|
|
335
|
+
now = time.monotonic()
|
|
336
|
+
with self._lock:
|
|
337
|
+
entries = list(self._store.items())
|
|
338
|
+
rows = []
|
|
339
|
+
for session_id, entry in entries:
|
|
340
|
+
try:
|
|
341
|
+
recipes = len(entry.fork._recipes) - baseline
|
|
342
|
+
except (AttributeError, TypeError):
|
|
343
|
+
recipes = None
|
|
344
|
+
rows.append({
|
|
345
|
+
"session_id": session_id,
|
|
346
|
+
"created_at": entry.created_at.isoformat(timespec="seconds"),
|
|
347
|
+
"age_s": round(now - entry.created, 1),
|
|
348
|
+
"idle_s": round(now - entry.touched, 1),
|
|
349
|
+
"requests": entry.requests,
|
|
350
|
+
"builds": entry.builds,
|
|
351
|
+
"recipes": recipes,
|
|
352
|
+
})
|
|
353
|
+
return rows
|
|
Binary file
|
|
Binary file
|
|
Binary file
|
|
Binary file
|
|
Binary file
|
|
Binary file
|
|
Binary file
|
|
Binary file
|
|
@@ -0,0 +1,5 @@
|
|
|
1
|
+
var L="top",R="bottom",x="right",I="left",fe="auto",It=[L,R,x,I],pt="start",Ot="end",Jn="clippingParents",ze="viewport",At="popper",ts="reference",We=It.reduce(function(n,t){return n.concat([t+"-"+pt,t+"-"+Ot])},[]),Ge=[].concat(It,[fe]).reduce(function(n,t){return n.concat([t,t+"-"+pt,t+"-"+Ot])},[]),es="beforeRead",ns="read",ss="afterRead",is="beforeMain",rs="main",os="afterMain",as="beforeWrite",cs="write",ls="afterWrite",us=[es,ns,ss,is,rs,os,as,cs,ls];function z(n){return n?(n.nodeName||"").toLowerCase():null}function k(n){if(n==null)return window;if(n.toString()!=="[object Window]"){var t=n.ownerDocument;return t&&t.defaultView||window}return n}function _t(n){var t=k(n).Element;return n instanceof t||n instanceof Element}function V(n){var t=k(n).HTMLElement;return n instanceof t||n instanceof HTMLElement}function qe(n){if(typeof ShadowRoot>"u")return!1;var t=k(n).ShadowRoot;return n instanceof t||n instanceof ShadowRoot}function ui(n){var t=n.state;Object.keys(t.elements).forEach(function(e){var s=t.styles[e]||{},i=t.attributes[e]||{},r=t.elements[e];!V(r)||!z(r)||(Object.assign(r.style,s),Object.keys(i).forEach(function(o){var a=i[o];a===!1?r.removeAttribute(o):r.setAttribute(o,a===!0?"":a)}))})}function hi(n){var t=n.state,e={popper:{position:t.options.strategy,left:"0",top:"0",margin:"0"},arrow:{position:"absolute"},reference:{}};return Object.assign(t.elements.popper.style,e.popper),t.styles=e,t.elements.arrow&&Object.assign(t.elements.arrow.style,e.arrow),function(){Object.keys(t.elements).forEach(function(s){var i=t.elements[s],r=t.attributes[s]||{},o=Object.keys(t.styles.hasOwnProperty(s)?t.styles[s]:e[s]),a=o.reduce(function(l,h){return l[h]="",l},{});!V(i)||!z(i)||(Object.assign(i.style,a),Object.keys(r).forEach(function(l){i.removeAttribute(l)}))})}}const hs={name:"applyStyles",enabled:!0,phase:"write",fn:ui,effect:hi,requires:["computeStyles"]};function Y(n){return n.split("-")[0]}var ft=Math.max,le=Math.min,Ct=Math.round;function Be(){var n=navigator.userAgentData;return n!=null&&n.brands&&Array.isArray(n.brands)?n.brands.map(function(t){return t.brand+"/"+t.version}).join(" "):navigator.userAgent}function ds(){return!/^((?!chrome|android).)*safari/i.test(Be())}function Nt(n,t,e){t===void 0&&(t=!1),e===void 0&&(e=!1);var s=n.getBoundingClientRect(),i=1,r=1;t&&V(n)&&(i=n.offsetWidth>0&&Ct(s.width)/n.offsetWidth||1,r=n.offsetHeight>0&&Ct(s.height)/n.offsetHeight||1);var o=_t(n)?k(n):window,a=o.visualViewport,l=!ds()&&e,h=(s.left+(l&&a?a.offsetLeft:0))/i,u=(s.top+(l&&a?a.offsetTop:0))/r,p=s.width/i,_=s.height/r;return{width:p,height:_,top:u,right:h+p,bottom:u+_,left:h,x:h,y:u}}function Xe(n){var t=Nt(n),e=n.offsetWidth,s=n.offsetHeight;return Math.abs(t.width-e)<=1&&(e=t.width),Math.abs(t.height-s)<=1&&(s=t.height),{x:n.offsetLeft,y:n.offsetTop,width:e,height:s}}function fs(n,t){var e=t.getRootNode&&t.getRootNode();if(n.contains(t))return!0;if(e&&qe(e)){var s=t;do{if(s&&n.isSameNode(s))return!0;s=s.parentNode||s.host}while(s)}return!1}function X(n){return k(n).getComputedStyle(n)}function di(n){return["table","td","th"].indexOf(z(n))>=0}function st(n){return((_t(n)?n.ownerDocument:n.document)||window.document).documentElement}function pe(n){return z(n)==="html"?n:n.assignedSlot||n.parentNode||(qe(n)?n.host:null)||st(n)}function gn(n){return!V(n)||X(n).position==="fixed"?null:n.offsetParent}function fi(n){var t=/firefox/i.test(Be()),e=/Trident/i.test(Be());if(e&&V(n)){var s=X(n);if(s.position==="fixed")return null}var i=pe(n);for(qe(i)&&(i=i.host);V(i)&&["html","body"].indexOf(z(i))<0;){var r=X(i);if(r.transform!=="none"||r.perspective!=="none"||r.contain==="paint"||["transform","perspective"].indexOf(r.willChange)!==-1||t&&r.willChange==="filter"||t&&r.filter&&r.filter!=="none")return i;i=i.parentNode}return null}function Ft(n){for(var t=k(n),e=gn(n);e&&di(e)&&X(e).position==="static";)e=gn(e);return e&&(z(e)==="html"||z(e)==="body"&&X(e).position==="static")?t:e||fi(n)||t}function Qe(n){return["top","bottom"].indexOf(n)>=0?"x":"y"}function Wt(n,t,e){return ft(n,le(t,e))}function pi(n,t,e){var s=Wt(n,t,e);return s>e?e:s}function ps(){return{top:0,right:0,bottom:0,left:0}}function _s(n){return Object.assign({},ps(),n)}function ms(n,t){return t.reduce(function(e,s){return e[s]=n,e},{})}var _i=function(t,e){return t=typeof t=="function"?t(Object.assign({},e.rects,{placement:e.placement})):t,_s(typeof t!="number"?t:ms(t,It))};function mi(n){var t,e=n.state,s=n.name,i=n.options,r=e.elements.arrow,o=e.modifiersData.popperOffsets,a=Y(e.placement),l=Qe(a),h=[I,x].indexOf(a)>=0,u=h?"height":"width";if(!(!r||!o)){var p=_i(i.padding,e),_=Xe(r),f=l==="y"?L:I,A=l==="y"?R:x,m=e.rects.reference[u]+e.rects.reference[l]-o[l]-e.rects.popper[u],E=o[l]-e.rects.reference[l],T=Ft(r),w=T?l==="y"?T.clientHeight||0:T.clientWidth||0:0,O=m/2-E/2,g=p[f],v=w-_[u]-p[A],b=w/2-_[u]/2+O,y=Wt(g,b,v),S=l;e.modifiersData[s]=(t={},t[S]=y,t.centerOffset=y-b,t)}}function gi(n){var t=n.state,e=n.options,s=e.element,i=s===void 0?"[data-popper-arrow]":s;i!=null&&(typeof i=="string"&&(i=t.elements.popper.querySelector(i),!i)||fs(t.elements.popper,i)&&(t.elements.arrow=i))}const gs={name:"arrow",enabled:!0,phase:"main",fn:mi,effect:gi,requires:["popperOffsets"],requiresIfExists:["preventOverflow"]};function St(n){return n.split("-")[1]}var Ei={top:"auto",right:"auto",bottom:"auto",left:"auto"};function vi(n,t){var e=n.x,s=n.y,i=t.devicePixelRatio||1;return{x:Ct(e*i)/i||0,y:Ct(s*i)/i||0}}function En(n){var t,e=n.popper,s=n.popperRect,i=n.placement,r=n.variation,o=n.offsets,a=n.position,l=n.gpuAcceleration,h=n.adaptive,u=n.roundOffsets,p=n.isFixed,_=o.x,f=_===void 0?0:_,A=o.y,m=A===void 0?0:A,E=typeof u=="function"?u({x:f,y:m}):{x:f,y:m};f=E.x,m=E.y;var T=o.hasOwnProperty("x"),w=o.hasOwnProperty("y"),O=I,g=L,v=window;if(h){var b=Ft(e),y="clientHeight",S="clientWidth";if(b===k(e)&&(b=st(e),X(b).position!=="static"&&a==="absolute"&&(y="scrollHeight",S="scrollWidth")),b=b,i===L||(i===I||i===x)&&r===Ot){g=R;var N=p&&b===v&&v.visualViewport?v.visualViewport.height:b[y];m-=N-s.height,m*=l?1:-1}if(i===I||(i===L||i===R)&&r===Ot){O=x;var C=p&&b===v&&v.visualViewport?v.visualViewport.width:b[S];f-=C-s.width,f*=l?1:-1}}var D=Object.assign({position:a},h&&Ei),j=u===!0?vi({x:f,y:m},k(e)):{x:f,y:m};if(f=j.x,m=j.y,l){var $;return Object.assign({},D,($={},$[g]=w?"0":"",$[O]=T?"0":"",$.transform=(v.devicePixelRatio||1)<=1?"translate("+f+"px, "+m+"px)":"translate3d("+f+"px, "+m+"px, 0)",$))}return Object.assign({},D,(t={},t[g]=w?m+"px":"",t[O]=T?f+"px":"",t.transform="",t))}function bi(n){var t=n.state,e=n.options,s=e.gpuAcceleration,i=s===void 0?!0:s,r=e.adaptive,o=r===void 0?!0:r,a=e.roundOffsets,l=a===void 0?!0:a,h={placement:Y(t.placement),variation:St(t.placement),popper:t.elements.popper,popperRect:t.rects.popper,gpuAcceleration:i,isFixed:t.options.strategy==="fixed"};t.modifiersData.popperOffsets!=null&&(t.styles.popper=Object.assign({},t.styles.popper,En(Object.assign({},h,{offsets:t.modifiersData.popperOffsets,position:t.options.strategy,adaptive:o,roundOffsets:l})))),t.modifiersData.arrow!=null&&(t.styles.arrow=Object.assign({},t.styles.arrow,En(Object.assign({},h,{offsets:t.modifiersData.arrow,position:"absolute",adaptive:!1,roundOffsets:l})))),t.attributes.popper=Object.assign({},t.attributes.popper,{"data-popper-placement":t.placement})}const Es={name:"computeStyles",enabled:!0,phase:"beforeWrite",fn:bi,data:{}};var Jt={passive:!0};function Ai(n){var t=n.state,e=n.instance,s=n.options,i=s.scroll,r=i===void 0?!0:i,o=s.resize,a=o===void 0?!0:o,l=k(t.elements.popper),h=[].concat(t.scrollParents.reference,t.scrollParents.popper);return r&&h.forEach(function(u){u.addEventListener("scroll",e.update,Jt)}),a&&l.addEventListener("resize",e.update,Jt),function(){r&&h.forEach(function(u){u.removeEventListener("scroll",e.update,Jt)}),a&&l.removeEventListener("resize",e.update,Jt)}}const vs={name:"eventListeners",enabled:!0,phase:"write",fn:function(){},effect:Ai,data:{}};var Ti={left:"right",right:"left",bottom:"top",top:"bottom"};function oe(n){return n.replace(/left|right|bottom|top/g,function(t){return Ti[t]})}var yi={start:"end",end:"start"};function vn(n){return n.replace(/start|end/g,function(t){return yi[t]})}function Ze(n){var t=k(n),e=t.pageXOffset,s=t.pageYOffset;return{scrollLeft:e,scrollTop:s}}function Je(n){return Nt(st(n)).left+Ze(n).scrollLeft}function wi(n,t){var e=k(n),s=st(n),i=e.visualViewport,r=s.clientWidth,o=s.clientHeight,a=0,l=0;if(i){r=i.width,o=i.height;var h=ds();(h||!h&&t==="fixed")&&(a=i.offsetLeft,l=i.offsetTop)}return{width:r,height:o,x:a+Je(n),y:l}}function Oi(n){var t,e=st(n),s=Ze(n),i=(t=n.ownerDocument)==null?void 0:t.body,r=ft(e.scrollWidth,e.clientWidth,i?i.scrollWidth:0,i?i.clientWidth:0),o=ft(e.scrollHeight,e.clientHeight,i?i.scrollHeight:0,i?i.clientHeight:0),a=-s.scrollLeft+Je(n),l=-s.scrollTop;return X(i||e).direction==="rtl"&&(a+=ft(e.clientWidth,i?i.clientWidth:0)-r),{width:r,height:o,x:a,y:l}}function tn(n){var t=X(n),e=t.overflow,s=t.overflowX,i=t.overflowY;return/auto|scroll|overlay|hidden/.test(e+i+s)}function bs(n){return["html","body","#document"].indexOf(z(n))>=0?n.ownerDocument.body:V(n)&&tn(n)?n:bs(pe(n))}function Bt(n,t){var e;t===void 0&&(t=[]);var s=bs(n),i=s===((e=n.ownerDocument)==null?void 0:e.body),r=k(s),o=i?[r].concat(r.visualViewport||[],tn(s)?s:[]):s,a=t.concat(o);return i?a:a.concat(Bt(pe(o)))}function je(n){return Object.assign({},n,{left:n.x,top:n.y,right:n.x+n.width,bottom:n.y+n.height})}function Ci(n,t){var e=Nt(n,!1,t==="fixed");return e.top=e.top+n.clientTop,e.left=e.left+n.clientLeft,e.bottom=e.top+n.clientHeight,e.right=e.left+n.clientWidth,e.width=n.clientWidth,e.height=n.clientHeight,e.x=e.left,e.y=e.top,e}function bn(n,t,e){return t===ze?je(wi(n,e)):_t(t)?Ci(t,e):je(Oi(st(n)))}function Ni(n){var t=Bt(pe(n)),e=["absolute","fixed"].indexOf(X(n).position)>=0,s=e&&V(n)?Ft(n):n;return _t(s)?t.filter(function(i){return _t(i)&&fs(i,s)&&z(i)!=="body"}):[]}function Si(n,t,e,s){var i=t==="clippingParents"?Ni(n):[].concat(t),r=[].concat(i,[e]),o=r[0],a=r.reduce(function(l,h){var u=bn(n,h,s);return l.top=ft(u.top,l.top),l.right=le(u.right,l.right),l.bottom=le(u.bottom,l.bottom),l.left=ft(u.left,l.left),l},bn(n,o,s));return a.width=a.right-a.left,a.height=a.bottom-a.top,a.x=a.left,a.y=a.top,a}function As(n){var t=n.reference,e=n.element,s=n.placement,i=s?Y(s):null,r=s?St(s):null,o=t.x+t.width/2-e.width/2,a=t.y+t.height/2-e.height/2,l;switch(i){case L:l={x:o,y:t.y-e.height};break;case R:l={x:o,y:t.y+t.height};break;case x:l={x:t.x+t.width,y:a};break;case I:l={x:t.x-e.width,y:a};break;default:l={x:t.x,y:t.y}}var h=i?Qe(i):null;if(h!=null){var u=h==="y"?"height":"width";switch(r){case pt:l[h]=l[h]-(t[u]/2-e[u]/2);break;case Ot:l[h]=l[h]+(t[u]/2-e[u]/2);break}}return l}function Dt(n,t){t===void 0&&(t={});var e=t,s=e.placement,i=s===void 0?n.placement:s,r=e.strategy,o=r===void 0?n.strategy:r,a=e.boundary,l=a===void 0?Jn:a,h=e.rootBoundary,u=h===void 0?ze:h,p=e.elementContext,_=p===void 0?At:p,f=e.altBoundary,A=f===void 0?!1:f,m=e.padding,E=m===void 0?0:m,T=_s(typeof E!="number"?E:ms(E,It)),w=_===At?ts:At,O=n.rects.popper,g=n.elements[A?w:_],v=Si(_t(g)?g:g.contextElement||st(n.elements.popper),l,u,o),b=Nt(n.elements.reference),y=As({reference:b,element:O,placement:i}),S=je(Object.assign({},O,y)),N=_===At?S:b,C={top:v.top-N.top+T.top,bottom:N.bottom-v.bottom+T.bottom,left:v.left-N.left+T.left,right:N.right-v.right+T.right},D=n.modifiersData.offset;if(_===At&&D){var j=D[i];Object.keys(C).forEach(function($){var ot=[x,R].indexOf($)>=0?1:-1,at=[L,R].indexOf($)>=0?"y":"x";C[$]+=j[at]*ot})}return C}function Di(n,t){t===void 0&&(t={});var e=t,s=e.placement,i=e.boundary,r=e.rootBoundary,o=e.padding,a=e.flipVariations,l=e.allowedAutoPlacements,h=l===void 0?Ge:l,u=St(s),p=u?a?We:We.filter(function(A){return St(A)===u}):It,_=p.filter(function(A){return h.indexOf(A)>=0});_.length===0&&(_=p);var f=_.reduce(function(A,m){return A[m]=Dt(n,{placement:m,boundary:i,rootBoundary:r,padding:o})[Y(m)],A},{});return Object.keys(f).sort(function(A,m){return f[A]-f[m]})}function $i(n){if(Y(n)===fe)return[];var t=oe(n);return[vn(n),t,vn(t)]}function Li(n){var t=n.state,e=n.options,s=n.name;if(!t.modifiersData[s]._skip){for(var i=e.mainAxis,r=i===void 0?!0:i,o=e.altAxis,a=o===void 0?!0:o,l=e.fallbackPlacements,h=e.padding,u=e.boundary,p=e.rootBoundary,_=e.altBoundary,f=e.flipVariations,A=f===void 0?!0:f,m=e.allowedAutoPlacements,E=t.options.placement,T=Y(E),w=T===E,O=l||(w||!A?[oe(E)]:$i(E)),g=[E].concat(O).reduce(function(Et,Z){return Et.concat(Y(Z)===fe?Di(t,{placement:Z,boundary:u,rootBoundary:p,padding:h,flipVariations:A,allowedAutoPlacements:m}):Z)},[]),v=t.rects.reference,b=t.rects.popper,y=new Map,S=!0,N=g[0],C=0;C<g.length;C++){var D=g[C],j=Y(D),$=St(D)===pt,ot=[L,R].indexOf(j)>=0,at=ot?"width":"height",P=Dt(t,{placement:D,boundary:u,rootBoundary:p,altBoundary:_,padding:h}),F=ot?$?x:I:$?R:L;v[at]>b[at]&&(F=oe(F));var Gt=oe(F),ct=[];if(r&&ct.push(P[j]<=0),a&&ct.push(P[F]<=0,P[Gt]<=0),ct.every(function(Et){return Et})){N=D,S=!1;break}y.set(D,ct)}if(S)for(var qt=A?3:1,be=function(Z){var kt=g.find(function(Qt){var lt=y.get(Qt);if(lt)return lt.slice(0,Z).every(function(Ae){return Ae})});if(kt)return N=kt,"break"},xt=qt;xt>0;xt--){var Xt=be(xt);if(Xt==="break")break}t.placement!==N&&(t.modifiersData[s]._skip=!0,t.placement=N,t.reset=!0)}}const Ts={name:"flip",enabled:!0,phase:"main",fn:Li,requiresIfExists:["offset"],data:{_skip:!1}};function An(n,t,e){return e===void 0&&(e={x:0,y:0}),{top:n.top-t.height-e.y,right:n.right-t.width+e.x,bottom:n.bottom-t.height+e.y,left:n.left-t.width-e.x}}function Tn(n){return[L,x,R,I].some(function(t){return n[t]>=0})}function Ii(n){var t=n.state,e=n.name,s=t.rects.reference,i=t.rects.popper,r=t.modifiersData.preventOverflow,o=Dt(t,{elementContext:"reference"}),a=Dt(t,{altBoundary:!0}),l=An(o,s),h=An(a,i,r),u=Tn(l),p=Tn(h);t.modifiersData[e]={referenceClippingOffsets:l,popperEscapeOffsets:h,isReferenceHidden:u,hasPopperEscaped:p},t.attributes.popper=Object.assign({},t.attributes.popper,{"data-popper-reference-hidden":u,"data-popper-escaped":p})}const ys={name:"hide",enabled:!0,phase:"main",requiresIfExists:["preventOverflow"],fn:Ii};function Mi(n,t,e){var s=Y(n),i=[I,L].indexOf(s)>=0?-1:1,r=typeof e=="function"?e(Object.assign({},t,{placement:n})):e,o=r[0],a=r[1];return o=o||0,a=(a||0)*i,[I,x].indexOf(s)>=0?{x:a,y:o}:{x:o,y:a}}function Pi(n){var t=n.state,e=n.options,s=n.name,i=e.offset,r=i===void 0?[0,0]:i,o=Ge.reduce(function(u,p){return u[p]=Mi(p,t.rects,r),u},{}),a=o[t.placement],l=a.x,h=a.y;t.modifiersData.popperOffsets!=null&&(t.modifiersData.popperOffsets.x+=l,t.modifiersData.popperOffsets.y+=h),t.modifiersData[s]=o}const ws={name:"offset",enabled:!0,phase:"main",requires:["popperOffsets"],fn:Pi};function Ri(n){var t=n.state,e=n.name;t.modifiersData[e]=As({reference:t.rects.reference,element:t.rects.popper,placement:t.placement})}const Os={name:"popperOffsets",enabled:!0,phase:"read",fn:Ri,data:{}};function xi(n){return n==="x"?"y":"x"}function ki(n){var t=n.state,e=n.options,s=n.name,i=e.mainAxis,r=i===void 0?!0:i,o=e.altAxis,a=o===void 0?!1:o,l=e.boundary,h=e.rootBoundary,u=e.altBoundary,p=e.padding,_=e.tether,f=_===void 0?!0:_,A=e.tetherOffset,m=A===void 0?0:A,E=Dt(t,{boundary:l,rootBoundary:h,padding:p,altBoundary:u}),T=Y(t.placement),w=St(t.placement),O=!w,g=Qe(T),v=xi(g),b=t.modifiersData.popperOffsets,y=t.rects.reference,S=t.rects.popper,N=typeof m=="function"?m(Object.assign({},t.rects,{placement:t.placement})):m,C=typeof N=="number"?{mainAxis:N,altAxis:N}:Object.assign({mainAxis:0,altAxis:0},N),D=t.modifiersData.offset?t.modifiersData.offset[t.placement]:null,j={x:0,y:0};if(b){if(r){var $,ot=g==="y"?L:I,at=g==="y"?R:x,P=g==="y"?"height":"width",F=b[g],Gt=F+E[ot],ct=F-E[at],qt=f?-S[P]/2:0,be=w===pt?y[P]:S[P],xt=w===pt?-S[P]:-y[P],Xt=t.elements.arrow,Et=f&&Xt?Xe(Xt):{width:0,height:0},Z=t.modifiersData["arrow#persistent"]?t.modifiersData["arrow#persistent"].padding:ps(),kt=Z[ot],Qt=Z[at],lt=Wt(0,y[P],Et[P]),Ae=O?y[P]/2-qt-lt-kt-C.mainAxis:be-lt-kt-C.mainAxis,ii=O?-y[P]/2+qt+lt+Qt+C.mainAxis:xt+lt+Qt+C.mainAxis,Te=t.elements.arrow&&Ft(t.elements.arrow),ri=Te?g==="y"?Te.clientTop||0:Te.clientLeft||0:0,cn=($=D?.[g])!=null?$:0,oi=F+Ae-cn-ri,ai=F+ii-cn,ln=Wt(f?le(Gt,oi):Gt,F,f?ft(ct,ai):ct);b[g]=ln,j[g]=ln-F}if(a){var un,ci=g==="x"?L:I,li=g==="x"?R:x,ut=b[v],Zt=v==="y"?"height":"width",hn=ut+E[ci],dn=ut-E[li],ye=[L,I].indexOf(T)!==-1,fn=(un=D?.[v])!=null?un:0,pn=ye?hn:ut-y[Zt]-S[Zt]-fn+C.altAxis,_n=ye?ut+y[Zt]+S[Zt]-fn-C.altAxis:dn,mn=f&&ye?pi(pn,ut,_n):Wt(f?pn:hn,ut,f?_n:dn);b[v]=mn,j[v]=mn-ut}t.modifiersData[s]=j}}const Cs={name:"preventOverflow",enabled:!0,phase:"main",fn:ki,requiresIfExists:["offset"]};function Vi(n){return{scrollLeft:n.scrollLeft,scrollTop:n.scrollTop}}function Hi(n){return n===k(n)||!V(n)?Ze(n):Vi(n)}function Wi(n){var t=n.getBoundingClientRect(),e=Ct(t.width)/n.offsetWidth||1,s=Ct(t.height)/n.offsetHeight||1;return e!==1||s!==1}function Bi(n,t,e){e===void 0&&(e=!1);var s=V(t),i=V(t)&&Wi(t),r=st(t),o=Nt(n,i,e),a={scrollLeft:0,scrollTop:0},l={x:0,y:0};return(s||!s&&!e)&&((z(t)!=="body"||tn(r))&&(a=Hi(t)),V(t)?(l=Nt(t,!0),l.x+=t.clientLeft,l.y+=t.clientTop):r&&(l.x=Je(r))),{x:o.left+a.scrollLeft-l.x,y:o.top+a.scrollTop-l.y,width:o.width,height:o.height}}function ji(n){var t=new Map,e=new Set,s=[];n.forEach(function(r){t.set(r.name,r)});function i(r){e.add(r.name);var o=[].concat(r.requires||[],r.requiresIfExists||[]);o.forEach(function(a){if(!e.has(a)){var l=t.get(a);l&&i(l)}}),s.push(r)}return n.forEach(function(r){e.has(r.name)||i(r)}),s}function Fi(n){var t=ji(n);return us.reduce(function(e,s){return e.concat(t.filter(function(i){return i.phase===s}))},[])}function Ki(n){var t;return function(){return t||(t=new Promise(function(e){Promise.resolve().then(function(){t=void 0,e(n())})})),t}}function Yi(n){var t=n.reduce(function(e,s){var i=e[s.name];return e[s.name]=i?Object.assign({},i,s,{options:Object.assign({},i.options,s.options),data:Object.assign({},i.data,s.data)}):s,e},{});return Object.keys(t).map(function(e){return t[e]})}var yn={placement:"bottom",modifiers:[],strategy:"absolute"};function wn(){for(var n=arguments.length,t=new Array(n),e=0;e<n;e++)t[e]=arguments[e];return!t.some(function(s){return!(s&&typeof s.getBoundingClientRect=="function")})}function Ns(n){n===void 0&&(n={});var t=n,e=t.defaultModifiers,s=e===void 0?[]:e,i=t.defaultOptions,r=i===void 0?yn:i;return function(a,l,h){h===void 0&&(h=r);var u={placement:"bottom",orderedModifiers:[],options:Object.assign({},yn,r),modifiersData:{},elements:{reference:a,popper:l},attributes:{},styles:{}},p=[],_=!1,f={state:u,setOptions:function(T){var w=typeof T=="function"?T(u.options):T;m(),u.options=Object.assign({},r,u.options,w),u.scrollParents={reference:_t(a)?Bt(a):a.contextElement?Bt(a.contextElement):[],popper:Bt(l)};var O=Fi(Yi([].concat(s,u.options.modifiers)));return u.orderedModifiers=O.filter(function(g){return g.enabled}),A(),f.update()},forceUpdate:function(){if(!_){var T=u.elements,w=T.reference,O=T.popper;if(wn(w,O)){u.rects={reference:Bi(w,Ft(O),u.options.strategy==="fixed"),popper:Xe(O)},u.reset=!1,u.placement=u.options.placement,u.orderedModifiers.forEach(function(C){return u.modifiersData[C.name]=Object.assign({},C.data)});for(var g=0;g<u.orderedModifiers.length;g++){if(u.reset===!0){u.reset=!1,g=-1;continue}var v=u.orderedModifiers[g],b=v.fn,y=v.options,S=y===void 0?{}:y,N=v.name;typeof b=="function"&&(u=b({state:u,options:S,name:N,instance:f})||u)}}}},update:Ki(function(){return new Promise(function(E){f.forceUpdate(),E(u)})}),destroy:function(){m(),_=!0}};if(!wn(a,l))return f;f.setOptions(h).then(function(E){!_&&h.onFirstUpdate&&h.onFirstUpdate(E)});function A(){u.orderedModifiers.forEach(function(E){var T=E.name,w=E.options,O=w===void 0?{}:w,g=E.effect;if(typeof g=="function"){var v=g({state:u,name:T,instance:f,options:O}),b=function(){};p.push(v||b)}})}function m(){p.forEach(function(E){return E()}),p=[]}return f}}var Ui=[vs,Os,Es,hs,ws,Ts,Cs,gs,ys],en=Ns({defaultModifiers:Ui});const Ss=Object.freeze(Object.defineProperty({__proto__:null,afterMain:os,afterRead:ss,afterWrite:ls,applyStyles:hs,arrow:gs,auto:fe,basePlacements:It,beforeMain:is,beforeRead:es,beforeWrite:as,bottom:R,clippingParents:Jn,computeStyles:Es,createPopper:en,detectOverflow:Dt,end:Ot,eventListeners:vs,flip:Ts,hide:ys,left:I,main:rs,modifierPhases:us,offset:ws,placements:Ge,popper:At,popperGenerator:Ns,popperOffsets:Os,preventOverflow:Cs,read:ns,reference:ts,right:x,start:pt,top:L,variationPlacements:We,viewport:ze,write:cs},Symbol.toStringTag,{value:"Module"}));/*!
|
|
2
|
+
* Bootstrap v5.3.8 (https://getbootstrap.com/)
|
|
3
|
+
* Copyright 2011-2025 The Bootstrap Authors (https://github.com/twbs/bootstrap/graphs/contributors)
|
|
4
|
+
* Licensed under MIT (https://github.com/twbs/bootstrap/blob/main/LICENSE)
|
|
5
|
+
*/const J=new Map,we={set(n,t,e){J.has(n)||J.set(n,new Map);const s=J.get(n);if(!s.has(t)&&s.size!==0){console.error(`Bootstrap doesn't allow more than one instance per element. Bound instance: ${Array.from(s.keys())[0]}.`);return}s.set(t,e)},get(n,t){return J.has(n)&&J.get(n).get(t)||null},remove(n,t){if(!J.has(n))return;const e=J.get(n);e.delete(t),e.size===0&&J.delete(n)}},zi=1e6,Gi=1e3,Fe="transitionend",Ds=n=>(n&&window.CSS&&window.CSS.escape&&(n=n.replace(/#([^\s"#']+)/g,(t,e)=>`#${CSS.escape(e)}`)),n),qi=n=>n==null?`${n}`:Object.prototype.toString.call(n).match(/\s([a-z]+)/i)[1].toLowerCase(),Xi=n=>{do n+=Math.floor(Math.random()*zi);while(document.getElementById(n));return n},Qi=n=>{if(!n)return 0;let{transitionDuration:t,transitionDelay:e}=window.getComputedStyle(n);const s=Number.parseFloat(t),i=Number.parseFloat(e);return!s&&!i?0:(t=t.split(",")[0],e=e.split(",")[0],(Number.parseFloat(t)+Number.parseFloat(e))*Gi)},$s=n=>{n.dispatchEvent(new Event(Fe))},G=n=>!n||typeof n!="object"?!1:(typeof n.jquery<"u"&&(n=n[0]),typeof n.nodeType<"u"),tt=n=>G(n)?n.jquery?n[0]:n:typeof n=="string"&&n.length>0?document.querySelector(Ds(n)):null,Mt=n=>{if(!G(n)||n.getClientRects().length===0)return!1;const t=getComputedStyle(n).getPropertyValue("visibility")==="visible",e=n.closest("details:not([open])");if(!e)return t;if(e!==n){const s=n.closest("summary");if(s&&s.parentNode!==e||s===null)return!1}return t},et=n=>!n||n.nodeType!==Node.ELEMENT_NODE||n.classList.contains("disabled")?!0:typeof n.disabled<"u"?n.disabled:n.hasAttribute("disabled")&&n.getAttribute("disabled")!=="false",Ls=n=>{if(!document.documentElement.attachShadow)return null;if(typeof n.getRootNode=="function"){const t=n.getRootNode();return t instanceof ShadowRoot?t:null}return n instanceof ShadowRoot?n:n.parentNode?Ls(n.parentNode):null},ue=()=>{},Kt=n=>{n.offsetHeight},Is=()=>window.jQuery&&!document.body.hasAttribute("data-bs-no-jquery")?window.jQuery:null,Oe=[],Zi=n=>{document.readyState==="loading"?(Oe.length||document.addEventListener("DOMContentLoaded",()=>{for(const t of Oe)t()}),Oe.push(n)):n()},H=()=>document.documentElement.dir==="rtl",B=n=>{Zi(()=>{const t=Is();if(t){const e=n.NAME,s=t.fn[e];t.fn[e]=n.jQueryInterface,t.fn[e].Constructor=n,t.fn[e].noConflict=()=>(t.fn[e]=s,n.jQueryInterface)}})},M=(n,t=[],e=n)=>typeof n=="function"?n.call(...t):e,Ms=(n,t,e=!0)=>{if(!e){M(n);return}const i=Qi(t)+5;let r=!1;const o=({target:a})=>{a===t&&(r=!0,t.removeEventListener(Fe,o),M(n))};t.addEventListener(Fe,o),setTimeout(()=>{r||$s(t)},i)},nn=(n,t,e,s)=>{const i=n.length;let r=n.indexOf(t);return r===-1?!e&&s?n[i-1]:n[0]:(r+=e?1:-1,s&&(r=(r+i)%i),n[Math.max(0,Math.min(r,i-1))])},Ji=/[^.]*(?=\..*)\.|.*/,tr=/\..*/,er=/::\d+$/,Ce={};let On=1;const Ps={mouseenter:"mouseover",mouseleave:"mouseout"},nr=new Set(["click","dblclick","mouseup","mousedown","contextmenu","mousewheel","DOMMouseScroll","mouseover","mouseout","mousemove","selectstart","selectend","keydown","keypress","keyup","orientationchange","touchstart","touchmove","touchend","touchcancel","pointerdown","pointermove","pointerup","pointerleave","pointercancel","gesturestart","gesturechange","gestureend","focus","blur","change","reset","select","submit","focusin","focusout","load","unload","beforeunload","resize","move","DOMContentLoaded","readystatechange","error","abort","scroll"]);function Rs(n,t){return t&&`${t}::${On++}`||n.uidEvent||On++}function xs(n){const t=Rs(n);return n.uidEvent=t,Ce[t]=Ce[t]||{},Ce[t]}function sr(n,t){return function e(s){return sn(s,{delegateTarget:n}),e.oneOff&&c.off(n,s.type,t),t.apply(n,[s])}}function ir(n,t,e){return function s(i){const r=n.querySelectorAll(t);for(let{target:o}=i;o&&o!==this;o=o.parentNode)for(const a of r)if(a===o)return sn(i,{delegateTarget:o}),s.oneOff&&c.off(n,i.type,t,e),e.apply(o,[i])}}function ks(n,t,e=null){return Object.values(n).find(s=>s.callable===t&&s.delegationSelector===e)}function Vs(n,t,e){const s=typeof t=="string",i=s?e:t||e;let r=Hs(n);return nr.has(r)||(r=n),[s,i,r]}function Cn(n,t,e,s,i){if(typeof t!="string"||!n)return;let[r,o,a]=Vs(t,e,s);t in Ps&&(o=(A=>function(m){if(!m.relatedTarget||m.relatedTarget!==m.delegateTarget&&!m.delegateTarget.contains(m.relatedTarget))return A.call(this,m)})(o));const l=xs(n),h=l[a]||(l[a]={}),u=ks(h,o,r?e:null);if(u){u.oneOff=u.oneOff&&i;return}const p=Rs(o,t.replace(Ji,"")),_=r?ir(n,e,o):sr(n,o);_.delegationSelector=r?e:null,_.callable=o,_.oneOff=i,_.uidEvent=p,h[p]=_,n.addEventListener(a,_,r)}function Ke(n,t,e,s,i){const r=ks(t[e],s,i);r&&(n.removeEventListener(e,r,!!i),delete t[e][r.uidEvent])}function rr(n,t,e,s){const i=t[e]||{};for(const[r,o]of Object.entries(i))r.includes(s)&&Ke(n,t,e,o.callable,o.delegationSelector)}function Hs(n){return n=n.replace(tr,""),Ps[n]||n}const c={on(n,t,e,s){Cn(n,t,e,s,!1)},one(n,t,e,s){Cn(n,t,e,s,!0)},off(n,t,e,s){if(typeof t!="string"||!n)return;const[i,r,o]=Vs(t,e,s),a=o!==t,l=xs(n),h=l[o]||{},u=t.startsWith(".");if(typeof r<"u"){if(!Object.keys(h).length)return;Ke(n,l,o,r,i?e:null);return}if(u)for(const p of Object.keys(l))rr(n,l,p,t.slice(1));for(const[p,_]of Object.entries(h)){const f=p.replace(er,"");(!a||t.includes(f))&&Ke(n,l,o,_.callable,_.delegationSelector)}},trigger(n,t,e){if(typeof t!="string"||!n)return null;const s=Is(),i=Hs(t),r=t!==i;let o=null,a=!0,l=!0,h=!1;r&&s&&(o=s.Event(t,e),s(n).trigger(o),a=!o.isPropagationStopped(),l=!o.isImmediatePropagationStopped(),h=o.isDefaultPrevented());const u=sn(new Event(t,{bubbles:a,cancelable:!0}),e);return h&&u.preventDefault(),l&&n.dispatchEvent(u),u.defaultPrevented&&o&&o.preventDefault(),u}};function sn(n,t={}){for(const[e,s]of Object.entries(t))try{n[e]=s}catch{Object.defineProperty(n,e,{configurable:!0,get(){return s}})}return n}function Nn(n){if(n==="true")return!0;if(n==="false")return!1;if(n===Number(n).toString())return Number(n);if(n===""||n==="null")return null;if(typeof n!="string")return n;try{return JSON.parse(decodeURIComponent(n))}catch{return n}}function Ne(n){return n.replace(/[A-Z]/g,t=>`-${t.toLowerCase()}`)}const q={setDataAttribute(n,t,e){n.setAttribute(`data-bs-${Ne(t)}`,e)},removeDataAttribute(n,t){n.removeAttribute(`data-bs-${Ne(t)}`)},getDataAttributes(n){if(!n)return{};const t={},e=Object.keys(n.dataset).filter(s=>s.startsWith("bs")&&!s.startsWith("bsConfig"));for(const s of e){let i=s.replace(/^bs/,"");i=i.charAt(0).toLowerCase()+i.slice(1),t[i]=Nn(n.dataset[s])}return t},getDataAttribute(n,t){return Nn(n.getAttribute(`data-bs-${Ne(t)}`))}};class Yt{static get Default(){return{}}static get DefaultType(){return{}}static get NAME(){throw new Error('You have to implement the static method "NAME", for each component!')}_getConfig(t){return t=this._mergeConfigObj(t),t=this._configAfterMerge(t),this._typeCheckConfig(t),t}_configAfterMerge(t){return t}_mergeConfigObj(t,e){const s=G(e)?q.getDataAttribute(e,"config"):{};return{...this.constructor.Default,...typeof s=="object"?s:{},...G(e)?q.getDataAttributes(e):{},...typeof t=="object"?t:{}}}_typeCheckConfig(t,e=this.constructor.DefaultType){for(const[s,i]of Object.entries(e)){const r=t[s],o=G(r)?"element":qi(r);if(!new RegExp(i).test(o))throw new TypeError(`${this.constructor.NAME.toUpperCase()}: Option "${s}" provided type "${o}" but expected type "${i}".`)}}}const or="5.3.8";class K extends Yt{constructor(t,e){super(),t=tt(t),t&&(this._element=t,this._config=this._getConfig(e),we.set(this._element,this.constructor.DATA_KEY,this))}dispose(){we.remove(this._element,this.constructor.DATA_KEY),c.off(this._element,this.constructor.EVENT_KEY);for(const t of Object.getOwnPropertyNames(this))this[t]=null}_queueCallback(t,e,s=!0){Ms(t,e,s)}_getConfig(t){return t=this._mergeConfigObj(t,this._element),t=this._configAfterMerge(t),this._typeCheckConfig(t),t}static getInstance(t){return we.get(tt(t),this.DATA_KEY)}static getOrCreateInstance(t,e={}){return this.getInstance(t)||new this(t,typeof e=="object"?e:null)}static get VERSION(){return or}static get DATA_KEY(){return`bs.${this.NAME}`}static get EVENT_KEY(){return`.${this.DATA_KEY}`}static eventName(t){return`${t}${this.EVENT_KEY}`}}const Se=n=>{let t=n.getAttribute("data-bs-target");if(!t||t==="#"){let e=n.getAttribute("href");if(!e||!e.includes("#")&&!e.startsWith("."))return null;e.includes("#")&&!e.startsWith("#")&&(e=`#${e.split("#")[1]}`),t=e&&e!=="#"?e.trim():null}return t?t.split(",").map(e=>Ds(e)).join(","):null},d={find(n,t=document.documentElement){return[].concat(...Element.prototype.querySelectorAll.call(t,n))},findOne(n,t=document.documentElement){return Element.prototype.querySelector.call(t,n)},children(n,t){return[].concat(...n.children).filter(e=>e.matches(t))},parents(n,t){const e=[];let s=n.parentNode.closest(t);for(;s;)e.push(s),s=s.parentNode.closest(t);return e},prev(n,t){let e=n.previousElementSibling;for(;e;){if(e.matches(t))return[e];e=e.previousElementSibling}return[]},next(n,t){let e=n.nextElementSibling;for(;e;){if(e.matches(t))return[e];e=e.nextElementSibling}return[]},focusableChildren(n){const t=["a","button","input","textarea","select","details","[tabindex]",'[contenteditable="true"]'].map(e=>`${e}:not([tabindex^="-"])`).join(",");return this.find(t,n).filter(e=>!et(e)&&Mt(e))},getSelectorFromElement(n){const t=Se(n);return t&&d.findOne(t)?t:null},getElementFromSelector(n){const t=Se(n);return t?d.findOne(t):null},getMultipleElementsFromSelector(n){const t=Se(n);return t?d.find(t):[]}},_e=(n,t="hide")=>{const e=`click.dismiss${n.EVENT_KEY}`,s=n.NAME;c.on(document,e,`[data-bs-dismiss="${s}"]`,function(i){if(["A","AREA"].includes(this.tagName)&&i.preventDefault(),et(this))return;const r=d.getElementFromSelector(this)||this.closest(`.${s}`);n.getOrCreateInstance(r)[t]()})},ar="alert",cr="bs.alert",Ws=`.${cr}`,lr=`close${Ws}`,ur=`closed${Ws}`,hr="fade",dr="show";class me extends K{static get NAME(){return ar}close(){if(c.trigger(this._element,lr).defaultPrevented)return;this._element.classList.remove(dr);const e=this._element.classList.contains(hr);this._queueCallback(()=>this._destroyElement(),this._element,e)}_destroyElement(){this._element.remove(),c.trigger(this._element,ur),this.dispose()}static jQueryInterface(t){return this.each(function(){const e=me.getOrCreateInstance(this);if(typeof t=="string"){if(e[t]===void 0||t.startsWith("_")||t==="constructor")throw new TypeError(`No method named "${t}"`);e[t](this)}})}}_e(me,"close");B(me);const fr="button",pr="bs.button",_r=`.${pr}`,mr=".data-api",gr="active",Sn='[data-bs-toggle="button"]',Er=`click${_r}${mr}`;class ge extends K{static get NAME(){return fr}toggle(){this._element.setAttribute("aria-pressed",this._element.classList.toggle(gr))}static jQueryInterface(t){return this.each(function(){const e=ge.getOrCreateInstance(this);t==="toggle"&&e[t]()})}}c.on(document,Er,Sn,n=>{n.preventDefault();const t=n.target.closest(Sn);ge.getOrCreateInstance(t).toggle()});B(ge);const vr="swipe",Pt=".bs.swipe",br=`touchstart${Pt}`,Ar=`touchmove${Pt}`,Tr=`touchend${Pt}`,yr=`pointerdown${Pt}`,wr=`pointerup${Pt}`,Or="touch",Cr="pen",Nr="pointer-event",Sr=40,Dr={endCallback:null,leftCallback:null,rightCallback:null},$r={endCallback:"(function|null)",leftCallback:"(function|null)",rightCallback:"(function|null)"};class he extends Yt{constructor(t,e){super(),this._element=t,!(!t||!he.isSupported())&&(this._config=this._getConfig(e),this._deltaX=0,this._supportPointerEvents=!!window.PointerEvent,this._initEvents())}static get Default(){return Dr}static get DefaultType(){return $r}static get NAME(){return vr}dispose(){c.off(this._element,Pt)}_start(t){if(!this._supportPointerEvents){this._deltaX=t.touches[0].clientX;return}this._eventIsPointerPenTouch(t)&&(this._deltaX=t.clientX)}_end(t){this._eventIsPointerPenTouch(t)&&(this._deltaX=t.clientX-this._deltaX),this._handleSwipe(),M(this._config.endCallback)}_move(t){this._deltaX=t.touches&&t.touches.length>1?0:t.touches[0].clientX-this._deltaX}_handleSwipe(){const t=Math.abs(this._deltaX);if(t<=Sr)return;const e=t/this._deltaX;this._deltaX=0,e&&M(e>0?this._config.rightCallback:this._config.leftCallback)}_initEvents(){this._supportPointerEvents?(c.on(this._element,yr,t=>this._start(t)),c.on(this._element,wr,t=>this._end(t)),this._element.classList.add(Nr)):(c.on(this._element,br,t=>this._start(t)),c.on(this._element,Ar,t=>this._move(t)),c.on(this._element,Tr,t=>this._end(t)))}_eventIsPointerPenTouch(t){return this._supportPointerEvents&&(t.pointerType===Cr||t.pointerType===Or)}static isSupported(){return"ontouchstart"in document.documentElement||navigator.maxTouchPoints>0}}const Lr="carousel",Ir="bs.carousel",it=`.${Ir}`,Bs=".data-api",Mr="ArrowLeft",Pr="ArrowRight",Rr=500,Vt="next",vt="prev",Tt="left",ae="right",xr=`slide${it}`,De=`slid${it}`,kr=`keydown${it}`,Vr=`mouseenter${it}`,Hr=`mouseleave${it}`,Wr=`dragstart${it}`,Br=`load${it}${Bs}`,jr=`click${it}${Bs}`,js="carousel",te="active",Fr="slide",Kr="carousel-item-end",Yr="carousel-item-start",Ur="carousel-item-next",zr="carousel-item-prev",Fs=".active",Ks=".carousel-item",Gr=Fs+Ks,qr=".carousel-item img",Xr=".carousel-indicators",Qr="[data-bs-slide], [data-bs-slide-to]",Zr='[data-bs-ride="carousel"]',Jr={[Mr]:ae,[Pr]:Tt},to={interval:5e3,keyboard:!0,pause:"hover",ride:!1,touch:!0,wrap:!0},eo={interval:"(number|boolean)",keyboard:"boolean",pause:"(string|boolean)",ride:"(boolean|string)",touch:"boolean",wrap:"boolean"};class Ut extends K{constructor(t,e){super(t,e),this._interval=null,this._activeElement=null,this._isSliding=!1,this.touchTimeout=null,this._swipeHelper=null,this._indicatorsElement=d.findOne(Xr,this._element),this._addEventListeners(),this._config.ride===js&&this.cycle()}static get Default(){return to}static get DefaultType(){return eo}static get NAME(){return Lr}next(){this._slide(Vt)}nextWhenVisible(){!document.hidden&&Mt(this._element)&&this.next()}prev(){this._slide(vt)}pause(){this._isSliding&&$s(this._element),this._clearInterval()}cycle(){this._clearInterval(),this._updateInterval(),this._interval=setInterval(()=>this.nextWhenVisible(),this._config.interval)}_maybeEnableCycle(){if(this._config.ride){if(this._isSliding){c.one(this._element,De,()=>this.cycle());return}this.cycle()}}to(t){const e=this._getItems();if(t>e.length-1||t<0)return;if(this._isSliding){c.one(this._element,De,()=>this.to(t));return}const s=this._getItemIndex(this._getActive());if(s===t)return;const i=t>s?Vt:vt;this._slide(i,e[t])}dispose(){this._swipeHelper&&this._swipeHelper.dispose(),super.dispose()}_configAfterMerge(t){return t.defaultInterval=t.interval,t}_addEventListeners(){this._config.keyboard&&c.on(this._element,kr,t=>this._keydown(t)),this._config.pause==="hover"&&(c.on(this._element,Vr,()=>this.pause()),c.on(this._element,Hr,()=>this._maybeEnableCycle())),this._config.touch&&he.isSupported()&&this._addTouchEventListeners()}_addTouchEventListeners(){for(const s of d.find(qr,this._element))c.on(s,Wr,i=>i.preventDefault());const e={leftCallback:()=>this._slide(this._directionToOrder(Tt)),rightCallback:()=>this._slide(this._directionToOrder(ae)),endCallback:()=>{this._config.pause==="hover"&&(this.pause(),this.touchTimeout&&clearTimeout(this.touchTimeout),this.touchTimeout=setTimeout(()=>this._maybeEnableCycle(),Rr+this._config.interval))}};this._swipeHelper=new he(this._element,e)}_keydown(t){if(/input|textarea/i.test(t.target.tagName))return;const e=Jr[t.key];e&&(t.preventDefault(),this._slide(this._directionToOrder(e)))}_getItemIndex(t){return this._getItems().indexOf(t)}_setActiveIndicatorElement(t){if(!this._indicatorsElement)return;const e=d.findOne(Fs,this._indicatorsElement);e.classList.remove(te),e.removeAttribute("aria-current");const s=d.findOne(`[data-bs-slide-to="${t}"]`,this._indicatorsElement);s&&(s.classList.add(te),s.setAttribute("aria-current","true"))}_updateInterval(){const t=this._activeElement||this._getActive();if(!t)return;const e=Number.parseInt(t.getAttribute("data-bs-interval"),10);this._config.interval=e||this._config.defaultInterval}_slide(t,e=null){if(this._isSliding)return;const s=this._getActive(),i=t===Vt,r=e||nn(this._getItems(),s,i,this._config.wrap);if(r===s)return;const o=this._getItemIndex(r),a=f=>c.trigger(this._element,f,{relatedTarget:r,direction:this._orderToDirection(t),from:this._getItemIndex(s),to:o});if(a(xr).defaultPrevented||!s||!r)return;const h=!!this._interval;this.pause(),this._isSliding=!0,this._setActiveIndicatorElement(o),this._activeElement=r;const u=i?Yr:Kr,p=i?Ur:zr;r.classList.add(p),Kt(r),s.classList.add(u),r.classList.add(u);const _=()=>{r.classList.remove(u,p),r.classList.add(te),s.classList.remove(te,p,u),this._isSliding=!1,a(De)};this._queueCallback(_,s,this._isAnimated()),h&&this.cycle()}_isAnimated(){return this._element.classList.contains(Fr)}_getActive(){return d.findOne(Gr,this._element)}_getItems(){return d.find(Ks,this._element)}_clearInterval(){this._interval&&(clearInterval(this._interval),this._interval=null)}_directionToOrder(t){return H()?t===Tt?vt:Vt:t===Tt?Vt:vt}_orderToDirection(t){return H()?t===vt?Tt:ae:t===vt?ae:Tt}static jQueryInterface(t){return this.each(function(){const e=Ut.getOrCreateInstance(this,t);if(typeof t=="number"){e.to(t);return}if(typeof t=="string"){if(e[t]===void 0||t.startsWith("_")||t==="constructor")throw new TypeError(`No method named "${t}"`);e[t]()}})}}c.on(document,jr,Qr,function(n){const t=d.getElementFromSelector(this);if(!t||!t.classList.contains(js))return;n.preventDefault();const e=Ut.getOrCreateInstance(t),s=this.getAttribute("data-bs-slide-to");if(s){e.to(s),e._maybeEnableCycle();return}if(q.getDataAttribute(this,"slide")==="next"){e.next(),e._maybeEnableCycle();return}e.prev(),e._maybeEnableCycle()});c.on(window,Br,()=>{const n=d.find(Zr);for(const t of n)Ut.getOrCreateInstance(t)});B(Ut);const no="collapse",so="bs.collapse",zt=`.${so}`,io=".data-api",ro=`show${zt}`,oo=`shown${zt}`,ao=`hide${zt}`,co=`hidden${zt}`,lo=`click${zt}${io}`,$e="show",wt="collapse",ee="collapsing",uo="collapsed",ho=`:scope .${wt} .${wt}`,fo="collapse-horizontal",po="width",_o="height",mo=".collapse.show, .collapse.collapsing",Ye='[data-bs-toggle="collapse"]',go={parent:null,toggle:!0},Eo={parent:"(null|element)",toggle:"boolean"};class jt extends K{constructor(t,e){super(t,e),this._isTransitioning=!1,this._triggerArray=[];const s=d.find(Ye);for(const i of s){const r=d.getSelectorFromElement(i),o=d.find(r).filter(a=>a===this._element);r!==null&&o.length&&this._triggerArray.push(i)}this._initializeChildren(),this._config.parent||this._addAriaAndCollapsedClass(this._triggerArray,this._isShown()),this._config.toggle&&this.toggle()}static get Default(){return go}static get DefaultType(){return Eo}static get NAME(){return no}toggle(){this._isShown()?this.hide():this.show()}show(){if(this._isTransitioning||this._isShown())return;let t=[];if(this._config.parent&&(t=this._getFirstLevelChildren(mo).filter(a=>a!==this._element).map(a=>jt.getOrCreateInstance(a,{toggle:!1}))),t.length&&t[0]._isTransitioning||c.trigger(this._element,ro).defaultPrevented)return;for(const a of t)a.hide();const s=this._getDimension();this._element.classList.remove(wt),this._element.classList.add(ee),this._element.style[s]=0,this._addAriaAndCollapsedClass(this._triggerArray,!0),this._isTransitioning=!0;const i=()=>{this._isTransitioning=!1,this._element.classList.remove(ee),this._element.classList.add(wt,$e),this._element.style[s]="",c.trigger(this._element,oo)},o=`scroll${s[0].toUpperCase()+s.slice(1)}`;this._queueCallback(i,this._element,!0),this._element.style[s]=`${this._element[o]}px`}hide(){if(this._isTransitioning||!this._isShown()||c.trigger(this._element,ao).defaultPrevented)return;const e=this._getDimension();this._element.style[e]=`${this._element.getBoundingClientRect()[e]}px`,Kt(this._element),this._element.classList.add(ee),this._element.classList.remove(wt,$e);for(const i of this._triggerArray){const r=d.getElementFromSelector(i);r&&!this._isShown(r)&&this._addAriaAndCollapsedClass([i],!1)}this._isTransitioning=!0;const s=()=>{this._isTransitioning=!1,this._element.classList.remove(ee),this._element.classList.add(wt),c.trigger(this._element,co)};this._element.style[e]="",this._queueCallback(s,this._element,!0)}_isShown(t=this._element){return t.classList.contains($e)}_configAfterMerge(t){return t.toggle=!!t.toggle,t.parent=tt(t.parent),t}_getDimension(){return this._element.classList.contains(fo)?po:_o}_initializeChildren(){if(!this._config.parent)return;const t=this._getFirstLevelChildren(Ye);for(const e of t){const s=d.getElementFromSelector(e);s&&this._addAriaAndCollapsedClass([e],this._isShown(s))}}_getFirstLevelChildren(t){const e=d.find(ho,this._config.parent);return d.find(t,this._config.parent).filter(s=>!e.includes(s))}_addAriaAndCollapsedClass(t,e){if(t.length)for(const s of t)s.classList.toggle(uo,!e),s.setAttribute("aria-expanded",e)}static jQueryInterface(t){const e={};return typeof t=="string"&&/show|hide/.test(t)&&(e.toggle=!1),this.each(function(){const s=jt.getOrCreateInstance(this,e);if(typeof t=="string"){if(typeof s[t]>"u")throw new TypeError(`No method named "${t}"`);s[t]()}})}}c.on(document,lo,Ye,function(n){(n.target.tagName==="A"||n.delegateTarget&&n.delegateTarget.tagName==="A")&&n.preventDefault();for(const t of d.getMultipleElementsFromSelector(this))jt.getOrCreateInstance(t,{toggle:!1}).toggle()});B(jt);const Dn="dropdown",vo="bs.dropdown",mt=`.${vo}`,rn=".data-api",bo="Escape",$n="Tab",Ao="ArrowUp",Ln="ArrowDown",To=2,yo=`hide${mt}`,wo=`hidden${mt}`,Oo=`show${mt}`,Co=`shown${mt}`,Ys=`click${mt}${rn}`,Us=`keydown${mt}${rn}`,No=`keyup${mt}${rn}`,yt="show",So="dropup",Do="dropend",$o="dropstart",Lo="dropup-center",Io="dropdown-center",ht='[data-bs-toggle="dropdown"]:not(.disabled):not(:disabled)',Mo=`${ht}.${yt}`,ce=".dropdown-menu",Po=".navbar",Ro=".navbar-nav",xo=".dropdown-menu .dropdown-item:not(.disabled):not(:disabled)",ko=H()?"top-end":"top-start",Vo=H()?"top-start":"top-end",Ho=H()?"bottom-end":"bottom-start",Wo=H()?"bottom-start":"bottom-end",Bo=H()?"left-start":"right-start",jo=H()?"right-start":"left-start",Fo="top",Ko="bottom",Yo={autoClose:!0,boundary:"clippingParents",display:"dynamic",offset:[0,2],popperConfig:null,reference:"toggle"},Uo={autoClose:"(boolean|string)",boundary:"(string|element)",display:"string",offset:"(array|string|function)",popperConfig:"(null|object|function)",reference:"(string|element|object)"};class U extends K{constructor(t,e){super(t,e),this._popper=null,this._parent=this._element.parentNode,this._menu=d.next(this._element,ce)[0]||d.prev(this._element,ce)[0]||d.findOne(ce,this._parent),this._inNavbar=this._detectNavbar()}static get Default(){return Yo}static get DefaultType(){return Uo}static get NAME(){return Dn}toggle(){return this._isShown()?this.hide():this.show()}show(){if(et(this._element)||this._isShown())return;const t={relatedTarget:this._element};if(!c.trigger(this._element,Oo,t).defaultPrevented){if(this._createPopper(),"ontouchstart"in document.documentElement&&!this._parent.closest(Ro))for(const s of[].concat(...document.body.children))c.on(s,"mouseover",ue);this._element.focus(),this._element.setAttribute("aria-expanded",!0),this._menu.classList.add(yt),this._element.classList.add(yt),c.trigger(this._element,Co,t)}}hide(){if(et(this._element)||!this._isShown())return;const t={relatedTarget:this._element};this._completeHide(t)}dispose(){this._popper&&this._popper.destroy(),super.dispose()}update(){this._inNavbar=this._detectNavbar(),this._popper&&this._popper.update()}_completeHide(t){if(!c.trigger(this._element,yo,t).defaultPrevented){if("ontouchstart"in document.documentElement)for(const s of[].concat(...document.body.children))c.off(s,"mouseover",ue);this._popper&&this._popper.destroy(),this._menu.classList.remove(yt),this._element.classList.remove(yt),this._element.setAttribute("aria-expanded","false"),q.removeDataAttribute(this._menu,"popper"),c.trigger(this._element,wo,t)}}_getConfig(t){if(t=super._getConfig(t),typeof t.reference=="object"&&!G(t.reference)&&typeof t.reference.getBoundingClientRect!="function")throw new TypeError(`${Dn.toUpperCase()}: Option "reference" provided type "object" without a required "getBoundingClientRect" method.`);return t}_createPopper(){if(typeof Ss>"u")throw new TypeError("Bootstrap's dropdowns require Popper (https://popper.js.org/docs/v2/)");let t=this._element;this._config.reference==="parent"?t=this._parent:G(this._config.reference)?t=tt(this._config.reference):typeof this._config.reference=="object"&&(t=this._config.reference);const e=this._getPopperConfig();this._popper=en(t,this._menu,e)}_isShown(){return this._menu.classList.contains(yt)}_getPlacement(){const t=this._parent;if(t.classList.contains(Do))return Bo;if(t.classList.contains($o))return jo;if(t.classList.contains(Lo))return Fo;if(t.classList.contains(Io))return Ko;const e=getComputedStyle(this._menu).getPropertyValue("--bs-position").trim()==="end";return t.classList.contains(So)?e?Vo:ko:e?Wo:Ho}_detectNavbar(){return this._element.closest(Po)!==null}_getOffset(){const{offset:t}=this._config;return typeof t=="string"?t.split(",").map(e=>Number.parseInt(e,10)):typeof t=="function"?e=>t(e,this._element):t}_getPopperConfig(){const t={placement:this._getPlacement(),modifiers:[{name:"preventOverflow",options:{boundary:this._config.boundary}},{name:"offset",options:{offset:this._getOffset()}}]};return(this._inNavbar||this._config.display==="static")&&(q.setDataAttribute(this._menu,"popper","static"),t.modifiers=[{name:"applyStyles",enabled:!1}]),{...t,...M(this._config.popperConfig,[void 0,t])}}_selectMenuItem({key:t,target:e}){const s=d.find(xo,this._menu).filter(i=>Mt(i));s.length&&nn(s,e,t===Ln,!s.includes(e)).focus()}static jQueryInterface(t){return this.each(function(){const e=U.getOrCreateInstance(this,t);if(typeof t=="string"){if(typeof e[t]>"u")throw new TypeError(`No method named "${t}"`);e[t]()}})}static clearMenus(t){if(t.button===To||t.type==="keyup"&&t.key!==$n)return;const e=d.find(Mo);for(const s of e){const i=U.getInstance(s);if(!i||i._config.autoClose===!1)continue;const r=t.composedPath(),o=r.includes(i._menu);if(r.includes(i._element)||i._config.autoClose==="inside"&&!o||i._config.autoClose==="outside"&&o||i._menu.contains(t.target)&&(t.type==="keyup"&&t.key===$n||/input|select|option|textarea|form/i.test(t.target.tagName)))continue;const a={relatedTarget:i._element};t.type==="click"&&(a.clickEvent=t),i._completeHide(a)}}static dataApiKeydownHandler(t){const e=/input|textarea/i.test(t.target.tagName),s=t.key===bo,i=[Ao,Ln].includes(t.key);if(!i&&!s||e&&!s)return;t.preventDefault();const r=this.matches(ht)?this:d.prev(this,ht)[0]||d.next(this,ht)[0]||d.findOne(ht,t.delegateTarget.parentNode),o=U.getOrCreateInstance(r);if(i){t.stopPropagation(),o.show(),o._selectMenuItem(t);return}o._isShown()&&(t.stopPropagation(),o.hide(),r.focus())}}c.on(document,Us,ht,U.dataApiKeydownHandler);c.on(document,Us,ce,U.dataApiKeydownHandler);c.on(document,Ys,U.clearMenus);c.on(document,No,U.clearMenus);c.on(document,Ys,ht,function(n){n.preventDefault(),U.getOrCreateInstance(this).toggle()});B(U);const zs="backdrop",zo="fade",In="show",Mn=`mousedown.bs.${zs}`,Go={className:"modal-backdrop",clickCallback:null,isAnimated:!1,isVisible:!0,rootElement:"body"},qo={className:"string",clickCallback:"(function|null)",isAnimated:"boolean",isVisible:"boolean",rootElement:"(element|string)"};class Gs extends Yt{constructor(t){super(),this._config=this._getConfig(t),this._isAppended=!1,this._element=null}static get Default(){return Go}static get DefaultType(){return qo}static get NAME(){return zs}show(t){if(!this._config.isVisible){M(t);return}this._append();const e=this._getElement();this._config.isAnimated&&Kt(e),e.classList.add(In),this._emulateAnimation(()=>{M(t)})}hide(t){if(!this._config.isVisible){M(t);return}this._getElement().classList.remove(In),this._emulateAnimation(()=>{this.dispose(),M(t)})}dispose(){this._isAppended&&(c.off(this._element,Mn),this._element.remove(),this._isAppended=!1)}_getElement(){if(!this._element){const t=document.createElement("div");t.className=this._config.className,this._config.isAnimated&&t.classList.add(zo),this._element=t}return this._element}_configAfterMerge(t){return t.rootElement=tt(t.rootElement),t}_append(){if(this._isAppended)return;const t=this._getElement();this._config.rootElement.append(t),c.on(t,Mn,()=>{M(this._config.clickCallback)}),this._isAppended=!0}_emulateAnimation(t){Ms(t,this._getElement(),this._config.isAnimated)}}const Xo="focustrap",Qo="bs.focustrap",de=`.${Qo}`,Zo=`focusin${de}`,Jo=`keydown.tab${de}`,ta="Tab",ea="forward",Pn="backward",na={autofocus:!0,trapElement:null},sa={autofocus:"boolean",trapElement:"element"};class qs extends Yt{constructor(t){super(),this._config=this._getConfig(t),this._isActive=!1,this._lastTabNavDirection=null}static get Default(){return na}static get DefaultType(){return sa}static get NAME(){return Xo}activate(){this._isActive||(this._config.autofocus&&this._config.trapElement.focus(),c.off(document,de),c.on(document,Zo,t=>this._handleFocusin(t)),c.on(document,Jo,t=>this._handleKeydown(t)),this._isActive=!0)}deactivate(){this._isActive&&(this._isActive=!1,c.off(document,de))}_handleFocusin(t){const{trapElement:e}=this._config;if(t.target===document||t.target===e||e.contains(t.target))return;const s=d.focusableChildren(e);s.length===0?e.focus():this._lastTabNavDirection===Pn?s[s.length-1].focus():s[0].focus()}_handleKeydown(t){t.key===ta&&(this._lastTabNavDirection=t.shiftKey?Pn:ea)}}const Rn=".fixed-top, .fixed-bottom, .is-fixed, .sticky-top",xn=".sticky-top",ne="padding-right",kn="margin-right";class Ue{constructor(){this._element=document.body}getWidth(){const t=document.documentElement.clientWidth;return Math.abs(window.innerWidth-t)}hide(){const t=this.getWidth();this._disableOverFlow(),this._setElementAttributes(this._element,ne,e=>e+t),this._setElementAttributes(Rn,ne,e=>e+t),this._setElementAttributes(xn,kn,e=>e-t)}reset(){this._resetElementAttributes(this._element,"overflow"),this._resetElementAttributes(this._element,ne),this._resetElementAttributes(Rn,ne),this._resetElementAttributes(xn,kn)}isOverflowing(){return this.getWidth()>0}_disableOverFlow(){this._saveInitialAttribute(this._element,"overflow"),this._element.style.overflow="hidden"}_setElementAttributes(t,e,s){const i=this.getWidth(),r=o=>{if(o!==this._element&&window.innerWidth>o.clientWidth+i)return;this._saveInitialAttribute(o,e);const a=window.getComputedStyle(o).getPropertyValue(e);o.style.setProperty(e,`${s(Number.parseFloat(a))}px`)};this._applyManipulationCallback(t,r)}_saveInitialAttribute(t,e){const s=t.style.getPropertyValue(e);s&&q.setDataAttribute(t,e,s)}_resetElementAttributes(t,e){const s=i=>{const r=q.getDataAttribute(i,e);if(r===null){i.style.removeProperty(e);return}q.removeDataAttribute(i,e),i.style.setProperty(e,r)};this._applyManipulationCallback(t,s)}_applyManipulationCallback(t,e){if(G(t)){e(t);return}for(const s of d.find(t,this._element))e(s)}}const ia="modal",ra="bs.modal",W=`.${ra}`,oa=".data-api",aa="Escape",ca=`hide${W}`,la=`hidePrevented${W}`,Xs=`hidden${W}`,Qs=`show${W}`,ua=`shown${W}`,ha=`resize${W}`,da=`click.dismiss${W}`,fa=`mousedown.dismiss${W}`,pa=`keydown.dismiss${W}`,_a=`click${W}${oa}`,Vn="modal-open",ma="fade",Hn="show",Le="modal-static",ga=".modal.show",Ea=".modal-dialog",va=".modal-body",ba='[data-bs-toggle="modal"]',Aa={backdrop:!0,focus:!0,keyboard:!0},Ta={backdrop:"(boolean|string)",focus:"boolean",keyboard:"boolean"};class $t extends K{constructor(t,e){super(t,e),this._dialog=d.findOne(Ea,this._element),this._backdrop=this._initializeBackDrop(),this._focustrap=this._initializeFocusTrap(),this._isShown=!1,this._isTransitioning=!1,this._scrollBar=new Ue,this._addEventListeners()}static get Default(){return Aa}static get DefaultType(){return Ta}static get NAME(){return ia}toggle(t){return this._isShown?this.hide():this.show(t)}show(t){this._isShown||this._isTransitioning||c.trigger(this._element,Qs,{relatedTarget:t}).defaultPrevented||(this._isShown=!0,this._isTransitioning=!0,this._scrollBar.hide(),document.body.classList.add(Vn),this._adjustDialog(),this._backdrop.show(()=>this._showElement(t)))}hide(){!this._isShown||this._isTransitioning||c.trigger(this._element,ca).defaultPrevented||(this._isShown=!1,this._isTransitioning=!0,this._focustrap.deactivate(),this._element.classList.remove(Hn),this._queueCallback(()=>this._hideModal(),this._element,this._isAnimated()))}dispose(){c.off(window,W),c.off(this._dialog,W),this._backdrop.dispose(),this._focustrap.deactivate(),super.dispose()}handleUpdate(){this._adjustDialog()}_initializeBackDrop(){return new Gs({isVisible:!!this._config.backdrop,isAnimated:this._isAnimated()})}_initializeFocusTrap(){return new qs({trapElement:this._element})}_showElement(t){document.body.contains(this._element)||document.body.append(this._element),this._element.style.display="block",this._element.removeAttribute("aria-hidden"),this._element.setAttribute("aria-modal",!0),this._element.setAttribute("role","dialog"),this._element.scrollTop=0;const e=d.findOne(va,this._dialog);e&&(e.scrollTop=0),Kt(this._element),this._element.classList.add(Hn);const s=()=>{this._config.focus&&this._focustrap.activate(),this._isTransitioning=!1,c.trigger(this._element,ua,{relatedTarget:t})};this._queueCallback(s,this._dialog,this._isAnimated())}_addEventListeners(){c.on(this._element,pa,t=>{if(t.key===aa){if(this._config.keyboard){this.hide();return}this._triggerBackdropTransition()}}),c.on(window,ha,()=>{this._isShown&&!this._isTransitioning&&this._adjustDialog()}),c.on(this._element,fa,t=>{c.one(this._element,da,e=>{if(!(this._element!==t.target||this._element!==e.target)){if(this._config.backdrop==="static"){this._triggerBackdropTransition();return}this._config.backdrop&&this.hide()}})})}_hideModal(){this._element.style.display="none",this._element.setAttribute("aria-hidden",!0),this._element.removeAttribute("aria-modal"),this._element.removeAttribute("role"),this._isTransitioning=!1,this._backdrop.hide(()=>{document.body.classList.remove(Vn),this._resetAdjustments(),this._scrollBar.reset(),c.trigger(this._element,Xs)})}_isAnimated(){return this._element.classList.contains(ma)}_triggerBackdropTransition(){if(c.trigger(this._element,la).defaultPrevented)return;const e=this._element.scrollHeight>document.documentElement.clientHeight,s=this._element.style.overflowY;s==="hidden"||this._element.classList.contains(Le)||(e||(this._element.style.overflowY="hidden"),this._element.classList.add(Le),this._queueCallback(()=>{this._element.classList.remove(Le),this._queueCallback(()=>{this._element.style.overflowY=s},this._dialog)},this._dialog),this._element.focus())}_adjustDialog(){const t=this._element.scrollHeight>document.documentElement.clientHeight,e=this._scrollBar.getWidth(),s=e>0;if(s&&!t){const i=H()?"paddingLeft":"paddingRight";this._element.style[i]=`${e}px`}if(!s&&t){const i=H()?"paddingRight":"paddingLeft";this._element.style[i]=`${e}px`}}_resetAdjustments(){this._element.style.paddingLeft="",this._element.style.paddingRight=""}static jQueryInterface(t,e){return this.each(function(){const s=$t.getOrCreateInstance(this,t);if(typeof t=="string"){if(typeof s[t]>"u")throw new TypeError(`No method named "${t}"`);s[t](e)}})}}c.on(document,_a,ba,function(n){const t=d.getElementFromSelector(this);["A","AREA"].includes(this.tagName)&&n.preventDefault(),c.one(t,Qs,i=>{i.defaultPrevented||c.one(t,Xs,()=>{Mt(this)&&this.focus()})});const e=d.findOne(ga);e&&$t.getInstance(e).hide(),$t.getOrCreateInstance(t).toggle(this)});_e($t);B($t);const ya="offcanvas",wa="bs.offcanvas",Q=`.${wa}`,Zs=".data-api",Oa=`load${Q}${Zs}`,Ca="Escape",Wn="show",Bn="showing",jn="hiding",Na="offcanvas-backdrop",Js=".offcanvas.show",Sa=`show${Q}`,Da=`shown${Q}`,$a=`hide${Q}`,Fn=`hidePrevented${Q}`,ti=`hidden${Q}`,La=`resize${Q}`,Ia=`click${Q}${Zs}`,Ma=`keydown.dismiss${Q}`,Pa='[data-bs-toggle="offcanvas"]',Ra={backdrop:!0,keyboard:!0,scroll:!1},xa={backdrop:"(boolean|string)",keyboard:"boolean",scroll:"boolean"};class nt extends K{constructor(t,e){super(t,e),this._isShown=!1,this._backdrop=this._initializeBackDrop(),this._focustrap=this._initializeFocusTrap(),this._addEventListeners()}static get Default(){return Ra}static get DefaultType(){return xa}static get NAME(){return ya}toggle(t){return this._isShown?this.hide():this.show(t)}show(t){if(this._isShown||c.trigger(this._element,Sa,{relatedTarget:t}).defaultPrevented)return;this._isShown=!0,this._backdrop.show(),this._config.scroll||new Ue().hide(),this._element.setAttribute("aria-modal",!0),this._element.setAttribute("role","dialog"),this._element.classList.add(Bn);const s=()=>{(!this._config.scroll||this._config.backdrop)&&this._focustrap.activate(),this._element.classList.add(Wn),this._element.classList.remove(Bn),c.trigger(this._element,Da,{relatedTarget:t})};this._queueCallback(s,this._element,!0)}hide(){if(!this._isShown||c.trigger(this._element,$a).defaultPrevented)return;this._focustrap.deactivate(),this._element.blur(),this._isShown=!1,this._element.classList.add(jn),this._backdrop.hide();const e=()=>{this._element.classList.remove(Wn,jn),this._element.removeAttribute("aria-modal"),this._element.removeAttribute("role"),this._config.scroll||new Ue().reset(),c.trigger(this._element,ti)};this._queueCallback(e,this._element,!0)}dispose(){this._backdrop.dispose(),this._focustrap.deactivate(),super.dispose()}_initializeBackDrop(){const t=()=>{if(this._config.backdrop==="static"){c.trigger(this._element,Fn);return}this.hide()},e=!!this._config.backdrop;return new Gs({className:Na,isVisible:e,isAnimated:!0,rootElement:this._element.parentNode,clickCallback:e?t:null})}_initializeFocusTrap(){return new qs({trapElement:this._element})}_addEventListeners(){c.on(this._element,Ma,t=>{if(t.key===Ca){if(this._config.keyboard){this.hide();return}c.trigger(this._element,Fn)}})}static jQueryInterface(t){return this.each(function(){const e=nt.getOrCreateInstance(this,t);if(typeof t=="string"){if(e[t]===void 0||t.startsWith("_")||t==="constructor")throw new TypeError(`No method named "${t}"`);e[t](this)}})}}c.on(document,Ia,Pa,function(n){const t=d.getElementFromSelector(this);if(["A","AREA"].includes(this.tagName)&&n.preventDefault(),et(this))return;c.one(t,ti,()=>{Mt(this)&&this.focus()});const e=d.findOne(Js);e&&e!==t&&nt.getInstance(e).hide(),nt.getOrCreateInstance(t).toggle(this)});c.on(window,Oa,()=>{for(const n of d.find(Js))nt.getOrCreateInstance(n).show()});c.on(window,La,()=>{for(const n of d.find("[aria-modal][class*=show][class*=offcanvas-]"))getComputedStyle(n).position!=="fixed"&&nt.getOrCreateInstance(n).hide()});_e(nt);B(nt);const ka=/^aria-[\w-]*$/i,ei={"*":["class","dir","id","lang","role",ka],a:["target","href","title","rel"],area:[],b:[],br:[],col:[],code:[],dd:[],div:[],dl:[],dt:[],em:[],hr:[],h1:[],h2:[],h3:[],h4:[],h5:[],h6:[],i:[],img:["src","srcset","alt","title","width","height"],li:[],ol:[],p:[],pre:[],s:[],small:[],span:[],sub:[],sup:[],strong:[],u:[],ul:[]},Va=new Set(["background","cite","href","itemtype","longdesc","poster","src","xlink:href"]),Ha=/^(?!javascript:)(?:[a-z0-9+.-]+:|[^&:/?#]*(?:[/?#]|$))/i,Wa=(n,t)=>{const e=n.nodeName.toLowerCase();return t.includes(e)?Va.has(e)?!!Ha.test(n.nodeValue):!0:t.filter(s=>s instanceof RegExp).some(s=>s.test(e))};function Ba(n,t,e){if(!n.length)return n;if(e&&typeof e=="function")return e(n);const i=new window.DOMParser().parseFromString(n,"text/html"),r=[].concat(...i.body.querySelectorAll("*"));for(const o of r){const a=o.nodeName.toLowerCase();if(!Object.keys(t).includes(a)){o.remove();continue}const l=[].concat(...o.attributes),h=[].concat(t["*"]||[],t[a]||[]);for(const u of l)Wa(u,h)||o.removeAttribute(u.nodeName)}return i.body.innerHTML}const ja="TemplateFactory",Fa={allowList:ei,content:{},extraClass:"",html:!1,sanitize:!0,sanitizeFn:null,template:"<div></div>"},Ka={allowList:"object",content:"object",extraClass:"(string|function)",html:"boolean",sanitize:"boolean",sanitizeFn:"(null|function)",template:"string"},Ya={entry:"(string|element|function|null)",selector:"(string|element)"};class Ua extends Yt{constructor(t){super(),this._config=this._getConfig(t)}static get Default(){return Fa}static get DefaultType(){return Ka}static get NAME(){return ja}getContent(){return Object.values(this._config.content).map(t=>this._resolvePossibleFunction(t)).filter(Boolean)}hasContent(){return this.getContent().length>0}changeContent(t){return this._checkContent(t),this._config.content={...this._config.content,...t},this}toHtml(){const t=document.createElement("div");t.innerHTML=this._maybeSanitize(this._config.template);for(const[i,r]of Object.entries(this._config.content))this._setContent(t,r,i);const e=t.children[0],s=this._resolvePossibleFunction(this._config.extraClass);return s&&e.classList.add(...s.split(" ")),e}_typeCheckConfig(t){super._typeCheckConfig(t),this._checkContent(t.content)}_checkContent(t){for(const[e,s]of Object.entries(t))super._typeCheckConfig({selector:e,entry:s},Ya)}_setContent(t,e,s){const i=d.findOne(s,t);if(i){if(e=this._resolvePossibleFunction(e),!e){i.remove();return}if(G(e)){this._putElementInTemplate(tt(e),i);return}if(this._config.html){i.innerHTML=this._maybeSanitize(e);return}i.textContent=e}}_maybeSanitize(t){return this._config.sanitize?Ba(t,this._config.allowList,this._config.sanitizeFn):t}_resolvePossibleFunction(t){return M(t,[void 0,this])}_putElementInTemplate(t,e){if(this._config.html){e.innerHTML="",e.append(t);return}e.textContent=t.textContent}}const za="tooltip",Ga=new Set(["sanitize","allowList","sanitizeFn"]),Ie="fade",qa="modal",se="show",Xa=".tooltip-inner",Kn=`.${qa}`,Yn="hide.bs.modal",Ht="hover",Me="focus",Pe="click",Qa="manual",Za="hide",Ja="hidden",tc="show",ec="shown",nc="inserted",sc="click",ic="focusin",rc="focusout",oc="mouseenter",ac="mouseleave",cc={AUTO:"auto",TOP:"top",RIGHT:H()?"left":"right",BOTTOM:"bottom",LEFT:H()?"right":"left"},lc={allowList:ei,animation:!0,boundary:"clippingParents",container:!1,customClass:"",delay:0,fallbackPlacements:["top","right","bottom","left"],html:!1,offset:[0,6],placement:"top",popperConfig:null,sanitize:!0,sanitizeFn:null,selector:!1,template:'<div class="tooltip" role="tooltip"><div class="tooltip-arrow"></div><div class="tooltip-inner"></div></div>',title:"",trigger:"hover focus"},uc={allowList:"object",animation:"boolean",boundary:"(string|element)",container:"(string|element|boolean)",customClass:"(string|function)",delay:"(number|object)",fallbackPlacements:"array",html:"boolean",offset:"(array|string|function)",placement:"(string|function)",popperConfig:"(null|object|function)",sanitize:"boolean",sanitizeFn:"(null|function)",selector:"(string|boolean)",template:"string",title:"(string|element|function)",trigger:"string"};class Rt extends K{constructor(t,e){if(typeof Ss>"u")throw new TypeError("Bootstrap's tooltips require Popper (https://popper.js.org/docs/v2/)");super(t,e),this._isEnabled=!0,this._timeout=0,this._isHovered=null,this._activeTrigger={},this._popper=null,this._templateFactory=null,this._newContent=null,this.tip=null,this._setListeners(),this._config.selector||this._fixTitle()}static get Default(){return lc}static get DefaultType(){return uc}static get NAME(){return za}enable(){this._isEnabled=!0}disable(){this._isEnabled=!1}toggleEnabled(){this._isEnabled=!this._isEnabled}toggle(){if(this._isEnabled){if(this._isShown()){this._leave();return}this._enter()}}dispose(){clearTimeout(this._timeout),c.off(this._element.closest(Kn),Yn,this._hideModalHandler),this._element.getAttribute("data-bs-original-title")&&this._element.setAttribute("title",this._element.getAttribute("data-bs-original-title")),this._disposePopper(),super.dispose()}show(){if(this._element.style.display==="none")throw new Error("Please use show on visible elements");if(!(this._isWithContent()&&this._isEnabled))return;const t=c.trigger(this._element,this.constructor.eventName(tc)),s=(Ls(this._element)||this._element.ownerDocument.documentElement).contains(this._element);if(t.defaultPrevented||!s)return;this._disposePopper();const i=this._getTipElement();this._element.setAttribute("aria-describedby",i.getAttribute("id"));const{container:r}=this._config;if(this._element.ownerDocument.documentElement.contains(this.tip)||(r.append(i),c.trigger(this._element,this.constructor.eventName(nc))),this._popper=this._createPopper(i),i.classList.add(se),"ontouchstart"in document.documentElement)for(const a of[].concat(...document.body.children))c.on(a,"mouseover",ue);const o=()=>{c.trigger(this._element,this.constructor.eventName(ec)),this._isHovered===!1&&this._leave(),this._isHovered=!1};this._queueCallback(o,this.tip,this._isAnimated())}hide(){if(!this._isShown()||c.trigger(this._element,this.constructor.eventName(Za)).defaultPrevented)return;if(this._getTipElement().classList.remove(se),"ontouchstart"in document.documentElement)for(const i of[].concat(...document.body.children))c.off(i,"mouseover",ue);this._activeTrigger[Pe]=!1,this._activeTrigger[Me]=!1,this._activeTrigger[Ht]=!1,this._isHovered=null;const s=()=>{this._isWithActiveTrigger()||(this._isHovered||this._disposePopper(),this._element.removeAttribute("aria-describedby"),c.trigger(this._element,this.constructor.eventName(Ja)))};this._queueCallback(s,this.tip,this._isAnimated())}update(){this._popper&&this._popper.update()}_isWithContent(){return!!this._getTitle()}_getTipElement(){return this.tip||(this.tip=this._createTipElement(this._newContent||this._getContentForTemplate())),this.tip}_createTipElement(t){const e=this._getTemplateFactory(t).toHtml();if(!e)return null;e.classList.remove(Ie,se),e.classList.add(`bs-${this.constructor.NAME}-auto`);const s=Xi(this.constructor.NAME).toString();return e.setAttribute("id",s),this._isAnimated()&&e.classList.add(Ie),e}setContent(t){this._newContent=t,this._isShown()&&(this._disposePopper(),this.show())}_getTemplateFactory(t){return this._templateFactory?this._templateFactory.changeContent(t):this._templateFactory=new Ua({...this._config,content:t,extraClass:this._resolvePossibleFunction(this._config.customClass)}),this._templateFactory}_getContentForTemplate(){return{[Xa]:this._getTitle()}}_getTitle(){return this._resolvePossibleFunction(this._config.title)||this._element.getAttribute("data-bs-original-title")}_initializeOnDelegatedTarget(t){return this.constructor.getOrCreateInstance(t.delegateTarget,this._getDelegateConfig())}_isAnimated(){return this._config.animation||this.tip&&this.tip.classList.contains(Ie)}_isShown(){return this.tip&&this.tip.classList.contains(se)}_createPopper(t){const e=M(this._config.placement,[this,t,this._element]),s=cc[e.toUpperCase()];return en(this._element,t,this._getPopperConfig(s))}_getOffset(){const{offset:t}=this._config;return typeof t=="string"?t.split(",").map(e=>Number.parseInt(e,10)):typeof t=="function"?e=>t(e,this._element):t}_resolvePossibleFunction(t){return M(t,[this._element,this._element])}_getPopperConfig(t){const e={placement:t,modifiers:[{name:"flip",options:{fallbackPlacements:this._config.fallbackPlacements}},{name:"offset",options:{offset:this._getOffset()}},{name:"preventOverflow",options:{boundary:this._config.boundary}},{name:"arrow",options:{element:`.${this.constructor.NAME}-arrow`}},{name:"preSetPlacement",enabled:!0,phase:"beforeMain",fn:s=>{this._getTipElement().setAttribute("data-popper-placement",s.state.placement)}}]};return{...e,...M(this._config.popperConfig,[void 0,e])}}_setListeners(){const t=this._config.trigger.split(" ");for(const e of t)if(e==="click")c.on(this._element,this.constructor.eventName(sc),this._config.selector,s=>{const i=this._initializeOnDelegatedTarget(s);i._activeTrigger[Pe]=!(i._isShown()&&i._activeTrigger[Pe]),i.toggle()});else if(e!==Qa){const s=e===Ht?this.constructor.eventName(oc):this.constructor.eventName(ic),i=e===Ht?this.constructor.eventName(ac):this.constructor.eventName(rc);c.on(this._element,s,this._config.selector,r=>{const o=this._initializeOnDelegatedTarget(r);o._activeTrigger[r.type==="focusin"?Me:Ht]=!0,o._enter()}),c.on(this._element,i,this._config.selector,r=>{const o=this._initializeOnDelegatedTarget(r);o._activeTrigger[r.type==="focusout"?Me:Ht]=o._element.contains(r.relatedTarget),o._leave()})}this._hideModalHandler=()=>{this._element&&this.hide()},c.on(this._element.closest(Kn),Yn,this._hideModalHandler)}_fixTitle(){const t=this._element.getAttribute("title");t&&(!this._element.getAttribute("aria-label")&&!this._element.textContent.trim()&&this._element.setAttribute("aria-label",t),this._element.setAttribute("data-bs-original-title",t),this._element.removeAttribute("title"))}_enter(){if(this._isShown()||this._isHovered){this._isHovered=!0;return}this._isHovered=!0,this._setTimeout(()=>{this._isHovered&&this.show()},this._config.delay.show)}_leave(){this._isWithActiveTrigger()||(this._isHovered=!1,this._setTimeout(()=>{this._isHovered||this.hide()},this._config.delay.hide))}_setTimeout(t,e){clearTimeout(this._timeout),this._timeout=setTimeout(t,e)}_isWithActiveTrigger(){return Object.values(this._activeTrigger).includes(!0)}_getConfig(t){const e=q.getDataAttributes(this._element);for(const s of Object.keys(e))Ga.has(s)&&delete e[s];return t={...e,...typeof t=="object"&&t?t:{}},t=this._mergeConfigObj(t),t=this._configAfterMerge(t),this._typeCheckConfig(t),t}_configAfterMerge(t){return t.container=t.container===!1?document.body:tt(t.container),typeof t.delay=="number"&&(t.delay={show:t.delay,hide:t.delay}),typeof t.title=="number"&&(t.title=t.title.toString()),typeof t.content=="number"&&(t.content=t.content.toString()),t}_getDelegateConfig(){const t={};for(const[e,s]of Object.entries(this._config))this.constructor.Default[e]!==s&&(t[e]=s);return t.selector=!1,t.trigger="manual",t}_disposePopper(){this._popper&&(this._popper.destroy(),this._popper=null),this.tip&&(this.tip.remove(),this.tip=null)}static jQueryInterface(t){return this.each(function(){const e=Rt.getOrCreateInstance(this,t);if(typeof t=="string"){if(typeof e[t]>"u")throw new TypeError(`No method named "${t}"`);e[t]()}})}}B(Rt);const hc="popover",dc=".popover-header",fc=".popover-body",pc={...Rt.Default,content:"",offset:[0,8],placement:"right",template:'<div class="popover" role="tooltip"><div class="popover-arrow"></div><h3 class="popover-header"></h3><div class="popover-body"></div></div>',trigger:"click"},_c={...Rt.DefaultType,content:"(null|string|element|function)"};class on extends Rt{static get Default(){return pc}static get DefaultType(){return _c}static get NAME(){return hc}_isWithContent(){return this._getTitle()||this._getContent()}_getContentForTemplate(){return{[dc]:this._getTitle(),[fc]:this._getContent()}}_getContent(){return this._resolvePossibleFunction(this._config.content)}static jQueryInterface(t){return this.each(function(){const e=on.getOrCreateInstance(this,t);if(typeof t=="string"){if(typeof e[t]>"u")throw new TypeError(`No method named "${t}"`);e[t]()}})}}B(on);const mc="scrollspy",gc="bs.scrollspy",an=`.${gc}`,Ec=".data-api",vc=`activate${an}`,Un=`click${an}`,bc=`load${an}${Ec}`,Ac="dropdown-item",bt="active",Tc='[data-bs-spy="scroll"]',Re="[href]",yc=".nav, .list-group",zn=".nav-link",wc=".nav-item",Oc=".list-group-item",Cc=`${zn}, ${wc} > ${zn}, ${Oc}`,Nc=".dropdown",Sc=".dropdown-toggle",Dc={offset:null,rootMargin:"0px 0px -25%",smoothScroll:!1,target:null,threshold:[.1,.5,1]},$c={offset:"(number|null)",rootMargin:"string",smoothScroll:"boolean",target:"element",threshold:"array"};class Ee extends K{constructor(t,e){super(t,e),this._targetLinks=new Map,this._observableSections=new Map,this._rootElement=getComputedStyle(this._element).overflowY==="visible"?null:this._element,this._activeTarget=null,this._observer=null,this._previousScrollData={visibleEntryTop:0,parentScrollTop:0},this.refresh()}static get Default(){return Dc}static get DefaultType(){return $c}static get NAME(){return mc}refresh(){this._initializeTargetsAndObservables(),this._maybeEnableSmoothScroll(),this._observer?this._observer.disconnect():this._observer=this._getNewObserver();for(const t of this._observableSections.values())this._observer.observe(t)}dispose(){this._observer.disconnect(),super.dispose()}_configAfterMerge(t){return t.target=tt(t.target)||document.body,t.rootMargin=t.offset?`${t.offset}px 0px -30%`:t.rootMargin,typeof t.threshold=="string"&&(t.threshold=t.threshold.split(",").map(e=>Number.parseFloat(e))),t}_maybeEnableSmoothScroll(){this._config.smoothScroll&&(c.off(this._config.target,Un),c.on(this._config.target,Un,Re,t=>{const e=this._observableSections.get(t.target.hash);if(e){t.preventDefault();const s=this._rootElement||window,i=e.offsetTop-this._element.offsetTop;if(s.scrollTo){s.scrollTo({top:i,behavior:"smooth"});return}s.scrollTop=i}}))}_getNewObserver(){const t={root:this._rootElement,threshold:this._config.threshold,rootMargin:this._config.rootMargin};return new IntersectionObserver(e=>this._observerCallback(e),t)}_observerCallback(t){const e=o=>this._targetLinks.get(`#${o.target.id}`),s=o=>{this._previousScrollData.visibleEntryTop=o.target.offsetTop,this._process(e(o))},i=(this._rootElement||document.documentElement).scrollTop,r=i>=this._previousScrollData.parentScrollTop;this._previousScrollData.parentScrollTop=i;for(const o of t){if(!o.isIntersecting){this._activeTarget=null,this._clearActiveClass(e(o));continue}const a=o.target.offsetTop>=this._previousScrollData.visibleEntryTop;if(r&&a){if(s(o),!i)return;continue}!r&&!a&&s(o)}}_initializeTargetsAndObservables(){this._targetLinks=new Map,this._observableSections=new Map;const t=d.find(Re,this._config.target);for(const e of t){if(!e.hash||et(e))continue;const s=d.findOne(decodeURI(e.hash),this._element);Mt(s)&&(this._targetLinks.set(decodeURI(e.hash),e),this._observableSections.set(e.hash,s))}}_process(t){this._activeTarget!==t&&(this._clearActiveClass(this._config.target),this._activeTarget=t,t.classList.add(bt),this._activateParents(t),c.trigger(this._element,vc,{relatedTarget:t}))}_activateParents(t){if(t.classList.contains(Ac)){d.findOne(Sc,t.closest(Nc)).classList.add(bt);return}for(const e of d.parents(t,yc))for(const s of d.prev(e,Cc))s.classList.add(bt)}_clearActiveClass(t){t.classList.remove(bt);const e=d.find(`${Re}.${bt}`,t);for(const s of e)s.classList.remove(bt)}static jQueryInterface(t){return this.each(function(){const e=Ee.getOrCreateInstance(this,t);if(typeof t=="string"){if(e[t]===void 0||t.startsWith("_")||t==="constructor")throw new TypeError(`No method named "${t}"`);e[t]()}})}}c.on(window,bc,()=>{for(const n of d.find(Tc))Ee.getOrCreateInstance(n)});B(Ee);const Lc="tab",Ic="bs.tab",gt=`.${Ic}`,Mc=`hide${gt}`,Pc=`hidden${gt}`,Rc=`show${gt}`,xc=`shown${gt}`,kc=`click${gt}`,Vc=`keydown${gt}`,Hc=`load${gt}`,Wc="ArrowLeft",Gn="ArrowRight",Bc="ArrowUp",qn="ArrowDown",xe="Home",Xn="End",dt="active",Qn="fade",ke="show",jc="dropdown",ni=".dropdown-toggle",Fc=".dropdown-menu",Ve=`:not(${ni})`,Kc='.list-group, .nav, [role="tablist"]',Yc=".nav-item, .list-group-item",Uc=`.nav-link${Ve}, .list-group-item${Ve}, [role="tab"]${Ve}`,si='[data-bs-toggle="tab"], [data-bs-toggle="pill"], [data-bs-toggle="list"]',He=`${Uc}, ${si}`,zc=`.${dt}[data-bs-toggle="tab"], .${dt}[data-bs-toggle="pill"], .${dt}[data-bs-toggle="list"]`;class Lt extends K{constructor(t){super(t),this._parent=this._element.closest(Kc),this._parent&&(this._setInitialAttributes(this._parent,this._getChildren()),c.on(this._element,Vc,e=>this._keydown(e)))}static get NAME(){return Lc}show(){const t=this._element;if(this._elemIsActive(t))return;const e=this._getActiveElem(),s=e?c.trigger(e,Mc,{relatedTarget:t}):null;c.trigger(t,Rc,{relatedTarget:e}).defaultPrevented||s&&s.defaultPrevented||(this._deactivate(e,t),this._activate(t,e))}_activate(t,e){if(!t)return;t.classList.add(dt),this._activate(d.getElementFromSelector(t));const s=()=>{if(t.getAttribute("role")!=="tab"){t.classList.add(ke);return}t.removeAttribute("tabindex"),t.setAttribute("aria-selected",!0),this._toggleDropDown(t,!0),c.trigger(t,xc,{relatedTarget:e})};this._queueCallback(s,t,t.classList.contains(Qn))}_deactivate(t,e){if(!t)return;t.classList.remove(dt),t.blur(),this._deactivate(d.getElementFromSelector(t));const s=()=>{if(t.getAttribute("role")!=="tab"){t.classList.remove(ke);return}t.setAttribute("aria-selected",!1),t.setAttribute("tabindex","-1"),this._toggleDropDown(t,!1),c.trigger(t,Pc,{relatedTarget:e})};this._queueCallback(s,t,t.classList.contains(Qn))}_keydown(t){if(![Wc,Gn,Bc,qn,xe,Xn].includes(t.key))return;t.stopPropagation(),t.preventDefault();const e=this._getChildren().filter(i=>!et(i));let s;if([xe,Xn].includes(t.key))s=e[t.key===xe?0:e.length-1];else{const i=[Gn,qn].includes(t.key);s=nn(e,t.target,i,!0)}s&&(s.focus({preventScroll:!0}),Lt.getOrCreateInstance(s).show())}_getChildren(){return d.find(He,this._parent)}_getActiveElem(){return this._getChildren().find(t=>this._elemIsActive(t))||null}_setInitialAttributes(t,e){this._setAttributeIfNotExists(t,"role","tablist");for(const s of e)this._setInitialAttributesOnChild(s)}_setInitialAttributesOnChild(t){t=this._getInnerElement(t);const e=this._elemIsActive(t),s=this._getOuterElement(t);t.setAttribute("aria-selected",e),s!==t&&this._setAttributeIfNotExists(s,"role","presentation"),e||t.setAttribute("tabindex","-1"),this._setAttributeIfNotExists(t,"role","tab"),this._setInitialAttributesOnTargetPanel(t)}_setInitialAttributesOnTargetPanel(t){const e=d.getElementFromSelector(t);e&&(this._setAttributeIfNotExists(e,"role","tabpanel"),t.id&&this._setAttributeIfNotExists(e,"aria-labelledby",`${t.id}`))}_toggleDropDown(t,e){const s=this._getOuterElement(t);if(!s.classList.contains(jc))return;const i=(r,o)=>{const a=d.findOne(r,s);a&&a.classList.toggle(o,e)};i(ni,dt),i(Fc,ke),s.setAttribute("aria-expanded",e)}_setAttributeIfNotExists(t,e,s){t.hasAttribute(e)||t.setAttribute(e,s)}_elemIsActive(t){return t.classList.contains(dt)}_getInnerElement(t){return t.matches(He)?t:d.findOne(He,t)}_getOuterElement(t){return t.closest(Yc)||t}static jQueryInterface(t){return this.each(function(){const e=Lt.getOrCreateInstance(this);if(typeof t=="string"){if(e[t]===void 0||t.startsWith("_")||t==="constructor")throw new TypeError(`No method named "${t}"`);e[t]()}})}}c.on(document,kc,si,function(n){["A","AREA"].includes(this.tagName)&&n.preventDefault(),!et(this)&&Lt.getOrCreateInstance(this).show()});c.on(window,Hc,()=>{for(const n of d.find(zc))Lt.getOrCreateInstance(n)});B(Lt);const Gc="toast",qc="bs.toast",rt=`.${qc}`,Xc=`mouseover${rt}`,Qc=`mouseout${rt}`,Zc=`focusin${rt}`,Jc=`focusout${rt}`,tl=`hide${rt}`,el=`hidden${rt}`,nl=`show${rt}`,sl=`shown${rt}`,il="fade",Zn="hide",ie="show",re="showing",rl={animation:"boolean",autohide:"boolean",delay:"number"},ol={animation:!0,autohide:!0,delay:5e3};class ve extends K{constructor(t,e){super(t,e),this._timeout=null,this._hasMouseInteraction=!1,this._hasKeyboardInteraction=!1,this._setListeners()}static get Default(){return ol}static get DefaultType(){return rl}static get NAME(){return Gc}show(){if(c.trigger(this._element,nl).defaultPrevented)return;this._clearTimeout(),this._config.animation&&this._element.classList.add(il);const e=()=>{this._element.classList.remove(re),c.trigger(this._element,sl),this._maybeScheduleHide()};this._element.classList.remove(Zn),Kt(this._element),this._element.classList.add(ie,re),this._queueCallback(e,this._element,this._config.animation)}hide(){if(!this.isShown()||c.trigger(this._element,tl).defaultPrevented)return;const e=()=>{this._element.classList.add(Zn),this._element.classList.remove(re,ie),c.trigger(this._element,el)};this._element.classList.add(re),this._queueCallback(e,this._element,this._config.animation)}dispose(){this._clearTimeout(),this.isShown()&&this._element.classList.remove(ie),super.dispose()}isShown(){return this._element.classList.contains(ie)}_maybeScheduleHide(){this._config.autohide&&(this._hasMouseInteraction||this._hasKeyboardInteraction||(this._timeout=setTimeout(()=>{this.hide()},this._config.delay)))}_onInteraction(t,e){switch(t.type){case"mouseover":case"mouseout":{this._hasMouseInteraction=e;break}case"focusin":case"focusout":{this._hasKeyboardInteraction=e;break}}if(e){this._clearTimeout();return}const s=t.relatedTarget;this._element===s||this._element.contains(s)||this._maybeScheduleHide()}_setListeners(){c.on(this._element,Xc,t=>this._onInteraction(t,!0)),c.on(this._element,Qc,t=>this._onInteraction(t,!1)),c.on(this._element,Zc,t=>this._onInteraction(t,!0)),c.on(this._element,Jc,t=>this._onInteraction(t,!1))}_clearTimeout(){clearTimeout(this._timeout),this._timeout=null}static jQueryInterface(t){return this.each(function(){const e=ve.getOrCreateInstance(this,t);if(typeof t=="string"){if(typeof e[t]>"u")throw new TypeError(`No method named "${t}"`);e[t](this)}})}}_e(ve);B(ve);export{U as D,nt as O,Lt as T,Rt as a};
|